[SOLVED]Please
#1

how would you make it so if they try to spawn as a certain skin it says you dont have a high required score

like TEAM_COP case:6 so only that certain skin cant be choosen unless you have like a score of 500 or something

Ex your try to select this skin but its hows

Код:
~w~you cannot use this class/skill~n~ you do not have the required score (500+) to play as~n~ ~b~ S.W.A.T
Reply
#2

can any one help me
i tried this and it didnt work

Код:
if(gTeam[playerid] == TEAM_COP || classid == 6 ) {
GetPlayerScore(playerid, oscore =< 999);
GameTextForPlayer(playerid,"~w~you cannot use this class/skill~n~ you do not have the required score (1000+) to play as~n~ ~b~ S.W.A.T.",5000,3);
	return 0;
}
Reply
#3

can anyone help me
Reply
#4

i think you can try this:
Код:
if(classid == 0)
{
if(gTeam[playerid] == TEAM_COP ) 
{
GetPlayerScore(playerid, oscore =< 999);
}
}
else
{
GameTextForPlayer(playerid,"~w~you cannot use this class/skill~n~ you do not have the required score (1000+) to play as~n~ ~b~ S.W.A.T.",5000,3);
}
	return 0;
I think this works
Reply
#5

i didnt work thanks though i got these

Код:
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5015) : warning 219: local variable "classid" shadows a variable at a preceding level
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5058) : warning 219: local variable "classid" shadows a variable at a preceding level
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : error 029: invalid expression, assumed zero
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : warning 215: expression has no effect
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : error 029: invalid expression, assumed zero
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#6

hm.. maybe try this:

Код:
for(new i = 0; i <MAX_PLAYERS; i++)
{
if(gTeam[i] == TEAM_COP || classid == 0) 
{
GetPlayerScore(playerid, oscore =< 999);
}
}
else
{
GameTextForPlayer(playerid,"~w~you cannot use this class/skill~n~ you do not have the required score (1000+) to play as~n~ ~b~ S.W.A.T.",5000,3);
}
	return 0;
Reply
#7

same results
Reply
#8

i changed a few things and got this
Код:
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5015) : warning 219: local variable "classid" shadows a variable at a preceding level
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5058) : warning 219: local variable "classid" shadows a variable at a preceding level
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5204) : warning 202: number of arguments does not match definition
C:\Documents and Settings\admin_pass\Desktop\KVRCR2\gamemodes\convert1.pwn(5852) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Warnings.
What i put
Код:
}
for(new i = 0; i <MAX_PLAYERS; i++)
{
if(gTeam[i] == TEAM_COP || classid == 6)
{
GetPlayerScore(playerid, oscore <= 999);
}
}
{
GameTextForPlayer(playerid,"~w~you cannot use this class/skill~n~ you do not have the required score (1000+) to play as~n~ ~b~ S.W.A.T.",5000,3);
}
Reply
#9

i tried it and it showed message but still let me spawn as that skin
Reply
#10

Код:
for(new i = 0; i <MAX_PLAYERS; i++)
{
if(gTeam[i] == TEAM_COP || classid == 6)
{
GetPlayerScore(playerid, oscore <= 999);
}
}
else
{
GameTextForPlayer(playerid,"~w~you cannot use this class/skill~n~ you do not have the required score (1000+) to play as~n~ ~b~ S.W.A.T.",5000,3);
}
You have a lot }
and the else forget
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)