Jump to content

Sneak Attack Multiplier from Behind


Bergzore

Recommended Posts

I'm making a perk that multiplies sneak attack damage but only if the enemy is facing away. Is GetHeadingAngle the condition I'm looking for, or is that just for cardinal directions N, S, E, W?

Link to comment
Share on other sites

I'm making a perk that multiplies sneak attack damage but only if the enemy is facing away. Is GetHeadingAngle the condition I'm looking for, or is that just for cardinal directions N, S, E, W?

it's the Z axis, measured in degrees.

 

if target.getheadingangle(playerref) = 0 then target is facing the player.

if it returns 180, then the player is behind the target.

Link to comment
Share on other sites

So 180 would be the enemy perfectly facing away, and 0 would be perfectly facing the player?

 

So I would need two conditions.

 

GetHeadingAngle(playerref) => 90 and GetHeadingAngle(playerref) <= 180.

 

Sound right?

Link to comment
Share on other sites

So 180 would be the enemy perfectly facing away, and 0 would be perfectly facing the player?

 

So I would need two conditions.

 

GetHeadingAngle(playerref) => 90 and GetHeadingAngle(playerref) <= 180.

 

Sound right?

 

between 135 and 225,

90 to 180 would give you the bottom right 90 degree slice of the clock.

or the bottom left, i have no idea if getheadingangle works clockwise or counterclockwise.

Link to comment
Share on other sites

I'm aware of that, but no, that's not it. I'm loading a save before the perk was gotten. I've tried different numbers from 0-360 and it doesn't seem to like them. It only registers the back right slice, and if any other degrees are put in, it doesn't give me a multiplier anywhere. I've tried 180-270 to get the back left slice, nothing. Just for shits, I tried 0-90, still nothing. lol wtf...

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...