Warnings
#1

i get 4 warnings..

PHP код:
(38990) : warning 219local variable "doors" shadows a variable at a preceding level
(38990) : warning 219local variable "lights" shadows a variable at a preceding level
(39021) : warning 219local variable "doors" shadows a variable at a preceding level
(39021) : warning 219local variable "lights" shadows a variable at a preceding level 
PHP код:
new panels,doors,lights,tires
if i delete new i get undefinded..
Reply
#2

EDIT: can you write the warnings you get after deleting it.
Reply
#3

Quote:
Originally Posted by Naruto_Emilio
Посмотреть сообщение
EDIT: can you write the warnings you get after deleting it.
pawn Код:
(38990) : warning 219: local variable "doors" shadows a variable at a preceding level
(38990) : warning 219: local variable "lights" shadows a variable at a preceding level
(39021) : warning 219: local variable "doors" shadows a variable at a preceding level
(39021) : warning 219: local variable "lights" shadows a variable at a preceding level
As far as I know you're trying to use these variables outside of the certain area as these variables are not global but local. Try making them global (put them at the top of your script).
Reply
#4

i got an anti name if i put it at onplayerconnect i get Connected then restarting cant connect tht happens if i have name even with _ FirstName_LastName

PHP код:
                new pname[MAX_PLAYER_NAME];
                      new 
namestr strfind(pname"_"true);
                    if(
namestr == -1)
                    {
                    
GetPlayerName(playeridpnamesizeof(pname));
                    
SendClientMessage(playeridCOLOR_RED"Your name must be like this Firstname_Lastname");
                    
Kick(playerid);
                    return 
1;
                    } 
EDIT:no warnings but cant work..
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)