4 errors in one line -_- | Rep+
#1

Hello, i was making a Clan Detecting system from a FS in my GM .
Quote:

C:\Users\Faqahat\LSSW\Server\gamemodes\LS-SW.pwn(3562) : error 017: undefined symbol "PlayerInfo"
C:\Users\Faqahat\LSSW\Server\gamemodes\LS-SW.pwn(3562) : warning 215: expression has no effect
C:\Users\Faqahat\LSSW\Server\gamemodes\LS-SW.pwn(3562) : error 001: expected token: ";", but found "]"
C:\Users\Faqahat\LSSW\Server\gamemodes\LS-SW.pwn(3562) : error 029: invalid expression, assumed zero
C:\Users\Faqahat\LSSW\Server\gamemodes\LS-SW.pwn(3562) : fatal error 107: too many error messages on one line

and on line 3562
Quote:

PlayerInfo[playerid][pClan]=0;

Thanks in advance
i know im a nab lol
Reply
#2

pawn Код:
(PlayerInfo [playerid][pClan] = 0);
Try that?
Reply
#3

nah bro
here are surroundings
Quote:

SendClientMessage ( playerid , 0x00FF00AA , str ) ;
(PlayerInfo [playerid][pClan] = 0);
strins(nom,"[Put the clan tag here]",0,sizeof(nom));
SetPlayerName(pid,nom);

Reply
#4

Got the correct includes and everything?
Reply
#5

Yeap Same line is used one other place but no error in that :/
Reply
#6

make sure you have a varaible on top like this
pawn Код:
new PlayerInfo[MAX_PLAYERS];
Reply
#7

You need to add enum

Код:
enum pInfo
{
    pClan
}
new PlayerInfo[MAX_PLAYERS][pInfo];
Reply
#8

Quote:
Originally Posted by RenSoprano
Посмотреть сообщение
You need to add enum

Код:
enum pInfo
{
    pClan
}
new PlayerInfo[MAX_PLAYERS][pInfo];
REP++ D Thank you
Reply
#9

No offense to OP, but it disgust me seeing entirely new scripters using multi-dimensional arrays with enums holding the data. OP in this case has no idea what variables even are, as he just assumes that PlayerInfo will work as he has seen it in other scripts.

If you don't know what enums does, what multi-dimensional arrays does, simply avoid them until you know what they do.
Reply
#10

Quote:
Originally Posted by LarzI
Посмотреть сообщение
No offense to OP, but it disgust me seeing entirely new scripters using multi-dimensional arrays with enums holding the data.
why would it disgust you?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)