The Mugen Fighters Guild

Help => M.U.G.E.N Configuration Help => Topic started by: Ki$@1st456v on January 13, 2021, 06:15:05 pm

Title: How To Make Projectiles That Stay On The Ground?
Post by: Ki$@1st456v on January 13, 2021, 06:15:05 pm
Hi, again everyone! I wanted to ask about another thing. Do you remember Trish's Trick Hopscotch from UMVC3/MVC3? I remembered that no matter how high she was off the ground, whenever she did the move, the trap would appear right next to her at ground level. I was wondering, how do you code a move to do that and what numbers do you put in the x and y values to do that? I still want the projectile to travel horizontally, but I am not sure how to code it where it begins at ground level right next to my character regardless of my character's height or altitude in the air. Is it a command such as postype= p1dist? Also, does it have to be from a helper state, projectile state, etc.? Thank you all for your help with my previous question and I am grateful for your assistance!
Title: Re: How To Make Projectiles That Stay On The Ground?
Post by: airforce111 on January 15, 2021, 08:26:15 pm
offset y value in projectile sctril should be: -pos y or ceil(-pos y)
Title: Re: How To Make Projectiles That Stay On The Ground?
Post by: Ki$@1st456v on January 16, 2021, 12:19:33 pm
Will that keep the projectiles at ground level however while you are in the air though? I know that the offset changes where the projectile appears in accordance to my character's position, but is there a value to ascribe a permanent position at ground level for the projectile?
Title: Re: How To Make Projectiles That Stay On The Ground?
Post by: NotAGoodName on January 19, 2021, 10:50:59 am
Just make it a helper projectile and have the helper move itself to the ground as its first SCTRL.

If you're making a projectile that can be fired in the air, but spawns on the ground, there's like a 99% chance that you're going to need it to do SOMETHING that a mugen projectile can't normally do.  Just save yourself the grief.
Title: Re: How To Make Projectiles That Stay On The Ground?
Post by: Ki$@1st456v on January 19, 2021, 03:24:04 pm
Okay, as an example, would it be like this when I code it?

[State 0, Helper]
type = Helper
triggerall = numhelper(1000)=0
trigger1 = AnimElem = 9
helpertype = normal ;player
name = "Plasma Beam"
ID = 1000
stateno = 1010
pos = floor(56*const(size.xscale)),floor(-78*const(size.yscale))
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1