Dio skripte: TD:
for(new i; i < MAX_PLAYERS; ++i)
{
GiveDamage = TextDrawCreate(171.000000, 388.000000, " ");
TextDrawAlignment(GiveDamage, 2);
TextDrawBackgroundColor(GiveDamage, 255);
TextDrawFont(GiveDamage, 2);
TextDrawLetterSize(GiveDamage, 0.160000, 0.599999);
TextDrawColor(GiveDamage, 0x00FF04FF);
TextDrawSetOutline(GiveDamage, 1);
TextDrawSetProportional(GiveDamage, 1);
}
for(new i; i < MAX_PLAYERS; ++i)
{
TakeDamage = TextDrawCreate(440.000000,388.000000, " ");
TextDrawAlignment(TakeDamage, 2);
TextDrawBackgroundColor(TakeDamage, 255);
TextDrawFont(TakeDamage, 2);
TextDrawLetterSize(TakeDamage, 0.160000, 0.599999);
TextDrawColor(TakeDamage, 0xE81010FF);
TextDrawSetOutline(TakeDamage, 1);
TextDrawSetProportional(TakeDamage, 1);
}OnPlayerTake i GiveDamage:
forward OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid);
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid)
{
new s;
format(s, 20, "+Damage %.0f %", amount, playerid);
TextDrawSetString(GiveDamage, s);
TextDrawShowForPlayer(playerid, GiveDamage);
PlayerPlaySound(playerid,17802,0.0,0.0,0.0);
SetTimerEx("DestruirTextoDraw", 1000, false, "i", playerid);
return 1;
}
forward DestruirTextoDraw(playerid);
public DestruirTextoDraw(playerid)
{
TextDrawHideForPlayer(playerid, GiveDamage);
TextDrawHideForPlayer(playerid, TakeDamage);
return 1;
}
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{
if(issuerid != INVALID_PLAYER_ID)
{
if(IgracPolicajac(issuerid))
{
if(GetPlayerWeapon(issuerid) == 23)
{
new string, Float:Poz;
GetPlayerPos(playerid, Poz, Poz, Poz);
if(IsPlayerInRangeOfPoint(issuerid, 5.0, Poz, Poz, Poz))
{
if(PlayerInfo == 0) return SCM(issuerid,-1,""PLAVA"( INFO ) "SIVA"Igrac nema Wanted Level!");
if(IgracPolicajac(playerid)) return SCM(issuerid,-1,""PLAVA"( INFO ) "SIVA"Ne mozes tazovati PD!");
if(PlayerInfo == 0) return SCM(issuerid,-1,""PLAVA"( INFO ) "SIVA"Suspendovan si!");
if(AdminDuty == 1) return SCM(issuerid,-1,""PLAVA"( INFO ) "SIVA"Taj igrac je Admin na duznosti!");
format(string, sizeof(string), "%s puca tazerom na %s-a i pogadja ga.", GetName(issuerid) ,GetName(playerid));
ProxDetector(20.0, issuerid, string, PROX,PROX,PROX,PROX,PROX);
JBC_TogglePlayerControllable(playerid, 0); IgracTazovan = 1;
TazerTimer = SetTimerEx("TazovanTajmer", 15000, false, "i", playerid);
OnePlayAnim(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0);
}
}
}
new s;
format(s, 20, "-Damage %.0f %.0f", amount, playerid);
TextDrawSetString(TakeDamage, s);
TextDrawShowForPlayer(playerid, TakeDamage);
PlayerPlaySound(playerid,17802,0.0,0.0,0.0);
SetTimerEx("DestruirTextoDraw", 1000, false, "i", playerid);
return 1;
}
if (weaponid == WEAPON_GRENADE || weaponid == 51)
{
new Float:health;
GetPlayerHealth(playerid, health);
SetPlayerHealth(playerid, (health - (amount * 0.3)));
FlashbangStage = 1;
HandleFlashbangStage(playerid);
}
return 1;
}Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log): ///
Slika/video ingame problema(obavezno ako je ingame problem): ///
