Retarded Trigger

Started by Fixer, January 12, 2019, 06:43:59 PM

Previous topic - Next topic

Fixer

I am getting now an error saying "parent in retarded trigger has beed destroyed"
It's not a game breaking bug but i would like to fix it but this one i have no clue how to do it, someone know how to?

Here is the code from where the error is coming from:

Spoiler (click to show)
;Renzokou Kikou Ha: Projectile Tail
[Statedef 7031]
type          = A
movetype      = I
physics      = N
anim         = 7027
;velset      = 0,0
ctrl         = 0
poweradd      = 0
juggle      = 0
facep2      = 0
hitdefpersist   = 0
movehitpersist   = 0
hitcountpersist   = 0
sprpriority      = 2

[State 7031:   AssertSpecial]
type         = AssertSpecial
trigger1      = 1
flag         = NoShadow
flag2         = Invisible

[State 7031:   NotHitBy]
type         = NotHitBy
trigger1      = 1
value         = SCA

[State 7031:   PlayerPush]
type         = PlayerPush
trigger1      = 1
value         = 0

[State 7031:   VelSet]
type         = VelSet
trigger1      = 1
x         = Parent, Vel X
y         = Parent, Vel Y

[State 7031:    AfterImage]
type          = AfterImage
trigger1       = (!Time)
time          = 30
timegap      = 1
framegap       = 3
length       = 60
paladd       = 0, 0, 0
palmul       = .50, .50, .50
palcontrast    = 100, 100, 100
trans       = add

[State 7031:   DestroySelf]
type         = DestroySelf
trigger1      = (Parent, MoveContact) || (Parent, FrontEdgeBodyDist < -10) || (Parent, StateNo != 7027)

Infinite Daze

I've ran into similar problems with helpers in the past.
Spoiler (click to show)

[Statedef 7031]
type          = A
movetype      = I
physics      = N
anim         = 7027
;velset      = 0,0
ctrl         = 0
poweradd      = 0
juggle      = 0
facep2      = 0
hitdefpersist   = 0
movehitpersist   = 0
hitcountpersist   = 0
sprpriority      = 2

[State 7031:   DestroySelf]
type         = DestroySelf
trigger1      = (Parent, MoveContact) || (Parent, FrontEdgeBodyDist < -10) || (Parent, StateNo != 7027)
ignorehitpause=1

[State 7031:   AssertSpecial]
type         = AssertSpecial
trigger1      = 1
flag         = NoShadow
flag2         = Invisible

[State 7031:   NotHitBy]
type         = NotHitBy
trigger1      = 1
value         = SCA

[State 7031:   PlayerPush]
type         = PlayerPush
trigger1      = 1
value         = 0

[State 7031:   VelSet]
type         = VelSet
trigger1      = 1
x         = Parent, Vel X
y         = Parent, Vel Y

[State 7031:    AfterImage]
type          = AfterImage
trigger1       = (!Time)
time          = 30
timegap      = 1
framegap       = 3
length       = 60
paladd       = 0, 0, 0
palmul       = .50, .50, .50
palcontrast    = 100, 100, 100
trans       = add


;might work placement priority of the destroyself and the velset or any other thing that might parent within the statedef.

inktrebuchet

#2
That message is from a trigger that uses a parent redirect after the parent has already been destroyed.

If changing the code order doesn't work you could try this:

The parent must be a helper for that to happen, so if you know that helpers ID(the parent) you could use numhelper(????) != 0 in [State 7031:   VelSet]. This way it only looks to the parent if the parent exists.

And adding numhelper(????) = 0 as the first trigger in the destroyself and setting the others to trigger2. You really shouldn't need the second trigger though.


Fixer

Thank you guys, i am definitely going to try this, thanks for the hint Infinite Intel.