SA-MP Forums Archive
PlayerName error, Rep + - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: PlayerName error, Rep + (/showthread.php?tid=337229)



PlayerName error, Rep + - Karl[NDZ] - 25.04.2012

I get this error when I'm making houses for my server.
pawn Код:
(851) : warning 219: local variable "PlayerName" shadows a variable at a preceding level
Line 851:
pawn Код:
new PlayerName[24];



Re: PlayerName error, Rep + - fordawinzz - 25.04.2012

delete the line


Re: PlayerName error, Rep + - Karl[NDZ] - 25.04.2012

Quote:
Originally Posted by fordawinzz
Посмотреть сообщение
delete the line
Then I get new errors:
pawn Код:
C:\Users\Karl\Desktop\Night-Drifterz\gamemodes\nightdrifterz.pwn(851) : error 076: syntax error in the expression, or invalid function call
C:\Users\Karl\Desktop\Night-Drifterz\gamemodes\nightdrifterz.pwn(852) : error 076: syntax error in the expression, or invalid function call
C:\Users\Karl\Desktop\Night-Drifterz\gamemodes\nightdrifterz.pwn(857) : error 076: syntax error in the expression, or invalid function call



Re: PlayerName error, Rep + - Tomer!.$ - 25.04.2012

Try this instead.
Код:
new pName[MAX_PLAYER_NAME];



Re: PlayerName error, Rep + - Karl[NDZ] - 25.04.2012

Quote:
Originally Posted by Tomer!.$
Посмотреть сообщение
Try this instead.
Код:
new pName[MAX_PLAYER_NAME];
Thx man it worked!


Re: PlayerName error, Rep + - Karl[NDZ] - 25.04.2012

Im wondering about something: I got a host from volt-host, and am I supposed to use mysql for the house saving and stuff?


Re: PlayerName error, Rep + - Tomer!.$ - 25.04.2012

You can use any saving system you want, MySQL, SQLite, Y_INI, simple INI, dini (Not recommended though)


Re: PlayerName error, Rep + - sanplayer - 25.04.2012

MySQL I'd say is most secure.
My script using MySQL I am coding.

10% done :P