Would you like to react to this message? Create an account in a few clicks or log in to continue.
Welcome!!! - Bienvenidos!!! - ( We hope you will get involved in the MMV Community which is dedicated to having fun with Mugen ) - Bienvenidos!!! - Welcome!!!
Posts : 2935 Join date : 2013-04-04 Age : 38 Location : Egypt
Subject: help in coding urgent October 2nd 2017, 11:15 am
Hello friends those who know me well know that i am a spriter but nowadays am taking very serious steps to code my chars
anyways i need help about this Helper Projectile attack it is supposed that Deadshot summons Boomerang who throws projectiles at his opponent it works fine when P1 is on the left of screen and boomerang comes just behind him to throw the projectiles but when P1 is on the right boomerang comes on the very side of screen after opponent 2 , i need help from coders to fix this
this is the code i set the posset at x=-110 to become just behind P1
;------------------------Bommerang Help------------------- [Statedef 4699] type = S movetype= I physics = N velset = 0,0 juggle = 0 anim = 4699 ctrl = 0 sprpriority = 2 poweradd = 0
[State 0, Helper] type = Helper trigger1 = animelem= 3 helpertype = normal ;player name = "Boomerang is here" ID = 4699 stateno = 4700 pos = -110,0 postype = back ;p2,front,back,left,right ownpal = 1 supermove =9999 pausemove =9999
[State 4699, ChangeState] type = ChangeState trigger1 = time= 60 value = 0 ctrl = 1 ;------------------------------------------- ; Boomerang come in [Statedef 4700] type = A physics = N velset = 5,-3 juggle = 0 anim = 4700 sprpriority = 2 poweradd = 0
[State 0, Gravity] type = Gravity trigger1 = TIME>10
[State 0, ChangeState] type = ChangeState trigger1 = pos Y>0 && vel Y >0 value = 4701 ;------------------------------------------- ; BOOMERANG STAND AND ATTACKS [Statedef 4701] type = S movetype= A physics = N velset = 8,6 juggle = 0 anim = 4701 sprpriority = 2 poweradd = 0
[State 0, ChangeState] type = ChangeState trigger1 = animtime=0 value = 4704 ;------------------------------------------- ; Boomerang Leaves [Statedef 4704] type = S movetype= A physics = N velset = 0,0 juggle = 0 anim = 4704 sprpriority = 2 poweradd = 0
[State 4704, PlaySnd] type = PlaySnd trigger1 =time=0 value = S43,2 volume = 0
[State 4704, VelSet] type = VelSet trigger1 = animelem=2 x=-5
[State 4704, DestroySelf] type = DestroySelf trigger1 =time=50 ;-------------------------------------------
Mistah Jorge
Posts : 2356 Join date : 2013-07-04 Age : 26 Location : Portugal
Subject: Re: help in coding urgent October 2nd 2017, 11:45 am
can you make a gif or video so i can see what exactly happens? describing the problem isn't enough to make ME understand
skhsato123
Posts : 2935 Join date : 2013-04-04 Age : 38 Location : Egypt
Subject: Re: help in coding urgent October 2nd 2017, 11:59 am
Mistah Jorge wrote:
can you make a gif or video so i can see what exactly happens? describing the problem isn't enough to make ME understand
Mistah Jorge
Posts : 2356 Join date : 2013-07-04 Age : 26 Location : Portugal
Subject: Re: help in coding urgent October 2nd 2017, 12:14 pm
try somthing like "parent, pos x - 'insert number here for distances' "
this should reposition your helper in relation of the parent (the helper's creator).
example: (parent, pos x): this is the current position of the parent (in this case should be deadshot) (parent, pos x) - 110: this should be 110 pixels behind deadshot (parent, pos x) + 110: this should be 110 pixels ahead of deadshot
just play with the numbers and you should be just fine
Ps: The parentisis are just for organization, i don't think they're needed, more like a failsafe whatever (and i'm not sure of any of this, if this doens't work then i will give it a deeper check)
skhsato123
Posts : 2935 Join date : 2013-04-04 Age : 38 Location : Egypt
Subject: Re: help in coding urgent October 2nd 2017, 12:26 pm
it worked very good friend well thank you so much and anyways if you are interested to help coding any of my chars just tell me