Jump to content
Sign in to follow this  
wizbomb

Ambiant Combat module

Recommended Posts

ok i am creating a free roam map and i have two questions

#1 can i get the ambiant combt module to work is certin places? EX. enemy HQ area, almost like a trigger

#2 how do i have the ambiant combat module spawn only one faction? EX. USMC or RUSSIA

THNXS for any help:yay::yay::yay:

Share this post


Link to post
Share on other sites

1. So far i think we dont have the answer to that one. I think its possible, but were waiting to know how to limit it to other places than just around the player.

2. To spawn the faction of choice just add/remove the respective faction(s) from this line in the init.sqf:

//factions to be spawned

[["USMC", "INS", "RU", "CDF", "GER"], BIS_ACM] call BIS_ACM_setFactionsFunc;

Bolded are all factions that can be spawned. Add the one you want and that will be the only one(s) to spawn. "GER" = Guerilla (independent), and "INS" = Insurgents (opfor). Remember to set the independent to friendly or foe if you use them.

Full init.sqf for ACM use here (How to use - at bottom of this post):

waitUntil {!isNil {BIS_ACM getVariable "initDone"}};

waitUntil {BIS_ACM getVariable "initDone"};

//Sets frequency and number of patrols (0-1). BIS_ACM is module name

[1, BIS_ACM] call BIS_ACM_setIntensityFunc;

//min max spawn distance.

[bIS_ACM, 300, 700] call BIS_ACM_setSpawnDistanceFunc;

//factions to be spawned

[["USMC", "INS", "RU", "CDF"], BIS_ACM] call BIS_ACM_setFactionsFunc;

//Skill range for spawned units.

[0, 0.5, BIS_ACM] call BIS_ACM_setSkillFunc;

//Amount of ammo spawned units possess.

[0.3, 0.6, BIS_ACM] call BIS_ACM_setAmmoFunc;

//Type of patrol. With 0 meaning no chance of appearing, and 1 meaning 100% chance. -1 removes patrol type completely.

["ground_patrol", 1, BIS_ACM] call BIS_ACM_setTypeChanceFunc;

["air_patrol", 0.5, BIS_ACM] call BIS_ACM_setTypeChanceFunc;

How to:

-Open notepad and copy/paste all in the quote above. Save as init.sqf (make sure it doesnt end with .txt).

-Place the init.sqf in the mission folder so its together with your mission.sqm file.

-Place the ACM module in he game - synchronize it to your player and name the module BIS_ACM in the name field.

-Change the values in the init.sqf to your likings. Values from 0-1 and everything in between such as 0.1 or 0.5 etc.

Have fun! :)

Alex

Edited by Alex72

Share this post


Link to post
Share on other sites

OMG THINK YOU, i was getting tired of running into cdf in the desert maps (: p.s. i am running a desert map, what would look better russions or insurgants?

---------- Post added at 06:18 PM ---------- Previous post was at 06:12 PM ----------

when i try to save the name in the module it says "invalid variable name", do you know what that means?:(

Edited by wizbomb

Share this post


Link to post
Share on other sites

Its prolly because of a space in the objectname..

example: "BIS_ACM" not "BIS ACM"

Share this post


Link to post
Share on other sites

Hi All,

As I am not very good with scripting, I wonder how to just modify the Ambiant combat module by adding commands in the "ini window" of the module you place on the map.

Can somebody post an example of "script" that can be used in the "ini window" of the module (and that works) rather than some complicated codes that need to be part of in a special file to add to the mission directory etc...

For example, how to modify a script like this to work in the 'ini window' of the module ?

waitUntil {!isNil {BIS_ACM getVariable "initDone"}};

waitUntil {BIS_ACM getVariable "initDone"};

[100, BIS_ACM] call BIS_ACM_setIntensityFunc;

[["USMC"], BIS_ACM] call BIS_ACM_setFactionsFunc;

[bIS_ACM, 1, 10] call BIS_ACM_setSpawnDistanceFunc;

["ground_patrol", 1, BIS_ACM] call BIS_ACM_setTypeChanceFunc;

["air_patrol", 0, BIS_ACM] call BIS_ACM_setTypeChanceFunc;

thank you all for your help !

Share this post


Link to post
Share on other sites

Try to use spawn.

this spawn {
sleep 1;
waitUntil {!isNil {BIS_ACM getVariable "initDone"}};
waitUntil {BIS_ACM getVariable "initDone"};
[100, BIS_ACM] call BIS_ACM_setIntensityFunc;
[["USMC"], BIS_ACM] call BIS_ACM_setFactionsFunc;
[bIS_ACM, 1, 10] call BIS_ACM_setSpawnDistanceFunc;
["ground_patrol", 1, BIS_ACM] call BIS_ACM_setTypeChanceFunc;
["air_patrol", 0, BIS_ACM] call BIS_ACM_setTypeChanceFunc;
};

Share this post


Link to post
Share on other sites

Yep spawn might work for you here. But honestly, you're making things hard for yourself. If you just add the lines you posted to the bottom of init.sqf, which is in your mission folder anyway, it should work fine... except for:

[100, BIS_ACM] call BIS_ACM_setIntensityFunc;

Not sure what setting intensity to 100 would do. Valid values are between 0 (off) and 1 (max).

[bIS_ACM, 1, 10] call BIS_ACM_setSpawnDistanceFunc;

Are you sure you want stuff to spawn within 10 metres of the player?

Share this post


Link to post
Share on other sites

You should just look at the main, already existing, ACM thread of the same name. It's got everything you need, most likely. There's tons of good stuff in that thread. Devs chime in as well.

Share this post


Link to post
Share on other sites

Hi guys,

Sorry to say that the script mentionned above by Indeedpete does not work in the ini window of the ACM module, it return an error message...

I am sure there are some simple commands that can be added to the ini window of the ACM module allowing to modify its behaviour simply...

Please help !

Manzilla: I got to the other thread but everything is very complicated and it all about making a script in an init.sqf file etc...

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
Sign in to follow this  

×