SA-MP Forums Archive
Get Right Color - 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: Get Right Color (/showthread.php?tid=81893)



Get Right Color - Teyhouse - 14.06.2009


Hello,
i try following:
If a Player from the Fraction 1 (Police) logged in the game, the Player would get the Color Blue!
My try:
Код:
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1) { SendClientMessage(playerid, COLOR_WHITE,"You are a Officer!); SetPlayerColor(playerid, 0x0000FFFF); }
Bat it doesn't work - i didn't know were in my (Godfather)Script i have to place my Code? I had it in the Login-Public bat there comes only the "You are a Officer" Message, bat my Player isn't blue!?

I know my English is not god because of this i try to Explain it all in all:
Player from Team 1 (Police) logged in > get the Color Blue

What is wrong on my Script and were i have to paste it in what part of my Script?

Ohh it cost my many many time to solve this problem... mhhh



Re: Get Right Color - qum - 14.06.2009

Hello

Quote:
Originally Posted by Teyhouse
Код:
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1) { SendClientMessage(playerid, COLOR_WHITE,"You are a Officer!); SetPlayerColor(playerid, 0x0000FFFF); }
Not verry big fault, but i think this is the problem you have
SetPlayerColor(playerid, 0x0000FFFF);
and it must be: ( i think so )
SetPlayerColor(playerid, 0x0000FFFFAA);

It's 0x(colorcode yours "0000FFFF")AA
for more info look
https://sampwiki.blast.hk/wiki/SetPlayerColor

Hope it works, otherwise feel free to pm me.
Qum


Re: Get Right Color - Teyhouse - 14.06.2009

Sorry, no that's not the Problem if i use a Text-Input Command with my Color-Code the Player is Blue, well the problem must be at a other place... bat where?
How i had explained:
At the End before the last Return 1; in public OnPlayerLogin(playerid,password[]) comes i put it in,
and the SendClientMessage i see bat the color doesn't change!?


Re: Get Right Color - Teyhouse - 15.06.2009

Nobody know how to solve this Problem...?


Re: Get Right Color - Teyhouse - 15.06.2009

Sorry bat: No

i puted it before the last return 1; in the Public OnPlayerSpawn, then i loged in to the game and the Message cames bat the Color doesn't change! Nobdoy know the solve that's crazy bat why!?


Re: Get Right Color - Pghpunkid - 16.06.2009

Replace Color_White with 0x0000FFFF.