Jump to content

Wicked AI/Mission system


Markk311

Recommended Posts

hi all, got this mostly working but getting a couple of RPT errors,

 

15:14:54 Error in expression < compile format ["%1",_data];
_status = _result select 0;
 
if (_status == "Objec>
15:14:54   Error position: <_result select 0;
 
if (_status == "Objec>
15:14:54   Error Undefined variable in expression: _result
15:14:54 File z\addons\dayz_server\system\server_monitor.sqf, line 265
 
---------------------------------------------------------------------------------------------------------------
 
15:15:04 Error in expression <{
_aiskin = _skin
};
_unit = _unitGroup createUnit [_aiskin, [(_position select >
15:15:04   Error position: <createUnit [_aiskin, [(_position select >
15:15:04   Error Type Any, expected Number
15:15:04 File z\addons\dayz_server\WAI\compile\SpawnGroup.sqf, line 53
15:15:04 Error in expression <{
 
------------------------------------------------------------------------------------------------------------------------
 
15:15:24 Error in expression < ["Mission",0] != 1) && !(vehicle _x in _safety) && (typeOf vehicle _x) != "Para>
15:15:24   Error position: <_safety) && (typeOf vehicle _x) != "Para>
15:15:24   Error Undefined variable in expression: _safety
 
 
 
 
 
Any help greatly appreciated
Link to comment
Share on other sites

That what you are asking is not so easy. Static place is ok, but if you want get there vehicles and choppers, you need to change compiled scripts, because you need to delete them by mission timeout. And special loot - you need to make some changes in missionCfg and make second lootbox... Its a lot of work man :-)

Link to comment
Share on other sites

That what you are asking is not so easy. Static place is ok, but if you want get there vehicles and choppers, you need to change compiled scripts, because you need to delete them by mission timeout. And special loot - you need to make some changes in missionCfg and make second lootbox... Its a lot of work man :-)

 

I know, but -Razor posted that he had it, maybe there is others too...

Link to comment
Share on other sites

First off like many other people here have said here. GREAT JOB ON THIS I Love it. Ok now I have a few questions. 1. Everything was working fine and now when missions start up all The AI's are dead with the exception of 2 AI's. Is anyone else having that problem and if so how did you fix it? 2. With custom Static spawns , I add'd my locations and units and nothing comes up. Do they spawn as a random mission ? if so is there a way I can make them just spawn all the time and after they get killed only respawn after server restart? And the same question for static Ammo box's? Sorry if this question have been asked , I read through and might have missed my answers. Thanks in Advance AFFRAID

Link to comment
Share on other sites

Im having problem with missions spawning very slow. Sometimes it takes like 1.5hours for mission to spawn even tho i have set them to spawn 20mins after each other.

Man using mission.cfg from set timer (1,2, string set time on start mission and mission clear per seconds) and see start this topic about cofiguration)

Link to comment
Share on other sites

First off like many other people here have said here. GREAT JOB ON THIS I Love it. Ok now I have a few questions. 1. Everything was working fine and now when missions start up all The AI's are dead with the exception of 2 AI's. Is anyone else having that problem and if so how did you fix it? 2. With custom Static spawns , I add'd my locations and units and nothing comes up. Do they spawn as a random mission ? if so is there a way I can make them just spawn all the time and after they get killed only respawn after server restart? And the same question for static Ammo box's? Sorry if this question have been asked , I read through and might have missed my answers. Thanks in Advance AFFRAID

 

 

 

 

In my server All working perfect. See you script and using notepadd ++ for editing file.

Link to comment
Share on other sites

I have this all working on my server everything works just fine apart from the ammo boxes they are not spawning at any of the AI missions only vehicles spawn? I use blur antihack would this effect the spawning of the ammo boxes?

 

There are an option in antihack config, "check hacker boxes" true or false, set it to false and everything will be ok.

Link to comment
Share on other sites

Hello guys. I know that some of you want to add some heavy weapons to the bots, because they are not shooting in some armored vehicles with default weapons, so I made a little script change for you.

AI will have RPG only on missions, and only 1 person from one group will have an RPG.

 

1) So, first of all you need to open SpawnGroup.sqf in WAI/custom/ folder.

Find there that code:

if (count _this > 8) then {
	_mission = _this select 8;
} else {
	_mission = False;
};

and replace it with that code:

if (count _this > 8) then {
	_mission = _this select 8;
	_RPG = 1;
} else {
	_mission = False;
	_RPG = -1;
};

2) find this code:

for "_i" from 1 to _mags do {_unit addMagazine _magazine;};
_unit addBackpack _aipack;	

and replace it with this code:

for "_i" from 1 to _mags do {_unit addMagazine _magazine;};
if ((_x == 1) && (_RPG > 0)) then {
  _unit addweapon "RPG7V"; 
  _unit addmagazine "PG7VL"; 
  _unit addmagazine "PG7VL";
} else {
  _unit addBackpack _aipack;	
};

If you want to leave RPG and ammo on the deadbodies that will be enough, but if you want to remove it after bot's death, you should do this thing:
Open file ai_killed.sqf and right after this code:

private ["_unit","_player","_humanity","_banditkills"];
_unit = _this select 0;
_player = _this select 1;
_type = _this select 2;

add this:

_unit removeWeapon "RPG7V";
_unit removeMagazine "PG7VL";
_unit removeMagazine "PG7VL";

So, you've done this! Your AI will now have an RPG on the missions and you know, they really like to shoot it:)

 

By the way, I also tested an RPG ammo, and I can say that if you want to kill any vehicle with oneshot, you should use "PG7VR" magazines.

And if you want to give to player a chance to survive, you can use "OG7" magazines, even HMMVW can survive after this shot.

PG7VL will destroy any  Vodnik's, but if you have any heave armored vehicles (like on my server), PG7VL will destroy tracks or wheels of BMP or BTR.

 

Sorry for my english:)

Link to comment
Share on other sites

Man using mission.cfg from set timer (1,2, string set time on start mission and mission clear per seconds) and see start this topic about cofiguration)

yeah i know. i have set timer to 1200sec (20mins) and still takes well over and hour before first mission comes

Link to comment
Share on other sites

Hello guys. I know that some of you want to add some heavy weapons to the bots, because they are not shooting in some armored vehicles with default weapons, so I made a little script change for you.

AI will have RPG only on missions, and only 1 person from one group will have an RPG.

 

1) So, first of all you need to open SpawnGroup.sqf in WAI/custom/ folder.

Find there that code:

if (count _this > 8) then {
	_mission = _this select 8;
} else {
	_mission = False;
};

and replace it with that code:

if (count _this > 8) then {
	_mission = _this select 8;
	_RPG = 1;
} else {
	_mission = False;
	_RPG = -1;
};

2) find this code:

for "_i" from 1 to _mags do {_unit addMagazine _magazine;};
_unit addBackpack _aipack;	

and replace it with this code:

for "_i" from 1 to _mags do {_unit addMagazine _magazine;};
if ((_x == 1) && (_RPG > 0)) then {
  _unit addweapon "RPG7V"; 
  _unit addmagazine "PG7VL"; 
  _unit addmagazine "PG7VL";
} else {
  _unit addBackpack _aipack;	
};

If you want to leave RPG and ammo on the deadbodies that will be enough, but if you want to remove it after bot's death, you should do this thing:

Open file ai_killed.sqf and right after this code:

private ["_unit","_player","_humanity","_banditkills"];
_unit = _this select 0;
_player = _this select 1;
_type = _this select 2;

add this:

_unit removeWeapon "RPG7V";
_unit removeMagazine "PG7VL";
_unit removeMagazine "PG7VL";

So, you've done this! Your AI will now have an RPG on the missions and you know, they really like to shoot it:)

 

By the way, I also tested an RPG ammo, and I can say that if you want to kill any vehicle with oneshot, you should use "PG7VR" magazines.

And if you want to give to player a chance to survive, you can use "OG7" magazines, even HMMVW can survive after this shot.

PG7VL will destroy any  Vodnik's, but if you have any heave armored vehicles (like on my server), PG7VL will destroy tracks or wheels of BMP or BTR.

 

Sorry for my english:)

 

I have added these in which missions should these appear?

Link to comment
Share on other sites

I have added these in which missions should these appear?

 

It will appear in every WAI mission. 1 man with RPG for a 1 group of bots (as you know, it could be 2, 3 or more groups spawned).

 

Thanks Semezky,

 

I noticed It was working before I posted that post, is there meant to be ammo boxes at all ai missions? most of the times its vehicles only the weapon missions have the ammo boxes

 

You know, previously I used SAR AI missions, and my infistar antihack somehow deleted all weapons from the crates, but not the tools, medicine etc.

Link to comment
Share on other sites

How can I fix this:

 

_item = createV>
21:37:08   Error Undefined variable in expression: _iclass
21:37:08 File z\addons\dayz_code\compile\spawn_loot.sqf, line 9
21:37:08 Error in expression <s select _index;
_itemType = _itemTypes select _index;
[_itemType select 0, _ite>
21:37:08   Error position: <select _index;
[_itemType select 0, _ite>
21:37:08   Error Zero divisor
21:37:08 File z\addons\dayz_server\WAI\missions\missions\crash_spawner.sqf, line 73
21:37:08 Error in expression <t 2;
_radius =    _this select 3;

switch (_iClass) do
{
default
 

:(

Link to comment
Share on other sites

Does anyone have some extra missions for this? this is by far the best mission system there is(except missions are still coming too slow for some reason(and yes i know how to set the timer in missioncfg)). i tried some other with this too but they screwed up everyones cars (after restart they were in different places) so had to delete them :(

some food,medical and construction item missions would be cool! and has anyone figured out a way to get more than 1 mission at a time?

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
×
×
  • Create New...