Jump to content

Forced Relative Orientation


portbash

Recommended Posts

So I've taken the "Forced Relative Orientation" Script from the useful script section of the GECK page, but I ain't great in math so I may ask how to add a reaction on the player's X angle update to the existing script... ?

 

begin GAMEMODE

set fRelativePos to player.GetPos z + 64
REF.setPos z fRelativePos

set fAngle to player.GetAngle Z 
REF.SetAngle Z fAngle

set fRelativePos to player.GetPos Y + 128 * cos fAngle
REF.SetPos Y fRelativePos

set fRelativePos to player.GetPos X + 128 * sin fAngle
REF.SetPos X fRelativePos

end

 

That would be cool.

In addition to that... would it be possible to update the reference's Z angle (onkeypress) while still having a working forced relative orientation? Sounds very difficult for me... as both blocks would include a Z angle update... anyone get me?

 

cheers

Link to comment
Share on other sites

  • Recently Browsing   0 members

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