Sir Spacebar Posted June 14, 2014 Report Share Posted June 14, 2014 So basically I have this mini-boost feature that activates when your xspeed reaches 7, but it only works when running right. How do I make it so it activates at both directions? Here's a short image of the code (I'm currently a newbie at MMF2, so I don't know how expressions and math works.) Other question, how do you make it so that the boost follows sonic's angles? Currently it only faces right. Link to comment Share on other sites More sharing options...
Guest Mr Lange Posted June 14, 2014 Report Share Posted June 14, 2014 (edited) Copy the event. "If boost speed <-7" "Subtract 4 from TopXSpeed" "I'm sure he didn't need a shot at his intelligence." - Your friendly neighborhood mod Edited June 14, 2014 by Abominal Taz Link to comment Share on other sites More sharing options...
Mr. Potatobadger Posted June 15, 2014 Report Share Posted June 15, 2014 Do this instead: Add another one to the first condition set that says: Direction of ( "Player_MovementValues" )=1 Then, in your second condition, change ">=7" to: TopXSpeed( "Player_MovementValues" )+Direction( "Player_MovementValues" ) Then, copy and paste it. In the second one, change direction from 1 to Negative 1 (-1). After that, start a new line, and make this: XSpeed <=7Or (Logical) XSpeed >=-7 Or (Logical) XSpeed =0 -Set TopXSpeed to 6 For the angle of the boost effect: Always: -Set Angle of ( "Effects_MiniBoost" ) to Angle ( "PlayerSkin_Sonic" ) To get the boost effect to face the same direction as sonic: Direction ( "Player_MovementValues" )=1 -Set Direction of ( "Effects_MiniBoost" ) --> Direction ( "Player_MovementValues" )=-1 -Set Direction of ( "Effects_MiniBoost" ) <-- I usually won't just straight up give people answers, i usually hint them, but you seem a decent level more advanced than the usual beginner, so I went ahead and gave you full detail. What I've told you is the gateway in to doing some really cool and advanced stuff in MMF2, and I think you can handle it. I figured I'd show you it's there and opens many possibilities. Link to comment Share on other sites More sharing options...
Recommended Posts