Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Move Player / Remove Timers
Adrianis Offline
Senior Member

Posts: 620
Threads: 6
Joined: Feb 2012
Reputation: 27
#4
RE: Move Player

Smoke's suggestion is probably the better way of doing it, however...

In the Justine expansion you have this extra function, shown at the bottom of hte Player section in the engine scripts page

void MovePlayerForward(float afAmount)

“REQUIRES THE 1.2 PATCH: JUSTINE” Moves the player forward. It needs to be called in a timer that updates 60 times / second.

Now, if you set up a script area behind where the player would be if they walked into the area displaying the message, then you can call
void StartPlayerLookAt(string& asEntityName, float afSpeedMul, float afMaxSpeed, string& asAtTargetCallback);
In the definition for the callback function, call StopPlayerLookAt(); [now they should be looking in the direction away from the area they walked into], then call MovePlayerForward in a looping timer function to get them to move away!

I've never done that before so I'm not entirely sure it will work, and I still think Smoke's idea is better/easier to implement, but it might be worth giving it a go!

(This post was last modified: 05-20-2013, 07:08 PM by Adrianis.)
05-20-2013, 07:08 PM
Find


Messages In This Thread
Move Player / Remove Timers - by Shirder - 05-20-2013, 06:10 PM
RE: Move Player - by Slanderous - 05-20-2013, 06:29 PM
RE: Move Player - by OriginalUsername - 05-20-2013, 06:35 PM
RE: Move Player - by Adrianis - 05-20-2013, 07:08 PM
RE: Move Player - by Shirder - 05-20-2013, 08:41 PM
RE: Move Player - by Adrianis - 05-21-2013, 02:45 AM
RE: Move Player - by PutraenusAlivius - 05-21-2013, 02:43 AM
RE: Move Player - by Shirder - 05-21-2013, 10:20 PM
RE: Move Player / Remove Timers - by Shirder - 05-22-2013, 11:33 AM
RE: Move Player / Remove Timers - by Adrianis - 05-22-2013, 01:03 PM



Users browsing this thread: 1 Guest(s)