# How do I speed up falling objects in increments?

Get help using Construct 2

### » Fri May 30, 2014 5:24 pm

I'm making a "catch stuff as it falls game" and I was wondering how I could speed the falling up say every 250 points or so in an attempt to make the game harder as each bonus minute is rewarded.
B
10
S
1
Posts: 69
Reputation: 641

### » Sun Jun 01, 2014 6:21 am

The way I have done this is in the past is to make the falling objects have a 'bullet' behaviour attatched. Set up all the parameters so that the objects fall the way / direction you want them to, but under the 'speed' or parameter, make a variable called 'Speed'. (So under the events, have an event that is something like "On 'object to catch' created" set speed to "speed". That way, you can manipulate the speed at run time through algorithms that are fairly simple, such as "If score > 250, speed = 250"

If you were going to event that, (and assuming your score is a global var), you'd make an event under system;
"compare variable" and define what range of score you want for a particular speed (e.g between 250 and 500), and then have that even set the variable 'speed' to the speed you would like.

Hope that helps and isn't too garbled!
B
4
Posts: 14
Reputation: 243

### » Sun Jun 01, 2014 12:58 pm

Said it all! I don't think I would do in any other way.
B
24
S
4
G
1
Posts: 177
Reputation: 1,827

### » Sun Jun 01, 2014 2:54 pm

There's an easier way to do it, you just need a Points variable to store your score, and your Bullet object

Then, you can just;
Bullet - Set speed to (floor( Points / 250 ) + 1) * 100 (Or any other speed increment)
B
43
S
18
G
17
Posts: 2,247
Reputation: 17,556

### » Mon Jun 02, 2014 4:37 pm

Pandemonium wrote:The way I have done this is in the past is to make the falling objects have a 'bullet' behaviour attatched. Set up all the parameters so that the objects fall the way / direction you want them to, but under the 'speed' or parameter, make a variable called 'Speed'. (So under the events, have an event that is something like "On 'object to catch' created" set speed to "speed". That way, you can manipulate the speed at run time through algorithms that are fairly simple, such as "If score > 250, speed = 250"

If you were going to event that, (and assuming your score is a global var), you'd make an event under system;
"compare variable" and define what range of score you want for a particular speed (e.g between 250 and 500), and then have that even set the variable 'speed' to the speed you would like.

Hope that helps and isn't too garbled!

It's not too garbled but I do get a little bit of a deer in headlights without visuals XD.
B
10
S
1
Posts: 69
Reputation: 641

### » Sun Jun 08, 2014 5:02 am

Okay! I'll knock something up and upload a pic, it may take a few days though before I can get it up here.

Edit: Also, as a point of interest, judging by your profile picture, is it safe to assume you're an RPG Maker user?
B
4
Posts: 14
Reputation: 243

### » Sun Jun 08, 2014 9:31 pm

Thanks, in the meantime I've been able to cobble something together using the gravity and the equation Whiteclaws suggested and it's working so far but thanks for the help.

And why yes I do use RPG Maker. I'm making a game called Mary Sue Busters. It originally was a demo I made for a final in my game studies class and I'm working on a complete version.
B
10
S
1
Posts: 69
Reputation: 641