Перейти к публикации
Поиск в
  • Дополнительно...
Искать результаты, содержащие...
Искать результаты в...
  • Нужна помощь?

    Создайте тему в соответствующем разделе
    Не нужно писать всё в чат!
  • Загляните на торговую площадку

    Там вы можете купить
    всё что касается игровых серверов
  • Не хотите бан?

    Пожалуйста, ознакомьтесь с нашими правилами
    Не нарушайте порядок!
  • Продаёте или покупаете?

    Пользуйтесь услугами гаранта
    Мы сделаем вашу сделку безопасной
BorizzK

Мод 0.63 AirDrop by Mov3ax на GitHub [отремонтирован]

Рекомендованные сообщения

PJIIOxa вы мне покажите код скрипта и строку, на которую сервер ругается, поправлю вам.

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах





123new да он так то ругался при запуске сервера мол уберите цифру "5" вот отсюда

GetGame().ChatPlayer(5, message); //Global chat for all players

все убрал сервер стал запускаться нормально в файле scripts_log все работает скрип Airdrop работает только сообщений не видно

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
4 минуты назад, PJIIOxa сказал:

123new да он так то ругался при запуске сервера мол уберите цифру "5" вот отсюда


GetGame().ChatPlayer(5, message); //Global chat for all players

все убрал сервер стал запускаться нормально в файле scripts_log все работает скрип Airdrop работает только сообщений не видно

замени

GetGame().ChatPlayer(5, message); //Global chat for all players

на

AirDrop_SendMessageToAllPlayers(message);

И добавь функцию где-нить между void-функциями в коде
 

void AirDrop_SendMessageToAllPlayers(string message) 
	{
		private array<Man> players = new array<Man>;
		GetGame().GetPlayers( players );
		private int numbOfplayers = players.Count();
		
		if(( numbOfplayers > 0 ) && (message != ""))
		{
			foreach(Man player: players)
			{
				if(( player ) && (message != ""))
				{
					Param1<string> m_GlobalMessage = new Param1<string>(message); 
					GetGame().RPCSingleParam(player, ERPCs.RPC_USER_ACTION_MESSAGE, m_GlobalMessage, true, player.GetIdentity()); 
				}
			}
		}		
	}

 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

так может кто гайдик короткий выложить как правильно установить !? 

Изменено пользователем Karmagedon (история изменений)

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
Только что, PJIIOxa сказал:

Karmagedon я же вам в личку гайдик запилил

не заметил... да лучше бы тут в общий закинули ребятам тоже. Спасибо буду пробовать... вопрос только как проверить работает ли скрипт или нет хот бы для теста!?

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

1. Открываешь файл init.c находящийся в Steam\steamapps\common\DayZServer\mpmissions\dayzOffline.chernarusplus

в самом начале этого файла находишь строку void main() и перед ней прописываешь это

#include "$CurrentDir:\\mpmissions\\dayzOffline.chernarusplus\\AirDrop.c"

2. в этом же файле init.c ищешь строку

class CustomMission: MissionServer
{	

сразу после скобки прописываешь это

ref AirDrop AirDropClass; // Class definition

    void CustomMission()
    {		
	    AirDropClass = new AirDrop;		
    }

    float TimerSlice; // Timeslice
    override void OnUpdate( float timeslice )
    {
	    super.OnUpdate( timeslice );

	    // FPS Fix
	    TimerSlice += timeslice;
	    if (TimerSlice >= AirDropClass.TimesliceMultiplyier)
	    {
	      	AirDropClass.CreateAirDrop();
		    TimerSlice = 0;	
	    }
    }

3. Создаешь файл AirDrop.c в папке миссии по пути Steam\steamapps\common\DayZServer\mpmissions\dayzOffline.chernarusplus

в этом файле прописываешь это

//Version 5.12.12.1737 
	//Deep modify by Borizz.K s-platoon.ru
	//21.01.2019
	//https://github.com/mov3ax/airdrop
	
	/*
	README:
	
	Credits
	•@i_kolobov - Documentation and Code snippets
	•@Arkensor - Code snippets
	•@FIDOv - Documentation
	•@Revelin - Code snippets
	•

	Setup
	•Extract archive to your mission folder, (e.g default dayzOffline.chernarusplus)
	•Open init.c file of your server using any notepad
	•Include plugin to your init.c file
	#include "$CurrentDir:\\mpmissions\\dayzOffline.chernarusplus\\plugins\\AirDrop.c"

	•Find your custom mission class
	class CustomMission : MissionServer

	•Append this code inside class
	ref AirDrop AirDropClass; // Class definition

	//Code:
	void CustomMission()
	{
		AirDropClass = new AirDrop;		
	}

	float TimerSlice; // Timeslice
	override void OnUpdate( float timeslice )
	{
		super.OnUpdate( timeslice );

		// FPS Fix
		TimerSlice += timeslice;
		if (TimerSlice >= AirDropClass.TimesliceMultiplyier)
		{
			AirDropClass.CreateAirDrop();
			TimerSlice = 0;	
		}
	}
	//Code.

	If you already have OnUpdate method you just have to add following code into it
	
	//Code:
	// FPS Fix
	TimerSlice += timeslice;
	if (TimerSlice >= AirDropClass.TimesliceMultiplyier)
	{
		AirDropClass.CreateAirDrop();
		TimerSlice = 0;	
	}
	//Code.

	Also don't forget to add following variable above OnUpdate
	float TimerSlice; // Timeslice

	Now you have installed airdrop plugin

	Configuration

	Default code -
	bool EnableAirdrops = true; // Main switch

	float TimesliceMultiplyier = 0.01; // Timeslice multiplyier, default value is 0.01 (60 FPS)
	float AirPlaneSpeed = 0.25; // Airplane fly speed 
	float AirPlaneAltitude = 500; // Airplane fly height 
	float AirDropFallSpeed = 0.2; // Airdrop fall speed 
	// 600 Seconds = 10 Minutes
	float TicksTimerFromStart = 600 / TimesliceMultiplyier; // How much time will pass from the server start to first airdrop
	bool PrintInformationMessages = true; // Show in chat when airplane flew out and when airdrop is landed
	bool PrintInformationCoordinates = true; // Show in chat coordinates where airdrop is landed
	// 36000 Seconds = 1 Hour
	float RemoveTime = 36000 / TimesliceMultiplyier; // After how much time airplane and loot will be removed and new airplane will be spawned
	bool SpawnZombie = true; // Spawn zombie near airdrop when landed
	bool ShowSignal = true; // Show smoke signal when airdrop landed

	float RandomBoundsMin = 95; // Airdrop drop bounds min
	float RandomBoundsMax = 180; // Airdrop drop bounds max
	
	bool SendDebugMessages = false; // Show debug messages (Debug)
	bool DropOnStart = false; // Drop airdrop instantly after airplane (Debug)
	bool TeleportDebug = false; // Teleport to airplane and airdrop during flight (Debug)

	EnableAirdrops - Enable or Disable airdrop switch TimesliceMultiplyier - Value that responds for smooth processing time, default value is 1, so if you wan't to process time in 60 FPS you need divide 1 by 60 that as a result equals 0.01 AirPlaneSpeed - How fast airplane will move AirPlaneAltitude - How high will the plane fly AirDropFallSpeed - How fast airdrop will fall TicksTimerFromStart - How much time will pass from the server start to first airdrop RandomBoundsMin - Airdrop drop bounds minimum RandomBoundsMax - Airdrop drop bounds maximum SpawnZombie - Spawn zombie near airdrop when landed ShowSignal - Show smoke signal when airdrop landed PrintInformationMessages - Show chat messages about -
	•Airplane flew out
	•Airdrop dropped
	•Airdrop landed

	DropOnStart - Use only for debug and test puproses, drop airdrop instantly after airplane flew out TeleportDebug - Use only for debug and test puproses, teleport all players to airplane and airdrop
	*/

class AirDrop
{

	/* ### ### ### ### ### ### ### ### ### ### ### ### */
	/* DayZ 0.63 AirDrop plugin by mov3ax / mov3ax.pro */
	/* ### ### ### ### ### ### ### ### ### ### ### ### */	

	void AirDrop()
	{
		Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: AirDrop() ::: Init :::");
	}

	void ~AirDrop()
	{
		Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: ~AirDrop() ::: UnInit :::");
	}

	/* ### ### ### ### ### ### ### ### */
	/* Configuration of plugin */
	/* ### ### ### ### ### ### ### ### */

	//100 Ticks = 1 second !!!

	bool 		init							= false; //Init flag
	bool 		EnableAirdrops 					= true; // Main switch
	float 		TimesliceMultiplyier 			= 0.01; // Timeslice multiplyier, default value is 0.01 (60 FPS)
	float 		AirPlaneSpeed 					= 0.15; // Airplane fly speed //0.25
	float 		AirPlaneAltitude 				= 550;  // Airplane fly height //500
	// TicksTimerFromStart = 60 ~ 1 Minute
	float 		TicksTimerFromStart 			= 120 / TimesliceMultiplyier; // How much time will pass from the server start to first airdrop //120 - 6000 ticks ~~ 120 seconds
	float 		TicksTimerBeforeAirDrop 		= TicksTimerFromStart + (10 / TimesliceMultiplyier); // How much time will pass to airdrop after airplane spawned and fly
	bool 		PrintInformationMessages 		= true; // Show in chat when airplane flew out and when airdrop is landed
	bool 		PrintInformationCoordinates 	= true; // Show in chat coordinates where airdrop is landed
	float 		RemoveTime 						= 120 / TimesliceMultiplyier; // After how much time airplane and loot will be removed and new airplane will be spawned after AirDrom Landed
	bool 		SpawnZombie 					= true; // Spawn zombie near airdrop when landed
	bool 		ShowSignal 						= true; // Show smoke signal when airdrop landed
	float 		RandomBoundsMin 				= 95; // Airdrop drop bounds min
	float 		RandomBoundsMax 				= 180; // Airdrop drop bounds max
	bool 		DropOnStart 					= false; // Drop airdrop instantly after airplane (Debug)
	bool 		TeleportDebug 					= false; // Teleport to airplane and airdrop during flight (Debug)
	int 		AirPlaneCount					= 0;
	int 		AirDropCount					= 0;

	//======================================================================================================================================================
	bool		AirDropStartTimerMessage		= false;  // One Debug message at the beginning AirDrop start timer // if PrintDebugMessages = true; (debug)
	bool		AirDropRemoveTimerMessage		= false;	 // One Debug message at the beginning AirDrop remove timer // if PrintDebugMessages = true; (debug)
	bool		SendAirDropTimersMessage		= false;  // (debug)
	
	bool		PrintMoveAirPlaneDebugMessages	= false;  // (debug)

	bool 		SendDebugMessages 				= false; // Send debug messages to all players (Debug)
	bool 		PrintDebugMessages 				= false; // Print debug messages in to log (Debug)
	
	bool 		SendAdminDebugMessages 			= false; // Send debug messages to Admin player (Debug) //In Progress
	bool 		PrintAdminDebugMessages 		= false; // Print debug messages in to Admin log (Debug) //In Progress
	
	bool 		PrintAirDropFallDebugMessages	= false;  // Print debug messages about AirDrop falls
	bool 		PrintAirDropLandedDebugMessages	= false;  // Print debug messages about AirDrop landed
	//======================================================================================================================================================

	/* ### ### ### ### ### ### ### ### */
	/* 		   Local variables 		   */
	/* ### ### ### ### ### ### ### ### */

	vector 		m_AirPlaneFixedPosition; 		// Local variable
	vector 		m_DropPos; 						// Local variable

	Object 		m_AirPlane; 					// Global airplane object
	Object 		m_AirDrop; 						// Global airdrop container object
	Object		m_Platform; 					// Global airdrop container object
	
	string 		m_AirPlaneModel 				= "Land_Wreck_C130J"; 	//AirPlane object class for spawn
	string 		m_PlatformModel					= "Land_Container_1Bo"; //Airdrop container object class for first spawn
	string 		m_AirDropModel 					= "Land_Container_1Bo"; //Airdrop container object class for spawn
	string 		m_PhysicsBodyModel				= "SurvivorM_Cyril"; 	//Physics Body - object with physics properties for free fall
	
	EntityAI 	m_AirDropLoot; 					// Airdrop container body
	ItemBase 	m_AirDropBase; 					// Airdrop container base

	EntityAI 	DropEffect; 					// Airdrop land particle effect	
	EntityAI 	SignalEffect; 					// Airdrop land particle effect	

	vector 		RandomRotOrientation; 			// Local variable	
	EntityAI 	PhysicsBody; 					// Local variable

	float 		RandomRot 						= 0; 	 // Default random rotation variable
	float 		RandomTime 						= 100;	 // Default random drop variable
	float 		Delay 							= 0;	 // Local variable for security
	float 		Ground; 								 // Local variable for security

	int 		AirDropTime 					= 0; 	 // Local variable
	int 		AirTimer 						= 0; 	 // Local variable
	int 		RemoveTimer 					= 0; 	 // Local variable

	bool 		RayReady 						= true;	 // Local variable
	bool 		TimerPassed 					= false; // Local variable
	bool 		AirPassed 						= false; // Local variable
	bool 		AirDropLanded 					= false; // Local variable //AirDrop Landed
	bool 		RemovePassed 					= false; // Local variable
	bool 		DropTime 						= false; // Local variable
	bool 		PassTime 						= false; // Local variable
	

	/* ### ### ### ### ### ### ### ### */
	/* 		  Global functions 		   */
	/* ### ### ### ### ### ### ### ### */

	// Send message in global chat to single or all players
	void SendMessage(PlayerBase player, string message) 
	{
		if (player)
		{
			Param1<string> m_MessageParam = new Param1<string>(message);
			GetGame().RPCSingleParam(player, ERPCs.RPC_USER_ACTION_MESSAGE, m_MessageParam, true, player.GetIdentity()); //Chat for single player
		}
		else
		{
			AirDrop_SendMessageToAllPlayers(message); //Global chat for all players
		}
	}
    
    void AirDrop_SendMessageToAllPlayers(string message) 
	{
		private array<Man> players = new array<Man>;
		GetGame().GetPlayers( players );
		private int numbOfplayers = players.Count();
		
		if(( numbOfplayers > 0 ) && (message != ""))
		{
			foreach(Man player: players)
			{
				if(( player ) && (message != ""))
				{
					Param1<string> m_GlobalMessage = new Param1<string>(message); 
					GetGame().RPCSingleParam(player, ERPCs.RPC_USER_ACTION_MESSAGE, m_GlobalMessage, true, player.GetIdentity()); 
				}
			}
		}		
	}
	
	// Teleport single or all players to position, debug
	void SetPosTo(PlayerBase player, vector pos) 
	{
		if (player)
		{
			player.SetPosition(pos); // Teleport single player
		}
		else
		{
			ref array<Man> players = new array<Man>; 
			GetGame().GetPlayers( players ); 
			
			for ( int i = 0; i < players.Count(); i++ ) 
			{ 
				player = PlayerBase.Cast(players.Get(i));  //Teleport all players
				player.SetPosition(pos);
			}
		}
	}

	/* ### ### ### ### ### ### ### ### */
	/* Configuration of loot and spawn points */
	/* ### ### ### ### ### ### ### ### */

	// Random Loot Presets
	string GetRandomLoot() 
	{
			
		TStringArray loot = {
			"LandMineTrap", 
			"TTSKOPants", 
			"TacticalBaconCan", 
			"M4A1", 
			"PlateCarrierComplete", 
			"BakedBeansCan", 
			"WaterBottle", 
			"Mag_AKM_Drum75Rnd",
			"GhilleAtt_Mossy",
			"GhillieSuit_Mossy",
			"GhillieHood_Mossy",
			"Battery9V",
			"BaseRadio",
			"BurlapSack",
			"Lockpick",
			"SmallProtectorCase",
			"Netting",
			"RocketAviators",
			"Binoculars",
			"TacticalGloves_Black",
			"HuntingKnife",
			"Shovel",
			"DuctTape",
			"DallasMask",
			"HoxtonMask",
			"BalaclavaMask_Blackskull",
			"BalaclavaMask_Black",
			"BalaclavaMask_Green",
			"BalaclavaMask_Blue",
			"HighCapacityVest_Olive",
			"HighCapacityVest_Black",
			"Mag_FNX45_15Rnd",
			"Mag_CZ75_15Rnd",
			"Mag_MP5_30Rnd",
			"Mag_UMP_25Rnd",
			"Mag_SVD_10Rnd",
			"KobraOptic",
			"PistolSuppressor",
			"AK_Suppressor",
			"Mag_STANAG_30Rnd",
			"M4_Suppressor",
			"Mag_AKM_30Rnd",
			"PUScopeOptic",
			"BandageDressing",
			"StartKitIV",
			"SalineBag",
			"AmmoBox",
			"AmmoBox_380_35rnd",
			"AmmoBox_45ACP_25rnd",
			"AmmoBox_556x45_20Rnd",
			"AmmoBox_762x39_20Rnd",
			"AmmoBox_762x54_20Rnd",
			"AmmoBox_9x19_25rnd",
			"Ammo_45ACP",
			"Ammo_556x45",
			"Ammo_762x39",
			"Ammo_762x54",
			"AKM",
			"SVD",
			"UMP45",
			"MP5K",
			"MakarovIJ70",
			"FNX45",
			"CZ75",
			"Mp133Shotgun",
			"Izh18",
			"Mosin9130",
			"SawedoffMosin9130",
			"CZ61",
			"Mag_STANAGCoupled_30Rnd",
			"SodaCan_Cola",
			"SodaCan_Kvass",
			"SodaCan_Pipsi",
			"SodaCan_Spite",
			"WaterBottle",
			"Canteen",
		};

		return loot.GetRandomElement();
	}
	
	// Generating random airdrop position from list
	// You can get coordinates using debug monitor or this map https://dayz.ginfo.gg/
	vector LoadAirPlanePos()
	{

		TVectorArray positions = { 
		"6305 0 8029", //OLD SOBOR
		"5829 0 7602", //OLD SOBOR
		"6515 0 7569", //OLD SOBOR
		"6139 0 7503", //OLD SOBOR
		};

		vector where = positions.GetRandomElement();
		where[1] = AirPlaneAltitude;
		if (PrintDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: LoadAirPlanePos() => " + where.ToString());
		}

        return where;
	}

	/* ### ### ### ### ### ### ### ### */
	/* 		  Zombie spawn list 	   */
	/* ### ### ### ### ### ### ### ### */

	TStringArray WorkingZombieClasses()
	{
		if (PrintDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: WorkingZombieClasses()");
		}
		return {
		"ZmbM_HermitSkinny_Base","ZmbM_HermitSkinny_Beige","ZmbM_HermitSkinny_Black","ZmbM_HermitSkinny_Green",
		"ZmbM_HermitSkinny_Red","ZmbM_FarmerFat_Base","ZmbM_FarmerFat_Beige","ZmbM_FarmerFat_Blue","ZmbM_FarmerFat_Brown",
		"ZmbM_FarmerFat_Green","ZmbF_CitizenANormal_Base","ZmbF_CitizenANormal_Beige","ZmbF_CitizenANormal_Brown",
		"ZmbF_CitizenANormal_Blue","ZmbM_CitizenASkinny_Base","ZmbM_CitizenASkinny_Blue","ZmbM_CitizenASkinny_Brown",
		"ZmbM_CitizenASkinny_Grey","ZmbM_CitizenASkinny_Red","ZmbM_CitizenBFat_Base","ZmbM_CitizenBFat_Blue","ZmbM_CitizenBFat_Red",
		"ZmbM_CitizenBFat_Green","ZmbF_CitizenBSkinny_Base","ZmbF_CitizenBSkinny","ZmbM_PrisonerSkinny_Base","ZmbM_PrisonerSkinny",
		"ZmbM_FirefighterNormal_Base","ZmbM_FirefighterNormal","ZmbM_FishermanOld_Base","ZmbM_FishermanOld_Blue","ZmbM_FishermanOld_Green",
		"ZmbM_FishermanOld_Grey","ZmbM_FishermanOld_Red","ZmbM_JournalistSkinny_Base","ZmbM_JournalistSkinny","ZmbF_JournalistNormal_Base",
		"ZmbF_JournalistNormal_Blue","ZmbF_JournalistNormal_Green","ZmbF_JournalistNormal_Red","ZmbF_JournalistNormal_White",
		"ZmbM_ParamedicNormal_Base","ZmbM_ParamedicNormal_Blue","ZmbM_ParamedicNormal_Green","ZmbM_ParamedicNormal_Red",
		"ZmbM_ParamedicNormal_Black","ZmbF_ParamedicNormal_Base","ZmbF_ParamedicNormal_Blue","ZmbF_ParamedicNormal_Green",
		"ZmbF_ParamedicNormal_Red","ZmbM_HikerSkinny_Base","ZmbM_HikerSkinny_Blue","ZmbM_HikerSkinny_Green","ZmbM_HikerSkinny_Yellow",
		"ZmbF_HikerSkinny_Base","ZmbF_HikerSkinny_Blue","ZmbF_HikerSkinny_Grey","ZmbF_HikerSkinny_Green","ZmbF_HikerSkinny_Red",
		"ZmbM_HunterOld_Base","ZmbM_HunterOld_Autumn","ZmbM_HunterOld_Spring","ZmbM_HunterOld_Summer","ZmbM_HunterOld_Winter",
		"ZmbF_SurvivorNormal_Base","ZmbF_SurvivorNormal_Blue","ZmbF_SurvivorNormal_Orange","ZmbF_SurvivorNormal_Red",
		"ZmbF_SurvivorNormal_White","ZmbM_SurvivorDean_Base","ZmbM_SurvivorDean_Black","ZmbM_SurvivorDean_Blue","ZmbM_SurvivorDean_Grey",
		"ZmbM_PolicemanFat_Base","ZmbM_PolicemanFat","ZmbF_PoliceWomanNormal_Base","ZmbF_PoliceWomanNormal","ZmbM_PolicemanSpecForce_Base",
		"ZmbM_PolicemanSpecForce","ZmbM_SoldierNormal_Base","ZmbM_SoldierNormal","ZmbM_usSoldier_normal_Base",
		"ZmbM_usSoldier_normal_Woodland","ZmbM_usSoldier_normal_Desert","ZmbM_CommercialPilotOld_Base","ZmbM_CommercialPilotOld_Blue",
		"ZmbM_CommercialPilotOld_Olive","ZmbM_CommercialPilotOld_Brown","ZmbM_CommercialPilotOld_Grey","ZmbM_PatrolNormal_Base",
		"ZmbM_PatrolNormal_PautRev","ZmbM_PatrolNormal_Autumn","ZmbM_PatrolNormal_Flat","ZmbM_PatrolNormal_Summer","ZmbM_JoggerSkinny_Base",
		"ZmbM_JoggerSkinny_Blue","ZmbM_JoggerSkinny_Green","ZmbM_JoggerSkinny_Red","ZmbF_JoggerSkinny_Base","ZmbF_JoggerSkinny_Blue",
		"ZmbF_JoggerSkinny_Brown","ZmbF_JoggerSkinny_Green","ZmbF_JoggerSkinny_Red","ZmbM_MotobikerFat_Base","ZmbM_MotobikerFat_Beige",
		"ZmbM_MotobikerFat_Black","ZmbM_MotobikerFat_Blue","ZmbM_VillagerOld_Base","ZmbM_VillagerOld_Blue","ZmbM_VillagerOld_Green",
		"ZmbM_VillagerOld_White","ZmbM_SkaterYoung_Base","ZmbM_SkaterYoung_Blue","ZmbM_SkaterYoung_Brown","ZmbM_SkaterYoung_Green",
		"ZmbM_SkaterYoung_Grey","ZmbF_SkaterYoung_Base","ZmbF_SkaterYoung_Brown","ZmbF_SkaterYoung_Striped","ZmbF_SkaterYoung_Violet",
		"ZmbF_DoctorSkinny_Base","ZmbF_DoctorSkinny","ZmbF_BlueCollarFat_Base","ZmbF_BlueCollarFat_Blue","ZmbF_BlueCollarFat_Green",
		"ZmbF_BlueCollarFat_Red","ZmbF_BlueCollarFat_White","ZmbF_MechanicNormal_Base","ZmbF_MechanicNormal_Beige","ZmbF_MechanicNormal_Green",
		"ZmbF_MechanicNormal_Grey","ZmbF_MechanicNormal_Orange","ZmbM_MechanicSkinny_Base","ZmbM_MechanicSkinny_Blue","ZmbM_MechanicSkinny_Grey",
		"ZmbM_MechanicSkinny_Green","ZmbM_MechanicSkinny_Red","ZmbM_ConstrWorkerNormal_Base","ZmbM_ConstrWorkerNormal_Beige",
		"ZmbM_ConstrWorkerNormal_Black","ZmbM_ConstrWorkerNormal_Green","ZmbM_ConstrWorkerNormal_Grey","ZmbM_HeavyIndustryWorker_Base",
		"ZmbM_HeavyIndustryWorker","ZmbM_OffshoreWorker_Base","ZmbM_OffshoreWorker_Green","ZmbM_OffshoreWorker_Orange","ZmbM_OffshoreWorker_Red",
		"ZmbM_OffshoreWorker_Yellow","ZmbF_NurseFat_Base","ZmbF_NurseFat","ZmbM_HandymanNormal_Base","ZmbM_HandymanNormal_Beige",
		"ZmbM_HandymanNormal_Blue","ZmbM_HandymanNormal_Green","ZmbM_HandymanNormal_Grey","ZmbM_HandymanNormal_White","ZmbM_DoctorFat_Base",
		"ZmbM_DoctorFat","ZmbM_Jacket_Base","ZmbM_Jacket_beige","ZmbM_Jacket_black","ZmbM_Jacket_blue","ZmbM_Jacket_bluechecks",
		"ZmbM_Jacket_brown","ZmbM_Jacket_greenchecks","ZmbM_Jacket_grey","ZmbM_Jacket_khaki","ZmbM_Jacket_magenta","ZmbM_Jacket_stripes",
		"ZmbF_PatientOld_Base","ZmbF_PatientOld","ZmbM_PatientSkinny_Base","ZmbM_PatientSkinny","ZmbF_ShortSkirt_Base","ZmbF_ShortSkirt_beige",
		"ZmbF_ShortSkirt_black","ZmbF_ShortSkirt_brown","ZmbF_ShortSkirt_green","ZmbF_ShortSkirt_grey","ZmbF_ShortSkirt_checks",
		"ZmbF_ShortSkirt_red","ZmbF_ShortSkirt_stripes","ZmbF_ShortSkirt_white","ZmbF_ShortSkirt_yellow","ZmbF_VillagerOld_Base",
		"ZmbF_VillagerOld_Blue","ZmbF_VillagerOld_Green","ZmbF_VillagerOld_Red","ZmbF_VillagerOld_White","ZmbM_Soldier","ZmbM_SoldierAlice",
		"ZmbM_SoldierHelmet","ZmbM_SoldierVest","ZmbM_SoldierAliceHelmet","ZmbM_SoldierVestHelmet","ZmbF_MilkMaidOld_Base",
		"ZmbF_MilkMaidOld_Beige","ZmbF_MilkMaidOld_Black","ZmbF_MilkMaidOld_Green","ZmbF_MilkMaidOld_Grey","ZmbM_priestPopSkinny_Base",
		"ZmbM_priestPopSkinny","ZmbM_ClerkFat_Base","ZmbM_ClerkFat_Brown","ZmbM_ClerkFat_Grey","ZmbM_ClerkFat_Khaki","ZmbM_ClerkFat_White",
		"ZmbF_Clerk_Normal_Base","ZmbF_Clerk_Normal_Blue","ZmbF_Clerk_Normal_White","ZmbF_Clerk_Normal_Green","ZmbF_Clerk_Normal_Red",
		};
	}

	/* ### ### ### ### ### ### ### ### */
	/*   Airplane and airdrop setup    */
	/* ### ### ### ### ### ### ### ### */

	void GetAirPlaneInfo()
	{
		Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: BEGIN :::");

		// Seconds devide on value of TimesliceMultiplyier (By default it is 0.01)
		RandomTime = Math.RandomFloat(RandomBoundsMin / TimesliceMultiplyier, RandomBoundsMax / TimesliceMultiplyier); // Random drop bounds
		RandomRot = Math.RandomFloat(130, 190); // Random rot bounds
		
		// Dynamic movement forward
        float Forward = RandomRot * 0.017453292;

		// 7.5 is airdrop container motion speed
		float MotionX  = (double)(Math.Sin(Forward) * 7.5); 
        float MotionZ = (double)(Math.Cos(Forward) * 7.5);
		
		// Fixed position, if we dont multiply value to -1 it will move backwards
		m_AirPlaneFixedPosition[0] = MotionX * -1;
		m_AirPlaneFixedPosition[1] = 10;
		m_AirPlaneFixedPosition[2] = MotionZ * -1;
		RandomRotOrientation[0] = RandomRot;

		if (PrintDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: Random rotation of airplane ::: RandomRot = " + RandomRot);
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: Dynamic movement forward ::: Forward = " + Forward);
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: airdrop container motion speed ::: MotionX = " + MotionX);
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: airdrop container motion speed ::: MotionZ = " + MotionZ);
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: airdrop container motion speed ::: m_AirPlaneFixedPosition = " + m_AirPlaneFixedPosition.ToString());
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: airdrop container motion speed ::: RandomRotOrientation = " + RandomRotOrientation.ToString());
		}

		if (SendDebugMessages)
		{
			SendMessage(NULL, "[Airdrop, Debug] Random rotation of airplane is " + RandomRot);
		}

		m_AirPlane = GetGame().CreateObject( m_AirPlaneModel, LoadAirPlanePos(), false, true ); // Create airplane model
		m_AirPlane.SetOrientation(RandomRotOrientation); // Rotate it to random angles in yaw

		m_AirPlane.PlaySoundLoop("powerGeneratorLoop", 1000, false); // Attach airplane sound to itself, need to be fixed //10000 / true
		
		if (PrintInformationMessages)
		{
			if (m_AirPlane != NULL)
			{
				SendMessage(NULL, "[Airdrop] Airplane was spotted on map!");	
			}
			else
			{
				SendMessage(NULL, "[Airdrop] Airplane object error!");	
			}
		}
		
		if (PrintDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: Airplane was spotted on map: " + m_AirPlane.ToString() + ", Pos: " + m_AirPlane.GetPosition().ToString());
		}
		
		m_AirPlane.SetPosition( m_AirPlane.GetPosition() );
		m_DropPos = ( m_AirPlane.GetPosition() ) - m_AirPlaneFixedPosition;

		protected vector pos;
		pos[0] = 0;
		pos[1] = AirPlaneAltitude;
		pos[2] = 0;

		m_Platform = GetGame().CreateObject(m_PlatformModel, pos, false, true);
		PhysicsBody = EntityAI.Cast(GetGame().CreateObject(m_PhysicsBodyModel, m_Platform.GetPosition(), false, true));
        PhysicsBody.SetAllowDamage(false);

		if (PrintDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: Create PhysicsBody: PhysicsBody = " + PhysicsBody.ToString() + ", Pos: " + PhysicsBody.GetPosition().ToString());
		}
	
		if (DropOnStart) // For debug puproses only
		{
			RayReady = false;

			m_AirDrop = GetGame().CreateObject( m_AirDropModel, m_DropPos, false, true ); // Create airdrop model, in this case it is red container
			
			SetVelocity(PhysicsBody, "10 0 0");
			GetGame().ObjectDelete(m_Platform);
			SetVelocity(PhysicsBody, "10 0 0");

			// Reset it to default values
			RemoveTimer = 0;
			RemovePassed = false;
			
			if (PrintInformationMessages)
			{
				SendMessage(NULL, "[Airdrop] Airdrop was dropped from the plane on start!");	
			}
			if (PrintDebugMessages)
			{
				Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: DropOnStart ::: Airdrop was dropped from the plane on start: " + m_AirDrop.ToString() + ", Pos: " + m_AirDrop.GetPosition().ToString());
			}

		}

		if (TeleportDebug) // For debug puproses only
		{
			if (m_AirPlane != NULL)
			{
				SetPosTo(NULL, m_AirPlane.GetPosition());
			}
		}
		
		Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: GetAirPlaneInfo() ::: END :::");
	}

	void MoveAirPlane()
	{
		// Dynamic movement forward
        float Forward = RandomRot * 0.017453292;

		// 7.5 is airdrop container motion speed
		float MotionX  = (double)(Math.Sin(Forward) * AirPlaneSpeed); 
        float MotionZ = (double)(Math.Cos(Forward) * AirPlaneSpeed);

		// Fixed position, if we dont multiply value to -1 it will move backwards
		m_AirPlaneFixedPosition[0] = MotionX * -1;
		m_AirPlaneFixedPosition[1] = 0;
		m_AirPlaneFixedPosition[2] = MotionZ * -1;

		//=============================================================================================================
			// Dynamic altitude correction relative to the surface 
			// Ground altitude at current pos
			vector ground_pos = m_AirPlane.GetPosition();
			ground_pos[1] = GetGame().SurfaceY( ground_pos[0], ground_pos[2] );
			// Ground altitude at next pos
			vector ground_nextpos = m_AirPlane.GetPosition() + m_AirPlaneFixedPosition;
			ground_nextpos[1] = GetGame().SurfaceY( ground_nextpos[0], ground_nextpos[2] );
			//Difference between heights
			float AirPlaneAltCorrect =  ground_nextpos[1] - ground_pos[1];
			//Icrease or decrease AirPlane Altitude - correction relative to the surface
			m_AirPlaneFixedPosition[1] = m_AirPlaneFixedPosition[1] + (AirPlaneAltCorrect / 2); //Default: no devide!
			// ^ Dynamic altitude correction relative to the surface  ^
		//==============================================================================================================
		
		m_AirPlane.SetPosition( m_AirPlane.GetPosition() + m_AirPlaneFixedPosition );
		m_DropPos = ( m_AirPlane.GetPosition() ) - m_AirPlaneFixedPosition;
		
		if (PrintMoveAirPlaneDebugMessages)
		{
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: m_AirPlane = " + m_AirPlane.ToString());
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: m_AirPlane pos = " + m_AirPlane.GetPosition().ToString());
			Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: DropTime = " + DropTime.ToString());
		}

		if (!RayReady)
		{
			Ground = GetGame().SurfaceY(m_AirDrop.GetPosition()[0], m_AirDrop.GetPosition()[2]);
			if (PhysicsBody.GetPosition()[1] <= Ground)
			{
				PhysicsBody.SetVelocity(PhysicsBody, "0 0 0");
			}

			//if (GetVelocity(PhysicsBody)[0] < 0.0001 && GetVelocity(PhysicsBody)[1] < 0.0001 && GetVelocity(PhysicsBody)[2] < 0.0001)
			if (PhysicsBody.GetPosition()[1] <= Ground)
			{
				if (PrintAirDropLandedDebugMessages)
				{
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Landed m_AirDrop ===> " + m_AirDrop.ToString() 	 + ", Pos: " 		   + m_AirDrop.GetPosition().ToString());
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Landed PhysicsBody => " + PhysicsBody.ToString() + ", Pos: " 		   + PhysicsBody.GetPosition().ToString());
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Landed PhysicsBody => " + PhysicsBody.ToString() + ", GetVelocity: "   + GetVelocity(PhysicsBody).ToString());
					//Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Landed PhysicsBody => " + PhysicsBody.ToString() + ", GetSpeed: " 	   + PhysicsBody.GetSpeed().ToString());
					//Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Landed PhysicsBody => " + PhysicsBody.ToString() + ", GetModelSpeed: " + PhysicsBody.GetModelSpeed().ToString());
				}

				m_AirDrop.PlaceOnSurface();
				m_AirDrop.SetPosition(m_AirDrop.GetPosition()); //Re Place On Surface at current pos
				m_AirDrop.SetDirection(m_AirDrop.GetDirection());
				m_AirDrop.SetOrientation(m_AirDrop.GetOrientation());
				
				if (PrintDebugMessages)
				{
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: m_AirDrop.PlaceOnSurface() => " + m_AirDrop.ToString() + ", Pos: " + m_AirDrop.GetPosition().ToString());
				}
	
				// Create airdrop lootable container, in this case it is sea chest	
				m_AirDropLoot = EntityAI.Cast(GetGame().CreateObject( "SeaChest", m_AirDrop.GetPosition(), false, true )); // We can't add barrel because it have to be opened
				// You can extend items count inside airdrop container or make it random
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropLoot.GetInventory().CreateInInventory(GetRandomLoot());
				m_AirDropBase = ItemBase.Cast(m_AirDropLoot); // Cast items to airdrop container

				// Play particle when airdrop container, in this case it is red container
				DropEffect = Particle.Play( ParticleList.EXPLOSION_LANDMINE, m_AirDrop.GetPosition() );
			
                // Shouts out Kolobov for that
                //DropEffect = EntityAI.Cast(GetGame().CreateObject( "LandMineTrap", m_AirDrop.GetPosition())); 
                //DropEffect.SetOrientation("0 0 0");
                //DropEffect.GetCompEM().SwitchOn();
                //DropEffect.Delete();	      
            
				if (PrintInformationMessages && !PrintInformationCoordinates)
				{
					SendMessage(NULL, "[Airdrop] Airdrop landed!");	
				}
				else if (PrintInformationMessages && PrintInformationCoordinates) 
				{
					array<string> arrCoords = new array<string>;
					string strAirdropPos = m_AirDrop.GetPosition().ToString();
					strAirdropPos = strAirdropPos.Substring(1, strAirdropPos.Length() - 2);
					strAirdropPos.Split( ", ", arrCoords );
					SendMessage(NULL, "[Airdrop] Airdrop landed on coordinates " + Math.Round( arrCoords.Get(0).ToInt() ) + " " + Math.Round( arrCoords.Get(2).ToInt() ) + "!");
				}

				if (SpawnZombie)
				{
					GetGame().CreateObject( WorkingZombieClasses().GetRandomElement(), m_AirDrop.GetPosition() - "10 0 0", false, true );	
					GetGame().CreateObject( WorkingZombieClasses().GetRandomElement(), m_AirDrop.GetPosition() - "0 0 10", false, true );	
					GetGame().CreateObject( WorkingZombieClasses().GetRandomElement(), m_AirDrop.GetPosition() - "10 0 -10", false, true );		
					GetGame().CreateObject( WorkingZombieClasses().GetRandomElement(), m_AirDrop.GetPosition() - "-10 0 10", false, true );
					if (PrintDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: SpawnZombie :::");
					}
				}
				
				if (ShowSignal)
				{
                    // Shouts out Kolobov for that
                    vector signal = "0 1.5 0"; 
                    SignalEffect = EntityAI.Cast(GetGame().CreateObject( "RDG2SmokeGrenade_Black", m_AirDrop.GetPosition() + signal)); 
                    SignalEffect.SetOrientation("0 0 0");
                    SignalEffect.GetCompEM().SwitchOn(); 
					if (PrintDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: ShowSignal ::: SignalEffect = " + SignalEffect.ToString());
					}
                    SignalEffect.Delete();
				}

				//Removing physics body
				PhysicsBody.SetPosition(vector.Zero);
				GetGame().ObjectDelete( PhysicsBody ); 
				PhysicsBody = NULL;	
				
				// Reset it to default values
				RayReady = true;
				
				if (PrintDebugMessages)
				{
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: RayReady = " + RayReady.ToString());
				}
				AirDropLanded = true;
			}
			else
			{
				if (m_AirDrop != NULL)
				{
					vector phys;

					phys[0] = m_AirDrop.GetPosition()[0];
					phys[1] = PhysicsBody.GetPosition()[1];
					phys[2] = m_AirDrop.GetPosition()[2];
					
					if (phys[1] <= Ground)
					{
						phys[1] = GetGame().SurfaceY(phys[0], phys[2]);
					}

					m_AirDrop.SetPosition(phys);
					m_AirDrop.SetOrientation(PhysicsBody.GetOrientation());

					if (PrintAirDropFallDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Falls m_AirDrop ===> " + m_AirDrop.ToString() 	+ ", Pos: " 		  + m_AirDrop.GetPosition().ToString());
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Falls PhysicsBody => " + PhysicsBody.ToString() + ", Pos: " 		  + PhysicsBody.GetPosition().ToString());
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Falls PhysicsBody => " + PhysicsBody.ToString() + ", Velocity: " 	  + GetVelocity(PhysicsBody).ToString());
						//Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Falls PhysicsBody => " + PhysicsBody.ToString() + ", GetSpeed: " 	  + PhysicsBody.GetSpeed().ToString());
						//Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: MoveAirPlane() ::: !RayReady ::: Falls PhysicsBody => " + PhysicsBody.ToString() + ", GetModelSpeed: " + PhysicsBody.GetModelSpeed().ToString());
					}
				}
			}
		}

		if (DropTime && !DropOnStart)
		{	
			RayReady = false;

			m_AirDrop = GetGame().CreateObject( m_AirDropModel, m_DropPos, false, true ); // Create airdrop model, in this case it is red container
			
			SetVelocity(PhysicsBody, "10 0 0");
			GetGame().ObjectDelete(m_Platform);
			SetVelocity(PhysicsBody, "10 0 0");

			if (PrintInformationMessages)
			{
				SendMessage(NULL, "[Airdrop] Airdrop was dropped from the plane!");	
			}
			if (PrintDebugMessages)
			{
				Print ("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: Airdrop was dropped from the plane: " + m_AirDrop.ToString() + ", Pos: " + m_AirDrop.GetPosition().ToString());
			}
			
			// Reset it to default values
			RemoveTimer = 0;
			RemovePassed = false;
			DropTime = false;		
		}
	}
	/* ### ### ### ### ### ### ### ### */
	/* 		 Airdrop controller        */
	/* ### ### ### ### ### ### ### ### */

	void CreateAirDrop()
	{
		if (!EnableAirdrops)
		{
			return; // Exit then EnableAirdrops = false
		}

		if (!init)
		{
			GetGame().AdminLog("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: Plugin initialized!");
			init = true;
		}

		// Remove timer works only then AirDrop Landed!
		if (AirDropLanded)
		{
			if (RemoveTimer <= RemoveTime)
			{
				RemoveTimer++;

				if (PrintDebugMessages)
				{
					Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: RemoveTimer <= RemoveTime ::: RemoveTimer = " + RemoveTimer + " : Wait for remove AirDrop : " + RemoveTime + " Ticks!");
				}

				if (AirDropRemoveTimerMessage)
				{
					if (SendAirDropTimersMessage)
					{
						SendMessage(NULL, "AirDrop will be removed after " + (RemoveTime * TimesliceMultiplyier) + " sec.");
					}
					AirDropRemoveTimerMessage = false;
				}
			}
			else // If RemoveTimer > RemoveTime;
			{
				// Removing all objects when remove timer is passed
				if (!RemovePassed)
				{
					if (PrintDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: Removing all objects when remove timer is passed!");
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: RemoveTimer > RemoveTime ::: RemovePassed = " + RemovePassed.ToString() + ", RemoveTimer = " + RemoveTimer	+ " : RemoveTime = " + RemoveTime);
					}

					if (m_AirDrop != NULL)
					{
						m_AirDrop.SetPosition(vector.Zero);
						GetGame().ObjectDelete( m_AirDrop ); 
						m_AirDrop = NULL;	
					}
				
					if (m_AirPlane != NULL)
					{
						m_AirPlane.SetPosition(vector.Zero);
						GetGame().ObjectDelete( m_AirPlane ); 
						m_AirPlane = NULL;	
					}

					if (m_AirDropBase != NULL)
					{
						m_AirDropBase.SetPosition(vector.Zero);
						GetGame().ObjectDelete( m_AirDropBase ); 
						m_AirDropBase = NULL;	
					}
				
					if (m_AirDropLoot != NULL)
					{
						m_AirDropLoot.SetPosition(vector.Zero);
						GetGame().ObjectDelete( m_AirDropLoot ); 
						m_AirDropLoot = NULL;	
					}
				
					if (DropEffect != NULL)
					{
						DropEffect.SetPosition(vector.Zero);
						DropEffect = NULL;
					}
				
					if (SignalEffect != NULL)
					{
						SignalEffect.SetPosition(vector.Zero);
						SignalEffect = NULL;
					}
				
					// Reset it to default values
					AirPassed = false;
					TimerPassed = false;
					AirDropTime = 0;
					AirTimer = 0;	
					RemovePassed = true;
					AirDropLanded = false;
					AirDropStartTimerMessage = true;
					AirDropRemoveTimerMessage = true;
					
					DropTime = false;		
					PassTime = false;

					if (PrintDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: RemoveTimer > RemoveTime ::: RemovePassed = " + RemovePassed.ToString() + ", RemoveTimer = " + RemoveTimer	+ " : RemoveTime = " + RemoveTime);
					}
				}
			}
		}
		// ^ Remove timer works only then AirDrop Landed! ^
		
		//  Wait timer for Arplane start
		if (AirTimer <= TicksTimerFromStart)
		{
			AirTimer++; //AirTimer increase
			
			if (SendDebugMessages)
			{
				SendMessage(NULL, "[Airdrop, Debug] Airtimer value is " + AirTimer);
			}
			
			if (PrintDebugMessages)
			{
				Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: AirTimer <= TicksTimerFromStart ::: AirTimer = " + AirTimer + " : Next AirDrop after: " + (TicksTimerFromStart * TimesliceMultiplyier) + " Sec!");
			}

			if (AirDropStartTimerMessage)
			{
				if (SendAirDropTimersMessage)
				{
					SendMessage(NULL, "Next AirDrop after: " + (TicksTimerFromStart * TimesliceMultiplyier) + " sec.");
				}
				AirDropStartTimerMessage = false; //Set to true after AirDrop removed.
			}
		} // ^ Wait timer for Arplane start ^
		else
		{ // AirTimer > TicksTimerFromStart - set flag TimerPassed to true for AirPlane/Airdrop start
			TimerPassed = true;
		}

		if (TimerPassed && !AirPassed)	
		{ //TimerPassed = true (AirTimer > TicksTimerFromStart), !AirPassed = false (AirPlane/AirDrop not spawn) - begin create AirPlane / AirDrop.
			if (SendDebugMessages)
			{
				SendMessage(NULL, "[Airdrop, Debug] Airtimer passed");
			}
			
			if (PrintDebugMessages)
			{
				Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: TimerPassed && !AirPassed : TimerPassed = " + TimerPassed.ToString() + " : AirPassed =  " + AirPassed.ToString());
			}

			GetAirPlaneInfo(); //Call create AirPlane / AirDrop.
			
			if (SendDebugMessages)
			{
				SendMessage(NULL, "[Airdrop, Debug] Airdrop spawned via timer");		
			}	
			// Reset it to default values
			AirPassed = true; //set flag AirPassed to true - AirPlane / AirDrop spawned!

			if (PrintDebugMessages)
			{
				Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: Airdrop spawned via timer " + TimerPassed.ToString() + " : AirPassed =  " + AirPassed.ToString());
				Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: TimerPassed && !AirPassed : TimerPassed = " + TimerPassed.ToString() + " : AirPassed =  " + AirPassed.ToString());
			}
		}	

		if (AirPassed) 
		{ // AirPlane / AirDrop spawned - move airplane
			if (m_AirPlane)
			{
				MoveAirPlane();
			}
		}
			
		if (AirDropTime <= RandomTime)
		{ //  Wait timer for AirDrop start
			AirDropTime++; //Increase RandomTime 
			
			if (TeleportDebug) // For debug puproses only
			{
				SetPosTo(NULL, m_AirPlane.GetPosition());
			}

			if (SendDebugMessages)
			{
				SendMessage(NULL, "[Airdrop, Debug] Airdrop time is " + AirDropTime + " from " + RandomTime);				
			}
			if (PrintDebugMessages)
			{
				Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: Wait timer for AirDrop start ::: AirDropTime = " + AirDropTime.ToString() + " <= RandomTime = " + RandomTime.ToString());
			}
		} // ^ Wait timer for AirDrop start ^
		else
		{
			if (Delay <= 1000)
			{ //Delay before set flags for start AirDrop.
				Delay++; 
			}
			else
			{ //Set flags for start AirDrop.
				if (!RayReady)
				{
					if (TeleportDebug) // For debug puproses only
					{
						SetPosTo(NULL, m_AirPlane.GetPosition());
					}
				}
			
				if (!PassTime)
				{
					// Reset it to default values
					DropTime = true; // Set flags for start AirDrop.
					PassTime = true; 
					
					if (PrintDebugMessages)
					{
						Print("::: [Airdrop] ::: Tick: " + GetGame().GetTickTime() + " ::: CreateAirDrop() ::: !PassTime : DropTime = " + DropTime.ToString() + " : PassTime =  " + PassTime.ToString());
					}
				}
			}
		}
	}

	/* ### ### ### ### ### ### ### ### */
}

 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

все уже сделал выставил как вы и написали значения по времени 900 в двух строках это значит на сервере самолет появится через 20 минут !? И исчезнет груз через 20 минут!? И как я понял сообщения тоже пофиксили да!? И спасибо за подробный гайд.

Изменено пользователем Karmagedon (история изменений)

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

вроди косяк нашел, зомби походу мертвые ресаются или не понятно что с ними произошло

https://steamuserimages-a.akamaihd.net/ugc/936090268467274383/6D22051B6BE9548C914981167A10C16FA0E45ED4/

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

а так все работает уведомление было с координатами в чате я сразу туда ТП и там летит самолет и контейнер на земле.

Пожалуйста, Войдите или Зарегистрируйтесь, чтобы увидеть это: Вложение.

Пожалуйста, Войдите или Зарегистрируйтесь, чтобы увидеть это: Вложение.

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

PJIIOxa да все работает как часы скрипт исправен... НО но тоже заметил зомби нету... и дыма от ящика.. хотя он то наверное не был задуман в данном скрипте уже..

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

приветствую есть вопрос, есть ли возможность в сообщении когда выводятся координаты плюсом к координатам вывести название примерного места положения к примеру

сообщение в чате 
 Air drop упал в координатах 6305 8029 Krasnostav!

 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

может кто сказать? как сделать чтоб место координат писало то что я хочу? типо там "Город Грозный" и тд

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
16 часов назад, SkaZzz сказал:

может кто сказать? как сделать чтоб место координат писало то что я хочу? типо там "Город Грозный" и тд

переписать немного код

 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

я к сожалению в кодах не очень силен.Думал там можно просто к координатном добавить названия через какие не то знаки типо - " , " " ; "
по координатном игроки к сожалению знают точное место расположения айрдропа. А хотелось бы чтоб писало просто название городов и пусть ищут

ладно значит не судьба) Спасибо за ответ 

Изменено пользователем SkaZzz (история изменений)

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

после пару падений начинает просто закрываться сервер. что не так? 
вижу в коде прописан дым, но он не работает. может кто починить или сказать что исправить в коде?

A particle was spawned on server-side! Particles can be spawned on client-side only!
Class:      'AirDrop'
Function: 'Error'
Stack trace:
scripts/1_Core/proto\endebug.c:44
scripts/3_Game/particle.c:470
scripts/3_Game/particle.c:520
scripts/3_Game/particle.c:529
$CurrentDir://mpmissions//dayzOffline.chernarusplus//AirDrop.c:601
$CurrentDir://mpmissions//dayzOffline.chernarusplus//AirDrop.c:904
$CurrentDir:mpmissions\dayzOffline.chernarusplus\init.c:1265
scripts/3_Game/dayzgame.c:2330

 

в крашлогах такое пишет. как только отключаю AirDrop все отлично и падений сервера нет

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

взял полностью стандартный код ничего не менял, сервер падает кода контейнер касается земли. раз через раз

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

Этот устарел и давно 1000 раз переделан и переписан всеми кому не лень под себя

 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
13.01.2020 в 16:23, BorizzK сказал:

Этот устарел и давно 1000 раз переделан и переписан всеми кому не лень под себя

 

Дк сделай об этом запись на главной странице, а то другие то будут пытаться пользоваться, а работает он через одно место на данный момент !
Или напиши корректный скрипт
1. Крашит сервак (Из за зомби и мины которая там есть типо в коде)
2. Спавнит от 1 до 7 шт Морских сундуков (С шмотками) время от времени 

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
3 часа назад, SkaZzz сказал:

Дк сделай об этом запись на главной странице, а то другие то будут пытаться пользоваться, а работает он через одно место на данный момент !
Или напиши корректный скрипт
1. Крашит сервак (Из за зомби и мины которая там есть типо в коде)
2. Спавнит от 1 до 7 шт Морских сундуков (С шмотками) время от времени 

а ничего что тема и скрипт в ветке по 0.63 патчу лежит, а ищете вы на 1.7?

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
1 минуту назад, 123new сказал:

а ничего что тема и скрипт в ветке по 0.63 патчу лежит, а ищете вы на 1.7?

В таком случае зачем вообще все эти разделы старые. 
Из патча 0.63 много что работает и до сих пор. почему же этот айр взять и не обновить или вовсе удалить с форума.
Не думаю что тут много что поменялось из кода. пару строк фикс и все будет работать. Я уже почти добился стабильный работы и сам выложу обновленный скрипт если все же у меня выйдет все сделать.

Из меня плохой скриптер пока еще, но уже понимаю что к чему

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

У мну в 1.07 пашет вовсю

Переделайте под себя

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
2 минуты назад, BorizzK сказал:

У мну в 1.07 пашет вовсю

Переделайте под себя

Я пытаюсь, но пока такое себе. Как ты мог выше прочитать я еше так себе скриптер. Если не составит труда выложи свой рабочий тем самым многие поймут что делают не так и научаться чему то

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах
11 часов назад, SkaZzz сказал:

Я пытаюсь, но пока такое себе. Как ты мог выше прочитать я еше так себе скриптер. Если не составит труда выложи свой рабочий тем самым многие поймут что делают не так и научаться чему то

Там все переделано - вообше - и увязано с парой других серверных модов и только у меня это будет работать

Но я попробую отрыть старую версию

Поделиться сообщением


Ссылка на сообщение
Поделиться на других сайтах

Создайте аккаунт или войдите в него для комментирования

Вы должны быть пользователем, чтобы оставить комментарий

Создать аккаунт

Зарегистрируйтесь для получения аккаунта. Это просто!

Зарегистрировать аккаунт

Войти

Уже зарегистрированы? Войдите здесь.

Войти сейчас

  • Похожие публикации

    • Автор: BR0wi
      Подскажите кто занимается модовыми машинами в дейз. 
    • Автор: BR0wi
      Подскажите где найти людей, которые делаю моды на заказ. К кому вообще обращаться? Или что бы реализовать свои идеи нужно самому "год" сидеть и изучать все механики модинга?
    • Автор: NooBIK
      Доброго времени суток. На некоторых модах есть кравт вещей, который является не ванильным. Вопрос собственно такой: Где и в каком файле узнать кравт вещей? (какие комбинируются вещи) в частности интересует dayzundergraunmod. В описании мода такой инфы нет в дискорде тоже. 
    • Автор: 6agu
      Поставил
      Пожалуйста, Войдите или Зарегистрируйтесь, чтобы увидеть это: Вложение.
  • Наш выбор

×
×
  • Создать...

Важная информация

Используя этот сайт, вы автоматически обязуетесь соблюдать наши Правила и Политика конфиденциальности.
Чтобы сделать этот веб-сайт лучше, мы разместили cookies на вашем устройстве. Вы можете изменить свои настройки cookies, в противном случае мы будем считать, что вы согласны с этим.