Create explosion on platform Behavior

Get help using Construct 2

Post » Thu Sep 27, 2012 11:15 pm

I'm working on a platform game and I want to create an explosion on the game. When the bomb explodes, it should affect the player [impact].

I know it's pretty easy to do with physics but I don't want to add it to the platform game.

B
85
S
31
G
23
Posts: 384
Reputation: 19,092

Post » Thu Sep 27, 2012 11:33 pm

https://dl.dropbox.com/u/41931267/Platform%20Explosion.capx

Here's an example. Click to make an explosions. The strength of the effect on the player is proportional to the distance from the explosion.
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Thu Sep 27, 2012 11:52 pm

@sqiddster

It's very close based on what I need. The only issue is that the player stop moving left or right after a few seconds even thought it's moving up or down.
B
85
S
31
G
23
Posts: 384
Reputation: 19,092

Post » Fri Sep 28, 2012 12:31 am

That's a side effect of the deceleration/max speed of the platform behavior. You could add an instance variable, 'exploded', or something, which adjusts these values, and returns them to normal when the player is onground.
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Fri Sep 28, 2012 12:38 am

In the game if the player steps on the mine and explodes, it dies.
I don't think it will be a problem when the player hits the ground again.

Tthanks for the sample, it helps a lot!
B
85
S
31
G
23
Posts: 384
Reputation: 19,092

Post » Fri Sep 28, 2012 12:42 am

OK, sounds good! In that case, you won't even need the instance variables. Just adjust the values on explosion.
B
90
S
30
G
24
Posts: 3,189
Reputation: 32,400

Post » Sun Sep 30, 2012 12:52 am

Let's suppose there is a mine on the ground instead of the click of the mouse. Which coordinates should I change to the make it work?
B
85
S
31
G
23
Posts: 384
Reputation: 19,092


Return to How do I....?

Who is online

Users browsing this forum: Callan S, gamecorpstudio, getplay, Kagubro and 24 guests