YesNoOk
avatar

Newbie Needs Projectile Help (Read 170 times)

Started by puissance, October 17, 2011, 02:38:10 am
Share this topic:
Newbie Needs Projectile Help
#1  October 17, 2011, 02:38:10 am
  • avatar
  • *

  • Online
Hi All,

I am trying to add a projectile to KEN LVL2 by azcal.    I've added the hadouken animation to the air and below is the code I have at the CNS.

[StateDef 777]
type = S
movetype= A
physics = S
juggle  = 1
velset = 0,0
ctrl = 0
anim = 777
poweradd = 20

[State 777, 1]
type = Projectile
trigger1 = AnimElem = 5
projanim = 1010
projhitanim = 1011
projpriority = 1
projheightbound = -240, 100
projedgebound = 100
projscreenbound = 100
projshadow = -1
offset = 141,-45
velocity = 3
attr = S, SP
damage   = 35
animtype = heavy
guardflag = MA
hitflag = MAFDP
pausetime = 10,10
hitsound   = 5,2
sparkxy = 500,500
guardsound = S6,0
ground.type = Low
ground.slidetime = 25
ground.hittime  = 25
ground.velocity = -6
air.animtype = Back
air.velocity = -4,-6
air.juggle = 3
air.fall = 1
down.velocity = -4,-6
down.hittime = 30
down.bounce = 0
accel=0.1

[State 777, sound]
type=playsnd
trigger1 = animelem = 5
value = S12345,0
volume = 100

[State 777, end]
type = ChangeState
trigger1 = AnimTime = 1
value = 0
ctrl = 1

below is what I have at the CMD file
[command]
name = "fireball"
command = ~D, DF, F, z
time = 20

[State -1, fireball]
type = ChangeState
value = 777
triggerall = command = "fireball"
trigger1 = (statetype = s) && ctrl

When I try to run the move in the game, the fireball comes out just fine but the hadouken animation where ken throws the fireball doesn't come out.  Instead, it shows the animation for the hard punch (z).   I know that probably should have set this up using a helper instead but I'm still trying to learn code/the basics.   Any help is greatly appreciated.

Thanks
Last Edit: October 17, 2011, 04:51:10 am by puissance
Re: Newbie Needs Projectile Help
#2  October 17, 2011, 02:41:02 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
Anim = 777 is the animation you're using for the throw. Is that the throw animation? I doubt it somehow. You may need to double check.

The stuff you have in the projectile sctrl is ONLY the projectile. Those animations should be the projectile, you don't want any ken animations inside that controller.


In M.U.G.E.N there is no magic button

They say a little knowledge is a dangerous thing, but it's not one half so bad as a lot of ignorance.
Re: Newbie Needs Projectile Help
#3  October 17, 2011, 04:58:43 am
  • avatar
  • *

  • Online
anim = 777 is the animation where ken throws the fireball and anim 1010 is the fireball animation.    I double checked that and those #s are correct.   

Thanks
Re: Newbie Needs Projectile Help
#4  October 17, 2011, 05:21:42 am
  • ******
  • Legendary XIII
  • I am the eye of the storm to come!
    • New Zealand
    • network.mugenguild.com/cyanide/
So, fireball anim is OK, but anim 777 is apparently hard punch? What does the state for hard punch look like? Is that using the animation 777?

Is your anim 777 actually using the sprites for hard punch?

Normally duplicate sprites/animation numbers will cause the issue you are having.


In M.U.G.E.N there is no magic button

They say a little knowledge is a dangerous thing, but it's not one half so bad as a lot of ignorance.
Re: Newbie Needs Projectile Help
#5  October 17, 2011, 06:23:13 am
  • avatar
  • *

  • Online
I got it to work.  What happened was that my animation didn't have any time attached to it for each frame - so once I added that it did what it was suppose to do.  Ah, the joy and agony of learning

Thanks for the help.