mindfaQ's Forum Posts

  • s000.tinyupload.com/index.php

    maybe this helps

    array.at(x) will get you the amount of stars of lvl x+1.

  • create object at x = scrollx and y = scrolly

  • set up a vertical cursor variable, generate the weapon sprites similar to the cloth sprites (give them an id variable, give each graphic a separate frame), then in the keyboardevents:

    on x pressed:

    -verticalcursor = 0

    -- the current events as subevent

    -verticalcursor = 1

    -- the current events as subevents, but change clothes to weapons and clotharray to weaponarray

    Or just continue to work with the cursorarray and cloth-sprite.

  • Yes, same problem here, win7 64bit

  • The official behaviours that involve movement already incorporate dt.

  • s000.tinyupload.com/file_uploaded.php

    Feel free to ask questions

    You will probably need a function to swap items, when you get more slots. Which item is in which slot could be saved in the array, so it is not a huge problem to expand it (I think).

  • Since I adjusted the variable to 0 to the left-most sprite6, it displays and the other ones have the value 1, it displays <varies>. Set it to 1 for all sprite6s except the first one and you should be fine. If you create a new Sprite6, you might need to define canspawn1 to the specific value you need at that place, but I don't think you need new ones, as you can just set them as invisible.

  • This should do it:

    s000.tinyupload.com/index.php

    2 new instance variables:

    canspawn1: default is 1, set it to 0 for your first sprite where you dont want a 1 to spawn

    occupied: default is 0, set it to 1 after it spawned a sprite

    If you want to repeat the spawning, you could put all this sprite generation into a function and at the start pick all sprite6 and set occupied to 0 again to free them up. It could look like this: s000.tinyupload.com/index.php

  • instance variables, for example a switch could have "doorid" as variable. Set it to the UID of the door you want it to open.

    Then upon the event of the door to open

    door-open-condition

    door pick by unique ID = switch.doorid: open door

    this way only the door with the fitting ID is opened.

    If you need one switch to open more doors, use an array or give doors a specific switchID and then instead of picking by UID, pick doors by comparison door.switchid = switch.doorid

    Edit: if you dislike using the UID, use the instance variables on both door and switch to connect them like I explained in the last part

  • Nope, on layout restart set score to pointsatcheckpoint.

    If you want to prevent abuse, make it this way:

    player overlapping checkpoint AND checkpointnumber < checkpointnumber : set pointsatcheckpoint to score

    add 1 to checkpointnumber

    this way it only happens the first time you hit it

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Oh I didn't know about the container function. Interesting, new thing learned.

  • And the correct position is the one they are created in from left to right? So if it spawns 5 1 2 3 4, you would need to order those cards to 5 1 2 3 4?

    How about changing the correct sequence to something else (like a second random generation of 5 invisible sprites on the same positions and later on check if 5 is overlapping invisible 5 and so on)

  • I can't find a problem with the code. Are there even any events that spawn player? Maybe they are interfering somehow.

  • use a global variable "pointsatcheckpoint" and set it when you reach the checkpoint. Then when you revive, set the score to pointsatcheckpoint.

  • Hmmm, wouldn't that mean you would need to conceal either the random cards at top (so that you don't see their number) or the required sequence on the bottom?

    Like give each sprite a second frame that shows the same card back for every card, set animation speed to 0. Then when the card is laid down, set frame to 1. Then when you want the number of the card to be revealed, for example when it is successfully laid on the correct number, set frame number to 0.