Problems with sprpriority

Started by GaziraAgain, February 28, 2024, 02:15:48 PM

Previous topic - Next topic

GaziraAgain

Hello everyone. I am creating a fightfx file and in this I have included animations for hyper background. Thanks to Tornillo Oxidado I have managed to get the animation to work perfectly when executing the char movement. The problem is that it appears above the lifebars. You can see  the combo fonts or the ko animation for example.
I have tried giving very high negative values to the sprpriority but it doesn't change anything, how could I do it?


The same happens when I put the hyper finish background in the code...


*I use layerno=1 for powerbars.

Here I leave the code that I use for the first animation:
Spoiler (click to show)

;Distortion Drive Effect
[Statedef 7000]
type = A
ctrl = 0
anim = 9999
velset = 0,0
movetype = I
physics = N
sprpriority = -1007

[State a]
type = playsnd
trigger1 = !ishelper(8995)
trigger1 = !time
value = f7000,0
ignorehitpause = 1

[state a]
type = AssertSpecial
trigger1 = 1
flag = noshadow

[state a]
type = assertspecial
trigger1 = time >= 30
flag = noFG

[State explod]
type = Explod
trigger1 = time = 1
anim = f7000
id = 7000
sprpriority = -1007
postype = left
pos = 0,0
bindtime = -1
removetime = -1
pausemovetime = 99999
supermovetime = 99999
ignorehitpause = 1
ownpal = 0
scale = GameWidth/1280*2,GameHeight/768*2

[state a]
type = changestate
trigger1 = root,movetype = H
trigger2 = root,stateno != [3000,3900]
value=7001

I hope someone can help me now that I'm so close. Thank you so much.

PlasmoidThunder

You can't without setting the lifebars to layerno 2. Sprpriority determines the draw order of sprites on the character layer, so no matter how low you set it, the sprites cannot display below the lifebars.

Quote from: Iced on July 24, 2013, 01:25:14 AM
Oh, I want a diagram. I fucking love diagrams.

GaziraAgain

Thanks a lot! I've tried it and it works perfectly. Now I will do the same with the time and the portraits. I thank you very much.

GaziraAgain

Today with time I put layerno = 2 in lifebars, names and portraits and everything is under fightfx animation but I see that like with layerno = 1 characters are under lifebars too. Maybe the only solution is create the lifebars using a .cns file like in Add004.