Jump to content

[Release] Wicked AI 2.2.0


f3cuk

Recommended Posts

Havoc302 - Uploaded here https://www.dropbox.com/s/x6vpnbrdo1mt0nl/WAI.zip?dl=0

 

Thanks!

 

Like I said the Missions are fine, just my custom spawns

Ok thanks man, taking a look now, I've noticed that some of your group spawns are set to spawn under ground -3 and -6.1m can you send me your RPT file, it should say where it's loaded the WAI system and static spawns are loaded right after that.

Link to comment
Share on other sites

 

Maybe they are getting cleaned up with Missions?

Easiest way to find out is to set mission timeout to say 300 (5 Min)

and see if your crates de-spawn after 5 min

 

Or, and I have no idea if this will work, add

_crate1 setVariable ["permaLoot",true];

_crate2 setVariable ["permaLoot",true];

 

You may also need to add 

 

_crate1 = _this select 0;
_crate2 = _this select 0;
_crate1 setVariable ["ObjectID","1",true];
_crate2 setVariable ["ObjectID","1",true];
 
I pulled these lines from DZMS I think.

 

 

I still cant get the boxes to stay ;/

Link to comment
Share on other sites

so how do you have control over what loot is in the crates? don't tell me you can't!!!!!!!

You don't as it is, but you can easily make a file to do it.

 

Here an example of one I did for a special mission I created.

 

First I added a variable to the config.sqf.

super_villain_loot = compile preprocessFileLineNumbers "\z\addons\dayz_server\WAI\loot\gunbox_super_villain_loot.sqf";

Just replace the names as you need.

 

Then I created a file called gunbox_super_villain_loot.sqf and placed it at the path above. In that file is lots of this..

 

//gunbox super villain


_customcrate = _this select 0;
_customcrate setVariable ["ObjectID","1",true];
_customcrate setVariable ["permaLoot",true];
PVDZE_serverObjectMonitor set [count PVDZE_serverObjectMonitor,_customcrate];


clearWeaponCargoGlobal _customcrate;
clearMagazineCargoGlobal _customcrate;


// RIFLES
_customcrate addWeaponCargoGlobal ["RPG18", 2];
_customcrate addWeaponCargoGlobal ["MAAWS", 2];
_customcrate addWeaponCargoGlobal ["Stinger", 2];
_customcrate addWeaponCargoGlobal ["IGLA", 2];


// PISTOLS
_customcrate addWeaponCargoGlobal ["M9SD", 2];


// AMMUNITION
_customcrate addMagazineCargoGlobal ["RPG18", 20];
_customcrate addMagazineCargoGlobal ["MAAWS_HEAT", 10];
_customcrate addMagazineCargoGlobal ["MAAWS_HEDP", 10];
_customcrate addMagazineCargoGlobal ["Stinger", 15];
_customcrate addMagazineCargoGlobal ["IGLA", 15];


_customcrate addMagazineCargoGlobal ["15Rnd_9x19_M9SD", 8];




// ITEMS
_customcrate addWeaponCargoGlobal ["LaserDesignator", 2];


//BACKPACKS
_customcrate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1", 4];


// CLOTHING
_customcrate addMagazineCargoGlobal ["Skin_Drake_Light_DZ", 2];

Then calling it from the mission (or I guess static spawn) is like this:

if (_complete) then {
[_customcrate] call super_villain_loot;
};

For static I guess it'd be more like

    _crate1 = createVehicle ["USVehicleBox",[x,y,z],[],0,"CAN_COLLIDE"];
    [_crate1] call custom_crate;

But don't quote me on that, give it a go.

Link to comment
Share on other sites

You don't as it is, but you can easily make a file to do it.

 

Here an example of one I did for a special mission I created.

 

First I added a variable to the config.sqf.

super_villain_loot = compile preprocessFileLineNumbers "\z\addons\dayz_server\WAI\loot\gunbox_super_villain_loot.sqf";

Just replace the names as you need.

 

Then I created a file called gunbox_super_villain_loot.sqf and placed it at the path above. In that file is lots of this..

 

//gunbox super villain


_customcrate = _this select 0;
_customcrate setVariable ["ObjectID","1",true];
_customcrate setVariable ["permaLoot",true];
PVDZE_serverObjectMonitor set [count PVDZE_serverObjectMonitor,_customcrate];


clearWeaponCargoGlobal _customcrate;
clearMagazineCargoGlobal _customcrate;


// RIFLES
_customcrate addWeaponCargoGlobal ["RPG18", 2];
_customcrate addWeaponCargoGlobal ["MAAWS", 2];
_customcrate addWeaponCargoGlobal ["Stinger", 2];
_customcrate addWeaponCargoGlobal ["IGLA", 2];


// PISTOLS
_customcrate addWeaponCargoGlobal ["M9SD", 2];


// AMMUNITION
_customcrate addMagazineCargoGlobal ["RPG18", 20];
_customcrate addMagazineCargoGlobal ["MAAWS_HEAT", 10];
_customcrate addMagazineCargoGlobal ["MAAWS_HEDP", 10];
_customcrate addMagazineCargoGlobal ["Stinger", 15];
_customcrate addMagazineCargoGlobal ["IGLA", 15];


_customcrate addMagazineCargoGlobal ["15Rnd_9x19_M9SD", 8];




// ITEMS
_customcrate addWeaponCargoGlobal ["LaserDesignator", 2];


//BACKPACKS
_customcrate addBackpackCargoGlobal ["DZ_LargeGunBag_EP1", 4];


// CLOTHING
_customcrate addMagazineCargoGlobal ["Skin_Drake_Light_DZ", 2];

Then calling it from the mission (or I guess static spawn) is like this:

if (_complete) then {
[_customcrate] call super_villain_loot;
};

For static I guess it'd be more like

    _crate1 = createVehicle ["USVehicleBox",[x,y,z],[],0,"CAN_COLLIDE"];
    [_crate1] call custom_crate;

But don't quote me on that, give it a go.

 

I am sorry to be a pain, but from what i understand i would have to do this for every mission there are?

 

I dont understand why dynamic would be good idea, one of the main features about WAI was that you could easily control what loot the mission/crates spawned, why remove this feature completely. !!!

 

Dynamic loot is a big NO NO on my server!! is there another version of WAI that is still being updated that I can use? this is too much to get to my liking right now as i still have to mod another 10 scripts!!!

 

Thanks

Link to comment
Share on other sites

I cant get my Ural to stay in my static mission :/

 

I just want a Ural sat there with loot in that the player can get in and drive to a location to empty it, then when the server restarts they go back to the default location

 

if I get in it and drive it 10m or so it blew up, I added it to the safe vehicles section of the variables.sqf and now it disappears when I drive it 10m :/

 

Cant work out what I'm doing wrong for it to just be drivable lol

 

This is the script I have made

 

//Ural
_vehicle_212 = objNull;
if (true) then
{
  _this = createVehicle ["Ural_UN_EP1", [2539.99, 5060.82, 0.00143], [], 0, "CAN_COLLIDE"];
  _vehicle_212 = _this;
  _this setDir -39.765995;
    //Clear Cargo    
  clearweaponcargoGlobal _this;
  clearmagazinecargoGlobal _this;
  //Add Cargo
  _this addWeaponCargoGlobal ["Binocular",2];
  _this addWeaponCargoGlobal ["Binocular_Vector",2];
  _this addWeaponCargoGlobal ["NVGoggles",2];
  _this addWeaponCargoGlobal ["ItemGPS",2];
  _this addmagazineCargoGlobal ["FoodMRE",10];
  _this addmagazineCargoGlobal ["ItemSodaMdew",10];
  _this addWeaponCargoGlobal ["M240_DZ",1];
  _this addWeaponCargoGlobal ["SCAR_L_STD_Mk4CQT",1];
  _this addWeaponCargoGlobal ["SCAR_H_CQC_CCO_SD",1];
 
  _this addmagazineCargoGlobal ["30Rnd_556x45_Stanag",20];
  _this addmagazineCargoGlobal ["20Rnd_762x51_B_SCAR",6];
  _this addmagazineCargoGlobal ["20Rnd_762x51_SB_SCAR",6];
  _this addmagazineCargoGlobal ["100Rnd_762x51_M240",2];
 
  _this setPos [2539.99, 5060.82, 0.00143];
};

 

Link to comment
Share on other sites

I got told crate loot was randomized from now but its still not...  [Example]

// AMMUNITION
_box addMagazineCargoGlobal ["30Rnd_556x45_G36", 10];
_box addMagazineCargoGlobal ["20Rnd_762x51_DMR", 10];
_box addMagazineCargoGlobal ["200Rnd_556x45_M249", 10];
_box addMagazineCargoGlobal ["5Rnd_762x51_M24", 4];
_box addMagazineCargoGlobal ["30Rnd_556x45_Stanag", 10];

Just 10 of all and not random...  :mellow:

Link to comment
Share on other sites

I am sorry to be a pain, but from what i understand i would have to do this for every mission there are?

 

I dont understand why dynamic would be good idea, one of the main features about WAI was that you could easily control what loot the mission/crates spawned, why remove this feature completely. !!!

 

Dynamic loot is a big NO NO on my server!! is there another version of WAI that is still being updated that I can use? this is too much to get to my liking right now as i still have to mod another 10 scripts!!!

 

Thanks

If you run a server better get used to having to modify scripts for your own purposes, very rarely will a mod come out that fits your exact needs.

 

It's really not that hard to do, you could do it in an afternoon. Once you have the first one made it's just copy paste and changing the loot items.

Link to comment
Share on other sites

Megaz, I copied yours & simply changed the co-ordinates but still nothing, would it be due to me only calling groups of 2?

 

I don't see that being a problem as this is what I had on my old WAI & worked fine....

 

I did however remove the -- at the start of yours as I didn't see the necessity of it along with the f here -- at the end

 

Guy's here is a link to my WAI folder all works only rpt error is about a back pack : as below- if anyone knows how to fix would be nice thanks

 

if (!_actionSet) then {

s_player_holderPickup>

10:54:02   Error position: <_actionSet) then {

s_player_holderPickup>

10:54:02   Error Undefined variable in expression: _actionset

10:54:02 File z\addons\dayz_code\init\object_BackpackAction.sqf, line 13

 

 

DOWNLOAD WAI working file: this is for napf map just change cords to suit

https://drive.google.com/folderview?id=0B1ZWkptRhF_7cXpGblJ0XzZoNG8&usp=sharing

 

this is at the end on my server-monitor.sqf

 

[] call compile preprocessFileLineNumbers "\z\addons\dayz_server\DZAI\init\dzai_initserver.sqf";

[] ExecVM "\z\addons\dayz_server\WAI\init.sqf";

[] ExecVM "\z\addons\dayz_server\DZMS\DZMSInit.sqf";

allowConnection = true;

sm_done = true;

publicVariable "sm_done";

Link to comment
Share on other sites

I can't seem to get chopper patrols working. And i can't seem to get Launchers on AI's to work at all..

Can somebody show me a script for a proper chopper patrol & where to add (EXACLY)

And can somebody tell me how to properly enable AI's walk around with RPGs?

 

 

Thanks ;p

Link to comment
Share on other sites

I can't seem to get chopper patrols working. And i can't seem to get Launchers on AI's to work at all..

Can somebody show me a script for a proper chopper patrol & where to add (EXACLY)

And can somebody tell me how to properly enable AI's walk around with RPGs?

 

 

Thanks ;p

 

    // Hill behind Sector 6

    [

        [14270,15135,2.67],    // Position that units will be dropped by

        [15195,15433,35],                            // Starting position of the heli

        600,                                // Radius from drop position a player has to be to spawn chopper

        "UH1H_DZ",                            // Classname of chopper (Make sure it has 2 gunner seats!)

        10,                                    // Number of units to be para dropped

        "extreme",                            // Skill level of units (easy, medium, hard, extreme, Random)

        "Random",                            // Primary gun set number and rocket launcher. "Random" for random weapon set, "at" for anti-tank, "aa" for anti-air launcher

        4,                                    // Number of magazines

        "Random",                            // Backpack classname, use "Random" or classname here

        "Bandit2_DZ",                        // Skin classname, use "Random" or classname here

        "Random",                            // Gearset number. "Random" for random gear set.

        "Bandit",                            // AI Type, "Hero" or "Bandit".

        true                                // true: Aircraft will stay at position and fight. false: Heli will leave if not under fire.

    ] spawn heli_para;

Link to comment
Share on other sites

be nice to have the heli drop with a split options...

 

Option for...

 

Where the heli spawns

Where the heli is actually triggered from

Where the Heli drops the AI off

 

So if you have an area like mine, I would love to get the players to the middle, then two heli's pop over and drop AI at both exits making them fight back out :)

 

    [
        [0,0,0],    // Position that units will be dropped by
        [0,0,0],                            // Starting position of the heli

        [0,0,0],                            // trigger location
        100,                                // Radius from trigger a player has to be to spawn chopper
        "UH1H_DZ",                            // Classname of chopper (Make sure it has 2 gunner seats!)
        10,                                    // Number of units to be para dropped
        "extreme",                            // Skill level of units (easy, medium, hard, extreme, Random)
        "Random",                            // Primary gun set number and rocket launcher. "Random" for random weapon set, "at" for anti-tank, "aa" for anti-air launcher
        6,                                    // Number of magazines
        "Random",                            // Backpack classname, use "Random" or classname here
        "Bandit2_DZ",                        // Skin classname, use "Random" or classname here
        "Random",                            // Gearset number. "Random" for random gear set.
        "Bandit",                            // AI Type, "Hero" or "Bandit".
        true,                                // true: Aircraft will stay at position and fight. false: Heli will leave if not under fire.

        false,                                //true: Aircraft will slow down to drop units off. False, Aircraft will NOT slow down to drop units off (helps spread units out over larger areas)
    ] spawn heli_para;

Link to comment
Share on other sites

If you run a server better get used to having to modify scripts for your own purposes, very rarely will a mod come out that fits your exact needs.

 

It's really not that hard to do, you could do it in an afternoon. Once you have the first one made it's just copy paste and changing the loot items.

 

 

Or save time and why not use this... since they removed static loot on here

 

 

what are the main advantages of using this over the linked one above?

Link to comment
Share on other sites

	Custom Chopper Patrol spawn Eg.

	[
		[725.391,4526.06,0],				// Position to patrol
		[0,0,0],							// Position to spawn chopper at
		2000,								// Radius of patrol
		10,									// Number of waypoints to give
		"UH1H_DZ",							// Classname of vehicle (make sure it has driver and two gunners)
		"Random",							// Skill level of units (easy, medium, hard, extreme, Random)
		"Random",							// Skin classname, use "Random" or classname here
		"Bandit"							// AI Type, "Hero" or "Bandit".
	] spawn heli_patrol;


	Place your heli patrols below
	[
		[725.391,4526.06,0],				
		[1500,960,1000],							
		2000,								
		3,
		"UH1H_DZ",							
		"Hard",							
		"Random",							
		"Bandit"							
	] spawn heli_patrol;

The second part of the code, is what i tried but didnt work. The first part of the code is what ib ased it off. Can somebody help me out here with what i did wrong? And what's the best way to get cordinates for the choppers? (the radius to spawn chopper iaadjusted that several times, based on the infistar debug monitor cordinates. Aint working?)

 

Tried these cordinates : 8893.29,9178.14,0.00143433 on spawnpoint & patrolpoint...

Link to comment
Share on other sites

Hi people any one know how to or if its possible to set up a group of AI to only spawn if someone reaches a certain Position on the map (some sort of trigger) I want to create it so server performance is not wasted having 100 + AI waiting around already spawned.

Thanks

MegaZ

Link to comment
Share on other sites

Or save time and why not use this... since they removed static loot on here

 

 

what are the main advantages of using this over the linked one above?

 

Apart from that it actually works on 1051? Try these: https://github.com/f3cuk/WICKED-AI/blob/master/changelist.md

 

Hi people any one know how to or if its possible to set up a group of AI to only spawn if someone reaches a certain Position on the map (some sort of trigger) I want to create it so server performance is not wasted having 100 + AI waiting around already spawned.

Thanks

MegaZ

 

Yes this is possible using something like this.

_position     = [0,0,0]; // coords center of the mission
_start         = false;
waitUntil{

    {
        if((isPlayer _x) && (_x distance _position <= 1500)) then {
            _start = true
        };
    } count playableUnits;

    (_start)

};

if I increase the communication distance to 2000m will all of my 15 groups of AI communicate together or is it only per group where the communication happens?

 

        ai_share_distance            = 2000;            // Distance from killed AI for AI to share your rough position

 

 

This is not how this works. ai_share_distance is the amount of distance between you and the AI you killed for AI to share your rough position. So for example if you set it to 300 and you are 400m away from the AI you just killed, they won't share your rough location (e.g. look towards you).

 

Is there a way to set a Chance for a Static Group to spawn? I don't want to be expecting a group of AIs at Cherno everytime.

 

Easy enough

_dice = random 10;

if(_dice < 2) then { // about 20% chance
    
        // code here

};
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
  • Advertisement
×
×
  • Create New...