-
Content Count
27 -
Joined
-
Last visited
Community Reputation
3 NeutralAbout Gizda
-
Rank
Scavenger
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
-
in file serverDZ.cfg line - serverTimePersistent=0; change value to 1 and set time and date in line - serverTime=2018/08/08/12/00; (for example)
-
Gizda changed their profile photo
-
delete all xml files in folder my documents\dayz
-
in your folder mpmissions\dayzOffline.chernarusplus\db open the file types.xml and add the necessary object to the line with the parameter - <value name="Tier4"/> For example: <type name="AmmoBox_762x54_20Rnd"> <nominal>40</nominal> <lifetime>7200</lifetime> <restock>0</restock> <min>30</min> <quantmin>-1</quantmin> <quantmax>-1</quantmax> <cost>100</cost> <flags count_in_cargo="1" count_in_hoarder="0" count_in_map="1" count_in_player="1" crafted="0" deloot="0"/> <category name="weapons"/> <usage name="Military"/> <value name="Tier4"/> </type>
-
-
Guys please tell me - all the servers crash all the time? Or are there ways to crash with the player in 063 EXP? The server can work all day without failures, and can crash every hour. Regardless of online. At first, I sinned on the settings of zombies and loot, but when I returned to the factory all the crash files continued exactly the same.
-
Hello friends. I am not good at writing scripts in this game, but there are some concepts in it. I ask for any help in the implementation of a separate zone on the server where the damage does not pass - the safe zone. In another forum thread, philippj proposed the idea of a script (I’ll post it below), but in this form the script does not work. Maybe someone has thoughts on the decision of this.Thank you in advance! bool IsInRadialZone(float x, float y, float center_x, float center_y, float radius) { // keep distance squared because squaring is cheaper then sqrt float distance_squared = Math.Pow(center_x-x, 2) + Math.Pow(center_y-y, 2); return (distance_squared < Math.Pow(radius, 2)); } override void OnUpdate(float timeslice) { UpdateDummyScheduler(); TickScheduler(timeslice); UpdateLogoutPlayers(); ref array<Man> players = new array<Man>; GetGame().GetPlayers( players ); float safezone_center_x = 0.0; float safezone_center_y = 0.0; float safezone_radius = 0.0; for ( int i = 0; i < players.Count(); i++ ) { PlayerBase player; Class.CastTo(player, players.Get(i)); vector pos = player.GetPosition(); if(IsInRadialZone(pos[0], pos[2], safezone_center_x, safezone_center_y, safezone_radius)) { player.SetAllowDamage( false ); } else { player.SetAllowDamage( true ); } } }
-
I want to disable the damage in a certain territory for the player. And there are no wolves and zombies
-
SetAllowDamage not working!
-
I tried variants of changing coordinates in-game and from the map, but it does not work.
-
lay out your file will be dealt with.
-
void main() { Hive ce = CreateHive(); if ( ce ) ce.InitOffline(); Weather weather = g_Game.GetWeather(); weather.GetOvercast().SetLimits( 0.0 , 1.0 ); weather.GetRain().SetLimits( 0.0 , 1.0 ); weather.GetFog().SetLimits( 0.0 , 0.25 ); weather.GetOvercast().SetForecastChangeLimits( 0.0, 0.2 ); weather.GetRain().SetForecastChangeLimits( 0.0, 0.1 ); weather.GetFog().SetForecastChangeLimits( 0.15, 0.45 ); weather.GetOvercast().SetForecastTimeLimits( 1800 , 1800 ); weather.GetRain().SetForecastTimeLimits( 600 , 600 ); weather.GetFog().SetForecastTimeLimits( 1800 , 1800 ); weather.GetOvercast().Set( Math.RandomFloatInclusive(0.0, 0.3), 0, 0); weather.GetRain().Set( Math.RandomFloatInclusive(0.0, 0.2), 0, 0); weather.GetFog().Set( Math.RandomFloatInclusive(0.0, 0.1), 0, 0); weather.SetWindMaximumSpeed(15); weather.SetWindFunctionParams(0.1, 0.3, 50); } class CustomMission: MissionServer { void SetRandomHealth(EntityAI itemEnt) { int rndHlt = Math.RandomInt(40,100); itemEnt.SetHealth("","",rndHlt); } override PlayerBase CreateCharacter(PlayerIdentity identity, vector pos, ParamsReadContext ctx, string characterName) { Entity playerEnt; playerEnt = GetGame().CreatePlayer(identity, characterName, pos, 0, "NONE");//Creates random player Class.CastTo(m_player, playerEnt); GetGame().SelectPlayer(identity, m_player); return m_player; } override void StartingEquipSetup(PlayerBase player, bool clothesChosen) { /* player.RemoveAllItems(); EntityAI item = player.GetInventory().CreateInInventory(topsArray.GetRandomElement()); EntityAI item2 = player.GetInventory().CreateInInventory(pantsArray.GetRandomElement()); EntityAI item3 = player.GetInventory().CreateInInventory(shoesArray.GetRandomElement()); */ EntityAI itemEnt; ItemBase itemBs; itemEnt = player.GetInventory().CreateInInventory("Rag"); itemBs = ItemBase.Cast(itemEnt); itemBs.SetQuantity(4); SetRandomHealth(itemEnt); itemEnt = player.GetInventory().CreateInInventory("AliceBag_Black"); itemBs = ItemBase.Cast(itemEnt); //itemEnt = player.GetInventory().CreateInInventory("PortableGasLamp"); itemBs = ItemBase.Cast(itemEnt); } }; Mission CreateCustomMission(string path) { return new CustomMission(bool IsInRadialZone(float x, float y, float center_x, float center_y, float radius) { // keep distance squared because squaring is cheaper then sqrt float distance_squared = Math.Pow(center_x-x, 2) + Math.Pow(center_y-y, 2); return (distance_squared < Math.Pow(radius, 2)); }; override void OnUpdate(float timeslice) { UpdateDummyScheduler(); TickScheduler(timeslice); UpdateLogoutPlayers(); ref array<Man> players = new array<Man>; GetGame().GetPlayers( players ); float safezone_center_x = 8150.0; float safezone_center_y =9100.0; float safezone_radius = 100.0; for ( int i = 0; i < players.Count(); i++ ) { PlayerBase player; Class.CastTo(player, players.Get(i)); vector pos = player.GetPosition(); if(IsInRadialZone(pos[0], pos[2], safezone_center_x, safezone_center_y, safezone_radius)) { player.SetAllowDamage( false ); } else { player.SetAllowDamage( true ); } } }); }; compile error: mpmissions\dayzOffline.chernarusplus\init.c(81): Broken expression (missing `;`?)
-
Very cool! Soon check and write down how it works! one question: "float safezone_radius = 0.0;" value in meters from the center?
-
when you turn on the debugging monitor, it monitors your position in real time, maybe this is something you can use for code?
-
Many thanks for the response and help! I have not quite figured out how to use this script for the test. If possible, explain in more detail where to insert this code.