1. Timer starts under OnGameModeInit calling the function that saves.
2. you'd have to wait till the player has 2.0 HP or so and apply the animations, toggleplayercontrolable 0. 3. That one is difficult. Best to look for a good afk system and rip it out. |
public Bw(playerid) { new Float:health; GetPlayerHealth(playerid,health); if (health < 2.0) { PlayerInfo[playerid][pBw] = 1; PlayerInfo[playerid][pBwCzas] = 15; } }
C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(1114) : error 017: undefined symbol "PlayerInfo" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(1115) : error 017: undefined symbol "PlayerInfo" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(2292) : warning 235: public function lacks forward declaration (symbol "DistanceCameraTargetToLocation") C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(4056) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(12920) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(13135) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(13351) : error 017: undefined symbol "pBw" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 6 Errors.
I did this BW thing like this and tryed to compile.
Код:
public Bw(playerid) { new Float:health; GetPlayerHealth(playerid,health); if (health < 2.0) { PlayerInfo[playerid][pBw] = 1; PlayerInfo[playerid][pBwCzas] = 15; } } Код:
C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(1114) : error 017: undefined symbol "PlayerInfo" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(1115) : error 017: undefined symbol "PlayerInfo" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(2292) : warning 235: public function lacks forward declaration (symbol "DistanceCameraTargetToLocation") C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(4056) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(12920) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(13135) : error 017: undefined symbol "pBw" C:\Users\Machlik\Desktop\samp03asvr_R8_win32\gamemodes\WZLSRP.pwn(13351) : error 017: undefined symbol "pBw" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 6 Errors. |
enum PLAYERINFO
{
pBw,
pBwCzas,
}
new PlayerInfo[MAX_PLAYERS][PLAYERINFO];
enum PLAYERINFO { pBw, pBwCzas, } new PlayerInfo[MAX_PLAYERS][PLAYERINFO];