ramones's Forum Posts

  • If anyone else comes across this problem and isn't sure where one event chain ends and another begins (I wasn't), it's basically an entirely new event.

    http://www.scirra.com/forum/r102-breaking-change-questions_topic56576_post352637.html#352637

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I wish it had intelligent auto-complete but there's always the expressions window that pops up when you're entering values. Double-click on your webstorage object and it shows all the available expressions.

    https://www.scirra.com/manual/59/expressions-panel

  • Open the sprite in the image editor, click the bottom button on the left and you can edit the size and shape of the collision box.

  • The way you had it you'd need a trigger once condition in there:

    System: P2Fired = 1

    System: Trigger once

       -> System: Wait 0.7 seconds

       -> System: Set P2Fired to 0

    otherwise that event is running every tick for 0.7 seconds while P2Fired = 1. Then after 0.7 seconds all the delayed actions will run, setting P2Fired back to 0 for the next 0.7 seconds.

  • I had a go. This isn't actually the effect I was going for but I think it's kind of cool. This is very much a work in progress (messy event sheet) but it might give you ideas.

    lightningTest.capx (r114)

    If you just want a single bolt, disable event 8.

  • I see what you mean. Jumpthru doesn't work well at all when the sprite is at an angle. What about giving them solid behavior and toggling it on and off depending on if the player is on the stairs or not. Works okay in this simple example apart from the player hopping a bit when he runs through the stairs from behind.

    slopeJumpthruWorkaround.capx (r114)

  • Web storage is simple. You're just storing pairs of keys and value. The keys are strings, the values are strings or numbers.

    For example, to store the player score:

    WebStorage: Set local key "score" to 500

    Then when you want to get that value from web storage you do:

    Set variable to WebStorage.LocalValue("score")

    You can easily save an entire array or dictionary to webstorage by saving it as JSON.

    WebStorage: Set local key "savedArray" to Array.AsJSON

    Array: Load from JSON string WebStorage.LocalValue("savedArray")

    For your tree I suppose you could do something like

    System: Every x seconds

    System: Compare two values floor(random(100)) < n

       -> Tree: Subtract floor(random(a, b)) from var

       

    (Every x seconds there is a n% chance to subtract a value from a to b-1)

  • Any use? touchGame_edit.capx (r114)

  • The easier way would be to put everything but the player on it's own layer and just rotate the layer when the player turns.

  • You have 'Circle: Spawn Circle' which makes the first Circle spawn another Circle at it's postion. You want 'Square: Spawn Circle'. That will make the Square spawn a Circle at the Square's position.

  • Nice game. I had some bug with kamikaze attacks. The AI got a kamikaze attack but it gave me control of the red ships so I had to launch the AI's attack myself. That happened me twice.

    Keyboard controls don't work for me in Firefox. Arrow keys just cause the web page to scroll. Works ok in Chrome. I know other people have had that issue with Kongregate games - not sure what the solution is.

    Other than that- cool game mechanics and it's fun to play.

  • Simple capx:

    createLoopGroup.capx (r114) Objects created in loop can't be picked in next event.

    Strangely enough if you add a blank event between 3 and 4 it works.

    Put a blank event after event 2 in Astrosus's capx and it works.

  • Change

    tokenAt(AJAX.LastData, ComboBoxListBox.IID, "|")

    to

    tokenAt(AJAX.LastData, loopindex, "|")

    The combo box IID will always be the same value - 0, so the tokenAt expression only returns the first token.

  • Since all of those events are in a group, the objects are not fully created until after the end of the group, therefore the events cannot pick the created objects.

    Arima r103.2 release notes:

    Separate triggers, and events in groups, are now treated as 'top level' when picking newly created objects.

    And it works but not when the object is created inside a loop. Then it can't be picked until the end of the group.

    This works. The sprite can be picked and it's angle is set to 45.

    <img src="https://dl.dropbox.com/u/8367729/construct/pics/createLoopGroup1.png" border="0" />

    And this doesn't. The angle isn't set. Only difference is the loop condition.

    <img src="https://dl.dropbox.com/u/8367729/construct/pics/createLoopGroup2.png" border="0" />

  • May be a bug with objects created/destroyed inside a loop within a group. Look at this:

    I have 3 sprites.

    <img src="https://dl.dropbox.com/u/8367729/construct/pics/destroyLoopGroup1.png" border="0">

    The sprites are destroyed in event 2 and in event 3 Sprite.Count = 0.

    <img src="https://dl.dropbox.com/u/8367729/construct/pics/destroyLoopGroup2.png" border="0">

    Here the sprites are destroyed inside a loop and in event 3 Sprite.Count = 3. The sprites aren't destroyed until the end of the group.

    destroyLoopGroup.capx