litle problem.
#1

hey guys. I'm having a little problem at the moment.
I'm working with teams now. But something is really strange.
I hope you guys will understand this.

When you spawn you will have your name colored to the team color. That is waht must happen.
This is also saving. SO when I relog I will have the color again. But when I have a red color and I relog and I join as ID 0 I see the exact color name as I had when I logged off. That was just good,
Then I logged in as ID 1 and I did see my name in a purple color. But the other people saw my name color as the color I logged of with.

So the problem is:
You only see your color from where you logged in as ID 0.
Other people see the good color. But when you are not ID 0 you will see your own color wrong.
Please help me guys.

I'm using this at where the player stats saves:
dUserSetINT(PlayerName2(playerid)).("Color",GetPla yerColor(playerid));

and this is when theb player logs in.
the whole script of the login
Код:
LoginPlayer(playerid)
{
	if(ServerInfo[GiveMoney] == 1) {ResetPlayerMoney(playerid); GivePlayerMoney(playerid, dUserINT(PlayerName2(playerid)).("money") ); }

	dUserSetINT(PlayerName2(playerid)).("loggedin",1);
	SetPlayerColor(playerid, dUserINT(PlayerName2(playerid)).("Color") );
	PlayerInfo[playerid][Deaths] = (dUserINT(PlayerName2(playerid)).("deaths"));
	PlayerInfo[playerid][Kills] = (dUserINT(PlayerName2(playerid)).("kills"));
	PlayerInfo[playerid][Exp] = (dUserINT(PlayerName2(playerid)).("Exp"));
	PlayerInfo[playerid][Bank] = (dUserINT(PlayerName2(playerid)).("Bank"));
 	PlayerInfo[playerid][Level] = (dUserINT(PlayerName2(playerid)).("level"));
  	PlayerInfo[playerid][hours] = dUserINT(PlayerName2(playerid)).("hours");
  	PlayerInfo[playerid][mins] = dUserINT(PlayerName2(playerid)).("minutes");
  	PlayerInfo[playerid][secs] = dUserINT(PlayerName2(playerid)).("seconds");
	PlayerInfo[playerid][Registered] = 1;
 	PlayerInfo[playerid][LoggedIn] = 1;
}
You can see the setcolor
Reply


Messages In This Thread
litle problem. - by bartje01 - 27.05.2010, 21:52
Re: litle problem. - by bartje01 - 27.05.2010, 23:02
Re: litle problem. - by bartje01 - 28.05.2010, 05:28
Re: litle problem. - by bartje01 - 28.05.2010, 12:02
Re: litle problem. - by DJDhan - 28.05.2010, 12:08
Re: litle problem. - by bartje01 - 28.05.2010, 12:37
Re: litle problem. - by bartje01 - 28.05.2010, 14:06

Forum Jump:


Users browsing this thread: 1 Guest(s)