21.08.2018, 13:50
Video :
Quote:
if(GetPVarInt(i, "EMSAttempt") != 0) { new Float:health; new string[128]; GetPlayerHealth(i,health); SetPlayerHealth(i, health-1); if(GetPVarInt(i, "EMSAttempt") == -1) { if(GetPlayerAnimationIndex(i) != 746) ClearAnimations(i), ApplyAnimation(i, "KNIFE", "KILL_Knife_Ped_Die", 4.0, 0, 1, 1, 1, 0, 1); if(!GetPVarType(i, "StreamPrep") && !IsPlayerInRangeOfPoint(i, 3.0, GetPVarFloat(i,"MedicX"), GetPVarFloat(i,"MedicY"), GetPVarFloat(i,"MedicZ")) && !GetPVarInt(i, "OnStretcher")) { SendClientMessageEx(i, COLOR_WHITE, "You fell unconscious, you were immediately sent to the hospital."); KillEMSQueue(i); SpawnPlayer(i); } GameTextForPlayer(i, "~r~Bi Thuong~n~~w~/dichvu capcuu Hoac /chapnhan chet", 5000, 3); format(string, sizeof(string), "(( Nguoi choi dang bi thuong. ))"); SetPlayerChatBubble(i,string,COLOR_LIGHTRED,50.0,1 0000); } if(GetPVarInt(i, "EMSAttempt") == 1) { if(GetPlayerAnimationIndex(i) != 746) ClearAnimations(i), ApplyAnimation(i, "KNIFE", "KILL_Knife_Ped_Die", 4.0, 0, 1, 1, 1, 0, 1); if(!GetPVarType(i, "StreamPrep") && !IsPlayerInRangeOfPoint(i, 3.0, GetPVarFloat(i,"MedicX"), GetPVarFloat(i,"MedicY"), GetPVarFloat(i,"MedicZ")) && !GetPVarInt(i, "OnStretcher")) { SendClientMessageEx(i, COLOR_WHITE, "You fell unconscious, you were immediately sent to the hospital."); KillEMSQueue(i); SpawnPlayer(i); } GameTextForPlayer(i, "~r~Injured~n~~w~Waiting for EMS to Arrive...", 5000, 3); format(string, sizeof(string), "(( Nguoi choi dang bi thuong. ))"); SetPlayerChatBubble(i,string,COLOR_LIGHTRED,50.0,1 0000); } |
Quote:
forward SendEMSQueue(playerid,type); public SendEMSQueue(playerid,type) { #if defined zombiemode if(zombieevent == 1 && GetPVarType(playerid, "pIsZombie")) { KillEMSQueue(playerid); SpawnPlayer(playerid); return 1; } if(zombieevent == 1 && GetPVarType(playerid, "pZombieBit")) { KillEMSQueue(playerid); ClearAnimations(playerid); MakeZombie(playerid); return 1; } #endif switch (type) { case 1: { Streamer_UpdateEx(playerid, GetPVarFloat(playerid,"MedicX"), GetPVarFloat(playerid,"MedicY"), GetPVarFloat(playerid,"MedicZ")); SetPlayerPos(playerid, GetPVarFloat(playerid,"MedicX"), GetPVarFloat(playerid,"MedicY"), GetPVarFloat(playerid,"MedicZ")); SetPlayerVirtualWorld(playerid, GetPVarInt(playerid,"MedicVW")); SetPlayerInterior(playerid, GetPVarInt(playerid,"MedicInt")); SetPVarInt(playerid, "EMSAttempt", -1); if(GetPlayerInterior(playerid) > 0) Player_StreamPrep(playerid, GetPVarFloat(playerid,"MedicX"), GetPVarFloat(playerid,"MedicY"), GetPVarFloat(playerid,"MedicZ"), FREEZE_TIME); GameTextForPlayer(playerid, "~r~Bi Thuong~n~~w~/dichvu capcuu Hoac /chapnhan chet", 5000, 3); ClearAnimations(playerid); ApplyAnimation(playerid, "WUZI", "CS_Dead_Guy", 4.0, 0, 1, 1, 0, 0, 1); SetPlayerHealth(playerid, 100); RemoveArmor(playerid); if(GetPVarInt(playerid, "usingfirstaid") == 1) { firstaidexpire(playerid); } SetPVarInt(playerid,"MedicCall",1); } case 2: { SetPVarInt(playerid,"EMSAttempt", 2); ClearAnimations(playerid); ApplyAnimation(playerid, "SWAT", "gnstwall_injurd", 4.0, 0, 1, 1, 1, 0, 1); SetPlayerHealth(playerid, 100); RemoveArmor(playerid); } } return 1; } |