I've been trying to make A_RotateSpikeball work for months this is my last resort

marcxworld

avid enjoyer of rvz, currently trying to get 1:12
SOC::
State S_SAMURAISWORD1
SpriteName = SASW
SpriteFrame = A
Duration = 1
Next = S_SAMURAISWORD2
Var1 = MT_SAMURAIBOT
Var2 = 0
Action = A_FindTarget

State S_SAMURAISWORD2
SpriteName = SASW
SpriteFrame = A
Duration = 1
Next = S_SAMURAISWORD2
Var1 = 0
Var2 = 0
Action = A_RotateSpikeball

Object MT_SAMURAISWORD
MapThingNum = 4054
SpawnState = S_SAMURAISWORD1
Speed = 3
Radius = 30*FRACUNIT
Height = 10*FRACUNIT
Flags = MF_SCENERY|MF_PAIN|MF_NOGRAVITY

and dont think this is all i've tried, i've tried manually setting the target with lua and it just.. dissapears? but when there's no target it's completely fine. Then when I set the target with A SINGLE LINE of code it just breaks. I notice that it only messes up when I give it a target, and for some reason that makes it completely disapear or respawn. Idk which one but it isn't there when it has a target. So, basically, how do I set up a target for A_RotateSpikeball without the entirre thing failing? as it only messes up when it has a target for some reason.
 
Actions don't run when a mobj is first spawned, that A_FindTarget isn't being fired. You can either add "MF_RUNSPAWNFUNC" to its flags, or just add another spawn state that transitions into that one. Additionally, speed should be a multiple of FRACUNIT, try writing "3*FRACUNIT" instead.
 
omg thats what i was missing bruh... thanks! (btw i removed the *FRACUNIT because i thought it may have been bugged, turns out it wasn't lol)
 

Who is viewing this thread (Total: 1, Members: 0, Guests: 1)

Back
Top