Need help with error:undefined symbol "SetupPlayerForClassSelection"
#5

Quote:

public OnPlayerRequestClass(playerid, classid)
{
return 1;
}

switch(classid)
{
case 0 .. 14:
{
gTeam[playerid] = GROVE;
}
case 15 .. 20:
{
gTeam[playerid] = AZTEC;
}
case 21 .. 27:
{
gTeam[playerid] = TRIAD;
}
case 28 .. 31:
{
gTeam[playerid] = BALLA;
}
case 32 .. 35:
{
gTeam[playerid] = VAGOS;
}
case 36 .. 41:
{
gTeam[playerid] = RIFFA;
}
case 42 .. 50:
{
gTeam[playerid] = ITALI;
}
case 51 .. 56:
{
gTeam[playerid] = TRIAD;
}
}

switch must be insibe OnPlayerRequestClass, like that
PHP код:
public OnPlayerRequestClass(playeridclassid)
{
    switch(
classid)
    {
                case 
.. 14:
        {
            
gTeam[playerid] = GROVE;
        }
                case 
15 .. 20:
                {
            
gTeam[playerid] = AZTEC;
                }
        case 
21 .. 27:
        {
            
gTeam[playerid] = TRIAD;
        }
                case 
28 .. 31:
                {
                        
gTeam[playerid] = BALLA;
                }
                case 
32 .. 35:
                {
                        
gTeam[playerid] = VAGOS;
                }
                case 
36 .. 41:
                {
                        
gTeam[playerid] = RIFFA;
                }
                case 
42 .. 50:
                {
                        
gTeam[playerid] = ITALI;
                }
                case 
51 .. 56:
                {
                        
gTeam[playerid] = TRIAD;
                }
    }
    return 
1;

Here is SetupPlayerForClassSelection, from riveshell script as Vince said
PHP код:
forward SetupPlayerForClassSelection(playerid);
public 
SetupPlayerForClassSelection(playerid)
{
    
// Set the player's orientation when they're selecting a class.
    
SetPlayerPos(playerid,1984.4445,157.9501,55.9384);
    
SetPlayerCameraPos(playerid,1984.4445,160.9501,55.9384);
    
SetPlayerCameraLookAt(playerid,1984.4445,157.9501,55.9384);
    
SetPlayerFacingAngle(playerid,0.0);

and Readd this line
PHP код:
SetupPlayerForClassSelection(playerid); 
OnPlayerRequestClass
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)