Whiteclaws's Recent Forum Activity

  • Hello there ,

    I'm looking for someway to trigger a list of actions (for that instance) each time a condition applies to that instance but only once

    Here's what I got ...

    I have a Block Object , and a (imaginary) grid where the block snaps ... and each time an instance snaps ( I have the snapping condition , I need to trigger some events for that instance( once )

    So , Bigger explanation

    I need to trigger some actions (for that instance) once each time an instance meets a condition , taking note that I already have that condition

    <img src="https://dl.dropboxusercontent.com/u/89532891/Everything/Images/Example.png" border="0" />

    Distance_to_snap = 0.3

    unfortunately , it only works when all instances move and snap

    So Briefly,

    When an instance snaps , I need to pick it and trigger some events (ONCE) for that instance , what conditions could do the trick ?

    Cheers !

  • You could create an invisible object on each wall (1-pixel bigger than the wall on the side of the enemies ) that , on collision with enemy while they are running away from the player , set the enemies platform disabled , and the wall width is set to wall width + enemy width , and when the player is far enough , set the wall to it's initial width and set the enemies platform enabled

    I hope this give you an idea !

  • Bump

  • You could add the solid behavior to them

    Or , you could disable platform behavior when overlapping and re-enable it when not overlapping

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hello ,

    I'm working on a grid-based game

    and sometimes , I create some instances directly on others ...

    I would like to delete instances DIRECTLY at the bottom , let's take an example

    I have an instance (1) and I create another instance ontop of the other one (2)

    (2) is deletable when

    (1)X and Y = (2)X and Y

    and not otherwise

    But I may have other instances scattered on the screen

    so I need to pick (1) -Bottom Instance- and delete it even if there's a third or four instance , taking note of the rule above

    How would I go about picking 1 and other instances that follow the rule ?

    Thanks for reading and have a nice day

  • Whiteclaws

    Making worthless posts since 2013

  • Why not do this ?

    For each element

    • If overlapping a block

    -- Destroy

  • Works for me ... too

  • Did you make them ?

    They are actually pretty amazing !

  • To be honest , and if possible , I'm looking for a techique that doesn't involve variable usage

  • shinkan , just a random one

  • Yeah , I was thinking of suggesting this too , but for now , you'll need to stick to an X,Y array or 2 variables

    Ashley , what do you think ?

Whiteclaws's avatar

Whiteclaws

Member since 14 Feb, 2011

None one is following Whiteclaws yet!

Trophy Case

  • 13-Year Club
  • x4
    Coach One of your tutorials has over 1,000 readers
  • Email Verified

Progress

15/44
How to earn trophies