GetPlayerFPS + another question
#8

Well look, I'm getting a few errors:

Quote:

D:\Program Files\GTA San Andreas\SAMP_Server\gamemodes\deathmatch.pwn(1341) : warning 225: unreachable code
D:\Program Files\GTA San Andreas\SAMP_Server\gamemodes\deathmatch.pwn(2256) : error 017: undefined symbol "string"
D:\Program Files\GTA San Andreas\SAMP_Server\gamemodes\deathmatch.pwn(2256) : error 017: undefined symbol "string"
D:\Program Files\GTA San Andreas\SAMP_Server\gamemodes\deathmatch.pwn(2256) : error 029: invalid expression, assumed zero
D:\Program Files\GTA San Andreas\SAMP_Server\gamemodes\deathmatch.pwn(2256) : fatal error 107: too many error messages on one line

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


4 Errors.

I never defined a string here:

pawn Код:
forward FPSUP();
public FPSUP()
{
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i))
            {
                format(string,sizeof(string),"FPS: %d",FPS2[i]-1); //here
                        TextDrawSetString(FPS[i],string); //here
                }
                continue;
        }
}
Not sure where I should have had put it...

Also, is this okay under "OnGameModeInit"?

pawn Код:
public OnGameModeInit() {
   
    //other stuff
        for(new i=0; i < sizeof(ZoneInfo); i++)
        {
            ZoneID[i] = GangZoneCreate(ZoneInfo[i][zMinX], ZoneInfo[i][zMinY], ZoneInfo[i][zMaxX], ZoneInfo[i][zMaxY]);
        }
       
//////here is your's
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            FPS[i] = TextDrawCreate(8.000000, 428.000000, "FPS: 30");
            TextDrawBackgroundColor(FPS[i], 255);
            TextDrawFont(FPS[i], 3);
            TextDrawLetterSize(FPS[i], 0.480000, 2.000000);
            TextDrawColor(FPS[i], -65281);
            TextDrawSetOutline(FPS[i], 1);
            TextDrawSetProportional(FPS[i], 1);
        }
        SetTimer("FPSUP",1203,true);
        return 1;
       
        DisableInteriorEnterExits();
        //rest of callback
Reply


Messages In This Thread
GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 08:27
Re: GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 10:44
Re: GetPlayerFPS + another question - by [XST]O_x - 10.03.2012, 10:45
Re: GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 10:50
Re: GetPlayerFPS + another question - by [XST]O_x - 10.03.2012, 10:53
Re: GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 10:56
Re: GetPlayerFPS + another question - by [XST]O_x - 10.03.2012, 10:57
Re: GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 11:04
Re: GetPlayerFPS + another question - by [XST]O_x - 10.03.2012, 11:49
Re: GetPlayerFPS + another question - by Twisted_Insane - 10.03.2012, 11:59

Forum Jump:


Users browsing this thread: 3 Guest(s)