making team help
#1

I am a new scripter and im trying to make a teamdeathmatch gamemode but i have problem making the teams and i following an tutorial i did everything the tutorial say but i keep getting errors. can someone tell me what i did wrong.



SetPlayerTeamFromClass(playerid, classid)
{
switch(classid)
{
case 0:
{
gTeam[playerid] = TEAM_YSPAWN;
}
case 1:
{
gTeam[playerid] = TEAM_BALLAS;
}
}
return 1;
}


and i keep getting these errors

C:\Documents and Settings\NADINE.HOME-C13C86E48E\Desktop\New Folder\sampserver 2\gamemodes\lskz.pwn(399) : error 029: invalid expression, assumed zero
C:\Documents and Settings\NADINE.HOME-C13C86E48E\Desktop\New Folder\sampserver 2\gamemodes\lskz.pwn(403) : error 029: invalid expression, assumed zero
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


line 399: gTeam[playerid] = TEAM_YSPAWN;

line 403: gTeam[playerid] = TEAM_BALLAS;
Reply
#2

can you show each line with its number ?
Reply
#3

Quote:
Originally Posted by Ahmad45123
Посмотреть сообщение
can you show each line with its number ?
There are the lines
Reply
#4

Bump
Reply
#5

Sorry for the third post but I really need help
Reply
#6

How did you define gTeam, TEAM_YSPAWN and TEAM_BALLAS?
Reply
#7

New gTeam [MAX_PLAYERS];

#define TEAM_YSPAWN
#define TEAM_BALLAS
Reply
#8

try this :

#define TEAM_YSPAWN 1
#define TEAM_BALLAS 2
Reply
#9

Quote:
Originally Posted by TomatoRage
Посмотреть сообщение
try this :

#define TEAM_YSPAWN 1
#define TEAM_BALLAS 2
Thanks man that helped me
+1rep
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)