Forum Jump :

Author Message


Posts: 4
Rank:


Level: Member

Country: de
Location:
Occupation:
Age:
In-game name:

 
#1 Posted at 2010-06-27 18:53        
     
First of all, this site is awesome.

Now to my problem: I would be so happy, if somebody could help me... I saw this video http://www.youtube.com/watch?v=4rqB5oTAjPs&feature=related and I want to do the same, but I do not know what to do..

Can you explain me it please in an easy way? Cuz Iam an absolutely beginner.


Thanks


Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#2 Posted at 2010-06-27 23:39        
     
This can be done using a script by Evil_Echo I found on the BI Forums.

First, place yourself as a russian soldier. Then a new Side called Game Logic should appear in the dropdown list to place units. Next. place a game logic object and name it target it its name box. Place it in the middle of Chernogorsk

    1. Place groups of Artillery, I used Russian D30s, but make sure that their special box (on the right hand side of unit placer) is set to None

    2. Create triggers (f3) for each of the groups. Place each one over its own group and set its activation to Opfor > Present

    3. Create an artillery module (F7) for each group and synchronize it (F5, click on module and drag to the group leader) to the respective group leader. Then, give each module a name, specifically: ABattery, BBattery, CBattery. etc.

    4. Now, in the respective trigger for the group put this:

    ok = [ABattery, getPosASL target, "HE", 30, 180.0] execVM "arty_strike.sqf";

    Its important that this goes in the trigger over the group that is synched to ABattery, and same for the rest!
    This command will have the battery fire 30 High Explosive Rounds in a radius of 180 meters.

    5. Save your misson.

    6. Copy this script into notepad:
    _battery = _this select 0;
    _coords = _this select 1;
    _type = _this select 2;
    _count = _this select 3;
    _mils = _this select 4;
    
    _mission = ["IMMEDIATE", _type, 0.4, _count];
    
    if ( [_battery, _mission] call BIS_ARTY_F_StillViable ) then {
    //	hint format["%1 firing at %2, %3 rounds of %4, %5 mils", _battery, _coords, _count, _type, _mils];
    	[_battery, 10*_mils] call BIS_ARTY_F_SetDispersion;
    	[_battery, _coords, _mission] spawn BIS_ARTY_F_ExecuteTemplateMission;
    } else {
    //	hint format["%1 cannot fire at %2, %3 rounds of %4", _battery, _coords, _count, _type, _mils];
    };

    7. In notepad go to: File > "save as" and then find your Documents > ArmA 2 > Missions folder and find the mission you just saved. Make the file name arty_strike.sqf and change the Save as Type box below it to All (You don't want to save it as a .txt file).

    8. Open up your misson again and try it!

Please tell if it works and if you have any troubles or questions! If you end up releasing this as an official misson credit Evil_Echo with the script.

*DRINK*
Nightrain

This post was edited by Nightrain (2010-06-28 20:47, ago)

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Advertisement


Author Message


Posts: 4
Rank:


Level: Member

Country: de
Location:
Occupation:
Age:
In-game name:

 
#3 Posted at 2010-06-28 20:08        
     
Hey dude, thank you very much!!!!!!!!!!!!!!!!!!!!!!


My first problem: When Iam writing "ok = [ABattery, _pos, "HE", 30, 180.0] execVM "arty_strike.sqf";" into the trigger, it comes an error : Local variable in global place


Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#4 Posted at 2010-06-28 20:44        
     
# 45Killa : My first problem: When Iam writing "ok = [ABattery, _pos, "HE", 30, 180.0] execVM "arty_strike.sqf";" into the trigger, it comes an error : Local variable in global place

*CRAZY* Oops, I forgot to fix that when I edited it. Use this code in the onAct:

ok = [ABattery, getPosASL target, "HE", 30, 180.0] execVM "arty_strike.sqf";

My bad. *PARDON*

Nightrain

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Author Message


Posts: 4
Rank:


Level: Member

Country: de
Location:
Occupation:
Age:
In-game name:

 
#5 Posted at 2010-06-28 21:33        
     
Ok bro, I did exactly everything as you said, but if I start the game, nothing happens !?


Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#6 Posted at 2010-06-29 12:51        
     
Well, place yourself by the artillery and see if they fire. They take a test shot before they actually start firing. Give them a chance. IF it doesn't work you might have to move them depending on location. I tested it again and it works fine. Are you using D30s or something else?

Also, did you follow step 7?

7. In notepad go to: File > "save as" and then find your Documents > ArmA 2 > Missions folder and find the mission you just saved. Make the file name arty_strike.sqf and change the Save as Type box below it to All (You don't want to save it as a .txt file).

Your mission folder for the mission should look like this (i have vista) click on the image:



Edit: Have you tried again. I want this to work for you cause I know it works for me.

This post was edited by Nightrain (2010-07-01 12:51, ago)

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#7 Posted at 2010-07-01 22:42        
     
Any luck? I would like to know if you need any more help. *BYE*

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Author Message


Posts: 429
Rank:


Level: Member

Country: us
Location:
Occupation: Retired
Age: 61
In-game name:

 
#8 Posted at 2010-07-02 12:04        
     
Would you folks like me to work on this script and friends a bit more and release it for general use? The script mentioned is just the low-level driver called by a FSM for AI to use in managing battery fire direction. The net effect is nasty if your forces get spotted by units deemed capable of calling for artillery support - shortly afterwards you get to experience mortar fire raining down on their best guess of your location. :-D

I am fear.

Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#9 Posted at 2010-07-05 13:47        
     
# Evil_Echo : Would you folks like me to work on this script and friends a bit more and release it for general use? The script mentioned is just the low-level driver called by a FSM for AI to use in managing battery fire direction. The net effect is nasty if your forces get spotted by units deemed capable of calling for artillery support - shortly afterwards you get to experience mortar fire raining down on their best guess of your location. :-D

Evil_Echo, did you release the full version of that script. I would like to use it, it sounds great. And with some editing should work very well for a mission I'm making in OA (prolly won't release it though).

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Author Message


Posts: 429
Rank:


Level: Member

Country: us
Location:
Occupation: Retired
Age: 61
In-game name:

 
#10 Posted at 2010-07-06 12:10        
     
The version mentioned here was something I originally posted on the BI forums as part of a thread on artillery management. I am working on some newer stuff which I could make into an official release. But feel free to use what's already out there, does the job very nicely.

The driver script will not take much more embellishment - mostly rate of fire that depends on ammo type.

The FSM is far more complicated a critter and perhaps not as interesting to some mission makers. It currently takes two lists, batteries of artillery and spotters. It periodically queries the spotters for local intel and builds up a potential target list that is then used to designate fire missions for the various batteries. The tricky part is analysing the position data for clusters, taking into account that the data is fuzzy ( A2 includes accuracy estimates ) and high/low value targets. Also I wish to improve the logic for excluding targets dynamically to avoid friendly fire.

-----

Additional - thought a little example might help some of you.

I made a test mission, creating the following units and named them.

Player/observer - EE
Two mortar batteries with BI artillery modules synched to them - A_Battery, B_Battery
Two russion tanks as target - RU_Tank1, RU_Tank2

and the init.sqf...
private ["_battery", "_target"];

waitUntil { not isNil "BIS_ARTY_LOADED"};
hint "Ready";

{
	_battery = _x;
	{
		_target = getPosATL _x;
		ok = [_battery, _target, "HE", 3, 10] execVM "arty_strike.sqf";
		waitUntil {_battery getVariable "ARTY_COMPLETE"};
	} forEach [RU_Tank1, RU_Tank2];
} forEach  [A_Battery, B_Battery];

This post was edited by Evil_Echo (2010-07-06 12:31, ago)

I am fear.

Author Message


Posts: 62
Rank:


Level: Member

Country: us
Location:
Occupation:
Age:
In-game name:

 
#11 Posted at 2010-07-14 20:08        
     
# Nightrain : Any luck? I would like to know if you need any more help. *BYE*
whenever i save script it says it cant find it when i play mission, says script arty_strike.sqf not found. help please!!


Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#12 Posted at 2010-07-14 21:02        
     
# austinporter : whenever i save script it says it cant find it when i play mission, says script arty_strike.sqf not found. help please!!

Did you save it in the mission folder:

7. In notepad go to: File > "save as" and then find your Documents > ArmA 2 > Missions folder and find the mission you just saved. Make the file name arty_strike.sqf and change the Save as Type box below it to All (You don't want to save it as a .txt file).

Your mission folder for the mission should look like this (i have vista) click on the image:


How about you take a picture of the mission file..like I did, using paint.

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."

Author Message


Posts: 429
Rank:


Level: Member

Country: us
Location:
Occupation: Retired
Age: 61
In-game name:

 
#13 Posted at 2010-07-21 11:03        
     
Progress report.

Am coding a series of functions to support my FSM. It makes the debugging easier and they could be used for other applications.

So far have the following.

Observer - Given a list of designated spotters, return a list of observation data. Each unit in the report is unique, multiple observations of the same unit are reduced to the best-known entry. Status - done.

Classify - Given a list of observations, generate sub-lists according to target type. Status - done.

ClusterID - Given a list of observations, minimum membership count, and maximum distance between units - generate a list of unit clusters. Status - done.

Centroid - find the center of a cluster and it's radius. Status - done.

My test mission using this is displaying some very nice results.

This post was edited by Evil_Echo (2010-07-23 16:06, ago)

I am fear.

Author Message


Posts: 429
Rank:


Level: Member

Country: us
Location:
Occupation: Retired
Age: 61
In-game name:

 
#14 Posted at 2010-08-07 08:39        
     
Code is done, writing documentation and having it beta-tested. Then should be uploaded here, hopefully next week.

I am fear.

Author Message

Nightrain  

I blow you away


Posts: 960
Rank:


Level: Member

Country: us
Location:
Occupation:
Age: 29
In-game name:

 
#15 Posted at 2010-08-07 15:26        
     
# Evil_Echo : Code is done, writing documentation and having it beta-tested. Then should be uploaded here, hopefully next week.

That sounds great! I wondered if you were still working on this.

Armstrong-"Hey Carillo, do you see that?"
Carillo-"See what?"
Armstrong-"Something's burning over there, see the smoke?"
Carillo-"That's not smoke it's dust!"
Armstrong-"Dust? i don't get it."