Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #define GET_HUM(x) \
- if (x > 0) then {_txtHum = "+" + str(x); }else{ _txtHum = x;};\
- _totalHum = _totalHum + x;
- #define CALL_MsgKill(x)\
- MPVEH_MsgKill = [_msg,_speed,MK_lvl];\
- MK_lvl = MK_lvl + 1;\
- \
- if(!isNull _player) then { \
- sleep 0.8;\
- _clientID publicVariableClient "MPVEH_MsgKill";\
- \
- PVDZE_plr_HumanityChange = [_player, x, 0.5];\
- _clientID publicVariableClient "PVDZE_plr_HumanityChange";\
- PVDZE_plr_Save = [_player,(magazines _player),true,true] ;\
- publicVariableServer "PVDZE_plr_Save";\
- };
- private ["_body","_type","_msg","_clientID","_speed","_player","_getHum","_txtHum","_playerUID","_humanity","_isBandit","_isHero","_dead","_chVeh","_inVehicle","_totalMsg","_distance","_totalHum","_humDead","_tHum","_showTotalMsgZombie","_showTotalMsgBots","_showTotalMsgPeople"];
- _getPlayerHumanity = {
- private ["_kiler","_dead","_DeadBandit","_KillerBandit","_Deadherou","_Dead_kepka","_Killerherou","_Killer_kepka","_DeadHumanity","_KillerHumanity","_kills","_hum"];
- _kiler = _this select 0;
- _dead = _this select 1;
- _DeadBandit = false;
- _KillerBandit = false;
- _Deadherou = false;
- _Dead_kepka = false;
- _Killerherou = false;
- _Killer_kepka = false;
- _DeadHumanity = _dead getVariable["humanity",0];
- if (_DeadHumanity <= -5000) then {_DeadBandit = true;};
- if (_DeadHumanity >= 5000) then {_Deadherou = true;};
- if ((!_DeadBandit) && (!_Deadherou)) then {_Dead_kepka = true;};
- _KillerHumanity = _kiler getVariable["humanity",0];
- if (_KillerHumanity <= -5000) then {_KillerBandit = true;};
- if (_KillerHumanity >= 5000) then {_Killerherou = true;};
- if ((!_KillerBandit) && (!_Killerherou)) then {_Killer_kepka = true;};
- if (_DeadBandit) then {
- _kills = _kiler getVariable ["banditKills",0];
- _kiler setVariable ["banditKills",(_kills + 1),true];
- }else{
- _kills = _kiler getVariable ["humanKills",0];
- _kiler setVariable ["humanKills",(_kills + 1),true];
- };
- if (_Deadherou) then {
- if (_Killerherou) then {
- _hum = -1000;
- };
- if (_KillerBandit) then {
- _hum = -500;
- _i = -((_DeadHumanity / 100) * 2);
- _hum = round(_hum + _i);
- };
- if (_Killer_kepka) then {
- _hum = -5;
- };
- };
- if (_DeadBandit) then {
- if (_Killerherou) then {
- _hum = 1000;
- };
- if (_KillerBandit) then {
- _hum = 100;
- };
- if (_Killer_kepka) then {
- _hum = 500;
- _i = -((_DeadHumanity / 1000) * 4);
- _hum = round(_hum + _i);
- };
- };
- if (_Dead_kepka) then {
- if (_Killerherou) then {
- _hum = -500;
- };
- if (_KillerBandit) then {
- _hum = -100;
- };
- if (_Killer_kepka) then {
- _hum = -500;
- };
- };
- _hum
- };
- _player = _this select 0;
- _type = _this select 1;
- _getHum = _this select 2;
- _showTotalMsgZombie = false; //Отображать итог при убийсве зомби
- _showTotalMsgBots = false; //Отображать итог при убийсве ботов
- _showTotalMsgPeople = true; //Отображать итог при убийсве людей
- if (!isPlayer _player) exitWith {};
- _msg = "";
- _txtHum = "";
- _totalMsg = "";
- _isBandit = false;
- _isHero = false;
- _chVeh = false;
- _inVehicle = false;
- _dead = nil;
- _humDead = 0;
- _totalHum = 0;
- _distance = 0;
- _playerUID = getPlayerUID _player;
- _clientID = owner _player;
- _speed = -1.8;
- {
- if (_playerUID == (getPlayerUID _x)) then {
- if (_clientID != (owner _x)) then {
- _clientID = owner _x;
- _player = _x;
- _chVeh = true;
- };
- };
- } forEach playableUnits;
- if (_type == "player") then {
- _dead = _this select 3;
- _humDead = _dead getVariable ["humanity",0];
- if (_humDead >= 5000) then { _isHero = true; }else{ _isBandit = true; };
- _distance = floor(_player distance _dead);
- };
- if (isNil "MK_lvl") then { MK_lvl = 0; };
- /*------------------------------------------------Cообщения об убийстве---------------------------------------------*/
- _gHum_FirstBlood = -20;
- _gHum_Killx2 = -75;
- _gHum_Killx3 = -100;
- _gHum_Killx4 = -150;
- _gHum_Killx5 = -200;
- _gHum_Killx6 = -300;
- _gHum_inVeh = -55;
- _gHum_inHead = -10;
- // стандарт
- _gHum_metr = -125;
- //
- _gHum_m500 = -125;
- _gHum_m1000 = -175;
- _gHum_m1250 = -200;
- _gHum_m1500 = -350;
- _gHum_m2000 = -500;
- if (_type == "player") then { _getHum = [_player,_dead] call _getPlayerHumanity; };
- GET_HUM(_getHum)
- /*------------------------------------------------Cообщения об убийстве---------------------------------------------*/
- switch _type do {
- case "zombie": { //убил зомби
- _kills = _player getVariable["zombieKills",0];
- _player setVariable["zombieKills",(_kills + 1),true];
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Освободитель</t>",_txtHum]; //убил зомби
- };
- case "player": { //убил игрока
- if (_isHero) then {
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Изменник</t>",_txtHum]; //Убил героя
- }else{
- if (_isBandit) then {
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Законник</t>",_txtHum]; //Убил бандита
- }else{
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Жнец</t>",_txtHum]; //Убил бандитa
- };
- };
- };
- case "botPlus": { _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Чистильщик</t>",_txtHum]; }; //Боты в +
- case "botMin": { _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Ха, получил пулю...</t>",_txtHum]; }; //Боты в -
- case "botOther": { _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Ха, получил пулю...</t>",_txtHum]; }; //Особые боты +/-
- };
- CALL_MsgKill(_getHum)
- /*------------------------------------------------------------Ачивки-------------------------------------------------------*/
- switch _type do {
- case "player": {
- _countKill = _player getVariable ["CountKill", 0];
- _timeKill = _player getVariable ["TimeCKill", time];
- if ((time - _timeKill) < 120) then {
- _player setVariable ["CountKill", (_countKill + 1), true];
- }else{
- _player setVariable ["CountKill", 1, true];
- _player setVariable ["TimeCKill", time, true];
- };
- switch _countKill do {
- case 2: {
- GET_HUM(_gHum_Killx2)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Двоих подряд</t>",_txtHum];
- CALL_MsgKill(_gHum_Killx2)
- };
- case 3: {
- GET_HUM(_gHum_Killx3)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Троих подряд</t>",_txtHum];
- CALL_MsgKill(_gHum_Killx3)
- };
- case 4: {
- GET_HUM(_gHum_Killx4)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>4-ых подряд</t>",_txtHum];
- CALL_MsgKill(_gHum_Killx4)
- };
- case 5: {
- GET_HUM(_gHum_Killx5)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>5 Убитых - Непобедимый!</t>",_txtHum];
- CALL_MsgKill(_gHum_Killx5)
- };
- case 6: {
- GET_HUM(_gHum_Killx6)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>6 Убитых - Кто ты?!</t>",_txtHum];
- CALL_MsgKill(_gHum_Killx6)
- };
- };
- if !(_player getVariable ["FirstBlood", false]) then {
- GET_HUM(_gHum_FirstBlood)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Первая кровь</t>",_txtHum];
- _player setVariable ["FirstBlood", true, true];
- CALL_MsgKill(_gHum_FirstBlood)
- };
- if (_chVeh) then {
- _inVehicle = vehicle _player != _player;
- if (_inVehicle) then {
- GET_HUM(_gHum_inVeh)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Кармагедон</t>",_txtHum];
- CALL_MsgKill(_gHum_inVeh)
- };
- };
- if ((_dead getVariable ["deathType", ""]) == "shothead") then {
- GET_HUM(_gHum_inHead)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>В голову</t>",_txtHum];
- CALL_MsgKill(_gHum_inHead)
- };
- if (_distance > 500) then {
- if (_distance > 1000) then {
- if (_distance > 1250) then {
- if (_distance > 1500) then {
- if (_distance > 2000) then {
- _gHum_metr = _gHum_m2000;
- if (_distance > 3500) then {
- PVDZE_send = [_player,"HackLog","Убийство свыше 3000м"];
- publicVariableServer "PVDZE_send";
- };
- }else{
- _gHum_metr = _gHum_m1500;
- };
- }else{
- _gHum_metr = _gHum_m1250;
- };
- }else{
- _gHum_metr = _gHum_m1000;
- };
- }else{
- _gHum_metr = _gHum_m500;
- };
- GET_HUM(_gHum_metr)
- _msg = format ["<t size='0.5' color='#EDEE6D'> %1</t> <t size='0.5' color='#088BC9'>Снайпер %2 метров</t>",_txtHum,_distance];
- CALL_MsgKill(_gHum_metr)
- };
- };
- };
- /*--------------------------------------------------------------------------------------------------------------------------*/
- if (((_type == "zombie") && !_showTotalMsgZombie) || ((_type == "player") && !_showTotalMsgPeople) || (((_type == "botPlus") || (_type == "botMin") || (_type == "botOther")) && !_showTotalMsgBots)) exitWith {};
- if (_totalHum > 0) then {_txtHum = "+" + str(_totalHum);}else {_txtHum = _totalHum;};
- _msg = format ["<t size='0.5' color='#500000'> %1</t>",_txtHum];
- CALL_MsgKill(0)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement