View unanswered posts | View active topics It is currently Fri Dec 27, 2024 11:16 pm



Reply to topic  [ 2 posts ] 
 How to check which specific player is controlling actor 
Author Message
User avatar

Joined: Tue Jun 12, 2007 11:52 pm
Posts: 13144
Location: Here
Reply with quote
Post How to check which specific player is controlling actor
How do you check which specific player is controlling the stated actor? Search and wiki didn't help.


Wed Sep 30, 2009 2:36 am
Profile
DRL Developer
DRL Developer
User avatar

Joined: Wed Dec 13, 2006 5:27 am
Posts: 3138
Location: A little south and a lot west of Moscow
Reply with quote
Post Re: How to check which specific player is controlling actor
Use a for loop to cycle through ActivityMan:GetActivity().PlayerCount. With each loop, check if self.Controller.Player is equal to the player being checked.
Don't forget that the player number starts at 0. That means that if there are 2 players, the players are 1 and 0. In your for loop, make sure to only loop the player count minus one.


Wed Sep 30, 2009 4:16 am
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 2 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.027s | 15 Queries | GZIP : Off ]