Jump to content

Cavadus

Member
  • Posts

    130
  • Joined

  • Last visited

Posts posted by Cavadus

  1. Hey Face, would adding launchers and their ammo to the machine gun array in loots.h interact poorly with A3EAI?  I keep trying to add launchers to my server's loot table but every time I do it breaks the server and it won't boot.  Trying to track down the issue.

     

    Here's a link to the post containing the two arrays I edited:  

  2. Alright, will give that a try.  Will report with results in a few.

     

    Here's the new code for the LMG/ammo arrays in loots.h:

     

    UPDATED

    	class Machinegun
    	{
    		items[] = {
    				{ { "LMG_Zafir_F", "weapon" }, 1 },
    				{ { "Machinegun_arifle_MX_SW_F", "CfgLootTable" }, 2 },
    				{ { "LMG_Mk200_F", "weapon" }, 3 },
    				{ { "launch_NLAW_F", "weapon" }, 1 },
    				{ { "launch_RPG32_F", "weapon" }, 1 },
    				{ { "launch_Titan_F", "weapon" }, 1 },
    				{ { "launch_Titan_short_F", "weapon" }, 1 },
    				{ { "Machinegun_m249_EPOCH", "CfgLootTable" }, 3 },
    				{ { "MMG_MarkDLC_EPOCH", "CfgLootTable" }, 1 }
    		};
    	};
    
    ...
    
            class MachinegunAmmo
    	{
    		items[] = {
    				{ { "MachinegunAmmo_200Rnd_65x39_cased_Box", "CfgLootTable" }, 8 },
    				{ { "130Rnd_338_Mag", "magazine" }, 6 },
    				{ { "MachinegunAmmo_150Rnd_762x54_Box", "CfgLootTable" }, 10 },
    				{ { "MachinegunAmmo_100Rnd_65x39_caseless_mag", "CfgLootTable" }, 22 },
    				{ { "200Rnd_556x45_M249", "magazine" }, 19 },
    				{ { "150Rnd_93x64_Mag", "magazine" }, 10 },
    				{ { "NLAW_F", "magazine" }, 10 },
    				{ { "RPG32_HE_F", "magazine" }, 10 },
    				{ { "RPG32_F", "magazine" }, 10 },
    				{ { "Titan_AA", "magazine" }, 10 },
    				{ { "Titan_AP", "magazine" }, 10 },
    				{ { "Titan_AT", "magazine" }, 10 },
    				{ { "MachinegunAmmo_30Rnd_65x39_caseless_mag", "CfgLootTable" }, 29 }
    		};
    	};
    
  3. CfgLootTable should only be used if its another class so change them to magazine or weapon

     

    Well, that's what I did but it broke my server.  You can see the exact code I used.  I added it to the mission pbo and then my server wouldn't start.  Reverted it and it started up just fine.  As you can see I added launchers to the LMG arrays.  I must have messed something up, however.  No idea what it was, though.  The code looks solid to me.

     

    Have you tested how the mission AI react to it. Does it work with that too. I don't mine that player have to download something as I am working on a weapon/vehicle/object modpack.

     

    They ignore it completely.  It has no effect on them whatsoever.  So it's perfectly compatible with A3EAI, Andre Convy, and SEM.

  4. Need some help, not sure I'm getting the class names quite right.  I edited the machine gun arrays to include static HMGs, AGLs, and launchers and then I added the associated ammo the MG ammo array but now my server won't start.  I noticed that an item can be tagged as either weapon/magazine or CfgLootTable.  I just don't know what should be what.  

    Could anyone clear this up?  Here are the two arrays I edited:

    	class Machinegun
    	{
    		items[] = {
    				{ { "LMG_Zafir_F", "weapon" }, 1 },
    				{ { "Machinegun_arifle_MX_SW_F", "CfgLootTable" }, 2 },
    				{ { "LMG_Mk200_F", "weapon" }, 3 },
    				{ { "launch_NLAW_F", "weapon" } 1 },
    				{ { "launch_RPG32_F", "weapon" } 1 },
    				{ { "launch_Titan_F", "weapon" } 1 },
    				{ { "launch_Titan_short_F", "weapon" } 1 },
    				{ { "B_HMG_01_F", "CfgLootTable" } 1 },
    				{ { "B_GMG_01_F", "CfgLootTable" } 1 },
    				{ { "O_HMG_01_F", "CfgLootTable" } 1 },
    				{ { "O_GMG_01_F", "CfgLootTable" } 1 },
    				{ { "Machinegun_m249_EPOCH", "CfgLootTable" }, 3 },
    				{ { "MMG_MarkDLC_EPOCH", "CfgLootTable" }, 1 }
    		};
    	};
    
    ...
    
    	class MachinegunAmmo
    	{
    		items[] = {
    				{ { "MachinegunAmmo_200Rnd_65x39_cased_Box", "CfgLootTable" }, 8 },
    				{ { "130Rnd_338_Mag", "magazine" }, 6 },
    				{ { "MachinegunAmmo_150Rnd_762x54_Box", "CfgLootTable" }, 10 },
    				{ { "MachinegunAmmo_100Rnd_65x39_caseless_mag", "CfgLootTable" }, 22 },
    				{ { "200Rnd_556x45_M249", "magazine" }, 19 },
    				{ { "150Rnd_93x64_Mag", "magazine" }, 10 },
    				{ { "NLAW_F", "magazine" }, 10 },
    				{ { "RPG32_HE_F", "magazine" }, 10 },
    				{ { "RPG32_F", "magazine" }, 10 },
    				{ { "Titan_AA", "magazine" }, 10 },
    				{ { "Titan_AP", "magazine" }, 10 },
    				{ { "Titan_AT", "magazine" }, 10 },
    				{ { "500Rnd_127x99_mag_Tracer_Green", "magazine" }, 10 },
    				{ { "500Rnd_127x99_mag_Tracer_Red", "magazine" }, 10 },
    				{ { "200Rnd_127x99_mag_Tracer_Red", "magazine" }, 10 },
    				{ { "200Rnd_127x99_mag_Tracer_Green", "magazine" }, 10 },
    				{ { "100Rnd_127x99_mag_Tracer_Red", "magazine" }, 10 },
    				{ { "96Rnd_40mm_G_belt", "magazine" }, 10 },
    				{ { "40Rnd_20mm_g_belt", "magazine" }, 10 },
    				{ { "MachinegunAmmo_30Rnd_65x39_caseless_mag", "CfgLootTable" }, 29 }
    		};
    	};
    
  5. If I where you I would add this and just add the extra thing in it, plus the normal stuff, and then adjust how much you like it should spawn.

     

     

    And with outfits, I don't know how to fix. As you can have them in the loot list, but you can't wear them, not all of them anyway. If you figure that one out let me know as I think the same as you. 

     

    Got it working.  Was actually pretty simple.  I just followed the instructions exactly for installation on the server (so just upload the entire zip to the arma3 directory) and then I added a startline parameter for the mod.

     

    Clients need to also install the mod.  If they don't they can loot the uniforms and see others wearing them but will not be able to equip them.

  6. Hey Face, one minor nitpick.  When it comes to armed vehicles the AI is kinda dumb.  If you disable the tires to tracks all of the AI will jump out and abandon the gun.  The gunner should be staying on the vehicle for over watch and fire support.  The players on my server have been disabling the armored/armed vehicles in this fashion to remove the RCWS weapons from the situation.

     

    Smart on their part; dumb on the AI's part.

  7. Also, I added some launchers (as you can see above) but I'm not getting them to spawn.  All of the explosives and the launcher ammo is spawning, though.  Any ideas?

     

    I added the launcher ammo in separately.  Was that a mistake?  I just wanted to make sure that with the dual ammo type launchers I wasn't getting all of one kind or another.

  8.  

    Combined with A3EAI you could add the crash location as a spawn location for AI, insert at line 39 of HeliCrashes.sqf:

     

    I do the same with Zupas capture points and random crate spawns

    //Infantry spawns using the A3EAI
    _CrashName = format ["Crashsite_%1",_j];
    [_CrashName,_posOfCrash,75,3,2,false,300] call A3EAI_createCustomInfantryQueue;	
    diag_log text format ["[HeliCrash]: Creating AI at %1 (%2)",_CrashName,_posOfCrash];
    

     

    Hey second_coming, does this look right to you?  It feels like I'm getting weird AI spawning behavior in general with A3EAI since making this modification.

    private ["_crashNum","_lootNum","_loot","_coords"];
    /////////////////////////////////////
    //      Function file for UKGZ	   //
    //        Created by: Richie       //
    //  Modded by:  Vampire & xBowBii  //
    /////////////////////////////////////
    // Number of Crashes
    _crashNum = 4;
    
    // Number of Loot Piles
    _lootNum = 16;
    
    _loot = [
    	"m107_EPOCH","MultiGun","Srifle_GM6_F","Srifle_LRR_F","M14_EPOCH","srifle_EBR_F","m249_EPOCH","LMG_Mk200_F","LMG_Zafir_F",
    	"m16_EPOCH","akm_EPOCH","m4a3_EPOCH","Rollins_F","sr25_epoch","l85a2_epoch","arifle_MX_GL_F",
    	"srifle_DMR_02_ARCO_F","srifle_DMR_02_sniper_F","srifle_DMR_03_spotter_F","srifle_DMR_03_tan_AMS_LP_F","srifle_DMR_03_tan_F","srifle_DMR_03_woodland_F",
    	"srifle_DMR_04_ARCO_F","srifle_DMR_04_DMS_F","srifle_DMR_04_F","srifle_DMR_04_MRCO_F","srifle_DMR_05_blk_F","srifle_DMR_05_DMS_F","srifle_DMR_05_DMS_snds_F","srifle_DMR_05_hex_F",
    	"srifle_DMR_06_camo_F","srifle_DMR_06_camo_khs_F","srifle_DMR_06_olive_F","MMG_01_hex_ACRO_LP_F","MMG_01_hex_F","MMG_01_tan_F","MMG_02_camo_F","MMG_02_sand_F","MMG_02_sand_RCO_LP_F",
    	"launch_NLAW_F","launch_RPG32_F","launch_Titan_short_F","HandGrenade","MiniGrenade","Titan_AP","Titan_AT","NLAW_F","RPG32_HE_F","RPG32_F",
    	
    	"optic_Nightstalker","optic_LRPS","optic_DMS","optic_Aco_smg","optic_ACO_grn_smg","optic_Holosight_smg",
    	"optic_Aco","optic_Holosight","acc_pointer_IR","Rangefinder",
    	
    	"ATMine_Range_Mag","APERSMine_Range_Mag","APERSBoundingMine_Range_Mag","SLAMDirectionalMine_Wire_Mag","APERSTripMine_Wire_Mag","ClaymoreDirectionalMine_Remote_Mag","SatchelCharge_Remote_Mag","DemoCharge_Remote_Mag",
    	
    	"EnergyPack","Repair_EPOCH","Defib_EPOCH","Heal_EPOCH","FAK","ItemWatch","CircuitParts","ItemScraps","jerrycan_epoch","VehicleRepair","CircuitParts",
    	
    	"meatballs_epoch","ItemSodaRbull","sardines_epoch","scam_epoch","sweetcorn_epoch","Towelette"
    ];
    
    _spawnCenter = [10088,9045,0]; //Center of your map (usually in mission.sqm)
    _min = 0; // minimum distance from the center position (Number) in meters
    _max = 12000; // maximum distance from the center position (Number) in meters
    _mindist = 10; // minimum distance from the nearest object (Number) in meters, ie. spawn at least this distance away from anything within x meters..
    //Low _mindist means helicrashes could spawn near towns or in forests.. higher the number it would be spawning in an open field etc
    _water = 0; // water mode 0: cannot be in water , 1: can either be in water or not , 2: must be in water
    _shoremode = 0; // 0: does not have to be at a shore , 1: must be at a shore
    
    vSpawnCrashes = {
    	for "_j" from 1 to _crashNum do {
    		_posOfCrash = [_spawnCenter,_min,_max,_mindist,_water,20,_shoremode] call BIS_fnc_findSafePos; // find a random loc
    		//Infantry spawns using the A3EAI
    		_CrashName = format ["Crashsite_%1",_j];
    		[_CrashName,_posOfCrash,75,3,2,false,300] call A3EAI_createCustomInfantryQueue;	
    		diag_log text format ["[HeliCrash]: Creating AI at %1 (%2)",_CrashName,_posOfCrash];
    		_helicopters = ["Land_UWreck_Heli_Attack_02_F","Land_Wreck_Heli_Attack_01_F"]; //Add Heli classnames here
    		_element = _helicopters call BIS_fnc_SelectRandom;
    		_vehHeli = _element createVehicle [0,0,0];
    		_burnthefucker = "test_EmptyObjectForFireBig" createVehicle (position _vehHeli);  _burnthefucker attachto [_vehHeli, [0,0,-1]];  
    		_vehHeli setposATL [(_posOfCrash) select 0,(_posOfCrash) select 1,0];
    		_vehHeli setVariable ["LAST_CHECK", (diag_tickTime + 14400)];
    				
    		for "_i" from 1 to _lootNum do {
    			_crate0 = createVehicle ["weaponHolderSimulated", _vehHeli modelToWorld [(random 10) - 3, (random 10) - 4, 0], [], 0, "CAN_COLLIDE"];
    			_crate1 = createVehicle ["weaponHolderSimulated", _vehHeli modelToWorld [(random 10) - 3, (random 10) - 4, 0], [], 0, "CAN_COLLIDE"];
    			
    			_item = _loot call BIS_fnc_selectRandom;
    			switch (true) do
    			{
    				case (isClass (configFile >> "CfgWeapons" >> _item)): {
    					_kindOf = [(configFile >> "CfgWeapons" >> _item),true] call BIS_fnc_returnParents;
    					if ("ItemCore" in _kindOf) then {
    						// Min 1, Max 2
    						_crate0 addItemCargoGlobal [_item,(floor(random(2)))+1];
    						_crate1 addItemCargoGlobal [_item,(floor(random(2)))+1];
    					} else {
    						// One Weapon, Three Mags
    						_crate0 addWeaponCargoGlobal [_item,1];
    						_crate1 addWeaponCargoGlobal [_item,1];
    						
    						_cAmmo = [] + getArray (configFile >> "cfgWeapons" >> _item >> "magazines");
    						{
    							if (isClass(configFile >> "CfgPricing" >> _x)) exitWith {
    								_crate0 addMagazineCargoGlobal [_x,3];
    								_crate1 addMagazineCargoGlobal [_x,3];
    							};
    						} forEach _cAmmo;
    					};
    				};
    				case (isClass (configFile >> "cfgMagazines" >> _item)): {
    					// Min 1, Max 3
    					_crate0 addMagazineCargoGlobal [_item,(floor(random(3)))+1];
    					_crate1 addMagazineCargoGlobal [_item,(floor(random(3)))+1];
    				};
    				case ((getText(configFile >> "cfgVehicles" >> _item >>  "vehicleClass")) == "Backpacks"): {
    					// One Bag
    					_crate0 addBackpackCargoGlobal [_item,1];
    					_crate1 addBackpackCargoGlobal [_item,1];
    				};
    			};
    			_crate0 setPos [(getPos _crate0 select 0) +5, (getPos _crate0 select 1), 0];
    			_crate1 setPos [(getPos _crate1 select 0) -10, (getPos _crate1 select 1), 0];
    			_crate0 setVariable ["LAST_CHECK", (diag_tickTime + 14400)];
    			_crate1 setVariable ["LAST_CHECK", (diag_tickTime + 14400)];
    			_cutter0 = "Land_ClutterCutter_medium_F" createVehicle (getpos _crate0);
    			_cutter1 = "Land_ClutterCutter_medium_F" createVehicle (getpos _crate1);
    			_cutter0 setVariable ["LAST_CHECK", (diag_tickTime + 14400)];
    			_cutter1 setVariable ["LAST_CHECK", (diag_tickTime + 14400)];
    
    			
    		};
    	};
    };
    
    call vSpawnCrashes;
    
  9. Thanks, Dwarfer.  I'll probably just add that stuff to an existing array or something.

     

    Last question, how do I add my new loot to the admin spawn menu?  I downloaded epoch.hpp but all I see is a ESP-LOOT reference.  Unsure where to go after that.

  10. So, if I wanted to add RPGs, their ammo, and vehicle ammo would y'all recommend simply adding it into an existing class array or creating a new one?  And if I create a new one, I assume there are references to it somewhere to ensure they spawn correctly, right?  And if so, where would I find them?

  11. here is why

    ["I_Truck_02_medical_F",1],

    ["I_Truck_02_fuel_F",1],

    ];

     

    do this

     

    ["I_Truck_02_medical_F",1],

    ["I_Truck_02_fuel_F",1] <-------- no comma at the end

    ];

     

     

    sec reviewing his script again, I forgot if it was like that.

     

     

    here is mine, not being used atm

     

    A3EAI_vehList = [

    ["B_MRAP_01_EPOCH",5],

    ["C_Van_01_transport_EPOCH",5],

    ["C_Offroad_01_EPOCH",5],

    ["C_Hatchback_02_EPOCH",5],

    ["C_Hatchback_01_EPOCH",5],

    ["B_Truck_01_transport_EPOCH",5],

    ["B_Truck_01_mover_EPOCH",5],

    ["B_Truck_01_covered_EPOCH",5],

    ["B_Truck_01_box_EPOCH",5]

    ];

     

    so I was correct, don't put the comma at the end.

     

    Removed comma, still broken.  No vehicles spawning whatsover.  Swapped in the default config file and everything started working again.  The changes in that list is the only difference between default and customized.

     

    EDIT: Got it working.  Removed that comma but then I forgot to ADD a comma after ["B_Truck_01_box_EPOCH",5].

     

    Awesome!

  12. Hey Face,

     

    I added vehicles to the script and it completely broke all vehicle spawns just like the last time I tried it.

    Here's what the vehicle spawn class looks like straight out of my sqf:

     

     

    //Classnames of land vehicle types to use, with the maximum amount of each type to spawn.

    A3EAI_vehList = [
    ["C_Van_01_transport_EPOCH",1],
    ["C_Offroad_01_EPOCH",1],
    ["C_Hatchback_02_EPOCH",1],
    ["C_Hatchback_01_EPOCH",1],
    ["B_Truck_01_transport_EPOCH",1],
    ["B_Truck_01_mover_EPOCH",1],
    ["B_Truck_01_covered_EPOCH",1],
    ["B_Truck_01_box_EPOCH",1],
    //Custom Vehicle Adds
    ["I_MRAP_03_F",1],
    ["I_MRAP_03_hmg_F",1],
    ["I_MRAP_03_gmg_F",1],
    ["B_MRAP_01_F",1],
    ["B_MRAP_01_gmg_F",1],
    ["B_MRAP_01_hmg_F",1],
    ["O_MRAP_02_F",1],
    ["O_MRAP_02_hmg_F",1],
    ["O_MRAP_02_gmg_F",1],
    ["B_G_Offroad_01_armed_F",2],
    ["O_G_Offroad_01_F",2],
    ["O_G_Offroad_01_armed_F",2],
    ["I_G_Offroad_01_armed_F",2],
    ["O_Truck_02_fuel_F",1],
    ["B_Truck_01_transport_F",1],
    ["B_Truck_01_covered_F",1],
    ["B_Truck_01_box_F",1],
    ["B_Truck_01_Repair_F",1],
    ["B_Truck_01_ammo_F",1],
    ["B_Truck_01_fuel_F",1],
    ["B_Truck_01_medical_F",1],
    ["O_Truck_02_covered_F",1],
    ["O_Truck_02_transport_F",1],
    ["O_Truck_02_box_F",1],
    ["O_Truck_02_medical_F",1],
    ["O_Truck_02_Ammo_F",1],
    ["O_Truck_02_fuel_F",1],
    ["I_Truck_02_ammo_F",1],
    ["I_Truck_02_box_F",1],
    ["I_Truck_02_medical_F",1],
    ["I_Truck_02_fuel_F",1],
    ];
  13. One quick question.  I want fewer overall convoys but bigger ones.  When I go into the sqf and find:

    //Cars in each convoy (refere to donn_carsConvy)
    _convoyFormation = [
    	[0,5],
    	[3,4],
    	[1,3],
    	[6],
    	[1,6],
    	[3,3],
    	[4,5],
    	[3,3]
    ];
    

    To delete a convoy entirely do I need to just delete the contents in the brackets so it reads [] or can I just delete the entire line?

  14. So, I'm having an issue editing the loadouts for the crates.  I wanted to increase the quantity of food, ammo, and add some ammo types but when I edit the SDROP_functions.sqg I seem to break the crate loadouts.

    They all just revert to a single default instead of the four different setups.  Even if I simply increase the quantity of the existing items it breaks the loadouts in this way.

     

    Any ideas?

×
×
  • Create New...