keepee's Forum Posts

  • you can do 1-variable as a neat way of making it toggle between 1 and 0 with one event:

    + Is in touch   

    buttonMusic1 | set animation frame to music

    system       | set music to 1-music

  • playback rate !

  • works best when you set velocity directly

    click+drag

    https://dl.dropboxusercontent.com/u/53374990/Forum/PhysDrag.capx

  • uh..sorry, i see now you are only using the family as a way to differentiate from the created wall object

    In which case, your events in the original post actually look correct, so are you sure it's not a problem with the way you position it after creation? You could check if the wall have been created or not by using a text object to display wall.count

    if they're not being created, it could still be a problem with the AreaSelector, or ZoneSelector... you can check these with a debug text object too.

    If all that stuff is fine, try reshuffling the conditions so the 'For each' is before the variable check, it shouldn't make a difference, but I remember having to do this in some cases

    like:

    +On start of layout

    +Zones | ZoneNumber = ZoneSelector

    +For each Walls                     

    +Walls | AreaType = AreaSelector      >Create object wall etc

  • The purpose of the 'pick object instance with UID' was to pick the same object as the family you had filtered..

    now you've put 'for each object', and then you try and pick an object with the UID of an unspecified family..

    I think it'd help if I understand the context better..

    now that i look at it more carefully..

    is 'wall' a tiledbg within the 'walls' family? or is it a sprite that isn't part of the family?

    also what's this for? are you swapping out editor placeholders for actual objects on start up?

  • sqiddster it's never really worked for me, there's always inconsistency with framerate

  • when you filter/pick instances of a family, it doesn't automatically filter the individual objects that may or may not be in that family.

    (To avoid confusion I'll refer to 'Walls' as 'Family' and 'Wall' as 'object')

    So you may be correctly picking what Family instance.. but it's still ambiguous as to what Object instance you want..

    hope that makes sense..

    a way to pick the same object as the family you've alread picked is, for example

    For each Family

       Object | Pick instance with UID: Family.UID

  • Out of curiosity I found the original shockwave game.. and I ended up playing it all day..

    The levels are kept interesting with variation and it forces you to experiment with a lot of different tactics...

    cool game

  • faamorim

    can't add an else after a trigger

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • 'is any key pressed' is a trigger and so it makes sense that you can't invert that

    however, you would be able to invert 'is any key down'...

    ..if it existed.

    Not sure why it doesn't.

    anyway, just to expand on method

    if the variable is local and non static

    +var = 0

    +on any key pressed > set var = 1

    then you don't need to keep adding or subtracting cos the var gets reset to 0 every tick anyway

  • NaN stands for 'Not a Number'

    If it's something that works on preview, but breaks on export it could be a bug.

    But it sounds like it could be fixed anyway..

    I don't know your context exactly but I think rounds is being set to a string from however your saving it.

    Can you convert it to an Integer when the value is retrieved? using Int(value)

  • what was the action that followed?

    I suspect that the condition was being met fine, just the action wasn't right..

  • the efficiency (in this case) is most likely negligible so you should do what reads best :)

  • Just as a note to that .cap i posted.. I'm doing things like setting all the bodies to stop their control every tick and then just overriding the selected one in the very next event.. that kind of stuff is kinda the lazy/'brute force' way to do it and is probably not wise in some cases.

    anyway, no worries, nice d.a gallery by the way- skilled in different styles, varied, interesting.

    Good luck with the game etc

  • I recommend reading the manual page for the Gamepad object..

    A condition and expression combination that would be useful is:

    Gamepad | on Gamepad(0) any button pressed   >   [variable] to Gamepad.LastButton(0)

    so for example you can have a variable that stores the button ID for jumping, called 'JumpID' or something.

    and for a custom controls screen it can prompt you for each button, one by one

    a text object could read "press key for Jump"

    and then have the event

    Gamepad | on Gamepad(0) any button pressed > set JumpID to Gamepad.LastButton(0)

    and then set the text object to read "press key for Attack"

    Gamepad | on Gamepad(0) any button pressed > set AttackID to Gamepad.LastButton(0)

    etc.

    and then, to check if the jump button is pressed, you can use the condition

    Gamepad | on Gamepad(0) button JumpID pressed/down