YesNoOk
avatar

Facing (Triggers) (Read 3059 times)

Started by Just No Point, October 09, 2015, 04:43:03 am
Share this topic:
Facing (Triggers)
#1  October 09, 2015, 04:43:03 am
  • ******
    • www.justnopoint.com/
Returns 1 if the player is facing to the right, and -1 if the player is facing to the left.

Format:
Facing
Arguments:
none
Return type:
int
Error conditions:
none
Example:

Code:
Trigger = Facing = -1
  Triggers if the player is facing toward the left of the screen.
Re: Facing (Triggers)
#2  February 13, 2016, 02:36:44 am
  • *****
    • Guyana
    • Skype - ryon_persaud
Doc of the Day took me here.

Facing and !Facing.

When coding cinematic supers, I always have trouble when coding facing left vs facing right.
one side will work but the other will not.

What is the proper way to go about handling facing?
Characters := http://www.mediafire.com/folder/kx11h6lcbbqj1/Characters
Stages := http://www.mediafire.com/folder/xy7wk5q9qka62/Stages

Projected Character Forcast := FighterZ Android 18 , FighterZ Vegeta , FighterZ Goku.
Last Edit: February 13, 2016, 08:27:06 am by Odb718
Re: Facing (Triggers)
#3  February 13, 2016, 08:27:47 am
  • *****
  • Shame on you!
    • USA
Usually for that, you'd make a bit of an equation watching P1 and P2's facing values.
I know I  have this exact question in one of my character's ultras. I just cant remember which one. I'll try to find it.

But for now,
Basically I believe you should be able to just compare whether P1's facing value is greater than P2's.

So something like
Triggerall = Facing > enemy,facing
This will only work if P1 is on the left;    1 > -1
When P1 is on the right the values are  -1 > 1
You should be able to figure something out with that. You could also use target,facing if the check is in the middle of an ultra.

----
Sorry about editing your post. I meant to hit reply and not edit >_<
vVv Wheat Stage Released vVv
Re: Facing (Triggers)
#4  February 13, 2016, 03:26:28 pm
  • *****
    • Guyana
    • Skype - ryon_persaud
LOL.

Ok so, What I ususally do since i can't figure out the short way of using facing.

I would make multiple codes with triggerall = facing = 1, and triggerall = facing = -1.
it's mostly velsets and possets, but if I can avoid having multiple codes that would be great.
Characters := http://www.mediafire.com/folder/kx11h6lcbbqj1/Characters
Stages := http://www.mediafire.com/folder/xy7wk5q9qka62/Stages

Projected Character Forcast := FighterZ Android 18 , FighterZ Vegeta , FighterZ Goku.
Re: Facing (Triggers)
#5  February 13, 2016, 10:09:55 pm
  • ****
  • Robotics Engineer
    • USA
    • altoiddealer@gmail.com
facing will either equal the enemies facing, or it won't

trigger1 = facing = enemy,facing
or
trigger1 = facing != enemy,facing

When using it in controller parameters, you'd want to check it like example:

facing = Cond((facing = enemy,facing),1,-1)