Jump to content
ilikepizza

[Release] Radio Communication Script v1.3.1

Recommended Posts

};
//Menu
#include "custom\snap_build\points.hpp"
#include "custom\rightclickmenu\extra_rc.hpp"
#include "custom\RC\desc_inc.h"
};
I have not forgotten^^

Why not just upload a zip-file with your mission file? Just remove unnecessary files, which should have no effect.

Example: init.sqf, custom\RC\ directory and description.ext

We could help you better if we have the whole file. Also add your RPT log file from one of the clients. If there are any errors, we could tell you what the problem is.

Share this post


Link to post
Share on other sites

I have added a Debug Version of the script for download. This version has no new features, it is for problem checking for server where the script doesn't seem to work correctly.

 

Please read the new Debug Version part in the description. You can send me your RPT file as attachments via Message or post a cut version of it here. It would be best if I get 2 RPT files of both players testing at the same time who try to see each other on the map/gps.

Share this post


Link to post
Share on other sites

I have added a Debug Version of the script for download. This version has no new features, it is for problem checking for server where the script doesn't seem to work correctly.

 

Please read the new Debug Version part in the description. You can send me your RPT file as attachments via Message or post a cut version of it here. It would be best if I get 2 RPT files of both players testing at the same time who try to see each other on the map/gps.

 

Has the Debug Version been taken down? 

Share this post


Link to post
Share on other sites

@ilikepizza

 

I want to learn my Errors.

my description.ext

respawn = "BASE";
respawndelay = 5;
onLoadMission= "DayZ Epoch Chernarus";
OnLoadIntro = "Welcome to DayZ Epoch Chernarus";
OnLoadIntroTime = False;
OnLoadMissionTime = False;
disabledAI = true;
disableChannels[]={0,2,6};
enableItemsDropping = 0;

briefing = 0;
debriefing = 0;

onPauseScript = "";
loadScreen = "custom\loginmod\DayZLoadscreen.jpg";

class Header
{
 gameType = COOP;            //DM, Team, Coop, ...
 minPlayers = 1;             //min # of players the mission supports
 maxPlayers = 100;            //Max # of players the mission supports
};

aiKills = 1;
diagRadio = 1;
diagHit = 1;

class RscText
{
	type = 0;
	idc = -1;
	x = 0;
	y = 0;
	h = 0.037;
	w = 0.3;
	style = 0x100; 
	font = Zeppelin32;
	SizeEx = 0.03921;
	colorText[] = {1,1,1,1};
	colorBackground[] = {0, 0, 0, 0};
	linespacing = 1;
};
class RscPicture
{
	access=0;
	type=0;
	idc=-1;
	style=48;
	colorBackground[]={0,0,0,0};
	colorText[]={1,1,1,1};
	font="TahomaB";
	sizeEx=0;
	lineSpacing=0;
	text="";
};
class CfgSounds
{
    sounds[] =
    {
    introSong
    };
    class introSong
    {
    name="introSong";
    sound[]={custom\loginmod\introSong.ogg,0.9,1};
    titles[] = {};
    };
    class carlock
    {
    name = "signalka";
    sound[] = {custom\carlock\carlock.ogg,0.2,1};
    titles[] = {};
    };
};
class RscLoadingText : RscText
{
	style = 2;
	x = 0.323532;
	y = 0.666672;
	w = 0.352944;
	h = 0.039216;
	sizeEx = 0.03921;
	colorText[] = {0.543,0.5742,0.4102,1.0};
};
class RscProgress
{
	x = 0.344;
	y = 0.619;
	w = 0.313726;
	h = 0.0261438;
	texture = "\ca\ui\data\loadscreen_progressbar_ca.paa";
	colorFrame[] = {0,0,0,0};
	colorBar[] = {1,1,1,1};
};
class RscProgressNotFreeze
{
	idc = -1;
	type = 45;
	style = 0;
	x = 0.022059;
	y = 0.911772;
	w = 0.029412;
	h = 0.039216;
	texture = "#(argb,8,8,3)color(0,0,0,0)";
};
//
// the loading screen itself
//
class DayZ_loadingScreen
{ 
	idd = -1;
	duration = 10e10;
	fadein = 0;
	fadeout = 0;
	name = "loading screen";
	class controlsBackground
	{
		class blackBG : RscText
		{
			x = safezoneX;
			y = safezoneY;
			w = safezoneW;
			h = safezoneH;
			text = "";
			colorText[] = {0,0,0,0};
			colorBackground[] = {0,0,0,1};
		};
		/*
		class nicePic : RscPicture
		{
			style = 48 + 0x800; // ST_PICTURE + ST_KEEP_ASPECT_RATIO
			x = safezoneX + safezoneW/2 - 0.25;
			y = safezoneY + safezoneH/2 - 0.2;
			w = 0.5;
			h = 0.4;
			text = "img\nicePic.paa";
		};
		*/
	};
	class controls
	{
		class Title1 : RscLoadingText
		{
			text = "$STR_LOADING"; // "Loading" text in the middle of the screen
		};
		class CA_Progress : RscProgress // progress bar, has to have idc 104
		{
			idc = 104;
			type = 8; // CT_PROGRESS
			style = 0; // ST_SINGLE
			texture = "\ca\ui\data\loadscreen_progressbar_ca.paa";
		};
		class CA_Progress2 : RscProgressNotFreeze // progress bar that will go reverse
		{
			idc = 103;
		};
		class Name2: RscText // the text on the top-left
		{
			idc = 101;
			x = 0.05;
			y = 0.029412;
			w = 0.9;
			h = 0.04902;
			text = "";
			sizeEx = 0.05;
			colorText[] = {0.543,0.5742,0.4102,1.0};
		};
	};
};
// DayZ Watermark
class RscTitles {
	class wm_disp {
		idd = -1;
		onLoad = "uiNamespace setVariable ['wm_disp', _this select 0]";
		fadein = 0;
		fadeout = 0;
		duration = 10e10;
		controlsBackground[] = {};
		objects[] = {};
		class controls {
			class wm_text2 {
				idc = 1;
				x = safeZoneX+0.027;//safeZoneW*0.01;
				y = safeZoneY+safeZoneH-0.16;
				w = 0.151*safeZoneH;
				h = 0.057*safeZoneH;
				shadow = 2;
				class Attributes
				{
					font = "EtelkaNarrowMediumPro";
					color = "#24FFFFFF";
					align = "left"; // put "center" here if you want some background
					valign = "middle";
					shadow = 2;
				};
				colorBackground[] = { 1, 0.3, 0, 0 };  // uncomment and increase 4th number to have a background
				font = "EtelkaNarrowMediumPro";
				size = 0.05*safeZoneH;
				type = 13;
				style = 0;
				text="";
			};
		};
	};
};
//Menu
#include "custom\snap_build\points.hpp"
#include "custom\rightclickmenu\extra_rc.hpp"
};

Where should I add the line.(#include "custom\RC\desc_inc.h")

Share this post


Link to post
Share on other sites

Due to the security risk involved with disabling stuff on anti-hacks for this to work, I will not be using it on my server just yet until its fully tested and confirmed working with infistar.

 

at the moment it works for admins only and that's with a security. Nice script though keep up the good work. will keep an eye on it for now :D

Share this post


Link to post
Share on other sites

Has the Debug Version been taken down?

Why? It is still there at the bottom of the post and as reference in the "Debug Version" part.

 

Where should I add the line.(#include "custom\RC\desc_inc.h")

There :

[...]
// DayZ Watermark
class RscTitles {
        #include "custom\RC\desc_inc.h"
        class wm_disp {
        idd = -1;
[...]

Due to the security risk involved with disabling stuff on anti-hacks for this to work, I will not be using it on my server just yet until its fully tested and confirmed working with infistar.

I don't think that day will come. Letting the user create something to visualize data will always also help hackers. That is the view of infiSTAR. A good solution would be to let you as server admins choose which functions should be disabled. Similar to Battleye, but that isn't foolproof either. I think you can achive that on your own, by modifiying the infiSTAR files. You could only allow local marker functions, which should minimize the threat. But instead you disable many more functions, by setting that variable to false (BHF =  false). No offense on infiSTAR, I think they have better things to do, than adding options for the server admins to disable parts of their protection system.

 

The problem is Arma itself. There are hackers, cause the game is build to be abused. And no script will be able to counter this for sure. Best you can do, are very frequent database backups, to retore to the point, before the hacker shows up, after he is done with your server.

 

at the moment it works for admins only and that's with a security. Nice script though keep up the good work. will keep an eye on it for now :D

Only 1 Person currently told me it is only working for admins on infiSTAR protected servers. If that is the case for all, the people should better start complaining a lot more. Until there is more than only 1 person with the same problem, I assume it is a unique problem, and has to be solved as such.

So I ask everyone with infistar protected server, is this script only working for admins?

Share this post


Link to post
Share on other sites

I got a new idea and checked out if it was possible. This is the result:

 

3d_names.jpg

 

This could also work for the infiSTAR people, so check out the next version (v1.3) when it comes out.

 

Can anyone of the people with infiSTAR confirm, that the GUI in v1.2 is working? (even if it is only with admins)

Share this post


Link to post
Share on other sites

Hi Guys,

 nice script and works correctly on our servers, but I have one issue, now with this added safe codes,door codes etc...only stay on the screen for like 1 second and go away too fast for people to get them, any ideal how to resolve this issue?

Share this post


Link to post
Share on other sites

Hi Guys,

 nice script and works correctly on our servers, but I have one issue, now with this added safe codes,door codes etc...only stay on the screen for like 1 second and go away too fast for people to get them, any ideal how to resolve this issue?

 

 

From my testing you need to slow down the checking and updating. 

 

There is two files you need to edit the config file and the checkconfig file.

 

Change the check update thingy that is at 0.5 seconds change it to 5 seconds

 

and same in the config file change the spots that are 0.5 to 5 and that will slow down accuracy of the markers but fix your messages from dissappearing too fast!  hope that helps

Share this post


Link to post
Share on other sites

From my testing you need to slow down the checking and updating. 

 

There is two files you need to edit the config file and the checkconfig file.

 

Change the check update thingy that is at 0.5 seconds change it to 5 seconds

 

and same in the config file change the spots that are 0.5 to 5 and that will slow down accuracy of the markers but fix your messages from dissappearing too fast!  hope that helps

ok will try this and report back thanks for the update

Share this post


Link to post
Share on other sites

I got a new idea and checked out if it was possible. This is the result:

 

 

 

This could also work for the infiSTAR people, so check out the next version (v1.3) when it comes out.

 

Can anyone of the people with infiSTAR confirm, that the GUI in v1.2 is working? (even if it is only with admins)

 

Since this script was released, I have tried to use this with infiSTAR AH. However, I confirmed that this script only works for admins with the latest version(released date 22/04/2014). The latest version I used also has the option BHF. Even if I turned it off, it seems to work for admin.

Share this post


Link to post
Share on other sites

I think this is a problem with the new GUI. On every marker update the name list is shown. Thanks for the hint, I can certainly solve that problem in the next update.

That did fix my issue just so you know it worked, I moved it up to 5 and everything else was ok.  Thanks again for the script....7

Share this post


Link to post
Share on other sites

Hm, but if you set the time e.g. to 10 seconds and place a safe, and the message with the code appears when the update time is already at 9 seconds, the message will also be gone too fast.

Maybe it could be done that the player decides when to update the GUI (via a key or something). Or is there a way to stop this intefering with title messages?

Share this post


Link to post
Share on other sites

Maybe it could be done that the player decides when to update the GUI (via a key or something). Or is there a way to stop this intefering with title messages?

I will check what the problem is with the other GUI messages. I already have an idea how I could change the GUI updates without player interaction. So it will be solved. Don't worry.

 

 

Hm, but if you set the time e.g. to 10 seconds and place a safe, and the message with the code appears when the update time is already at 9 seconds, the message will also be gone too fast.

 

Changing the update interval value is only a workaround and is not solving the problem, you are right.

Share this post


Link to post
Share on other sites

Works really well default, on testing I tagged two friends and had one shoot me. When I pressed abort, it crashed both of their clients at the same time.

 

I removed the GUI (top left) addition and tried again, no issues since. Only tried the bug once and never went back to it when removing the GUI worked. I like and dislike the GUI, I prefer minimalistic for games like DayZ so its good that its customizable!

 

Good job on the script bud, any news on the names/groups addition?

 

Credited in our own personal community changelog, as with all scripts we use!

Share this post


Link to post
Share on other sites

Its not working on my server.. if i edited description.ext like that:

respawn = "BASE";
respawndelay = 5;
onLoadMission= "DayZ Epoch Chernarus";
OnLoadIntro = "Welcome to DayZ Epoch Chernarus";
OnLoadIntroTime = False;
OnLoadMissionTime = False;
disabledAI = true;
disableChannels[]={0,2,6};
enableItemsDropping = 0;

briefing = 0;
debriefing = 0;

onPauseScript = "";
loadScreen = "\z\addons\dayz_code\gui\dayz_logo_ca.paa";

class Header
{
 gameType = COOP;            //DM, Team, Coop, ...
 minPlayers = 1;             //min # of players the mission supports
 maxPlayers = 100;            //Max # of players the mission supports
};

aiKills = 1;
diagRadio = 1;
diagHit = 1;

class RscTitles
{
	#include "RC\desc_inc.h"
};

class RscText
{
	type = 0;
	idc = -1;
	x = 0;
	y = 0;
	h = 0.037;
	w = 0.3;
	style = 0x100; 
	font = Zeppelin32;
	SizeEx = 0.03921;
	colorText[] = {1,1,1,1};
	colorBackground[] = {0, 0, 0, 0};
	linespacing = 1;
};
class RscPicture
{
	access=0;
	type=0;
	idc=-1;
	style=48;
	colorBackground[]={0,0,0,0};
	colorText[]={1,1,1,1};
	font="TahomaB";
	sizeEx=0;
	lineSpacing=0;
	text="";
};
class RscLoadingText : RscText
{
	style = 2;
	x = 0.323532;
	y = 0.666672;
	w = 0.352944;
	h = 0.039216;
	sizeEx = 0.03921;
	colorText[] = {0.543,0.5742,0.4102,1.0};
};
class RscProgress
{
	x = 0.344;
	y = 0.619;
	w = 0.313726;
	h = 0.0261438;
	texture = "\ca\ui\data\loadscreen_progressbar_ca.paa";
	colorFrame[] = {0,0,0,0};
	colorBar[] = {1,1,1,1};
};
class RscProgressNotFreeze
{
	idc = -1;
	type = 45;
	style = 0;
	x = 0.022059;
	y = 0.911772;
	w = 0.029412;
	h = 0.039216;
	texture = "#(argb,8,8,3)color(0,0,0,0)";
};
//
// the loading screen itself
//
class DayZ_loadingScreen
{ 
	idd = -1;
	duration = 10e10;
	fadein = 0;
	fadeout = 0;
	name = "loading screen";
	class controlsBackground
	{
		class blackBG : RscText
		{
			x = safezoneX;
			y = safezoneY;
			w = safezoneW;
			h = safezoneH;
			text = "";
			colorText[] = {0,0,0,0};
			colorBackground[] = {0,0,0,1};
		};
		/*
		class nicePic : RscPicture
		{
			style = 48 + 0x800; // ST_PICTURE + ST_KEEP_ASPECT_RATIO
			x = safezoneX + safezoneW/2 - 0.25;
			y = safezoneY + safezoneH/2 - 0.2;
			w = 0.5;
			h = 0.4;
			text = "img\nicePic.paa";
		};
		*/
	};
	class controls
	{
		class Title1 : RscLoadingText
		{
			text = "$STR_LOADING"; // "Loading" text in the middle of the screen
		};
		class CA_Progress : RscProgress // progress bar, has to have idc 104
		{
			idc = 104;
			type = 8; // CT_PROGRESS
			style = 0; // ST_SINGLE
			texture = "\ca\ui\data\loadscreen_progressbar_ca.paa";
		};
		class CA_Progress2 : RscProgressNotFreeze // progress bar that will go reverse
		{
			idc = 103;
		};
		class Name2: RscText // the text on the top-left
		{
			idc = 101;
			x = 0.05;
			y = 0.029412;
			w = 0.9;
			h = 0.04902;
			text = "";
			sizeEx = 0.05;
			colorText[] = {0.543,0.5742,0.4102,1.0};
		};
	};
};

#include "custom\snap_build\points.hpp"
#include "custom\extra_rc.hpp"

And Init.sqf like that:

/*	
	For DayZ Epoch
	Addons Credits: Jetski Yanahui by Kol9yN, Zakat, Gerasimow9, YuraPetrov, zGuba, A.Karagod, IceBreakr, Sahbazz
*/
startLoadingScreen ["","RscDisplayLoadCustom"];
cutText ["","BLACK OUT"];
enableSaving [false, false];

//REALLY IMPORTANT VALUES
dayZ_instance =	11;					//The instance
dayzHiveRequest = [];
initialized = false;
dayz_previousID = 0;

//disable greeting menu 
player setVariable ["BIS_noCoreConversations", true];
//disable radio messages to be heard and shown in the left lower corner of the screen
enableRadio true;
// May prevent "how are you civillian?" messages from NPC
enableSentences false;

// DayZ Epoch config
spawnShoremode = 1; // Default = 1 (on shore)
spawnArea= 1500; // Default = 1500
DZE_BuildingLimit = 1000; // with 1000 being the amount of building items you want to allow within 30 meters.
MaxVehicleLimit = 300; // Default = 50
MaxDynamicDebris = 250; // Default = 100
MaxMineVeins = 50;  //Ore veins
MaxAmmoBoxes = 25;  //Wepon crates
dayz_MapArea = 14000; // Default = 10000
dayz_maxLocalZombies = 45; // Default = 30 
DefaultMagazines = ["ItemBandage"]; 
DefaultWeapons = ["itemradio"]; 
DefaultBackpack = ""; 
DefaultBackpackWeapon = "";
dayz_paraSpawn = true;

dayz_minpos = -1; 
dayz_maxpos = 16000;

dayz_sellDistance_vehicle = 10;
dayz_sellDistance_boat = 30;
dayz_sellDistance_air = 40;

dayz_maxAnimals = 8; // Default: 8
dayz_tameDogs = true;
DynamicVehicleDamageLow = 0; // Default: 0
DynamicVehicleDamageHigh = 95; // Default: 100

DZE_BuildOnRoads = true; // Default: False

EpochEvents = [["any","any","any","any",30,"crash_spawner"],["any","any","any","any",0,"crash_spawner"],["any","any","any","any",15,"supply_drop"]];
dayz_fullMoonNights = true;

//Load in compiled functions
call compile preprocessFileLineNumbers "custom\variables.sqf";				//Initilize the Variables (IMPORTANT: Must happen very early)
progressLoadingScreen 0.1;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\publicEH.sqf";				//Initilize the publicVariable event handlers
progressLoadingScreen 0.2;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\medical\setup_functions_med.sqf";	//Functions used by CLIENT for medical
progressLoadingScreen 0.4;
call compile preprocessFileLineNumbers "\z\addons\dayz_code\init\compiles.sqf";				//Compile regular functions
progressLoadingScreen 0.5;
call compile preprocessFileLineNumbers "custom\snap_build\compiles.sqf"; 				//Snap build doplnek
progressLoadingScreen 0.6;
call compile preprocessFileLineNumbers "custom\bike_deploy\compiles.sqf"; 				//Bike deploy compiles
progressLoadingScreen 0.7;
call compile preprocessFileLineNumbers "server_traders.sqf";				//Compile trader configs
progressLoadingScreen 1.0;

"filmic" setToneMappingParams [0.153, 0.357, 0.231, 0.1573, 0.011, 3.750, 6, 4]; setToneMapping "Filmic";

if (isServer) then {
	call compile preprocessFileLineNumbers "\z\addons\dayz_server\missions\DayZ_Epoch_11.Chernarus\dynamic_vehicle.sqf";
	//Compile vehicle configs
	
	// Add trader citys
	_nil = [] execVM "\z\addons\dayz_server\missions\DayZ_Epoch_11.Chernarus\mission.sqf";
	_serverMonitor = 	[] execVM "\z\addons\dayz_code\system\server_monitor.sqf";
};

if (!isDedicated) then {
	//Conduct map operations
	0 fadeSound 0;
	waitUntil {!isNil "dayz_loadScreenMsg"};
	dayz_loadScreenMsg = (localize "STR_AUTHENTICATING");
	
	//Run the player monitor
	_id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}];
	_playerMonitor = 	[] execVM "\z\addons\dayz_code\system\player_monitor.sqf";	
	
	//anti Hack
	[] execVM "\z\addons\dayz_code\system\antihack.sqf";

	//Lights
	//[false,12] execVM "\z\addons\dayz_code\compile\local_lights_init.sqf";
	
	//Evac
	_nil = [] execVM "custom\JAEM\EvacChopper_init.sqf";
};

#include "\z\addons\dayz_code\system\REsec.sqf"

//Start Dynamic Weather
execVM "\z\addons\dayz_code\external\DynamicWeatherEffects.sqf";

#include "\z\addons\dayz_code\system\BIS_Effects\init.sqf"

execVM "RC\init.sqf";

And, ofcourse RC folder uploaded to server, it makes only freez the game starting on "waiting for server".. 

 

Does anybody know what i have wrong? I really dont know :/

Share this post


Link to post
Share on other sites
Does anybody know what i have wrong? I really dont know :/

 

Generally everything looks ok. If the server was running ok before the change.

 

What is in that "custom\extra_rc.hpp" in your description.ext ? Could you send it to me as attachment or upload somewhere?

 

BTW, 1.3 is coming soon, I got it finished and just need to test it on my server in real environment situations.

Share this post


Link to post
Share on other sites

Generally everything looks ok. If the server was running ok before the change.

 

What is in that "custom\extra_rc.hpp" in your description.ext ? Could you send it to me as attachment or upload somewhere?

 

BTW, 1.3 is coming soon, I got it finished and just need to test it on my server in real environment situations.

Thanks for reply, maybe next version will solve my problem..

 

extra_rc.hpp is part of Evac Chopper script. Here is content:

class ExtraRc {
    class ItemRadio {
        class Use {
            text = "Call Evac-Chopper";
            script = "execVM 'custom\JAEM\CallEvacChopper.sqf'";
        };
    };
};

Share this post


Link to post
Share on other sites

 

Thanks for reply, maybe next version will solve my problem..

 

extra_rc.hpp is part of Evac Chopper script. Here is content:

class ExtraRc {
    class ItemRadio {
        class Use {
            text = "Call Evac-Chopper";
            script = "execVM 'custom\JAEM\CallEvacChopper.sqf'";
        };
    };
};

That include shound't beak anything either. You better check your server rpt log file. If the server hangs, it is giving you errors in there. You can send it to me as private message if you want.

Share this post


Link to post
Share on other sites

Version 1.3 is released.

 

The 3D GUI is working fine, a little slow on updating, but that seems to be an engine limitation. The bug with the vanishing dayz combination messages should be fixed for good, no matter what update rate you use for the positions.

 

I also added a variable in the init.sqf RC_path to set the directory where the script files are located, for easier moving of the script in the mision file. This should reduce the change of file paths to 2 places. RC_path in "init.sqf" and the "desc_inc.h" include in the "description.ext".

 

Have fun people!

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Similar Content

    • By tyrant50187
      Im looking for the ability to add Script allowing Eyescan (retina scan) For Safe's and lockboxes, ether or, its something i havent found any script for but have found mentions and seen, any suggestions, links, or scripts are welcome, please Let me know!
    • By Bloodthirsty
      Hey I just need some files for this server, any and all you guys can come up with and think it deserve post that shit in chat rn. I want to see some crazy ideas and additions if you got em :) Lets see what you guys can come up with

    • By randall421
      The loot spawning on my server will respawn or cycle right infrnt of you if you move more than 5m away or if someone else near you moves 5ft away. I check player_spawncheck.sqf and it looks fine. 
      player_spawncheck.sqf 
      //player_spawncheck.sqf private ["_isWreck","_maxControlledZombies","_looted","_zombied","_doNothing","_spawnZedRadius","_serverTime","_age","_nearbyBuildings","_position","_speed","_radius","_maxlocalspawned","_maxWeaponHolders","_currentWeaponHolders","_maxtoCreate","_inVehicle","_isAir","_isLand","_isSea","_Controlledzeddivided","_totalcrew","_nearby","_type","_config","_canSpawn","_dis","_checkLoot","_islocal","_bPos","_zombiesNum"]; _age = -1; //_nearbyBuildings = []; _position = [player] call fnc_getPos; _speed = speed (vehicle player); _radius = 200; //150*0.707; Pointless Processing (106.5) _spawnZedRadius = 20; /* //Tick Time PVDZ_getTickTime = player; publicVariableServer "PVDZ_getTickTime"; */ //Total Counts _maxlocalspawned = round(dayz_spawnZombies); _maxControlledZombies = round(dayz_maxLocalZombies); _maxWeaponHolders = round(dayz_maxMaxWeaponHolders); _currentWeaponHolders = round(dayz_currentWeaponHolders); //Limits (Land,Sea,Air) _inVehicle = (vehicle player != player); /* _isAir = vehicle player iskindof "Air"; _isLand = vehicle player iskindof "Land"; _isSea = vehicle player iskindof "Sea"; if (_isLand) then { } else { }; if (_isAir) then { } else { }; if (_isSea) then { } else { }; */ _doNothing = false; if (_inVehicle) then { _Controlledzeddivided = 0; //exit if too fast if (_speed > 25) exitwith {_doNothing = true;}; //Crew can spawn zeds. _totalcrew = count (crew (vehicle player)); if (_totalcrew > 1) then { _Controlledzeddivided = 2; //Dont allow driver to spawn if we have other crew members. if (player == driver (vehicle player)) exitwith {_doNothing = true;}; } else { _Controlledzeddivided = 4; }; if (_Controlledzeddivided > 0) then { _maxControlledZombies = round(_maxControlledZombies / _Controlledzeddivided); r_player_divideinvehicle = _Controlledzeddivided; }; }; if (_doNothing) exitwith {}; /*if ("ItemMap_Debug" in items player) then { deleteMarkerLocal "MaxZeds"; deleteMarkerLocal "Counter"; deleteMarkerLocal "Loot30"; deleteMarkerLocal "Loot120"; deleteMarkerLocal "Agro80"; _markerstr = createMarkerLocal ["MaxZeds", _position]; _markerstr setMarkerColorLocal "ColorYellow"; _markerstr setMarkerShapeLocal "ELLIPSE"; _markerstr setMarkerBrushLocal "Border"; _markerstr setMarkerSizeLocal [_radius, _radius]; _markerstr1 = createMarkerLocal ["Counter", _position]; _markerstr1 setMarkerColorLocal "ColorRed"; _markerstr1 setMarkerShapeLocal "ELLIPSE"; _markerstr1 setMarkerBrushLocal "Border"; _markerstr1 setMarkerSizeLocal [_radius+100, _radius+100]; _markerstr2 = createMarkerLocal ["Agro80", _position]; _markerstr2 setMarkerColorLocal "ColorRed"; _markerstr2 setMarkerShapeLocal "ELLIPSE"; _markerstr2 setMarkerBrushLocal "Border"; _markerstr2 setMarkerSizeLocal [80, 80]; _markerstr2 = createMarkerLocal ["Loot30", _position]; _markerstr2 setMarkerColorLocal "ColorRed"; _markerstr2 setMarkerShapeLocal "ELLIPSE"; _markerstr2 setMarkerBrushLocal "Border"; _markerstr2 setMarkerSizeLocal [30, 30]; _markerstr3 = createMarkerLocal ["Loot120", _position]; _markerstr3 setMarkerColorLocal "ColorBlue"; _markerstr3 setMarkerShapeLocal "ELLIPSE"; _markerstr3 setMarkerBrushLocal "Border"; _markerstr3 setMarkerSizeLocal [120, 120]; diag_log ("LocalZombies: " +str(dayz_spawnZombies) + "/" +str(dayz_maxLocalZombies)); //Logging diag_log (format["%1 Local.Agents: %2/%3, NearBy.Agents: %8/%9, Global.Agents: %6/%7, W.holders: %10/%11, (radius:%4m %5fps).","SpawnCheck", _maxlocalspawned, _maxControlledZombies, _radius, round diag_fpsmin,dayz_currentGlobalZombies, dayz_maxGlobalZeds, dayz_CurrentNearByZombies, dayz_maxNearByZombies, _currentWeaponHolders,_maxWeaponHolders]); };*/ // nearObjects is faster than nearestObjects when sorting by distance isn't needed // "Building" includes House and all of its child classes (Crashsite, IC_Fireplace1, IC_Tent, etc.) _nearby = _position nearObjects ["Building",_radius]; _maxlocalspawned = _maxlocalspawned max floor(_maxControlledZombies*.8); if (_maxlocalspawned > 0) then { _spawnZedRadius = _spawnZedRadius * 3; }; //Spawn Zeds & loot in buildings { _type = typeOf _x; _config = missionConfigFile >> "CfgLoot" >> "Buildings" >> _type; _canSpawn = isClass (_config); if (_canSpawn) then { _dis = _x distance player; _checkLoot = (count (getArray (_config >> "lootPos"))) > 0; _islocal = _x getVariable ["", false]; // object created locally via TownGenerator. //Make sure wrecks always spawn Zeds _isWreck = _x isKindOf "CrashSite"; //Loot if (getNumber(_config >> "lootChance") > 0) then { if (_currentWeaponHolders < _maxWeaponHolders) then { //Basic loot check if ((_dis < 125) and (_dis > 30) and !_inVehicle and _checkLoot) then { _serverTime = serverTime; _looted = (_x getVariable ["looted",_serverTime]); _age = _serverTime - _looted; //Building refresh rate if (_age == 0 or (_age > getNumber(_config >> "lootRefreshTimer"))) then { _x setVariable ["looted",_serverTime,!_islocal]; _x call building_spawnLoot; if (!(_x in dayz_buildingBubbleMonitor)) then { dayz_buildingBubbleMonitor set [count dayz_buildingBubbleMonitor, _x]; }; //diag_log [ diag_tickTime, "new loot at",_x,"age:", _age, "serverTime:", _serverTime]; }/* else { diag_log [ diag_tickTime, "won't spawn loot at",_x,"age:", _age, "serverTime:", _serverTime]; }*/; }; }; }; //Zeds if (getNumber(_config >> "zombieChance") > 0) then { if (_dis > _spawnZedRadius) then { _serverTime = serverTime; _zombied = (_x getVariable ["zombieSpawn",_serverTime]); _age = _serverTime - _zombied; if ((_age == 0) or (_age > 300)) then { if (!_isWreck) then { if ((dayz_spawnZombies < _maxControlledZombies) and (dayz_CurrentNearByZombies < dayz_maxNearByZombies) and (dayz_currentGlobalZombies < dayz_maxGlobalZeds)) then { _bPos = getPosATL _x; _zombiesNum = count (_bPos nearEntities ["zZombie_Base",(((sizeOf _type) * 2) + 10)]); if (_zombiesNum == 0) then { _x setVariable ["zombieSpawn",_serverTime,!_islocal]; if (!(_x in dayz_buildingBubbleMonitor)) then { //add active zed to var dayz_buildingBubbleMonitor set [count dayz_buildingBubbleMonitor, _x]; }; //start spawn [_x] call building_spawnZombies; }; //diag_log (format["%1 building. %2", __FILE__, _x]); }; } else { _bPos = getPosATL _x; _zombiesNum = count (_bPos nearEntities ["zZombie_Base",(((sizeOf _type) * 2) + 30)]); //Should be a wreck if (_zombiesNum == 0) then { [_x,_isWreck] call building_spawnZombies; }; }; }; }; }; }; } forEach _nearby; At first I thought it was a respawn timer issue or something like that but if you don't move the loot will stay, you have to back away from it or someone else has to get within range and its not like you have to run away for this to happen, you can just back up a few steps and watch the loot change right infront of you. I have been playing around with it just trying to see if i can figure it out but if anyone knows what i should do or can at least point me in the right direction it would be a huge help.
       
      Thanks
    • By calinova22
      I was wondering if it is possible to make it so that a players humanity would not change for a certain amount of time? I have a PVP arena with a teleport in and I was wanting to make it so people could TP in and fight without worrying about gaining or losing humanity.
    • By Thug
      When I send a group invite, the players join, great.  Then you get all this radio chatter and speech text telling you to regroup, heli 1500m out, and BS BS BS . How do I turn off the radio chatter and the speech text?
  • Advertisement
  • Supporters
  • Discord

×
×
  • Create New...