dzrealkiller Posted December 7, 2014 Report Share Posted December 7, 2014 God I hate that we cant modify things! Link to comment Share on other sites More sharing options...
uniflare Posted December 7, 2014 Report Share Posted December 7, 2014 Are the group variables group1/ailist, are they accessible externally to the server pbo? Maybe something using config pbo. Meg, thinking out loud. Basically only way to get around is add units to either of those groups. Of I suggest ailist. Link to comment Share on other sites More sharing options...
warriorn1 Posted December 7, 2014 Report Share Posted December 7, 2014 Got ai to spawn, markers to show. The ai now turns, shoots, runs and then gets deleted after ~7 seconds. Thought I had this nailed. Oh well, back to the drawing board. At least a box of loot spawns. However: _crate = createVehicle ["Box_NATO_Wps_F",[(DMS_Cords select 0) - 1, DMS_Cords select 1,0],[], 0, "CAN_COLLIDE"]; clearWeaponCargo _crate; clearMagazineCargo _crate; Doesn't seem to delete it's content. Perhaps it's the box itself that's designed to contain loot. How does your time/cleanup script look like do you have called twice with the timer so maybe it loops ? Link to comment Share on other sites More sharing options...
Defent Posted December 7, 2014 Report Share Posted December 7, 2014 I have not made a timer and cleanup atm. I am working on core functions before I ado the details. I suppose I will have to loop it in order to delete the content Link to comment Share on other sites More sharing options...
warriorn1 Posted December 7, 2014 Report Share Posted December 7, 2014 i see.. Hey how about adding this to AI script that goes with the Loot spawn but in a seperate call. for example .. _buildCIV= [ "Land_whatever", "Land_whatever" ]; items_spawn= [ ["gun"], ["anothergun"] ]; randomitems = { _position = _this; _selectedgroup = (floor(random(count items_spawn))); _weapon = items_spawn select _selectedgroup select 0; { deleteVehicle _x; } forEach nearestObjects [_position,["groundWeaponHolder"],0.3]; _weaponholder = createVehicle ["groundWeaponHolder", _position, [], 0, "CAN_COLLIDE"]; _weaponholder addItemCargoGlobal [_weapon, 1]; if((count((items_spawn) select _selectedgroup)) > 1) then { _mag = items_spawn select _selectedgroup select ((floor(random((count(items_spawnt select _selectedgroup) - 1)))) + 1); _weaponholder addMagazineCargoGlobal [_mag, 1]; }; _weaponholder setPos _position; }; ---- raising the loot where you want loot to spawn for example.. would it work ? (im still a noob at this... but anyhow that is why im asking) Defent 1 Link to comment Share on other sites More sharing options...
Cletis5 Posted December 7, 2014 Report Share Posted December 7, 2014 keep up the good work guys, AI missions would be much better for all to have. Link to comment Share on other sites More sharing options...
horbin Posted December 7, 2014 Report Share Posted December 7, 2014 I posted the following to the bug report forum. At this point I think there is something up with the server, possibly an unintended artifact of the admin tools or core ai code. 1. Personal Testing Server 2. Arma3 1.3.6, EPOCH 2.5.1 3. Adding static AI encounters -Attempting to add additional AI results in the server conducting cleanup within 7-30secs of the AI spawning -Additionally, AI spawned will target and engage a player, but the player is in 'god' mode and takes no damage from their weapons. -Killing the AI results in a corpse that contains lootable items. Dead bodies and associated gear remain after the cleanup. I have attempted to locate a publicvariable that may need to be set to dodge the cleanup, but the cleanup script itself does not look to evaluate for such a variable. I examined the logic for the UAV encounters, and did set the 'EPOCH_TEMPOBJ_PVS' variable but that did not seem to do the trick either. I am attempting to add the ai through the execVM of a script located in the mpmissions 'init.sqf' file Link to comment Share on other sites More sharing options...
Santa Posted December 7, 2014 Report Share Posted December 7, 2014 Well, after spending 3 days on my AI missions, i'm done. The hardest part was working around the cleanup Epoch has. Now to test them out :) Mr.XXX and MPG-DarkKnight 2 Link to comment Share on other sites More sharing options...
warriorn1 Posted December 7, 2014 Report Share Posted December 7, 2014 Santa, lets see if you live up to your nick :) hehe Link to comment Share on other sites More sharing options...
Atavis Posted December 7, 2014 Report Share Posted December 7, 2014 Santa, You have to make AI missions? Link to comment Share on other sites More sharing options...
horbin Posted December 7, 2014 Report Share Posted December 7, 2014 Santa, Do you plan to post how you overcame the cleanup before Christmas! :) Link to comment Share on other sites More sharing options...
uniflare Posted December 7, 2014 Report Share Posted December 7, 2014 On a side note, these additions being in mission file, doesn't that open the server to more vulnerability. Eg, air need to spawn on server, so missions file will have direct commands/execVM for that? Link to comment Share on other sites More sharing options...
horbin Posted December 7, 2014 Report Share Posted December 7, 2014 Stay on topic :) We need to figure out how to avoid the 'server cleanup' mission file has statements in it to only allow ai to be spawned by server. (ie in init.sqf) Link to comment Share on other sites More sharing options...
uniflare Posted December 7, 2014 Report Share Posted December 7, 2014 well the cleanup deletes everything not in its "lists", so from a general programming point of view you either;1. disable epoch cleanup some how2. add units you spawn to the cleanup safe lists (ailist etc)3. make units that cleanup cannot find somehow??Really what else can possibly be done? Link to comment Share on other sites More sharing options...
horbin Posted December 7, 2014 Report Share Posted December 7, 2014 you could post something obvious Link to comment Share on other sites More sharing options...
uniflare Posted December 7, 2014 Report Share Posted December 7, 2014 you could post something obviousI really dont get where your coming from? I haven't even tried adding AI so I do not know any solution yet, these are only my ideas from a programming background, though I do not know SQF very well yet.One of these must be possible surely? (albeit not disabling cleanup as is against rules, and ofc modifying it i didnt put on list also because of rules). Link to comment Share on other sites More sharing options...
Defent Posted December 7, 2014 Report Share Posted December 7, 2014 /* Finds random spot in radius of center map, bla bla bla marker @FileOverlordCreatorofAllMasterCommanderAlphandtheOmega: Defent */ private ["_pos","_centerPos"]; _centerPos = getArray(configFile >> "CfgWorlds" >> worldName >> "centerPosition"); _pos = [getMarkerPos "center",4000,20000,10,0,25,0] call BIS_fnc_findSafePos; DMS_Cords = _pos; diag_log format ["DMS: Pos found at: [%1] - markers spawning!",_pos]; // wait with script till pos is found waitUntil {_pos}; DMS_Main = createMarker ["DMS_Main", DMS_Cords]; DMS_Main setMarkerColor "ColorRed"; DMS_Main setMarkerShape "ELLIPSE"; DMS_Main setMarkerBrush "Grid"; DMS_Main setMarkerSize [150,150]; diag_log format ["DMS: Mission starting at %1",_pos]; sleep 4; publicVariable "DMS_Cords"; _aispawn = [DMS_Cords,80,6,6,1] execVM "Scrip\path\to\file.sqf";//AI Guards Here is my marker script, it also finds a random spot. If you're interested in how works. I will change this a lot since it's not optimized and it does not have any timers. I might share the rest of my (4) files if I feel like it. Who knows when that is. Link to comment Share on other sites More sharing options...
Cabrero Posted December 7, 2014 Report Share Posted December 7, 2014 /* Finds random spot in radius of center map, bla bla bla marker @FileOverlordCreatorofAllMasterCommanderAlphandtheOmega: Defent */ private ["_pos","_centerPos"]; _centerPos = getArray(configFile >> "CfgWorlds" >> worldName >> "centerPosition"); _pos = [getMarkerPos "center",4000,20000,10,0,25,0] call BIS_fnc_findSafePos; DMS_Cords = _pos; diag_log format ["DMS: Pos found at: [%1] - markers spawning!",_pos]; // wait with script till pos is found waitUntil {_pos}; DMS_Main = createMarker ["DMS_Main", DMS_Cords]; DMS_Main setMarkerColor "ColorRed"; DMS_Main setMarkerShape "ELLIPSE"; DMS_Main setMarkerBrush "Grid"; DMS_Main setMarkerSize [150,150]; diag_log format ["DMS: Mission starting at %1",_pos]; sleep 4; publicVariable "DMS_Cords"; _aispawn = [DMS_Cords,80,6,6,1] execVM "Scrip\path\to\file.sqf";//AI Guards Here is my marker script, it also finds a random spot. If you're interested in how works. I will change this a lot since it's not optimized and it does not have any timers. I might share the rest of my (4) files if I feel like it. Who knows when that is. I think everyone has that part made lol Link to comment Share on other sites More sharing options...
Defent Posted December 7, 2014 Report Share Posted December 7, 2014 I think everyone has that part made lol Great, then I won't be needing to post my second part that includes ai and patrols :) TheVampire and MGT 2 Link to comment Share on other sites More sharing options...
Cletis5 Posted December 7, 2014 Report Share Posted December 7, 2014 Great, then I won't be needing to post my second part that includes ai and patrols :) GG..................you could do it for the rest of the people that are more appreciative of peoples hard work. Link to comment Share on other sites More sharing options...
Atavis Posted December 7, 2014 Report Share Posted December 7, 2014 /* Finds random spot in radius of center map, bla bla bla marker @FileOverlordCreatorofAllMasterCommanderAlphandtheOmega: Defent */ private ["_pos","_centerPos"]; _centerPos = getArray(configFile >> "CfgWorlds" >> worldName >> "centerPosition"); _pos = [getMarkerPos "center",4000,20000,10,0,25,0] call BIS_fnc_findSafePos; DMS_Cords = _pos; diag_log format ["DMS: Pos found at: [%1] - markers spawning!",_pos]; // wait with script till pos is found waitUntil {_pos}; DMS_Main = createMarker ["DMS_Main", DMS_Cords]; DMS_Main setMarkerColor "ColorRed"; DMS_Main setMarkerShape "ELLIPSE"; DMS_Main setMarkerBrush "Grid"; DMS_Main setMarkerSize [150,150]; diag_log format ["DMS: Mission starting at %1",_pos]; sleep 4; publicVariable "DMS_Cords"; _aispawn = [DMS_Cords,80,6,6,1] execVM "Scrip\path\to\file.sqf";//AI Guards Here is my marker script, it also finds a random spot. If you're interested in how works. I will change this a lot since it's not optimized and it does not have any timers. I might share the rest of my (4) files if I feel like it. Who knows when that is. It would be nice if you helped to make missions for people. I wish you success in creating a mission. You will succeed. Link to comment Share on other sites More sharing options...
horbin Posted December 7, 2014 Report Share Posted December 7, 2014 Still running into issues with players being immune to AI that is spawned. If this was DOOM, god mode would be fun...but I digress :) Link to comment Share on other sites More sharing options...
warriorn1 Posted December 7, 2014 Report Share Posted December 7, 2014 /* Finds random spot in radius of center map, bla bla bla marker @FileOverlordCreatorofAllMasterCommanderAlphandtheOmega: Defent */ private ["_pos","_centerPos"]; _centerPos = getArray(configFile >> "CfgWorlds" >> worldName >> "centerPosition"); _pos = [getMarkerPos "center",4000,20000,10,0,25,0] call BIS_fnc_findSafePos; DMS_Cords = _pos; diag_log format ["DMS: Pos found at: [%1] - markers spawning!",_pos]; // wait with script till pos is found waitUntil {_pos}; DMS_Main = createMarker ["DMS_Main", DMS_Cords]; DMS_Main setMarkerColor "ColorRed"; DMS_Main setMarkerShape "ELLIPSE"; DMS_Main setMarkerBrush "Grid"; DMS_Main setMarkerSize [150,150]; diag_log format ["DMS: Mission starting at %1",_pos]; sleep 4; publicVariable "DMS_Cords"; _aispawn = [DMS_Cords,80,6,6,1] execVM "Scrip\path\to\file.sqf";//AI Guards Here is my marker script, it also finds a random spot. If you're interested in how works. I will change this a lot since it's not optimized and it does not have any timers. I might share the rest of my (4) files if I feel like it. Who knows when that is. if(!isServer) exitWith {}; markerready = true; missionrunning = false; _startTime = floor(time); _result = 0; while {true} do { _cnt = {alive _x} count playableUnits; _currTime = floor(time); if((_currTime - _startTime >= DMS_mission_timer) AND (!missionrunning)) then {_result = 1}; if(missionrunning) then { _startTime = floor(time); }; if((_result == 1) AND (_cnt >= 1) AND (markerready)) then { clean_running_mission = False; _mission = DMS_missions call BIS_fnc_selectRandom; execVM format ["Script\path\to\missions\%1.sqf",_mission]; missionrunning = true; diag_log format["DMS: Starting Mission %1",_mission]; _startTime = floor(time); _result = 0; } else { sleep 60; }; }; something like this ? starttime in config ofc right? Link to comment Share on other sites More sharing options...
horbin Posted December 8, 2014 Report Share Posted December 8, 2014 Great input guys, but I think all of this code is already out there for Arma2. Game logic code is all the same. The hurdles we are having are specific to the EPOCH mod. If anyone has figured out the AI cleanup, and/or the player god mod issue please let me know. Link to comment Share on other sites More sharing options...
drsubo Posted December 8, 2014 Report Share Posted December 8, 2014 I really don't know if there is a way to spawn ai without being able to edit the server files. I have tried tons of different ways and nothing works. Work around for vehicles and crates and all that good stuff but any attempt to work around the clean up for the ai just will not work. I see that a few people say that they have figured it out and if they did, great for them, but until I actually see some working script or something to show that they have actually figured it out I really don't think its possible and im going to but this on stop for now until we can edit the files more freely. Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now