SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 13/04/2012, 07:28 PM   #1
captainjohn
Huge Clucker
 
captainjohn's Avatar
 
Join Date: Jul 2010
Location: United Kingdom
Posts: 409
Reputation: 29
Default warning 219: local variable "PlayerName" shadows a variable at a preceding level

Code:
C:\Users\J\Desktop\Script\gamemodes\Bayside.pwn(8047) : warning 219: local variable "PlayerName" shadows a variable at a preceding level

Lines 8042 - 8048.

pawn Code:
dcmd_bigsmoke(playerid,params[])
{
    #pragma unused params
    PlayerDm[playerid] = 1;
    ResetPlayerWeapons(playerid);
    new PlayerName[MAX_PLAYER_NAME];
    GetPlayerName(playerid,PlayerName,sizeof(PlayerName));
captainjohn is offline   Reply With Quote
Old 13/04/2012, 07:39 PM   #2
Kiets
Big Clucker
 
Join Date: Oct 2011
Posts: 106
Reputation: 4
Default Re: warning 219: local variable "PlayerName" shadows a variable at a preceding level

You have already defined somewhere out of this function "PlayerName".
Kiets is offline   Reply With Quote
Old 13/04/2012, 07:44 PM   #3
Twisted_Insane
Gangsta
 
Twisted_Insane's Avatar
 
Join Date: Feb 2012
Posts: 975
Reputation: 95
Default Re: warning 219: local variable "PlayerName" shadows a variable at a preceding level

pawn Code:
new playaname[MAX_PLAYER_NAME];
GetPlayerName(playerid,playaname,sizeof(playaname));
__________________
Join the BEST Gangwar-server ever; Los Santos Gangwars!
http://forum.sa-mp.com/showthread.ph...42#post2235842
^ Read!

Any problems with ZCMD-commands? Simply PM me your topic or check out the tutorial(s) in my signature, more'll come soon!

Twisted_Insane is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
error 001: expected token: ";", but found "-identifier-" matwz Scripting Help 23 26/08/2017 03:30 PM
Expected token: "-string end-", but found "-identifier-" McCarthy Scripting Help 11 30/05/2012 11:32 PM
error 001: expected token: "-string end-", but found "-identifier-" Any Ideas? Jack_Rocker Scripting Help 4 04/11/2011 01:03 PM
error 001: expected token: "-string end-", but found "-identifier-" samtey Help Archive 9 04/08/2011 01:26 PM
error 001: expected token: "-string end-", but found "-identifier-" cdcyborg Help Archive 1 14/11/2009 06:22 AM


All times are GMT. The time now is 02:15 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.