over/under *SOLVED*

Started by sgn15, October 28, 2011, 11:11:04 AM

Previous topic - Next topic

sgn15

well there is this simple problem i had

in superpause:
first i call an explod on p2 sprpriorty = -5
then i call a helper on p2 sprpriorty = 5

the helper is still "under" the explod. I want the helper to be "over" the explod

related codes are here:
Spoiler (click to show)
Quote[Statedef 400]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 15
ctrl = 0
anim = 400

[State 0, SuperPause]
type = SuperPause
trigger1 = animelem = 10
time = 400
anim = -1
;sound = S10,0
pos = 0,0
movetime = 400
darken = 1
p2defmul = 0
poweradd = 0
unhittable = 1
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = animelemtime(10) = 0
anim = 406
ID = 406
pos = 15,70
postype = p2  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermove
pausemove
scale = 2,1
sprpriority = -5
ontop = 0
shadow = 0,0,0
ownpal = 0
removeongethit = 0
;ignorehitpause =
;persistent =
supermovetime = 99999999999
pausemovetime = 99999999999


[State 0, Helper]
type = Helper
trigger1 = animelemtime(10) = 50
helpertype = normal ;player
;name =
ID = 405
stateno = 405
pos = 10,-130
postype = p2
facing = 1
keyctrl = 0
ownpal = 1
ontop = 1
size.xscale = 1.0
size.yscale = 1.0
supermovetime = 99999999999
pausemovetime = 99999999999
;ignorehitpause =
;persistent =

;---------------------------------------------------------------------------
[Statedef 405]
type    = S
movetype= A
physics = N
juggle  = 5
poweradd= 0
ctrl = 0
anim = 405

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =

i actually have some more small problems, but this is the most important problem for now. thanks

Cyanide

why are supermove and pausemove in there with no settings.

Other than that, i don't see anything specifically wrong. Unless those settings are cancelling the rest of that sctrl, but that wouldn't explain the issue you're having. Sprpriority defaults to 0 for explods. Turn the superpause off and see if you get the same result (troubleshoot)


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.

sgn15

ok.
tried without explod= same result
tried without explod and without supermove and pausemove= same result

Cyanide

You mean tried without superpause right? Oh, helpers dont' take ontop as a parameter, but that wouldn't explain the issue either.

Remove sprpriority sctrl. Lets see what happens then. Really that should just be setting it to 5 over and over. But unless you're not editing the state you think you are, there is something dumb happening so let's see if we can figure out when.

add sprpriority = 1 into the helpers statedef section instead.


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.

sgn15

#4
yeah i meant superpause not explod. sorry about that
ok removed the ontop of helper sctrl

you meant like this?

;---------------------------------------------------------------------------
[Statedef 405]
type    = S
movetype= A
physics = N
juggle  = 5
poweradd= 0
ctrl = 0
anim = 405
sprpriority = 1

tried:
without sprpriority sctrl and added sprpriority = 1 in statedef of 405 = same result
without superpause and without sprpriority sctrl and added sprpriority = 1 in statedef of 405 = same result

EDIT:
in case there is something wrong with helper statedef, here it is

Spoiler (click to show)
;---------------------------------------------------------------------------
[Statedef 405]
type    = S
movetype= A
physics = N
juggle  = 5
poweradd= 0
ctrl = 0
anim = 405
sprpriority = 1

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
;ignorehitpause =
;persistent =
flag = noshadow

[State 0, Trans]
type = Trans
trigger1 = 1 ; time = 0
trans = add
;alpha =
;ignorehitpause =
persistent = 1

[State 0, VarSet]
type = VarSet
trigger1 = time = [0,10]
fv = 2
value = 0.7
;ignorehitpause =
persistent = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = time = [11,16]
fv = 2
value = 0.1
;ignorehitpause =
persistent = 1

[State 0, VarSet]
type = VarSet
trigger1 = time = [17,400]
fv = 2
value = 1.4
;ignorehitpause =
persistent = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = time > 400
fv = 2
value = -0.01
;ignorehitpause =
persistent = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
;value =  (winmugen only)
scale =  fvar(2),0.2
;ignorehitpause =
persistent = 1

[State 0, 4]
type = Destroyself
trigger1 = root, stateno = 400 && root, animelem = 13

Cyanide

I honestly see nothing wrong. There are no hitdefs that would be altering the priority. The explod sets it once. The helper sets it once. There is no reason for the helper to alter to be below the explod. There are only 2 ways that would happen

The helper is spawned first with the same priority as the explod (obviously not happening)
the explod has ontop = 1 (also obviously not the case)

You've got 2 choices for the next step.

1: recreate all the states, you can copy paste the data but do it in bits. Give them new statedef numbers and place them somewhere else in the .cns (honestly, i have fixed things by doing this before)

2: Start nulling stuff. Remove some of the variables. Basically, cut it down till it's just the bits giving you issues.


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.

sgn15

#6
I already did the 2nd method so far. I also tried coding the explod as helper with same priority  and removetime (destoryself) and other stuff and the helper (former explod) summoned the original helper (instead of p1 summoning the original helper). it is still the same result.

and i also have a question, if darken = 1 for superpause and a helper or explod is called while in superpause, the helper or explod is also darkened as well ?

I found this out by removing the helper/explod (the one that is supposed to be "under") and still having darken = 1 superpause, the helper (that is supposed to be "over" the explod) is also darkened.

this is the exact attack btw
http://www.youtube.com/watch?v=jWmdVBxZbtw
the vertical beam on p2 is the explod/helper (which is supposed to be "under" the 5 ovals)
the 5 ovals are the helpers that are supposed to be "over" the vertical beam

but in the video and the problem itself, the vertical beam is "over" the 5 ovals

for discussion's sake, i only mentioned 1 of the 5 ovals, but their states are 401 to 405
406 is the vertical beam
407 is the fire attack when the superpause is finished (this is not part of the problem)


Cyanide

Replicate it in some other states. Create an explod. Check you can put one of your helpers on top of it.

I would like to point out i had this exact problem in a stage. All stages were fine bar one where all explods seemed to have sprpriority = 7. I wound up recreating the stage to solve it. (yes, things that weird happen)


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.

sgn15

i recreated it in new states (for p1, explod, helper)

Spoiler (click to show)
[Statedef 430]
type    = C
movetype= A
physics = C
juggle  = 5
poweradd= 22
ctrl = 0
anim = 430

[State 0, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 400
anim = -1
sound = S10,0
pos = 0,0
movetime = 400
darken = 1
p2defmul = 0
poweradd = 0
unhittable = 1
;ignorehitpause =
;persistent =


[State 0, Explod]
type = Explod
trigger1 = time = 0
anim = 431
ID = 431
pos = 0,50
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermovetime = 9999999999999
pausemovetime = 9999999999999
scale = 1,1
sprpriority = -5
ontop = 0
shadow = 0,0,0
ownpal = 0
removeongethit = 0
;ignorehitpause =
;persistent =


[State 0, Helper]
type = Helper
trigger1 = animelemtime(1) = 50
helpertype = normal ;player
;name =
ID = 432
stateno = 432
pos = 5,-47
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 1
supermovetime = 9999999999999
pausemovetime = 9999999999999
size.xscale = 1.0
size.yscale = 1.0
;ignorehitpause =
;persistent =

[State 430, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 11
ctrl = 1

;---------------------------------------------------------------------------
[Statedef 432]
type    = S
movetype= A
physics = N
juggle  = 5
poweradd= 22
ctrl = 0
anim = 432
sprpriority = 5

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =


[State 0, DestroySelf]
type = DestroySelf
trigger1 = time = 5000 ;root, stateno = 430 && root, animelem = 2
;ignorehitpause =
;persistent =

I summoned explod and helper on p1 first (instead of p2)
i found new problems. the helper is not appearing, pos is correct, i used the ruler
when i enter debug mode, it seems the helper is there in the game although i cant see it
and the "spr = 0,#" in debug mode, the # is changing continuously from 0 to 4 i think

i have the anims for 430,431, and 432
I don't know what to fix here anymore

Cyanide

Upload or email to me please. This makes no sense i need to actually see what's happening.


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.

sgn15

Let me work some more on this, I used completely new states again, this time I used

Spoiler (click to show)
;---------------------------------------------------------------------------
; Crouching Strong Punch
[Statedef 428]
type    = C
movetype= A
physics = C
juggle  = 0
poweradd= 50
ctrl = 0
anim = 428

[State 0, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 400
anim = -1
sound = S10,0
pos = 0,0
movetime = 400
darken = 1
p2defmul = 0
poweradd = 0
unhittable = 1
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
trigger1 = time = 0
helpertype = normal ;player
;name =
ID = 429
stateno = 429
pos = 6,18
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 9999999999999
pausemovetime = 9999999999999
size.xscale = 1.0
size.yscale = 1.0
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
trigger1 = time = 50
helpertype = normal ;player
;name =
ID = 430
stateno = 430
pos = 9,-57
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 9999999999999
pausemovetime = 9999999999999
size.xscale = 1.0
size.yscale = 1.0
;ignorehitpause =
;persistent =

[State 420, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
[Statedef 429]
type    = S
movetype= A
physics = N
juggle  = 0
poweradd= 0
ctrl = 0
anim = 429

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = -5
;ignorehitpause =
;persistent =



;---------------------------------------------------------------------------
[Statedef 430]
type    = S
movetype= A
physics = N
juggle  = 0
poweradd= 0
ctrl = 0
anim = 430

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =

Spoiler (click to show)
;---------------------------------------------------------------------------
; Crouching Strong Punch
[Statedef 428]
type    = C
movetype= A
physics = C
juggle  = 0
poweradd= 50
ctrl = 0
anim = 428

[State 0, SuperPause]
type = SuperPause
trigger1 = time = 0
time = 400
anim = -1
sound = S10,0
pos = 0,0
movetime = 400
darken = 1
p2defmul = 0
poweradd = 0
unhittable = 1
;ignorehitpause =
;persistent =

[State 0, Explod]
type = Explod
trigger1 = time = 0
anim = 429
ID = 429
pos = 0,0
postype = p1  ;p2,front,back,left,right
facing = 1
vfacing = 1
bindtime = 1
vel = 0,0
accel = 0,0
random = 0,0
removetime = -2
supermovetime = 9999999999999
pausemovetime = 9999999999999
scale = 1,1
sprpriority = -5
ontop = 0
shadow = 0,0,0
ownpal = 0
removeongethit = 0
;ignorehitpause =
;persistent =

[State 0, Helper]
type = Helper
trigger1 = time = 50
helpertype = normal ;player
;name =
ID = 430
stateno = 430
pos = 9,-57
postype = p1    ;p2,front,back,left,right
facing = 1
keyctrl = 0
ownpal = 0
supermovetime = 9999999999999
pausemovetime = 9999999999999
size.xscale = 1.0
size.yscale = 1.0
;ignorehitpause =
;persistent =

[State 420, 5]
type = ChangeState
trigger1 = AnimTime = 0
value = 0
ctrl = 1

;---------------------------------------------------------------------------
[Statedef 430]
type    = S
movetype= A
physics = N
juggle  = 0
poweradd= 0
ctrl = 0
anim = 430

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =

those are 2 methods of coding the "under" anim (as helper or as explod). both worked like i wanted to (oval is over beam)

I also tried now the variables and angledraw on helper state 430 and it also worked
like this

Spoiler (click to show)
;---------------------------------------------------------------------------
[Statedef 430]
type    = S
movetype= A
physics = N
juggle  = 0
poweradd= 0
ctrl = 0
anim = 430

[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =

[State 0, AssertSpecial]
type = AssertSpecial
trigger1 = 1
;ignorehitpause =
;persistent =
flag = noshadow

[State 0, Trans]
type = Trans
trigger1 = 1 ; time = 0
trans = add
;alpha =
;ignorehitpause =
persistent = 1

[State 0, VarSet]
type = VarSet
trigger1 = time = [0,10]
fv = 3
value = 0.7
;ignorehitpause =
persistent = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = time = [11,16]
fv = 3
value = 0.05
;ignorehitpause =
persistent = 1

[State 0, VarSet]
type = VarSet
trigger1 = time = [17,400]
fv = 3
value = 1
;ignorehitpause =
persistent = 1

[State 0, VarAdd]
type = VarAdd
trigger1 = time > 400
fv = 3
value = -0.01
;ignorehitpause =
persistent = 1

[State 0, AngleDraw]
type = AngleDraw
trigger1 = 1
;value =  (winmugen only)
scale =  fvar(3),0.2
;ignorehitpause =
persistent = 1


[State 0, SprPriority]
type = SprPriority
trigger1 = 1
value = 5
;ignorehitpause =
;persistent =

so what do i do now? I still cannot notice what i did wrong in the original states (and also the helper not visible in the 2nd try, although that does not matter much now since i got it to work in this 3rd try)

Cyanide

If you have it working, nothing, you're done, just keep going.

I put this down to "Weird shit you cannot explain" it's in the same vein as an attack i was coding once. Wouldn't velset Y at all. Nulled all 0 vels and pos Y triggers and made it trigger1 = 1 with nothing to stop it at all. And he stayed on the ground. Deleted the whole state and rewrote it, word for word the same (basically) and then it worked. I believe occasionally you'll get corrupt "bits" in the word document and it bollocks' up everything.


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.

sgn15

it worked like you said! I just deleted all content from state 400 (except the changestate to 0 when animtime = 0), coded superpause and helper sctrls from scratch (not by copy pasting the old codes) and I also did not changed anything in the helper states (all states from 401 to 407)

thanks for the help. this weird problem I encountered will definitely add to my knowledge and experience. thanks again