SetPlayerMarkerForPlayer issue - 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: SetPlayerMarkerForPlayer issue (
/showthread.php?tid=596357)
SetPlayerMarkerForPlayer issue -
PaulDinam - 16.12.2015
I've never really used SetPlayerMarkerForPlayer, right now i'm trying to make a function so that it hides the player's marker on the radar but the color remains the same, however it works partially. For example, there's 2 players in the cop chase and only one of them has their marker hidden but the other one has it visible for some odd reason.
Here's my code:
pawn Код:
HideChaseMarkers()
{
for(new i = 0; i < MAX_COP_CHASE; i++)
{
new player = chaseList[i];
if(player == INVALID_PLAYER_ID) continue;
for(new cop = 0; cop < MAX_COP_CHASE; cop++)
{
new toPlayer = chaseList[cop];
if(toPlayer == INVALID_PLAYER_ID) continue;
if(toPlayer == player) continue;
SetPlayerMarkerForPlayer(toPlayer, player, (GetPlayerColor(player) & 0xFFFFFF00));
}
}
}
I tried debugging and it printed out everything properly, I've no idea what to do now so if anyone could help I would appreciate it.
Re: SetPlayerMarkerForPlayer issue -
prineside - 16.12.2015
Maybe you should also call
PHP код:
SetPlayerMarkerForPlayer(player, toPlayer, ...)
as this funcion only sets marker color of player A for player B