YesNoOk
avatar

Gravity control powers combo. (Read 1216 times)

Started by QuickFist, August 18, 2019, 02:06:33 am
Share this topic:
Gravity control powers combo.
#1  August 18, 2019, 02:06:33 am
  • *****
    • Venezuela
    • Blacksight22@Yahoo.Com.Ve
    • Skype - sebastian.osio
I'm making a char for my game who has the power to control gravity. I wanna give him a combo string that uses invisible waves in the air to trash P2 around. The combo would be: Horizontal attack to push him away, a remote uppercut to send him up, and an attack to smash him into the ground. The char does the motions with his body but the attacks are all remote. How would I code this?

Re: Gravity control powers combo.
#2  August 18, 2019, 02:32:48 am
  • ****
  • CPU Purple Heart
    • USA
    • www.dailymotion.com/2a8130871d2742d2f4da3b069
 The best bet to make remote attacks work regardless of distance is have P1 summon an invisible helper with a posset having x value being "enemy,pos x" and y value set to "enemy,pos y" so it will track P2 regardless of their distance. You can even use the same exact helper, but you will also need to create distinct hitdefs that have different hit properties like you want depending on what state the root is. Something like "trigger1 = root,stateno = 200" for a hitdef that knocks P2 backward and "trigger1 = root,stateno = 300" for the hitdef that knocks P2 straight up for example. The helper will be called in any stateno you do your gravity attacks and said helper will use the same helper stateno (with all those unique hitdefs for each attack state the root is in as mentioned earlier), but I'd recommend that each state calls the helper with a different ID just in case you want to distinguish each gravity attack.
Re: Gravity control powers combo.
New #3  August 18, 2019, 02:41:04 am
  • *****
    • Venezuela
    • Blacksight22@Yahoo.Com.Ve
    • Skype - sebastian.osio
Yeah that sounds good. Let me try it out.
@Nep Heart: Yeah, that worked, thanks a lot

Last Edit: August 18, 2019, 03:05:08 am by QuickFist