YesNoOk
avatar

How can I recreate Morrigan's Astral VIsion? (Read 12208 times)

Started by daonlylonely, July 08, 2024, 04:01:48 pm
Share this topic:
How can I recreate Morrigan's Astral VIsion?
#1  July 08, 2024, 04:01:48 pm
  • **
    • USA
Is there any chance someone could let me know how I can create a helper or something which is a essentially a clone of Morrigan that copies everything she does for a short period of time?

Re: How can I recreate Morrigan's Astral VIsion?
#2  July 08, 2024, 09:57:20 pm
  • ******
  • Hedgehog Whisperer
  • Red Bull addict
    • Spain
    • xgargoyle.mgbr.net
Easiest way, you have the helper just replicate the same anim as the root. But the helper will not be able to hit the enemy.

A better but slightly more complex way, have the helper go into the same states as the root. The helper will be able to hit the enemy.
After the period of time ends, have the helper destroy itself.
That's just the base, you will need to add failsafe conditions to the states with "IsHelper" triggers to avoid the helper going into incorrect states such as gethits
XGargoyle: Battle posing since 1979
http://xgargoyle.mgbr.net
http://www.pandorabots.com/pandora/talk?botid=e71c0d43fe35093a  <-- Please click that link
http://paypal.me/XGargoyle  <-- Donations welcome!
Last Edit: July 08, 2024, 10:13:23 pm by XGargoyle
Re: How can I recreate Morrigan's Astral VIsion?
#3  July 09, 2024, 10:02:25 am
  • **
    • USA
Apologies in advance since this would be my first time trying to create a helper. How would I go about making a helper replicate the same animations as the root?
Last Edit: July 09, 2024, 10:08:55 am by daonlylonely
Re: How can I recreate Morrigan's Astral VIsion?
#4  July 09, 2024, 03:03:18 pm
  • ******
  • Hedgehog Whisperer
  • Red Bull addict
    • Spain
    • xgargoyle.mgbr.net
inside the helper's state:

[State 6666, 2] ;this will allow the helper to replicate the same animation than the root
type = ChangeAnim
triggerall = SelfAnimExist(root,Anim) ;prevent debug error on custom anims
trigger1 = Anim != (root, anim)
trigger2 = AnimElemNo(0) > (root, AnimElemNo(0))
value = root, anim
elem = root,AnimElemNo(0)
ignorehitpause = 1
XGargoyle: Battle posing since 1979
http://xgargoyle.mgbr.net
http://www.pandorabots.com/pandora/talk?botid=e71c0d43fe35093a  <-- Please click that link
http://paypal.me/XGargoyle  <-- Donations welcome!
Re: How can I recreate Morrigan's Astral VIsion?
#5  July 25, 2024, 10:56:39 am
  • **
    • USA
So far, I haven't been successful in recreating it since the helper doesn't show up at all. I'm quite a noob at this so I'm sure there's at least a bajillion things I did wrong even with the help of a helper creating guide. I'll insert the code I used down below.

AIR file
Code:
; AV Mirror Image 
[Begin Action 790]
775,0, 0,0, 1
775,1, 0,0, 1

; AV Mirror Image Vanish
[Begin Action 791]
194,0, 0,0, 3
194,1, 0,0, 3
194,2, 0,0, -1

What I inserted into the "Dark Force" code
Code:
[State 770, AV Mirror Image]
type = helper
trigger1 = Anim = 770 && AnimElemTime(22) < 0
helpertype = normal
stateno = 790
ID = 790
pos = 50,0
name = "AV Mirror Image"
postype = p1
persistent = 0
keyctrl = 1

Helpers.cns file
Code:
;=====================<ASTRAL VISION MIRROR IMAGE>============================
[Statedef 790]
type = S
physics = N
movetype = S
anim = 790
ctrl = 0
velset = 0, 0
sprpriority = 1

[State 790, Fade In]
type = Trans
trigger1 = Anim = 790 && AnimElemTime(7)<0
trans = addalpha
alpha = ceil(5.7 * AnimElemTime(1)), ceil(256 -5.7 * AnimElemTime(1))

[State 790, 2] ;this will allow the helper to replicate the same animation than the root
type = ChangeAnim
triggerall = SelfAnimExist(root,Anim) ;prevent debug error on custom anims
trigger1 = Anim != (root, anim)
trigger2 = AnimElemNo(0) > (root, AnimElemNo(0))
value = root, anim
elem = root,AnimElemNo(0)
ignorehitpause = 1

[State 790, End]
type = ChangeState
trigger1 = Anim=771
value = 791

;AV Mirror Image Fade away
[Statedef 791]
type = A
physics = N
anim = 791
sprpriority = 1

[State 791, No AfterImages]
type = AfterImageTime
trigger1 = !Time
time = 0
ignorehitpause = 1

[State 791, Fade]
type = trans
trigger1 = 1
trans = addalpha
alpha = ceil(256 -8.5 * time), ceil(8.5 * time)

[State 791, Gravity]
type = VelAdd
trigger1 = 1
y = 0.5
Re: How can I recreate Morrigan's Astral VIsion?
#6  July 27, 2024, 04:39:30 am
  • *****
  • Shame on you!
    • USA
What you have seems solid enough that a helper should be showing up.
A few things to check
trigger1 = Anim = 770 && AnimElemTime(22) < 0
make sure this isn't the problem. Set it to something like Time = 2. Something you KNOW has to fire off.
The ChangeState for the helper might be instantly firing off because Root is doing something you're not expecting.
[State 790, End]
type = ChangeState
trigger1 = time >=75  ;just so you can see it for sure 
;trigger1 = Anim=771
value = 791


trigger1 = Anim = 790 && AnimElemTime(7)<0
That animelemtime, you might want to just change the animation as a test.

Code:
; AV Mirror Image 
[Begin Action 790]
775,0, 0,0, 1
775,1, 0,0, 1
775,0, 0,0, 1
775,1, 0,0, 1
775,0, 0,0, 1
775,1, 0,0, 1
775,0, 0,0, 1
775,1, 0,0, 1
775,0, 0,0, 1
775,1, 0,0, 1

You can try these 1 by 1 until it shows up.
vVv N00bSaibot & Muramasa RoofTop vVv
Re: How can I recreate Morrigan's Astral VIsion?
#7  July 27, 2024, 03:31:55 pm
  • **
    • USA
trigger1 = Anim = 770 && AnimElemTime(22) < 0

So I tried taking the line of code above and removed the AnimElemTime to see what happens and this is the result so far...



I've also tried everything else you've suggested and they didn't seem to make much of a difference from what I can see.

What I'm tryna figure out at this moment is how to stop the helper from being stationary, how to make it perform flipped versions of every animation it copies and also how to make it play its little startup animation before it starts copying the root.


Re: How can I recreate Morrigan's Astral VIsion?
#8  July 27, 2024, 03:44:53 pm
  • ******
  • Hedgehog Whisperer
  • Red Bull addict
    • Spain
    • xgargoyle.mgbr.net
Bindtoparent
XGargoyle: Battle posing since 1979
http://xgargoyle.mgbr.net
http://www.pandorabots.com/pandora/talk?botid=e71c0d43fe35093a  <-- Please click that link
http://paypal.me/XGargoyle  <-- Donations welcome!
Re: How can I recreate Morrigan's Astral VIsion?
#9  July 27, 2024, 04:20:21 pm
  • *****
  • Shame on you!
    • USA
What I'm tryna figure out at this moment is how to stop the helper from being stationary,

 how to make it perform flipped versions of every animation it copies

and also how to make it play its little startup animation before it starts copying the root.
use the bindtoparent like XGargoyle mentioned. It has the distance and the facing to take care of 2 of the problems.

The start up animation is pretty easy. Your "copy Root's anim" triggers just need a
Time >=X
where X is the amount of time the start up animation is.
vVv N00bSaibot & Muramasa RoofTop vVv
Re: How can I recreate Morrigan's Astral VIsion?
#10  July 29, 2024, 12:52:41 pm
  • **
    • USA


This is what I've managed to achieve so far.

These are the things I have left to figure out:
1. How to make the helper glide to the back of the opponent when it does the startup anim instead of just appearing. (If i had to guess its probly VelSet)
2. How to make the helper copy the root's states so that they can also hit the opponent.
3. Why does the opponent enters the block state whenever they move backwards between Morrigan and the helper. Also, the helper doesn't destroy itself when the dark force ends via something like a super.

Code:
;=====================<ASTRAL VISION MIRROR IMAGE>============================
[Statedef 790]
type = S
physics = N
movetype = A
anim = 790
ctrl = 0
velset = 0, 0
sprpriority = 1

[State 790, Fade In]
type = Trans
trigger1 = Anim = 790
trans = addalpha
alpha = ceil(5.7 * AnimElemTime(1)), ceil(256 -5.7 * AnimElemTime(1))

[State 790, Pos]
type= BindToParent
trigger1 = 1
time = 1
facing = -1
pos= 2*(Parent,P2Dist X), 0

[State 790, 2]
type = ChangeAnim
triggerall = SelfAnimExist(root,Anim) && Time >=44
trigger1 = Anim != (root, anim)
trigger2 = AnimElemNo(0) > (root, AnimElemNo(0))
value = root, anim
elem = root,AnimElemNo(0)
ignorehitpause = 1

[State 790, End]
type = ChangeState
trigger1 = Anim=771
value = 791

;AV Mirror Image Fade away
[Statedef 791]
type = A
physics = N
anim = 791
sprpriority = 1

[State 791, No AfterImages]
type = AfterImageTime
trigger1 = !Time
time = 0
ignorehitpause = 1

[State 791, Fade]
type = trans
trigger1 = 1
trans = addalpha
alpha = ceil(256 -8.5 * time), ceil(8.5 * time)

[State 790, End]
type = DestroySelf
trigger1 = parent, stateno !=771
value = 791

I suppose I'll also post the dark force code in case any of it is noteworthy
Code:
 ;===============<MAX Mode>===============
[Statedef 770]
type = S
movetype = I
physics = S
anim = 770
ctrl = 0
velset = 0,0

[State 770, NHB]
type = nothitby
trigger1 = 1
time = 1
value = SCA

[State 770, Voice]
type = PlaySnd
trigger1 = !Time
value = 770, 1
channel = 0

[State 770, MAX Snd]
type = PlaySnd
trigger1 = !Time
value = 770, 0

[State 770, Dark Force FX]
type = Helper
trigger1 = !Time
helperType = Normal
stateNo = 8400
ID = 8400
name = "Dark Force Startup FX"
posType = P1
pos = ceil(5 * const(size.xScale)), ceil(-62 * const(size.yScale))
superMoveTime = 255
size.xScale = 1
size.yScale = 1
ownPal = 1

[State 770, AV Mirror Image]
type = helper
trigger1 = Anim = 770
helpertype = normal
stateno = 790
ID = 790
pos = 0,0
name = "AV Mirror Image"
postype = p1
persistent = 0
keyctrl = 1

[State 770, PowerAdd]
type = PowerAdd
trigger1 = AnimElem = 1
value = -1000

[State 770, PowerSet Var]
type = Varset
trigger1 = Animelem = 1
var(24) = Power

[State 770, MAX Mode Timer]
type = VarSet
trigger1 = AnimElem = 1
var(20) = 688

[State 770, Max Meter V2]
type = Helper
helpertype = Normal
trigger1 = Animelem = 1 && !NumHelper(780)
id = 780
pos = 0,0
postype = left
name = "Max Meter"
stateno = 780
ignorehitpause = 1
pauseMoveTime = 255
superMoveTime = 255
ownpal = 1

[State 770, End]
type = ChangeState
trigger1 = !AnimTime
value = 0
ctrl = 1

;Reset
[Statedef 771]
type = S
physics = S
movetype = I
anim = 771
ctrl = 0
velset = 0, 0

[State 771, MAX Mode Deactivation Flag]
type = VarSet
trigger1 = !Time
var(50) = 0
ignoreHitPause = 1

[State 771, Var]
type = varset
trigger1 = var(20)
var(20) = 0

[State 771, End]
type = changestate
trigger1 = !animtime
value = 0
ctrl = 1
Last Edit: August 02, 2024, 10:48:15 am by daonlylonely
Re: How can I recreate Morrigan's Astral VIsion?
#11  August 03, 2024, 10:08:17 am
  • *****
  • Shame on you!
    • USA
vVv N00bSaibot & Muramasa RoofTop vVv