SA-MP Forums Archive
Gives me an error even thought there ain't nothing wrong? - 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: Gives me an error even thought there ain't nothing wrong? (/showthread.php?tid=548715)



Gives me an error even thought there ain't nothing wrong? - Write - 01.12.2014

fixed it, had to hook the arrays to compare the two


Re: Gives me an error even thought there ain't nothing wrong? - Stinged - 01.12.2014

Use MAX_PLAYER_NAME instead of sizeof(LastAdmin[countt]) because it's a 2D array.


Re: Gives me an error even thought there ain't nothing wrong? - Runn3R - 01.12.2014

You're probably missing a ";" above the error line.
Give us the line above the error line


Re: Gives me an error even thought there ain't nothing wrong? - Write - 01.12.2014

Quote:
Originally Posted by Stinged
View Post
Use MAX_PLAYER_NAME instead of sizeof(LastAdmin[countt]) because it's a 2D array.
What? that dosen't make sense, I am using LastAdmin[countt] for something else, why would I just replace it with MAX_PLAYER_NAME if it is already defined as one here new LastAdmin[21][MAX_PLAYER_NAME];


Quote:
Originally Posted by Runn3R
View Post
You're probably missing a ";" above the error line.
Give us the line above the error line
I'm not, I even moved the code it gives me the new line with that code there.


Re: Gives me an error even thought there ain't nothing wrong? - Runn3R - 01.12.2014

LastAdmin[21][MAX_PLAYER_NAME]
This is basicly: LastAdmin[21][24]...


Re: Gives me an error even thought there ain't nothing wrong? - Write - 01.12.2014

Quote:
Originally Posted by Runn3R
View Post
LastAdmin[21][MAX_PLAYER_NAME]
This is basicly: LastAdmin[21][24]...
That dosen't make any sense at all -_-


Re: Gives me an error even thought there ain't nothing wrong? - Runn3R - 01.12.2014

Code:
GetPlayerName(playerid, LastAdmin[countt], 24);
MAX_PLAYER_NAME == 24 it is already defined inside a_samp.
So yeah.


Re: Gives me an error even thought there ain't nothing wrong? - Write - 01.12.2014

deleted


Re: Gives me an error even thought there ain't nothing wrong? - Runn3R - 01.12.2014

Can you give us the full code? We can't help you like this -.-


Re: Gives me an error even thought there ain't nothing wrong? - Write - 01.12.2014

fixed