Jump to content
bangabob

Enemy occupation system (eos)

Recommended Posts

I have as well, but assumed that I had done something wrong.

The server that I'm building, initially, had the markers with a size of zero (I'm building off of A3 Wasteland). I went through and gave them real sizes, but it seemed to have killed the performance of the A3 scripts.

I'm taking a break because I need to code something with a Raspberry Pi for a gift... I need the "Language Separation", so I'm taking a break from A3.

are you using area markers (ellipse/rectangle) or just making the icon marker larger?

Share this post


Link to post
Share on other sites
are you using area markers (ellipse/rectangle) or just making the icon marker larger?

I went through and assigned area markers to all the cities. I -think- this helped with the "stacking" issue, but I'm not sure. It killed the performance of the server. I need to go back and play some more, but another project has really killed my free time.

Share this post


Link to post
Share on other sites

I've been enjoying this script, and had some comments.

1. I've been using bastion for a QRF of sorts. It revolves around an enemy ammo dump that the player must frequent. Player must battle through a EOS zone, then a trigger is tripped near ammo boxes, it activates this..

Condition...

isServer && this (I assume :j:)

null = [["bast1"],[2,1],[0,0],[0],[0,0],[5,1,EAST],[60,1,120,false,false]] call Bastion_Spawn;

I have altered the b_core.sqf to have a _Placement=(_mkrX); which is the border of marker, then I make the marker size reasonable to sight lines. I've altered the _placement because player would see a despawn of incoming QRF when exiting marker zone. The QRF heads straight to center of marker which is nice.

The only thing I would add is, after leaving zone and returning to "bast1" the same QRF would return in same way. Which they don't to my knowledge. I know I'm not using Bastion as intended, the problem with default is it makes more sense to have a small zone that is called in init., but this doesn't jive with ever leaving the zone, due to despawning AI, unless this is changed to have a despawn distance in the parameters. Or make a EOS option like what I'm doing, which is similar to the heli trans, but with ground forces.

Also, I get script errors with "EOS integration" true, when leaving zone, and "eos_spawnVehicle.sqf" error when using vehicles, with bastion.

2. I've also added a infPoolSF to unitPool.sqf. Then used them to be the cargo in vehicles. This makes a nice change of pace.

// CREATE CARGO
if (_type==9) then {
	for "_i" from 0 to 4 do{
		_unit=_InfPoolSF select (floor(random(count _InfPoolSF)));
		_temparray set [count _temparray,_unit];
						};
};

Thanks for making this so accessible.

Edited by PlacidPaul

Share this post


Link to post
Share on other sites

i have a few questions that i was hoping you could help me with.

first i will tell you what i have done.

I have placed 3 red markers named town1 town2 town3 and they work fine.

The questions what i wanted to ask

1) is it possible to only should 1 marker at 1 given time untill the AO is cleared?

2) and is it possible to make them randomized?

much appreciated

Hellstorm77

Share this post


Link to post
Share on other sites

I have managed to get the OA to be random and with AI. now the only problem i have is that if im next to all the markers AI Spawn on the 3 markers. how do i get them to only spawn at AO which has shown up on the map

_randomTown = ["town1","town2", "town3"] call BIS_fnc_selectRandom;

                       _marker = createMarker ["townActive",getmarkerPos _randomTown];
		_marker setMarkerBrush "DIAGGRID";
		_marker setMarkerColor "ColorRed";
		_marker setMarkerShape "ELLIPSE";
		_marker setMarkerSize [500, 500]; 

Share this post


Link to post
Share on other sites

What you'll have to do is call EOS_Spawn every time you want to start a new AO. The easiest way to do this is in eos_core.sqf modify the section starting at line 279 with:

_mkr setmarkercolor VictoryColor;
_mkr setmarkerAlpha _mAN;
[i]0 = [_mkr] call Kinch_LootReward;[/i] // This is where you'll call your AO starter script.
if (_debug) then {hint "Zone Captured";};

This allows you to have EOS automate the AO-selection process and keeps the mission going automatically. I have mine setup where OpenMe.sqf precompiles my LootReward script for use by eos_core. Give that a go and see if it works.

Share this post


Link to post
Share on other sites

I suffered this bug from 0.95 ver of BTC revive....

When I use both of BTC and EOS, bunch of units spawned in the corner of map whenever I click [respawn] and it cause huge system lag for everyone in the server.

attached screenshot..

I didn't modified any line of script(both of them).

how can I solve this problem..?

http://steamcommunity#com/sharedfiles/filedetails/?id=247389159

Share this post


Link to post
Share on other sites

Does this Eos version works good on MP guys ?

Share this post


Link to post
Share on other sites

i am not sure if its you as the creator of the eos or the author of the insurgency script i need advice, so will try here, just i can get a thanks in aswell :)

i am using the eos as a "third angle" to a tvt mission, so there is human players on opfor and blufor then independents are the ai generated by the eos.

how it is at present the squares are all red, then turn green when blufor defeat that zone.

what has been requested if possible, would be the squares are green, indicating independent control, then which ever team clears the zone, it turns that color, ie blue when blufor win it.

further down the line making a some kind of sector control tracker that gave a percentage as to who was winning would be cool, but at present i am simply weighing up what is feasible first

Share this post


Link to post
Share on other sites

Is it possible to give spawned units a INIT entry an additional eventhandler ? like

_unit addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}];

i tried

_grp=(_this select 0);
_skillArray=(_this select 1);

				_skillset = server getvariable _skillArray;
					{
			_unit = _x;
			{
		_skillvalue = (_skillset select _forEachIndex) + (random 0.2) - (random 0.2);
		_unit setSkill [_x,_skillvalue];
			} forEach ['aimingAccuracy','aimingShake','aimingSpeed','spotDistance','spotTime','courage','reloadSpeed','commanding','general'];

				if (EOS_DAMAGE_MULTIPLIER != 1) then {_unit removeAllEventHandlers "HandleDamage";_unit addEventHandler ["HandleDamage",{_damage = (_this select 2)*EOS_DAMAGE_MULTIPLIER;_damage}];};
				if (EOS_KILLCOUNTER) then {_unit addEventHandler ["killed", "null=[] execVM ""eos\functions\EOS_KillCounter.sqf"""]};
				// ADD CUSTOM SCRIPTS TO UNIT HERE
				_unit addEventHandler ["FiredNear",{[_this,_this select 1] execVM "snd.sqf";}];

					} forEach (units _grp);

in the "setskill.sqf" but it doesn't work :/

Edited by Vasilyevich

Share this post


Link to post
Share on other sites

stupid question figured it out

Edited by DirtyDel

Share this post


Link to post
Share on other sites

Very nice and useful script, BangaBob. I try to use it in conjuction with High Command module, High Command Extensions by DomZ to be precise, together with team switching feature, and I've got one question/request: can You make in the future a version of this script, which will spawn/delete and respawn enemy units in EOS zones not only when player by himself is closing to EOS Zone, but also when any units of his side are doing this? Because as a High Commander I spent most of the time deep behind the frontlines commanding my troops, so I want mainly them to activate/deactivate EOS zones, not by myself.

Also, it would be nice to have an option of spawning in EOS area not only the random units taken from the pool defined in OpenMe.sqf file, but also units placed there earlier, in the editor (with their waypoints and heights, etc.).

Edited by mnemonicjohn

Share this post


Link to post
Share on other sites

Hello all, maybe i missed it but ... I wounder, HOW to use the very useful script on a Headless client ? Thank you so much guys.

Share this post


Link to post
Share on other sites

Got an interesting problem for you.

The way I use EOS in my mission, I have approximately 50+ AOs (markers) scattered all around Altis, most of which spawn EAST units. Lately it works flawlessly until the server gets halfway through, and we run out of bad guys to shoot at. From near as we can tell the script still works (I've had reports of vehicles spawning in OK but lacking crew members), it's just run out of groups to work with.

Is there any way to make sure, when a marker is captured that it cleans up the groups used by EOS?

Share this post


Link to post
Share on other sites

A request for next update, re EOS_Spawn

Please apply the command

setUnitPos "UP";

to building-garrisoned units. This will force them to stand. At the moment, when they enter combat mode, they go prone, which is not suitable or fun for house-to-house combat. It's much better when they are shooting from windows and balconies, which they cannot do when they go prone.

Share this post


Link to post
Share on other sites

Loving the script, just 1 question - is there a way to make the zones invisible so that if there are so many zones on the map and me and others are roaming around

we have no idea what we are walking into and so that we do not see the enemy coming? any help would be great, thanks.

Share this post


Link to post
Share on other sites

Cheers

---------- Post added at 07:01 ---------- Previous post was at 06:55 ----------

Loving the script, just 1 question - is there a way to make the zones invisible so that if there are so many zones on the map and me and others are roaming around

we have no idea what we are walking into and so that we do not see the enemy coming? any help would be great, thanks.

I believe your looking for this

null = [["EOSinf_1","EOSinf_2"],[2,2,100],[2,2,100],[0,0,0],[0,0],[0],[0,0],[0,0,350,EAST,TRUE]] call EOS_Spawn;

0 = Highlighted

1 = Invisible

2 = Normal

Edited by 3lockad3

Share this post


Link to post
Share on other sites
Updated with video demonstration + instructions.

Any feedback would be appreciated :)

Is there anyway the marker could be invisible, but then turn red after clearing the cached marker ?

I want to make the map more of a patrol then KOS style with the new "Probability parameters".

And another great thing to add would be accuracy over distance, for instance, the AI's accuracy would be about 80% at 100m or less,, but at 300-400m if would be significantly reduced to 40%. Of course we could always play with the right params to get that realistic feel if you gave us the environment to choose it.

Thank you so much for this awesome script Banga and great tutorials.

Cheers

Share this post


Link to post
Share on other sites
Ya sorry about that. First post, first mission editing.

This is one of the zones I'm using as a test. The zone will not go to green after killing all the infantry..

null = [["mrkr47"],[1,2],[1,1],[1,1],[1],[1],[1,1],[5,0,300,EAST,FALSE,TRUE]] call EOS_Spawn;

Sounds like you forgot to add the game logic server. Be sure you grab that from the sample mission.

---------- Post added at 17:19 ---------- Previous post was at 17:00 ----------

Okay I damn near read everything in this thread and it ether has not been asked or I missed it.

By the time I get to a downed enemy he de-spawns before I can get his gear. Plus I looked in the code and think I may have found the lines responsible, but not to sure how to go about this argument, Help please! I don't want the units to clean up so fast.

Share this post


Link to post
Share on other sites

Yea we are also having the same problem squares just turning green without any enemy contact. We clear about 2 towns and this issue occurs. We are currently using the latest version if that helps. Any idea on how to fix this issue would be much appreciated.

Thanks for your time.

Share this post


Link to post
Share on other sites

Hey Banga, have a bug for you, when I place down a marker it seems like the op4 just keep re-spawning like it is on a 10 second loop.

Every 10 seconds they re-spawn and run out the temple,, then once again re-spawn and run out. Rinse and repeat.

Hope this helps you.

Thanks for this great script!

Cheers!

Share this post


Link to post
Share on other sites

Bug report:

v1.98

APCs spawned with bastion, do not use their guns. There is a full crew (driver,gunner,commander), but the gunner will only look at targets and will not engage.

I've encountered similar problems many months ago, when using BIS_fnc_spawnGroup to spawn mechanized squads (the prefab ones from config). The APC would not fire.

I have better luck with APCs when just using createVehicleArray and then createUnit/assignAs/moveIn for all the crew seats.

For repro on 1.98, set a bastion zone and have only APCs spawn (I have seen the issue with MSE-3 Marid and BTR-K Kamysh, but suspect it affects all APCs).

Share this post


Link to post
Share on other sites

Also I'm finding FIA spawn vehicles without crew on stable release, and on dev branch it gives a _crew variable not found error if that's a clue?

EDIT: ok it helped when i populated this option _crewPool= ["B_G_officer_F"]; :o

Edited by Katipo66

Share this post


Link to post
Share on other sites

Hi gents. Need some help as I'm new to editing. I'm using this script in my mission and a need the AI to be a bit worse in accuracy. I couldn't find if I should make the figure smaller or higher in the AI_Skill.sqf.

SO how do I change them to make them noobs?

0.20, // aimingAccuracy

0.45, // aimingShake

0.4, // aimingSpeed

0.2, // spotDistance

0.2, // spotTime

1, // courage

1, // reloadSpeed

1, // commanding

1 // general

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×