Guten Tag,
ich habe knapp 5 Warning´s Ich Fange mal an :
if(IsPlayerNPC(playerid))return 1;
new Spielername[64];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(Spielername,sizeof(Spielername),"/Accounts/%s.txt",name);
if(dini_Exists(Spielername))
Warning Code : C:\Users\Patrick\Desktop\Server\gamemodes\IRP-City.pwn(72) : warning 219: local variable "Spielername" shadows a variable at a preceding Level
--------------------------------
stock Register(playerid,key[])
{
new Spielername[120];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(Spielername,sizeof(Spielername),"/Accounts/%s.txt",name);
dini_Create(Spielername);
dini_Set(Spielername,"Passwort",key);
SendClientMessage(playerid,BLAU,"Erfolgreich registriert.");
SetPlayerScore(playerid,0);
SetPVarInt(playerid,"loggedin",1);
return 1;
}
Warning Code : C:\Users\Patrick\Desktop\Server\gamemodes\IRP-City.pwn(419) : warning 219: local variable "Spielername" shadows a variable at a preceding Level
---------------------------------------------------------------------
stock Login(playerid,key[])
{
new Spielername[64];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(Spielername,sizeof(Spielername),"/Accounts/%s.txt",name);
if(gettime()<dini_Int(Spielername,"timeban"))
{
SendClientMessage(playerid,ROT,"Du bist noch gebannt. Komm später wieder.");
Kick(playerid);
return 1;
Warning Code : C:\Users\Patrick\Desktop\Server\gamemodes\IRP-City.pwn(433) : warning 219: local variable "Spielername" shadows a variable at a preceding Level
----------------------------------------------------------
stock LoadAccount(playerid)
{
new Spielername[64];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(Spielername,sizeof(Spielername),"/Accounts/%s.txt",name);
SetPlayerScore(playerid,dini_Int(Spielername,"Level"));
GivePlayerMoney(playerid,dini_Int(Spielername,"Geld"));
SetPVarInt(playerid,"Adminlevel",dini_Int(Spielername,"Adminlevel"));
SetPVarInt(playerid,"Fraktion",dini_Int(Spielername,"Fraktion"));
SetPVarInt(playerid,"Baned",dini_Int(Spielername,"Baned"));
if(GetPVarInt(playerid,"Baned")==1)
{
SendClientMessage(playerid,ROT,"Du bist vom Server gebannt.");
Kick(playerid);
}
SetPVarInt(playerid,"loggedin",1);
return 1;
}
Warning Code : C:\Users\Patrick\Desktop\Server\gamemodes\IRP-City.pwn(461) : warning 219: local variable "Spielername" shadows a variable at a preceding Level
--------------------------------------------------------
stock SpielerSpeichern(playerid)
{
if(GetPVarInt(playerid,"loggedin")==1)
{
new Spielername[64];
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid,name,sizeof(name));
format(Spielername,sizeof(Spielername),"/Accounts/%s.txt",name);
dini_IntSet(Spielername,"Level",GetPlayerScore(playerid));
dini_IntSet(Spielername,"Geld",GetPlayerMoney(playerid));
dini_IntSet(Spielername,"Adminlevel",GetPVarInt(playerid,"Adminlevel"));
dini_IntSet(Spielername,"Fraktion",GetPVarInt(playerid,"Fraktion"));
dini_IntSet(Spielername,"Baned",GetPVarInt(playerid,"Baned"));
dini_IntSet(Spielername,"timeban",GetPVarInt(playerid,"timeban"));
}
return 1;
}
Warning Code : C:\Users\Patrick\Desktop\Server\gamemodes\IRP-City.pwn(483) : warning 219: local variable "Spielername" shadows a variable at a preceding level
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
5 Warnings.
Danke für eure Hilfe
mfg Ffreak