how to make a power up in my game

I am trying to make a power up that appears every 10 or so seconds and disappears when the character walks over it or in 5 seconds. The power up will give the character extra speed for 10 seconds!

Check this out, just open the creator and copy the behaviors you see!

http://flowlab.io/game/view/76150

I did that and it won’t work is it ok that i put everything in a bundle @leonnighte here is my game http://www.flowlab.io/game/play/74741

And how did u make like a shadow behind your character @leonknighte

You need to make the player a rectangle, not circle. The barrier is huge when it’s a circle and you touch spikes that aren’t even near you.

oh thanks @MhxAir

That’s just a speed effect, copy your character and create another object with your characters sprite. Then make it so when your character collides with the power-up, send a message to your character to switch on the switch connected to emit behavior. Have the left and right key triggers connect to start the switch to trigger the emitter. Then when the power-up wears off, have a timer turn off that switch.

ok but the power up doesn’t work @leonknighte

Strange. I’ll look at your game and see what is the problem.

I checked your game from the link before, your still missing the mailbox trigger (for the speed message) to turn off the original speed and to turn on the new speed. Also the message from the power-up needs to be selected to be sent to the player.

Here’s the link to the speed boost example again. Check the behaviors of the player, the bundle labeled speed boost should be looked at.

http://flowlab.io/game/view/76150

that link was old i changed the mailbox but it still won’t work. http://www.flowlab.io/game/play/74741

i used the same principal in a different way in my Top-view game Temple explorer I made a walk and a sprint. however my trail is always to the left or right of the character. how do i fix it? http://flowlab.io/game/view/76776

To answer jngthree, you need to extract the players x and y position with the trail. Just use the once trigger in the behaviors of the trail and then use the extractor x and y, choose to extract the hero’s properties, then link those to a position property.

As for ztg5, your missing the mailbox trigger that contains the same word, “Speed” as the message from the power-up. You need this to link this to switches that would turn them on (One switch for left arrow key and one for the right arrow key). The switches would then connect to numbers, higher values then your original speed, and have those connected to the x velocity. Then connect the x velocity to a timer trigger, which then turns off the switches the “Speed” mailbox turned on.

Oh, this must be part of your Player behavior.

jee thanks

@leonknighte can u give me a picture to follow

How do I make a screen shot?

for mac… hold down command and shift and press 3 @leonknighte