piranha305's Recent Forum Activity

  • This is a proposal to be able to interpolate C3 expressions into the javascript snippets that are created inside the event sheet. I am not really sure what the syntax would look like, but i would guess it be something like this

    (assume we have 2 sprite object in the event sheet sprite:player and sprite:enemy)

    On sprite:player collision with sprite:enemy => *js* let variable = {{Player.8Direction.VectorX}}

    or

    On sprite:player collision with sprite:enemy => *js* let variable = @(Player.8Direction.VectorX)

    in the above example @(Player.8Direction.VectorX) / {{Player.8Direction.VectorX}} is replaced with the value from the event sheet. the event sheet picks the player that has just collided with the enemy and runs the java script, when the java script code resolves the interpolation, it will used the picked instances and grab the players 8direction vector x property and store in the javascript variable.

    something like this allows for fluid interaction with the event sheet and the javascript modules. as of now it's pretty easy to send data from javascript to the event sheet via function call, but there is no way to send data from the event sheet to your javascript.

    the draw back to this approach is that the syntax used is not real javascript. and it could confuse people who are not familiar with the concept of interpolation or javascript. it is also really complicated to implement and might hinder perf if you have to evaluate the js code every time it runs.

    this is just one solution though? any solution to this would be great. maybe instead of the interpolation thing there could be a plugin that you can use to interface and pass data to the javascript code. or specific system actions

    as a work around i have been using a proxy object, pretty much one invisible object with a few instances variables that i pull into the js could at the start, but this is limited to just those instance variables on that object.

  • when you put java scripts in event behind the scenes it creates a async function that has the runtime injected, so it should be there if calling function from events

  • Yeah i figured, just wondering if it was on the road map with the new scripting feature, at the moment you can use c3_callFunction to interface with c3 for all of the use cases i have encountered so far. but having some of those interfaces exposed will make it way cleaner, since you wont have to define a separate function in events. this is by far one of the most exciting features added!!

  • Will there be plans in the future to expose plugin interface to the scripting API? construct.net/en/make-games/manuals/addon-sdk/runtime-reference/addon-interfaces/tilemap

    stuff like the above? Tilemap, Array, Dictionary and many more?

    at the moment the instance interface does not expose plugin specific property.

  • I think the need for sub folder is clearly defined in the feature request that was mentioned. if you have alot of different family, it's a quality of life improvement, to not have all the family fill up your plugin selection screen, it should help in finding the families as well if you have like 20+ families. and i agree with just having folder to help organize all your families, having nested families/ family inheritance on the other hand, i don't really see a point in that, because you can use family composition to achieve the same thing in a clearer way.

  • i think this answers one of my questions

  • I think Ashley mentioned that dynamic imports are supported using the await keyword. https://developers.google.com/web/updates/2017/11/dynamic-import, but this won't support older javascript libraries?

  • but in your example in your top level weapon folder did you want to give them basic weapon properties (instance variable/behavior)

    then as you drill down be more specific for each weapon family?

    Weapon --> (firerate, bulletSprite, range)

    Shotgun (numberOfBulletsPerShot)

    Rilfe (fireMode (burst or auto) )

    In this case Shot Gun and Rifle still have firerate, bulletSprite, and range

    This impact how family behave as opposed to just grouping them in a folder? the above is more like inheritance, even though it can also be accomplished using family composition?

    But they both behave differently

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • How are script files attached to the project? are they embedded in the runtime? or are they added as script tags to the head? will these files get minified on export (if you choose the option to minify)?

    Tagged:

  • Do you just want a folder where you can store your families with no impact to how they behave?

    or are you asking for being able to nest families and having them behave like inheritance?

    like sub families?

  • thanks have no idea how i missed that

  • Could we get a way to edit this sub header? or website? I Checked under Personal Information and there was no setting for this.

    Tagged:

piranha305's avatar

piranha305

Early Adopter

Member since 26 Apr, 2016

Twitter
piranha305 has 34 followers

Connect with piranha305

Trophy Case

  • 8-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Forum Contributor Made 100 posts in the forums
  • x5
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • x4
    Quick Draw First 5 people to up-vote a new Construct 3 release
  • x2
    Lightning Draw First person to up-vote a new Construct 3 release
  • Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

18/44
How to earn trophies