roflmuffin / CounterStrikeSharp

CounterStrikeSharp allows you to write server plugins in C# for Counter-Strike 2/Source2/CS2
https://docs.cssharp.dev
Other
709 stars 110 forks source link

How to point from the obtained "userid" to "CCSPlayerPawn"? #509

Open YCcHxxt opened 2 weeks ago

YCcHxxt commented 2 weeks ago

How to point from the obtained "userid" to "CCSPlayerPawn"? I have obtained "userid", but I want to teleport the player with userid=2 to a certain location Maybe the problem is relatively simple. I'm sorry to disturb everyone

TitaniumLithium commented 2 weeks ago

Almost Everything you can find in Doc : https://docs.cssharp.dev/docs/reference/referencing-players.html var player = Utilities.GetPlayerFromUserid(userid);