Danwood's Forum Posts

  • Problem Description

    Either "For Each" or "Spawn Another Object" (or even save/load) doesn't work properly for few seconds, after Save -> Refresh -> Load

    Attach a Capx

    See attached Capx

    Description of Capx

    There are 6 RED sprites overlapping each a BLACK sprite.

    Every tick, each RED overlapping BLACK (all 6) spawns an arrow, and set its angle toward the BLACK the RED is overlapping (the arrows fades out in 0.1 sec to avoid garbage)

    Normally, each arrow points to the BLACK overlapping "its own" RED (from where it was originated), but if you follow the steps below, something STRANGE happens.

    Steps to Reproduce Bug

      1 - Save (S) 2 - Refresh the page (or close/run preview) 3 - Load the previous save (L)

    Observed Result

    1 - Check the Arrows, for few seconds after loading, they are NOT pointing EACH to the BLACK picked by the condition as they should, but to a single BLACK.

    2 - Wait few seconds and the bug disappears (arrows go back to pointing each to its proper BLACK), this doesn't always happen, i don't know why.

    Expected Result

    Arrows should always point to each black picked by the condition, but this doesn't happen if you save, refresh and load.

    This bug has awful consequences in my game! (plz fix it Ash i luv you :3)

    Affected Browsers

    • Chrome: YES
    • FireFox: YES
    • Internet Explorer: NOT TESTED

    Operating System and Service Pack

    Win7 64 Ultimate SP1

    Construct 2 Version ID

    r191 (but i presume it did happen in 190 as well)

  • Changing opacity won't create any extra render cell work (it's not moving or Z ordering), but changing the angle counts as moving.

    Thank you Ashley, that answered my question!

  • Danwood

    For more info on render cells, Ashley has a new, in depth blog post:

    https://www.scirra.com/blog/ashley/14/h ... cells-work

    Yep i've checked it, my question regards this part:

    When to avoid it?

    Any layers with lots of changing objects - either creating, destroying, moving or changing Z order - will probably incur more extra work than is saved by the cheap viewport checks

    Does it include opacity/angle sine? If i have 1000 objects iwth angle or opacity sine, does it count as trade-off for cell rendering?

  • As ever the answer depends on measurements. If you can measure an improvement, then yes!

    Ideally you would move any moving objects to their own layer, so the one using render cells is truly static.

    Thanks, i made some mesurements and it doesn't seem to differ much (it is hard to measure though, since it fluctuates a lot).

    So sine opacity and angle will also make the object update render cell? In that case, i will move the "sine-ing" objects in another layer as you suggested.

  • Hey Ashley, thanks for the new update, you always deliver awesome improvements!

    I have a huge layer with hundred (and sometimes thousands) objects.

    Those objects are static, they only update variables once every 48 sec, but they have Sine (angle and opacity) happening from time to time for long periods of time.

    Is it convenient to enable the new Render cell option from r191? I'm testing CPU usage with the debugger, but still can't find any difference. I just need to be sue i'm using the right criteria to enable the new feature after reading yur article on cell rendering.

  • Thanks, it was not necessary since behaviours already use it

  • I guess this has been asked before, but i didn't find anything confirmating it as i need to sleep tonight, so i'll ask here, hope it won't make you crazy

    Do i need to add *dt to the Bullet Speed calculation (which changes during the game via events) to make it framerate independent? In that case, how? just adding *dt, or something like (number*60)*dt?

  • Is this problem the same that forced me to do this: (?)

    There ar enaimals on the layout, one of them spawn "dung" using "spawn another object", and then dung sets it's "dry" variable to 100

    In order to avoid the game picking ALL the dung on the layout and set the variable to 100 for all, instead of only the one which is just created, i need to add another event "pick dung nearest to animal".

    When using the "create object" action, i dont need the other event, and it just picks the dung just created.

  • I've noticed this as well

  • Thanks folks, TiAm you're not a n00b anymore

  • I'll try to explain the question the best i can (sorry for the english!)

    I have Wolves and Sheeps

    Wolf LoS considers Sheep as obstacle, so he won't see behind her.

    BUT

    Wolf also attacks sheep if she is in LoS, and since she's an obstacle herself, she will never be in LoS.

    Is there a way to allow LoS obstacle to be seen by the very same LoS behaviour they're an obstacle to?

  • All those steps to get the 0.10.5 version?

    just download it from here: https://github.com/rogerwang/node-webki ... d-versions

    N00b!

  • Totally agree with ASHLEY. Oh and thanks for solving the Sine bug i reported for the next Beta, you are a boss

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I have try the new node-webkit v0.11.1 , still not fix the problem

    Apparently it's a Chrome issue, not directly caused by node-webkit

  • but hopefully it means a fix is on the way.

    YES PLEASE, YES PLEASE, YESSS PLEEEEEEESSSSSSSSS