Jump to content
dreadpirate

Jebus - Just Editor Based Unit Spawning

Recommended Posts

6 hours ago, behemeth said:

Updated to also allow additional stuff (bags, tools, camonets etc.):

https://pastebin.com/B0He3jwZ

 

Edit: just to clarify, with the changes you don't need the INIT parameter. You can basically just edit the vehicle in the editor (e.g. via "edit vehicle appearance") and in its basic init field. The stuff will be stored by the fn_main.sqf and pushed into the new spawned vehicle.

Thanks for this. I'll update Jebus over the weekend. 

  • Like 2

Share this post


Link to post
Share on other sites

We should use a github or discord to discuss, since i also made some tweaks that i liked (like using variables instead of triggers to activate spawns, and cache units holding their starting positions for precise garrisoning) and there is probably a handful of different versions going on 

Share this post


Link to post
Share on other sites

@behemeth

 

v1.42 (2018/5/6)

  • The behemeth update
  • Backpacks in vehicle cargo saved
  • Vehicle fuel and hitpoints saved
  • Vehicle skin, camonets, slat armour, etc. saved
  • Group synchronizations are saved

Download

GitHub

Notes

  • I didn't write any code for this release. Thank you to behemeth
  • I noticed that the Offroad at the southern tip of Stratis doesn't save it's animations correctly, but I'm releasing as is for people to try

 

  • Like 1
  • Thanks 3

Share this post


Link to post
Share on other sites

@dreadpirate

 

Thanks for updating. I feel bad asking for a new feature rite after an update haha..

 

but do you think its possible to add an ability for user made waypoints for respawning groups to recognize triggers that are attached to them via syncing?

I have a scenario where groups spawn via JEBUS and follow waypoints,after waypoint two,i want them to hold until the conditions are met from a synced waypoint and then continue on,currently AI respawning ignore such synced waypoints.

  • Like 1

Share this post


Link to post
Share on other sites
14 hours ago, redarmy said:

@dreadpirate

 

Thanks for updating. I feel bad asking for a new feature rite after an update haha..

 

but do you think its possible to add an ability for user made waypoints for respawning groups to recognize triggers that are attached to them via syncing?

I have a scenario where groups spawn via JEBUS and follow waypoints,after waypoint two,i want them to hold until the conditions are met from a synced waypoint and then continue on,currently AI respawning ignore such synced waypoints.

It might be possible, I'll have a look. In the meantime, you can have your trigger set a variable, and have the condition field of the waypoint check that variable. 

 

(I'd do a demo mission, but I'm on my phone)

 

I'm thinking about ways to make Jebus more modular. It might be possible to save a group as a template and then spawn it from a trigger, marker or game logic, meaning less units cluttering up the mission file and all running Jebus at mission start. 

  • Like 1

Share this post


Link to post
Share on other sites
2 hours ago, dreadpirate said:

It might be possible, I'll have a look. In the meantime, you can have your trigger set a variable, and have the condition field of the waypoint check that variable. 

 

(I'd do a demo mission, but I'm on my phone)

 

I'm thinking about ways to make Jebus more modular. It might be possible to save a group as a template and then spawn it from a trigger, marker or game logic, meaning less units cluttering up the mission file and all running Jebus at mission start. 

Oh good thinking with the setvariable,il give it a go.

 

And i agree modular would be better.After a certain amount of units spawn in my mission i have a massive hang for a few seconds,iv had to look at other scripts in my mission and use a wait until,or sleep command to avoid laggy intro's in combination with JEBUS.

 

Also i wanted to report a small bug with respawning groups,i beleive 200m is default pause distance for spawning groups,correct? I have noticed if i am in that area(lets say 199m from spawn point) then move out(201m) then move in again the group spawns twice...in this case it ran GAIA code,and the extra spawned group didnt get that applied to it.Not a real big problem but i thought you might wana know.

 

If you wana test it...wait for group or vehicle to spawn,kill it,then teleport to a position on map,far enough away and then teleport back to spawn area,you will see two groups.

 

And i wanted to ask,regarding the command line "pause" entered manually,is there anyway to have this not be affected by Air classes?

 

EDIT: I just read fnc_enemyinradius.sqf...

 

// Detects if enemy is within a given radius (Planes excluded)
// [<position>, <friendly side>, <radius>] call Jebus_fnc_enemyInRadius.

 

seems it already does not count planes,can i uncomment the helicopter part in the lower line?....

 

_nearestEnemies = [];
_nearestUnits = _position nearEntities [["Man","LandVehicle","Helicopter","Ship"], _radius];

 

to exclude helo's without breaking anything?

Share this post


Link to post
Share on other sites
On 5/6/2018 at 2:01 PM, redarmy said:

@dreadpirate

 

Thanks for updating. I feel bad asking for a new feature rite after an update haha..

 

but do you think its possible to add an ability for user made waypoints for respawning groups to recognize triggers that are attached to them via syncing?

I have a scenario where groups spawn via JEBUS and follow waypoints,after waypoint two,i want them to hold until the conditions are met from a synced waypoint and then continue on,currently AI respawning ignore such synced waypoints.

 

Please try:

fn_saveWaypoints.sqf: https://pastebin.com/PsQHy18h

fn_applyWaypoints.sqf: https://pastebin.com/nTHdp7J7

 

I only tried it with Lives=1, but from what I understand it should also work with respawns. If it doesn't, please share the mission and I'll be happy to debug it.

  • Like 1

Share this post


Link to post
Share on other sites

I found that it was not possible to have different groups in one vehicle. Use Case: You want to have a driver and a task force in a vehicle. The vehicle goes to a drop off point and the task force exits and both, vehicle and task force, continue their own specific waypoints.

I changed the fn_main.sqf to allow for such: https://pastebin.com/XAV7qFkP

 

I also provide an example mission of this use case: https://drive.google.com/open?id=1vp4wkuh64RN1PVGd27pDH28Ypkq9vvbc

 

The changes for the additional groups within the vehicle are a little more invasive than the changes up to now. I did debug with 2 lives and it did work nicely. However, Jebus offers a lot of options, which I do not use yet and hence didn't test. So there's no guarantee the code changes will work for every possible scenario.

Share this post


Link to post
Share on other sites
5 hours ago, behemeth said:

 

Please try:

fn_saveWaypoints.sqf: https://pastebin.com/PsQHy18h

fn_applyWaypoints.sqf: https://pastebin.com/nTHdp7J7

 

I only tried it with Lives=1, but from what I understand it should also work with respawns. If it doesn't, please share the mission and I'll be happy to debug it.

I appreciate that mate thank you,il look when i get home.

Share this post


Link to post
Share on other sites

@dreadpirate

hey

1. how do I turn off the debug I set the _debug  to false in the FN_main.SQF but still see the notifications of unit spawning

2. where is your code that adds the units that use Jebus to the zeus module. I can't find any code that adds the units? maybe I am missing something. 3. you still have UPmons script in your demo mission. When I use UPMONS some of the armor vehicles  and the mechanized units don't work. it always take  a few minutes for upmons to generate waypoints.  Are you aware of this issue with UPMONS script now?  Avibird.

 

 

 

//Set up default parameters
_lives = -1;
_cacheRadius = 0;
_reduceRadius = 0;
_pauseRadius = 200;
_respawnDelay = 30;
_initialDelay = 0;
_gaiaParameter = "";
_gaiaZone = 0;
_special = "NONE";
_respawnMarkers = [];
_initString = "";
_debug = false;
 
//Get parameters
for "_parameterIndex" from 1 to (count _this - 1) do {
    switch (_this select _parameterIndex) do {
        case "LIVES=" : {_lives = _this select (_parameterIndex + 1)};
        case "DELAY=" : {_respawnDelay =  _this select (_parameterIndex + 1)};
        case "START=" : {_initialDelay = _this select (_parameterIndex + 1)};
        case "CACHE=" : {_cacheRadius =  _this select (_parameterIndex + 1)};
        case "REDUCE=" : {_reduceRadius =  _this select (_parameterIndex + 1)};
        case "GAIA_MOVE=" : {_gaiaParameter = "MOVE"; _gaiaZone = _this select (_parameterIndex + 1)};
        case "GAIA_NOFOLLOW=" : {_gaiaParameter = "NOFOLLOW"; _gaiaZone =  _this select (_parameterIndex + 1)};
        case "GAIA_FORTIFY=" : {_gaiaParameter = "FORTIFY"; _gaiaZone = _this select (_parameterIndex + 1)};
        case "FLYING" : {_special = "FLY"};
        case "RESPAWNMARKERS=" : {_respawnMarkers = _this select (_parameterIndex + 1)};
        case "PAUSE=" : {_pauseRadius = _this select (_parameterIndex + 1)};
        case "EXIT=" : {_exitTrigger = _this select (_parameterIndex + 1)};
        case "INIT=" : {_initString = _this select (_parameterIndex + 1)};
        case "DEBUG" : {_debug = false};  //true

Share this post


Link to post
Share on other sites
10 minutes ago, avibird 1 said:

@dreadpirate

hey

1. how do I turn off the debug I set the _debug  to false in the FN_main.SQF but still see the notifications of unit spawning

2. where is your code that adds the units that use Jebus to the zeus module. I can't find any code that adds the units? maybe I am missing something. 3. you still have UPmons script in your demo mission. When I use UPMONS some of the armor vehicles  and the mechanized units don't work. it always take  a few minutes for upmons to generate waypoints.  Are you aware of this issue with UPMONS script now?  Avibird.

 

 

 

//Set up default parameters
_lives = -1;
_cacheRadius = 0;
_reduceRadius = 0;
_pauseRadius = 200;
_respawnDelay = 30;
_initialDelay = 0;
_gaiaParameter = "";
_gaiaZone = 0;
_special = "NONE";
_respawnMarkers = [];
_initString = "";
_debug = false;
 
//Get parameters
for "_parameterIndex" from 1 to (count _this - 1) do {
    switch (_this select _parameterIndex) do {
        case "LIVES=" : {_lives = _this select (_parameterIndex + 1)};
        case "DELAY=" : {_respawnDelay =  _this select (_parameterIndex + 1)};
        case "START=" : {_initialDelay = _this select (_parameterIndex + 1)};
        case "CACHE=" : {_cacheRadius =  _this select (_parameterIndex + 1)};
        case "REDUCE=" : {_reduceRadius =  _this select (_parameterIndex + 1)};
        case "GAIA_MOVE=" : {_gaiaParameter = "MOVE"; _gaiaZone = _this select (_parameterIndex + 1)};
        case "GAIA_NOFOLLOW=" : {_gaiaParameter = "NOFOLLOW"; _gaiaZone =  _this select (_parameterIndex + 1)};
        case "GAIA_FORTIFY=" : {_gaiaParameter = "FORTIFY"; _gaiaZone = _this select (_parameterIndex + 1)};
        case "FLYING" : {_special = "FLY"};
        case "RESPAWNMARKERS=" : {_respawnMarkers = _this select (_parameterIndex + 1)};
        case "PAUSE=" : {_pauseRadius = _this select (_parameterIndex + 1)};
        case "EXIT=" : {_exitTrigger = _this select (_parameterIndex + 1)};
        case "INIT=" : {_initString = _this select (_parameterIndex + 1)};
        case "DEBUG" : {_debug = false};  //true

Debug is set where you call Jebus in the init line. 

0 = [this, "DEBUG"] etc etc

 

Zeus is called curator in sqf. Search for that. 

 

I don't use Upsmon myself, I just put it into the demo mission to demonstrate that Jebus can use different patrol scripts. 

Share this post


Link to post
Share on other sites

Hey @dreadpirate 

Upmon definitely not working. Wait it had a long delay and most of the armor is broken infantry still work but not in safe mode always on alert.

 

UPS is broken units are always in alert and never in safe limited speed as the script should be.

 

I don't know if this was due to last few updates but patrols scripts don't really work. GAIA works great ?. 

Share this post


Link to post
Share on other sites

Yes, upsmon is broken, nothing to do with jebus though, gaia works fine

Share this post


Link to post
Share on other sites

The only issue with GAIA is that the groups in a zone no matter how big the zone is setup  for the units groups are to knowledgeable of your exact location on the map. UPs and UPMONS you could adjust the settings for knowledge for the groups. Avibird

Share this post


Link to post
Share on other sites

But you can still do hit and run tactics, since they only know your last position so if you change your position quickly by sprinting or whatever they won't find you (i have seen this in zeus that groups go to your last position and if they don't find you they get a S&D waypoint in the vicinity for a while until the next report) you may be using a AI sharing script like VCOM or ASR AI (although ASR AI still has some time delay between broadcasts)

Share this post


Link to post
Share on other sites

Yes but still GAIA is very accurate with the locations compared to most AI Scripts. I only use a few units/ groups with GAIA if I put it into a mission. What I like to have is one or two groups motorized units very far away from the initial OA to start with infinite respawn on them to always have a slow but accurate reinforcement pool to the current OA in the mission. I always like to have a sniper group with GAIA. 

 

No back to my point I have done a lot of testing the last few days and jebus definitely breaks UPS and totally breaks UPMONS. UPMONS still works with infantry units with a 2 min delay to issue waypoints but with jebus over 8 minutes. I am currently testing USPS right now. It is very similar to upmons and ups but with one really cool feature house searching parameters. 

 

I usually used all three of these Scripts with the first editor spawn script  by murk and armaholic. I wanted to update some of my older missions with jebus because it's still being worked on and updated by the author thank you @dreadpirate.

 

How does jebus work with vcom alive ect I have not really spent to much time with some of the newer AI scripts. I am old and get very used to what I know lol. But I'm trying to open my mind ?

 

PS I love  MCC so I am very familiar with GAIA.

Share this post


Link to post
Share on other sites

But why do you say jebus breaks ups and upsmon? as far i know nothing from the code of jebus could break those two scripts, and they are really old so probably they don't even work at all

 

I have tested upsmon personally some months ago and it didn't work (i did it without jebus), the only version i know of upsmon up to date is from Antistasi but it's totally rewritten to work within it

Share this post


Link to post
Share on other sites

Like I said ups when using it with jebus the AI are always on alert never safe limited speed ect so yes it is broken with jebus for sure it works fine on it's on and with the other editor spawn script ie murk.  For upmons it was a based on ups with some more bells and whistles and yes most of upmons vehicles are  broken but infantry still works for sure on it's on and with murk editor spawn script but there is a delay of 2 minutes or so before waypoints get generated however with jebus over 8 minutes before waypoints get generated.

 

Why are you getting so defensive. Jebus is a great script that adds a lot. But using GAiA with it for a whole mission with a few hundred units is a little to much for my liking. Yes I could always added nofollow parameters but I prefer not to play with that or  despawning and respawning of units in the zones. Just my opinion. There are a few new AI control generated Waypoint scripts that I'm going to try with jebus. 

Share this post


Link to post
Share on other sites

Ah okay, thought you didn't tested without jebus

 

The delay between waypoints generated could be because the scheduler gets overwhelmed for any reason

Share this post


Link to post
Share on other sites

Yes tested with and without jebus UPS is broken now  units are always on alert moving at full speed and in combat mode I said this like three times lol

Share this post


Link to post
Share on other sites

Separate question about integrating UPSMON into Jebus...  With the updated versions (since 1.41), units won't respawn more than once.  Here's an example of my unit init:

 

0 = [this, "LIVES=", [3,3], "DELAY=", 10, "INIT=","[_proxyThis,'GF1'] execVM 'scripts\upsmon.sqf'", "RESPAWNMARKERS=", ["g11"]] spawn jebus_fnc_main; 

 

With older versions of Jebus, I could can get units to respawn as many times as I set with the old syntax, but with the new one, they only spawn once.  Is my syntax incorrect for where to put the modifiers?  I'm hoping to make this work as I prefer not to give AI units specific waypoints.

Share this post


Link to post
Share on other sites
14 hours ago, gatordev said:

Separate question about integrating UPSMON into Jebus...  With the updated versions (since 1.41), units won't respawn more than once.  Here's an example of my unit init:

 


0 = [this, "LIVES=", [3,3], "DELAY=", 10, "INIT=","[_proxyThis,'GF1'] execVM 'scripts\upsmon.sqf'", "RESPAWNMARKERS=", ["g11"]] spawn jebus_fnc_main; 

 

With older versions of Jebus, I could can get units to respawn as many times as I set with the old syntax, but with the new one, they only spawn once.  Is my syntax incorrect for where to put the modifiers?  I'm hoping to make this work as I prefer not to give AI units specific waypoints.

Try adding "DEBUG" to your parameters and see what happens. I just made a test mission with this exact init and it worked fine. The group spawned 3 times and then stopped. It ran UPSMON each time.

 

By the way, if you want 3 lives only, you can just do:

 

0 = [this, "LIVES=", 3] spawn jebus_fnc_main;

 

I'm not quite sure what the issue is with UPSMON and JEBUS. JEBUS just spawns a group and runs the init string. It doesn't do anything else until the group is eliminated.

Share this post


Link to post
Share on other sites

Thanks @dreadpirate.  Looks like what was happening was that it was reading my player character as an enemy too close to the spawn point.  It was spawning the first time because I was still "sided" as a civilian, but then once I kept shooting the AI, it was changing my side.  Once I tried farther away, it worked perfectly.  I used to know where to find that parameter in UPS, but I wasn't able to find that variable when I was looking through the scripts.

 

Thanks again for keeping this updated.  For me, it's essential to missions, especially now that UPSMON is throwing so many errors and unsupported.

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

×