[PROBLEM]Weird Trouble with 2 codes
#1

Hello guys, i am recently scripting a gamemode, but now i am having some trouble..
i have an include which contains:


//CODE No1

pawn Код:
stock IsPlayerRegistered(playerid)
{

new name[MAX_PLAYER_NAME];  GetPlayerName(playerid, name, sizeof(name));
new file[256], tmp;

format(file,256,"users/%s.sav",udb_encode(name));
tmp = dini_Int(file,"registered");

if( (IsPlayerConnected(playerid)) && (tmp == 1))
    return true;
else return false;

}
so this working fine:

pawn Код:
if(IsPlayerRegistered(playerid))
{
//
}
but when i add in my gamemode these code to make some teamnames :


//CODE No2

pawn Код:
new fstn[256];
        format(fstn,sizeof(fstn),"[Gangster]%s", playername(playerid) );
     SetPlayerName(playerid,fstn);
     djSet(fstt,"player/TeamName",fstn);
no one of the codes are working, when i am removing the CODE No1 , the code No2 working..
when i am removing CODE No2, code No1 working...

but i want to get both codes working!

please do not offer me other ways to make teamnames, just help me to solve this weird problem...
thanks

PS: Pawn has no warnings/errors , its clean on combile..
PS.2:Sorry for my bad english
Reply
#2

bump
sorry for bumping so early but i have to fix this fast..
Reply
#3

What do you mean "not working" ?
Reply
#4

Quote:
Originally Posted by MadeMan
Посмотреть сообщение
What do you mean "not working" ?
i mean not working,
for example if i have a command wich send a message when the player is registered, if are the both codes on the script then the command do nothing..
but if i remove the code No2 then the command working fine...
and if i remove the code No1 then something wich use the code No2 is working fine...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)