0 Favourites

How do I Increase speed of an object over time?

  • Hey Devs,

    I am curious on how you would increase bullets speed if score is = 5?

    ex: if score = 5 then increase bullet speed to 500

    Not only am I curious as to that but how would I increase the bullet speed for every +5 scored?

    ex: for every 5 score increase bullet speed by 100

    I know the basics but when it comes to continuously increasing by increments I get super lost.

    Any help would be great!

    Thanks!

  • Construct 3

    Buy Construct 3

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

    Buy Now Construct 3 users don't see these ads
  • For the first question it's pretty simple, just add a condition to check for when the score is 5 then add an action to set the bullet speed to 500.

    For adding 100 to the speed every 5 seconds you could make an every tick event with an action to set the speed with the expression:

    int(score/5)*100+initial_speed

    Where initial_speed is whatever the bullet speed started at, or rather what speed you want it to start at.

  • For the first question it's pretty simple, just add a condition to check for when the score is 5 then add an action to set the bullet speed to 500.

    For adding 100 to the speed every 5 seconds you could make an every tick event with an action to set the speed with the expression:

    int(score/5)*100+initial_speed

    Where initial_speed is whatever the bullet speed started at, or rather what speed you want it to start at.

    That worked and it helped me with a few more of my other questions....

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)
Similar Topics Posts Views Last Post
Unread hot topic
234 61,264
DARKSETH's avatar
DARKSETH
Unread hot topic
99 10,159
karshinkoff's avatar
karshinkoff
Unread hot topic
167 14,518
DMT2005's avatar
DMT2005