Set marker for skins - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Set marker for skins (
/showthread.php?tid=91406)
Set marker for skins -
DeathOnaStick - 14.08.2009
Heyho community,
here we go again with one of my questions XD.
There is following problem:
I just made this code:
Код:
if (!strcmp("/lvtaxi",cmdtext,true))
{
SendClientMessage(playerid,0xFF800096,"you called a taxi and your playermarker is shown on the minimap so the driver can find you!");
SendClientMessage(playerid,0xFF800096,"type '/canceltaxi' to cancel your call for a taxi!");
SendClientMessageToSkin(234, 0x00FF4096, "DISPATCH: call for a taxi recieved! the caller is marked 'lightgreen'on the minimap");
for(new i = 0; i < MAX_PLAYERS; i++)
SetPlayerMarkerForPlayer(i,playerid ,0x00FF00FF);
}
okaay... it works well but that problem what i have is, that i dont want it to be shown for all players, but for one skin(234). I tried many things yet, but without success (that was really frustrating :/ )
But i still hope anybody here can help me XD
Thanks,
DeathOnaStick
Re: Set marker for skins -
brett7 - 14.08.2009
if(GetPlayerSkin(playerid) == 185)
{
do stuff
}
Re: Set marker for skins -
DeathOnaStick - 14.08.2009
nope... that doesnt work because "playerid" is the one who wrote the command... i want it to be the one who should get the Marker, and not the Player, who writes the command, itself.
Re: Set marker for skins -
DeathOnaStick - 15.08.2009
Does nobody know the sollution? Maybe have some alternatives to that? Really frustrating again :/
Re: Set marker for skins -
dice7 - 15.08.2009
Then use 'i'
Re: Set marker for skins -
DeathOnaStick - 15.08.2009
yes... and then?
When i try this i have:
Код:
if(GetPlayerSkin(i) == 185)
{
for(new i = 0; i < MAX_PLAYERS; i++)
SetPlayerMarkerForPlayer(i,playerid ,0x00FF00FF);
}
it still makes a marker for everybody, because i used "i" and when i would use "playerid" it would just make it for the one who sends the answer :/
Re: Set marker for skins -
dice7 - 15.08.2009
pawn Код:
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(GetPlayerSkin(i) == 185) SetPlayerMarkerForPlayer(i,playerid ,0x00FF00FF);
}
Re: Set marker for skins -
DeathOnaStick - 15.08.2009
kk thanks... working