Jump to content
  • 0

0.3.2.0 - Restricted build areas


dnk_paul

Question

18 answers to this question

Recommended Posts

  • 0

 

Hi!

 

All has been swallowed by Exile, supposedly. :-)

 

Easiest way -get back to you old description.ext from 0.3.1, which sits in your epoch.something.pbo.

Just change string epochVersion = "0.3.1.0"; to epochVersion = "0.3.2.0";.

Text block blockedArea[] = { }; contains restricted zones coords.

https://github.com/EpochModTeam/Epoch/blob/0.3.1.0/Sources/mpmissions/epoch.Altis/description.ext

Good luck.

Edited by zhaleks
Link to comment
Share on other sites

  • 0

Thanks zhaleks

I was more wanting to remove them than add them in. We tried to build at the military base north of the central spawn, and it's telling us that it's a protected frequency, event though the option for building near military is set to allowed. So, i presumed that bit of config moved somewhere else instead

Paul

Link to comment
Share on other sites

  • 0

That's how I'm set already...

 

 

#include "cfgPricing.hpp"
#include "trader\Halv_defines.hpp"
#include "addons\halv_spawn\spawndialog.hpp"
#include "trader\tradedialog.hpp"
#include "trader\HSPricing.hpp"
author = "Epoch Mod Team";
class Header
{
 gameType = Sandbox;
 minPlayers = 1;
 maxPlayers = 100;
};
respawn = "BASE";
respawnDelay = 600;
respawnDialog = 0;
onLoadMission= "Epoch";
OnLoadIntro = "Welcome to Epoch Mod";
loadScreen = "\x\addons\a3_epoch_assets\pictures\loadScreen_ca.paa";
OnLoadIntroTime = False;
OnLoadMissionTime = False;
onLoadName = "Epoch Mod";
disabledAI = true;
scriptedPlayer = 1;
disableChannels[]={2,6};
enableItemsDropping = 0;
briefing = 0;
debriefing = 0;
enableDebugConsole = 0;
joinUnassigned = 0;
respawnOnStart = 0;
forceRotorLibSimulation = 0;
corpseManagerMode = 1;
corpseLimit = 10;
corpseRemovalMinTime = 1200;
corpseRemovalMaxTime = 3600;
wreckManagerMode = 1;
wreckLimit = 2;
wreckRemovalMinTime = 60;
wreckRemovalMaxTime = 360;
class CfgRemoteExecCommands {};
class CfgEpochClient
{
    epochVersion = "0.3.2.0";
    sapperRngChance = 100; // increase number to reduce chances and reduce to increase. Default 100 = 1% - 55% if soiled (+ 2% if in city) chance to spawn sapper
    droneRngChance = 100; // increase number to reduce chances and reduce to increase. Default 100 = // 2% chance (+ 4% chance if in city) (1% - 2% Half if using silencer) to spawn drone if shot fired
    buildingNearbyMilitary = 1; //1 to allow building nearby
    buildingNearbyMilitaryRange = 0; //Define radius of blocked area
    buildingRequireJammer = 0; // 1 = to allow building without a jammer
    buildingCountLimit = 250; // how many objects can be built within range of a jammer
    buildingJammerRange = 125; // jammer range in meters
    EPOCH_news[] = {"Word is that Sappers have a new boss.","Dogs will often lure them monsters away.","My dog was blown up. I miss him.."};
    #include "\x\addons\a3_epoch_config\Configs\CfgEpochClient\Altis.hpp"
};
class CfgEpochSapper
{
    detonateDistMax = 8; //Random distance between 3m and this number at which sapper detonates. Min value = 4
    groanTrig = 16; //Percentage chance of a groan. Min value = 4
    sRange = 300; //Distance from target over which sapper will dispose. Range within which sapper code will be aware of targets. Distance up to which sapper will attempt to find a spot to hide in. Min Value = 150.
    smellDist = 24; //Distance up to which sapper can smell. Used to decide if sapper can see target when deciding to charge and influences target selection. Is influenced by wind direction. Min Value = 8.
};
class CfgEpochUAV
{
    UAVMinDist = 48; //Minimum distance to choose next position when roaming. Min Value = 8.
    UAVMaxDist = 180; //Maximum distance to choose next position when roaming. Min Value = 42 / Max Value = 400.
    UAVHeight = 50; //Set height when roaming, slight randomness is applied to this value. UAV will choose own height when locked onto target. Min Value = 42 / Max Value = 280. UAV can still spot targets from height !
};
class CfgEpochAirDrop
{
    AirDropFreq = 1200; //AirDropChance, to decide if Air drop occurs, will only be checked once per AirDropFreq time period, for each player. Min value = 120.
    AirDropChance = 6; //Percentage chance of air drop, for current player. Checked every AirDropFreq and upon antagonists spawn trigger. -1 To disable.
};
class CfgEpochCloak
{
    cRange = 300; //Distance, from target, at which Cloak will dispose. Cloak is also aware of players within this range. (Min: 60 / Max: 600)
    cAggression = 75; //Percentage chance of attack, currently a psychological attack (Cultist spooky voice). (Min: 1 / Max: 100)
    attackFrequency = 120; //One attack only per this period. (Min: 120)
    attackDistance = 38; // Distance, from target, up to which Cloak will attack. Lower for less vocals. (Min: 16)
    targetChangeFrequency = 42; //Cloak will only attempt to change target once per this period. Make Higher to stick to first target player. (Min: 42)
    teleportChance = 66; //Chance for cloak to teleport. (Min: 1)
    hoverFrequency = 1280; //Cloak has new hover attack. When player is above cloak, and at a distance, cloak will float to player and teleport attack. Only perform one of these moves per this period. (Min: 240)
};
class RscTitles
    {
    
    #include "addons\Status_Bar\statusBar.hpp"
    
    }; 

 

Hence the confusion!

Edited by dnk_paul
Added code tags
Link to comment
Share on other sites

  • 0

Also would like to know how to do this. Building is blocked in several random areas within towns too (like the hospital in Kavala for example) which we'd also like to allow. Tried adding\editing this in  description.ext:

	buildingInRestrictedAreas = 1; 		//1 to allow building in Banned Areas
	buildingNearbyCapitals = 1; 		//1 to allow building in Capital Cities
  
	buildingNearbyMilitary = 1; 		//1 to allow building nearby
	buildingNearbyMilitaryRange = 250; 	//Define radius of blocked area; Default radius 300

And commenting those areas mentioned above out in the Altis.hpp file, but it's had no effect. Still unable to build near the hospital. 

I found all this in EPOCH_isBuildAllowed.sqf: 

if !(_buildingAllowed)exitWith{ false };

if (getNumber(_config >> "buildingNearbyMilitary") == 0) then{
    _range = getNumber(_config >> "buildingNearbyMilitaryRange");
    if (_range > 0) then {
        _restricted = nearestObjects [player, ["ProtectionZone_Invisible_F","Cargo_Tower_base_F","Cargo_HQ_base_F","Cargo_Patrol_base_F","Cargo_House_base_F"], 300];
    } else {
        _restricted = nearestObjects [player, ["Cargo_Tower_base_F","Cargo_HQ_base_F","Cargo_Patrol_base_F","Cargo_House_base_F"], _range];
        _restricted append (nearestObjects [player, ["ProtectionZone_Invisible_F","Cargo_Tower_base_F","Cargo_HQ_base_F","Cargo_Patrol_base_F","Cargo_House_base_F"], 300]);
    };
} else {
    _restricted = nearestObjects [player, ["ProtectionZone_Invisible_F"], 300];
};
if !(_restricted isEqualTo []) then {
    _buildingAllowed = false;
    _dt = ["<t size = '0.8' shadow = '0' color = '#99ffffff'>Building Disallowed: Protected Frequency</t>", 0, 1, 5, 2, 0, 1] spawn bis_fnc_dynamictext;
};

_restrictedLocations = nearestLocations [player, ["NameCityCapital"], 300];
if !(_restrictedLocations isEqualTo []) then {
    _buildingAllowed = false;
    _dt = ["<t size = '0.8' shadow = '0' color = '#99ffffff'>Building Disallowed: Protected Frequency</t>", 0, 1, 5, 2, 0, 1] spawn bis_fnc_dynamictext;
};

_myPosATL = getPosATL player;
{
    if ((_x select 0) distance _myPosATL < (_x select 1)) exitWith {
        _buildingAllowed = false;
        _dt = ["<t size = '0.8' shadow = '0' color = '#99ffffff'>Building Disallowed: Protected Frequency</t>", 0, 1, 5, 2, 0, 1] spawn bis_fnc_dynamictext;
    };
} forEach(getArray(_config >> worldname >> "blockedArea"));

_buildingAllowed

...but I'm not sure how to override it, or even if that's what I should be doing to get this to work

Edited by blue00
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...