Code stops working if Create action is outside loop block

0 favourites
  • 3 posts
From the Asset Store
Weather Sounds contains 132 sounds from them 64 seamless loops
  • Hello,

    I was following this great Rope tutorial by bartalluyn, and I made (almost)exactly the same steps, but my code didn't work.

    I found the error(!?), but still do not understand why.

    This works:

    This doesn't work (The rope/wire links are created, but not linked together, so they all fall down immediately):

    The only difference is that I moved the "Create" from the loop's block to a sub-block.

    Generally, the code works if the steps are in a Sub-block UNDER the Create block, not adjacent to it.

    I thought that since the steps are below the create, they will be executed after it. Or maybe the problem is related to how Picking works (i.e. the next steps cannot pick the recently created wire)?

    Why?

    Thanks!

  • I think the actions shown there would still work but the events below wouldn't be able to pick the sprite because of an availability thing. I'm guessing those 3 actions work and it breaks with the event conditions loopindex=0 and below?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I think the actions shown there would still work but the events below wouldn't be able to pick the sprite because of an availability thing. I'm guessing those 3 actions work and it breaks with the event conditions loopindex=0 and below?

    Yes.

    I thought they are all in the same sub-block so they should see the created object.

    But I found that to see the created object, the actions need to be in another sub-block under the Create action.

    I.e: Adjacent blocks won't see it. Only children blocks will see it.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)