Why SetPlayerPos not working? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Why SetPlayerPos not working? (
/showthread.php?tid=575684)
Why SetPlayerPos not working? -
GeorgeMcReary - 29.05.2015
Hello,
I tried to use SetPlayerPos to teleport a player to a casino but when i do this insted of setting player's position inside casino, it falls underground and then starting falling from sky


please help!
Code which makes TP:
Код:
f(IsPlayerInRangeOfPoint(playerid, 3.0, 1446.8043,-1561.2388,13.6759))
{
if(PlayerInfo[playerid][pDonateRank] >= 1)
{
SetPlayerPos(playerid, 2581.2180,1417.3933,7701.9907);
SetPlayer// teleport here
return 1;
}
what i have done wrong?
Re: Why SetPlayerPos not working? -
bgedition - 29.05.2015
use this:
https://sampwiki.blast.hk/wiki/SetPlayerInterior
Edit: there are the interior ids
http://weedarr.wikidot.com/interior
Re: Why SetPlayerPos not working? -
Ghazal - 29.05.2015
Might be because you didn't use Streamer_UpdateEx (If the casino is mapped.)
Re: Why SetPlayerPos not working? -
GeorgeMcReary - 29.05.2015
Quote:
Originally Posted by bgedition
|
you mean i should use it to set int 0 or something else?
Re: Why SetPlayerPos not working? -
bgedition - 29.05.2015
yep look at my previous post. I edited it
SetPlayerInterior(playerid, interiorid);
Re: Why SetPlayerPos not working? -
GeorgeMcReary - 29.05.2015
Quote:
Originally Posted by Slotomic
Might be because you didn't use Streamer_UpdateEx (If the casino is mapped.)
|
can you show me how to do it?
Re: Why SetPlayerPos not working? -
PepsiCola23 - 29.05.2015
You have to know the interior id,and then use what bgedition said.
Re: Why SetPlayerPos not working? -
Vince - 29.05.2015
If it's a default interior, the Z coordinate is absolutely incorrect. Most interiors sit around 1000 Z. Also GTA SA's engine tends to screw up if you place anything outside its 6000 x 6000 x 6000 bounding box (that is -3000 to 3000 on every axis).
Re: Why SetPlayerPos not working? -
SoFahim - 29.05.2015
use setplayerinterior(playerid , the casino's interior id) Simple