GabrielIq's Recent Forum Activity

  • Its works, thank you very much.

  • Does the number of coins decreases?

    Please share your capx, it's hard to guess what could be causing the problem without it.

    Yes, it decreases.

    I did the capx again from 0, the frame change works. But not if I make a layout change, so it is blocked again and I can not use the animation until I buy it again.

    For example:

    Click on play, starts the game, get the cash coin, lose the life with the yellow box. Click on options, click on the unlock box, its turn to green and you can use the other skin. Click on play, it works.

    Now ... if you click on menu, then on options, the box is blocked again, so you have to buy it again, it does not remain permanently.

    Capx:

    ht tps://ufile. io/ymb7l

  • Hi, I'm trying to use the coins earned in the game to spend on skins.

    I want to make the selection of the skin through an animation of a layout, which changes(unlock) after having bought the skin.

    The problem is when I click on the text field, I does not change the animation of the sprite in the options layout

    Event:

    on touched / Text "buy"

    Action:

    System / substract 1 from coin

    Sprite8 / set animation "second" play from beggining

  • Sounds like it's playing constantly because you are triggering it every tick that life is 0. Use 'trigger once' if you want it to play once on dying.

    Thanks! its works! =)

  • Hi, I have all the sounds of objects working well. But, the sound that must be reproduced when dying (with duracion of 0.2 seconds) got bugged, because it sounds like a lot of metal being crushed, very different from the real sound.

    Please,someone helps me to add it correctly.

    The event:

    System/life <= 0 /

    Actions:

    Audio/ play "nolife" not looping 0 db

    System/wait 0.5 seconds

    System/ go to start

  • Correct, "time" is different from the system time.

    "time" starts from 0 when the application starts.

    Ok thanks you very much, now i learned how to implement events with time.Thanks!

  • Did you put "Set StartTime to time" at the "On Start of layout"?

    Then yes, it will be very close to 0 when you launch the game. (because "time" starts from 0)

    Every time this layout is restarted, StartTime will be updated to current time.

    It works, but this "time" its different from system time?

    Because the system time starts and does not stop. When the application starts it does not return to 0

  • Create a variable "StartTime", set it to "time" on start of the layout.

    Then change your event to this:

    System-> Compare two values -> (time-StartTime)<=10

    Its works, thanks you very much.

    But I do not understand what is happening.

    At the start of the game, the StartTime variable is being initialized together with the system time?

    how did StartTime get the restart, without setting StartTime in 0 again?

  • Hello, I have "every x seconds" events with "compare time"

    Event: Action

    System/time <= 10.0 second create object "sprite"

    every 3.0 second/

    I want to create and spam objects until the second 10 after the game was started, but in "on start of layout", the time continues, so the objects will not be generated, due to the condition that it only needs to be created until the second 10 of having started the game.

    Thanks.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks for all your answers Doptrix. I understand that my main problem was not using variables for the allocation of movement, by not using them, the pipes obtained double movement causing bugs. But thanks to your answers with comments, I understood how useful it is to combine variables with assignment events, to avoid bugs.

  • The pipes are moving too fast and disappear from the screen before they change Sine movement.

    But now I understand that you wanted to change movement at the moment the sprite is created, not 5 seconds after it was created.

    I'm guessing you want to create pipes with Horizontal movement for 5 seconds, then with Vertical movement for 5 seconds and so on?

    You can do this with a single variable, say verticalMovement=0

    > Every 5 seconds
        verticalMovement=0  -> set verticalMovement=1
        Else -> set verticalMovement=0
    
    Every 1 second ->    Create object bottomPipe
        verticalMovement=1 -> bottomPipe Set Sine movement to Vertical
    [/code:30hrbmcx]
    

    It works but it is not what I wanted. I will explain myself better:

    Being an event "every x seconds" means that it alternates the movement every x seconds from horizontal to vertical, and vertical to horizontal.

    At the beginning I said about the "compare time" event in 15 seconds,

    because I wanted when the player plays from the second 0 to the 14 had pipes with their default movement (horizontal). Then, when he reached the second 15 in the game, the pipes get the vertical movement permanently. Finally, when he's 30 seconds, the pipes get Angle movement permanently, and maybe a new movement on the 45, 60...

    This, would give a feeling that the player is advancing between levels, but in reality it will be forever in the same layout.

  • I still don't see any errors.

    Could you save your project as a single file (capx) and share it?

    Of course sir, here is it uploadfiles.io/euzfs

GabrielIq's avatar

GabrielIq

Member since 23 Dec, 2017

None one is following GabrielIq yet!

Trophy Case

  • 6-Year Club
  • Jupiter Mission Supports Gordon's mission to Jupiter
  • Email Verified

Progress

8/44
How to earn trophies