1StepCloser's Recent Forum Activity

  • Yeah, we talked about conditional expressions here: construct.net/en/forum/construct-3/general-discussion-7/personal-performance-160459

    This test just really showcases how big of a difference this can be.

    As for ELSE, per the manual it is as you state. I use ELSE quite religiously, so this is good to know.

  • c) Avoids all the if statements by putting it into a single conditional expression when applying movement to the object, i.e. each step:

    action - set sprite x = x < 0 ? 800 : x > 800 ? 0 : x + sx*dt

    action - set sprite y = y < 0 ? 450 : y > 450 ? 0 : y + sy*dt

    These expressions allow you to 'short circuit' the evaluation, i.e. if the first part (x<0) is true then the rest of the checks will be skipped. This is what I wished the ELSE event would do...

    Hope that makes sense...

    Wow, 25k difference by switching to conditional expressions?

    I thought the else condition operates the same way, but with the downside of still having event block overhead unlike the conditional expression. This is interesting, thanks again for these experiments.

  • Thanks simstratic,

    1) I'm curious how such a pronounced difference can be possible between C3 and gamemaker if, as you state, gamemaker YYC export is compiling to entirely C++. Is this a case where JIT compiling can outperform C++? My guess is it probably has to due with the difficulties of replicating comparisons between different engines.

    2) Can you go into more detail about the different ways you set up Construct 3s experiments? (Behaviors vs Events vs conditional expressions vs conditional expression with rotation) There are some significant differences between these results that could be relevant to those of us trying to squeeze out every bit of performance possible.

    Thanks,

    1Step

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You do not have permission to view this post

  • Good point, I opted to just use the storage of the data object itself, but tokenat is another route I could take, thanks.

  • Do the instance variables of an array get stored in the AsJSON method?

    Problem: When I load an array from JSON the instance variables don't seem to load.

    Considering that the JSON only shows object type, array size, and the cell values, I'm not too surprised.

    Suggestion: Considering we have scenarios such as tile-maps where you can save the object as JSON(.AsJSON) or the tile state as JSON (.TilesJSON) is there a reason this can't be done for arrays? As of now it seems to act as a TilesJSON method of saving rather than the full object state.

    This suggestion assumes that my problem is a global occurrence and not a result of an error in my events.

  • You do not have permission to view this post

  • Understood, can you be even more specific, text/graph based game, ok now what do you want in your text/graph based game? What is the general game design/flow?

  • What exactly are you struggling with?

    Please be specific, the more specific, the more likely someone will be able to give more than general recommendations of how to better understand C3.

  • That makes sense. Probably the case.

  • Hello for those more well versed in TileJSON, I'd like to know how to read this: (particularly when the x is involved).

    {"c2tilemap":true,"width":25,"height":12,"data":"146,158,156,98,110,104,150,4x158,3x154,152,98,6x106,104,54,60,52,147,159,156,101,150,4x159,157,96,54,60,100,150,154,152,54,4x62,63,61,55,60,147,157,97,151,2x159,155,159,157,54,63,61,97,145,98,104,55,5x63,57,55,63,60,147,154,2x159,153,96,151,153,55,2x63,56,96,150,156,51,4x63,61,100,55,59,63,60,96,147,157,96,150,157,96,51,63,57,150,158,2x159,156,51,3x63,61,97,49,100,51,59,60,96,147,158,159,155,156,96,49,150,159,2x155,159,157,100,55,3x63,60,102,111,110,108,51,58,60,147,153,96,151,2x158,159,153,102,108,151,157,97,55,63,2x59,61,103,2x111,107,106,108,51,2x62,60,151,2x159,157,102,111,109,151,159,156,55,61,102,108,53,103,111,105,150,156,99,104,51,59,61,147,2x159,157,103,111,109,151,159,153,55,61,99,105,53,99,109,150,2x159,3x158,156,51,60,147,159,157,99,111,105,151,157,100,55,63,2x62,61,48,97,151,5x159,157,96,49,96,147,155,156,97,150,159,153,101,51,3x59,57,96,146,159,2x158,159,2x158,159,153,96,50,56,96,150,154,159,156,48,102,104,146,154,155,152"}

    Tagged:

  • Thanks for the input oosyrag.

1StepCloser's avatar

1StepCloser

Member since 1 Mar, 2018

Twitter
1StepCloser has 3 followers

Connect with 1StepCloser

Trophy Case

  • 6-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

10/44
How to earn trophies