Power UP making help

ANISH101

  • Posts: 7
Hey, I was wondering how I can make a power up that increases jump height or speed... is that possible and if so how can I do it.

Also how do I add background music? (everytime i try the behaviour seems to not play the music :-( )

Any help would be appreciated :) TY in advance!

Sunflower

  • Posts: 591
First, if you want to have modifiable speed or jump height, you need to make an Attribute for these.

Then, when you collect power up, all you need to do is something like:
for [Powered Up Actor], set [_JumpHeight] to [100] for behavior [Jump]
for [Powered Up Actor], set [_Speed] to [16] for behavior [Run]
These blocks can be found in Messaging >> For Actor.

ANISH101

  • Posts: 7
Umm... could you explain in a more noob friendly way please... I made the attribute but I dunno how to get the actual powerup to do the powering or how to place it... also any help with getting background music wud be nice ;) but TY anyway!

jamesvhyde

  • Posts: 25
The Action Adventure game template has a power up--the sword. Before you get the sword, nothing happens when you hit the attack button. After, the sword appears. You can look at this game to see how the logic works. Maybe it will give you some ideas.

Edit:
I made a quick change to the Action Adventure to increase the player's speed when the sword is picked up. See the attached screenshot. This is not the best way to do it, but it was the quickest. I changed the "Collectable Item Pickup" behavior so that it modified the "Top Speed" attribute of the "4 Way Movement" behavior for the player actor when the sword is picked up.

« Last Edit: August 09, 2011, 04:26:54 pm by jamesvhyde »