User Tools

Site Tools


arma2:editor_modules:artillery

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
arma2:editor_modules:artillery [2009-05-31 16:43]
snakeman created new artillery module page.
arma2:editor_modules:artillery [2017-10-06 20:31] (current)
snakeman http to https switch.
Line 3: Line 3:
 Introduction Introduction
  
-ARTY Module by Headspace +The ARTY module allows scenario designers to utilize AI and player-controlled Artillery in their scenarios. ARTY supports any properly configured unit and will support fixed or self propelled vehicles as artillery pieces. The framework supports rocket artillery such as the MLRS and Grad weapon systems, as well as the standard mortars and howitzers. ​
- +
-The ARTY module allows scenario designers to utilize AI and player-controlled Artillery in their scenarios. ARTY supports any properly configured unit and will support fixed or self propelled vehicles as artillery pieces. The framework supports rocket artillery such as the MLRS and Grad weapon systems, as well as the standard mortars and howitzers.+
  
  
Line 18: Line 16:
 You will see an option to target the artillery in your action menu. Clicking this brings up the artillery firing interface map. Each fall line on the map shows the fall altitude of your shell (or mortar round) at a given elevation and azimuth. You will see an option to target the artillery in your action menu. Clicking this brings up the artillery firing interface map. Each fall line on the map shows the fall altitude of your shell (or mortar round) at a given elevation and azimuth.
  
-Note that you will need to be using ARTY ammo for this to work. Load an ARTY Magazine in your vehicle if you do not have one loaded already.+Note that you will need to be using ARTY ammo for this to work. Load an ARTY Magazine in your vehicle if you do not have one loaded already. ​
  
-**Setting up a battery**+Setting up a battery
  
 The first step to using the ARTY module with the AI is to set up a battery. You can have either a real battery or a virtual battery. For purposes of this tutorial we will use a real battery. The battery can consist of a group of any kind of artillery unit, but there are some simple ground rules that should be followed: The first step to using the ARTY module with the AI is to set up a battery. You can have either a real battery or a virtual battery. For purposes of this tutorial we will use a real battery. The battery can consist of a group of any kind of artillery unit, but there are some simple ground rules that should be followed:
Line 28: Line 26:
   * Self-propelled Artillery vehicles will need to stop to execute fire missions, so take this into account when making your missions. ​   * Self-propelled Artillery vehicles will need to stop to execute fire missions, so take this into account when making your missions. ​
  
-Setting up a battery involves laying down a few artillery units in the editor and setting them up as a group. In order to "ARTY enable" ​this group, create an Artillery System game logic and Synchronize it to one of the units using the Synchronize (F5) function of the editor.+Setting up a battery involves laying down a few artillery units in the editor and setting them up as a group. In order to ARTY enable” this group, create an Artillery System game logic and Synchronize it to one of the units using the Synchronize (F5) function of the editor. ​
  
-{{ http://tactical.nekromantix.com/images/wiki/​ARTY_battery_creation.jpg }}+{{ https://pmc.editing.wiki/​images/​ARTY_battery_creation.jpg }}
  
 Note that the Artillery System will consider the unit that is synced to to be the "​lead"​ unit. What this means is that this unit's position will be considered to be the canonical position of the Artillery battery, and firing solutions will be calculated accordingly. Note that the Artillery System will consider the unit that is synced to to be the "​lead"​ unit. What this means is that this unit's position will be considered to be the canonical position of the Artillery battery, and firing solutions will be calculated accordingly.
Line 36: Line 34:
 **Creating fire missions** **Creating fire missions**
  
-Because there are numerous variables involved in setting up a fire mission, there is a type of array known as a fire mission template that is used to generalize specific types of fire missions. To set up a fire mission template, create an array consisting of the following elements, in respective order:+Because there are numerous variables involved in setting up a fire mission, there is a type of array known as a fire mission template that is used to generalize specific types of fire missions. To set up a fire mission template, create an array consisting of the following elements, in respective order: ​
  
-  * Mission Type: "IMMEDIATE" ​or "TIMED"+  * Mission Type: IMMEDIATE” or TIMED
    * The IMMEDIATE mission type will complete after a requested number of rounds have been fired.    * The IMMEDIATE mission type will complete after a requested number of rounds have been fired.
    * The TIMED mission type will complete after a specific number of seconds have elapsed. ​    * The TIMED mission type will complete after a specific number of seconds have elapsed. ​
   * Ordnance Type: This is a string indicating the general type of ordnance to fire. Ordnance types are defined either by default or by calling the BIS_ARTY_F_AddOrdnanceType function. For each type of artillery, there are one or more ordnance types. Common default ordnance types include:   * Ordnance Type: This is a string indicating the general type of ordnance to fire. Ordnance types are defined either by default or by calling the BIS_ARTY_F_AddOrdnanceType function. For each type of artillery, there are one or more ordnance types. Common default ordnance types include:
-   ​* ​"HE" ​- High Explosive +   ​* ​HE” - High Explosive 
-   ​* ​"WP" ​- White Phosphorous ("Willie Pete"+   ​* ​WP” - White Phosphorous (Willie Pete
-   ​* ​"SADARM" ​- Search and Destroy Armor +   ​* ​SADARM” - Search and Destroy Armor 
-   ​* ​"LASER" ​- Laser guided artillery shell +   ​* ​LASER” - Laser guided artillery shell 
-   ​* ​"ILLUM" ​- Flares +   ​* ​ILLUM” - Flares 
-   ​* ​"SMOKE" ​- Non-Incendiary Smoke +   ​* ​SMOKE” - Non-Incendiary Smoke 
   * Rate of Fire: The delay, in seconds, between each shot. This delay will be applied globally throughout the entire battery. For example, if gun 1 fires, there will be a delay between that event and when gun 2 fires (and so on).   * Rate of Fire: The delay, in seconds, between each shot. This delay will be applied globally throughout the entire battery. For example, if gun 1 fires, there will be a delay between that event and when gun 2 fires (and so on).
   * Duration of Mission OR Round Count: This depends on the mission type. This value is used as follows:   * Duration of Mission OR Round Count: This depends on the mission type. This value is used as follows:
Line 53: Line 51:
    * For TIMED missions, the number of seconds to sustain fire.     * For TIMED missions, the number of seconds to sustain fire. 
  
-For example: We want to define a fire mission template that has the battery firing 15 rounds of high explosive ammunition. To do this, we define the following template:+For example: We want to define a fire mission template that has the battery firing 15 rounds of high explosive ammunition. To do this, we define the following template: ​
  
 <code cpp> <code cpp>
-_heTemplate = ["IMMEDIATE""HE", 0, 15];+_heTemplate = [IMMEDIATEHE, 0, 15];
 </​code>​ </​code>​
  
Line 63: Line 61:
 To use your new battery in a fire support role, you can call the BIS_ARTY_F_ExecuteTemplateMission function. In order to do this, you must first have a target. Target coordinates must always be given in 3d, with the Z component being the altitude above sea level. This is particularly critical if you are not using spawn mode, because otherwise the artillery will not be able to properly calculate a firing solution. To use your new battery in a fire support role, you can call the BIS_ARTY_F_ExecuteTemplateMission function. In order to do this, you must first have a target. Target coordinates must always be given in 3d, with the Z component being the altitude above sea level. This is particularly critical if you are not using spawn mode, because otherwise the artillery will not be able to properly calculate a firing solution.
  
-The easiest way to test this is to set a target vehicle or unit, and then use:+The easiest way to test this is to set a target vehicle or unit, and then use: 
  
 <code cpp> <code cpp>
-_targetPos = getPosASL _targetUnit;+_targetPos = getPosASL _targetUnit
 </​code>​ </​code>​
  
Line 77: Line 75:
 Depending on how far away you are from the battery and its initial orientation,​ you may have to wait a few moments for it to rotate into place. After this happens, you will hear the artillery firing on the target and soon see the shells hitting in the vicinity (or on top of) your target vehicle. Depending on how far away you are from the battery and its initial orientation,​ you may have to wait a few moments for it to rotate into place. After this happens, you will hear the artillery firing on the target and soon see the shells hitting in the vicinity (or on top of) your target vehicle.
  
-Also note that when calling any of ARTY's functions, the artillery logic itself counts as your "battery" ​variable.+Also note that when calling any of ARTY's functions, the artillery logic itself counts as your battery” variable. ​
  
  
Line 88: Line 86:
 This is the simplest artillery mode and is based on the shell-spawning found in the original Warfare. In this mode, shells will spawn in the air above your target after their time of flight has elapsed. The Artillery battery will still calculate a firing solution so you will see a realistic flight time, but there is no risk of complications from your shells hitting terrain in front of the artillery battery or along the trajectory. You should use spawn mode in cases where the scenario requires that the artillery shells always impact their target and you do not want to worry about micromanaging the position of the artillery battery. This is the simplest artillery mode and is based on the shell-spawning found in the original Warfare. In this mode, shells will spawn in the air above your target after their time of flight has elapsed. The Artillery battery will still calculate a firing solution so you will see a realistic flight time, but there is no risk of complications from your shells hitting terrain in front of the artillery battery or along the trajectory. You should use spawn mode in cases where the scenario requires that the artillery shells always impact their target and you do not want to worry about micromanaging the position of the artillery battery.
  
-Turn on spawn mode by running the following SQF code, where _battery is your group of artillery pieces:+Turn on spawn mode by running the following SQF code, where _battery is your group of artillery pieces: ​
  
 <code cpp> <code cpp>
Line 98: Line 96:
 In non-spawn mode, artillery shells will be shot at an elevation and azimuth appropriate to the firing solution and will then be allowed to fly to their target on their own. However, you must be careful using this mode as large terrain obstructions,​ such as mountains, will block the battery'​s fire. In addition, if you place your battery in a poor position (such as in front of a building or trees), disaster could occur. Since non-spawn mode is the more realistic of the two firing modes, care must be taken in battery deployment to ensure that you do not cause an accident. The ARTY system uses high-angle fires by default. In non-spawn mode, artillery shells will be shot at an elevation and azimuth appropriate to the firing solution and will then be allowed to fly to their target on their own. However, you must be careful using this mode as large terrain obstructions,​ such as mountains, will block the battery'​s fire. In addition, if you place your battery in a poor position (such as in front of a building or trees), disaster could occur. Since non-spawn mode is the more realistic of the two firing modes, care must be taken in battery deployment to ensure that you do not cause an accident. The ARTY system uses high-angle fires by default.
  
-Non-Spawn mode is enabled by default, but it can be reactivated ​thusly:+Non-Spawn mode is enabled by default, but it can be reactivated ​through:
  
 <code cpp> <code cpp>
Line 111: Line 109:
 The virtual artillery piece will do everything that a real artillery piece does, without physically existing. It cannot be destroyed by the enemy and will not show up as an enemy vehicle on radar. The virtual artillery piece is primarily used in cases such as during a random Artillery Barrage secop request, where the battery is spawned somewhere on the map and there is no time to pick a suitable place for it. The virtual artillery piece will do everything that a real artillery piece does, without physically existing. It cannot be destroyed by the enemy and will not show up as an enemy vehicle on radar. The virtual artillery piece is primarily used in cases such as during a random Artillery Barrage secop request, where the battery is spawned somewhere on the map and there is no time to pick a suitable place for it.
  
-Because of its "virtual" ​nature, the virtual artillery piece needs to simulate a specific real artillery piece. By default, it will simulate an M119, but you can change this with the BIS_ARTY_F_SetVirtualGun function. For instance, to set up a virtual D30, do the following on a piece of virtual artillery (in this case _virtualPiece):​+Because of its virtual” nature, the virtual artillery piece needs to simulate a specific real artillery piece. By default, it will simulate an M119, but you can change this with the BIS_ARTY_F_SetVirtualGun function. For instance, to set up a virtual D30, do the following on a piece of virtual artillery (in this case _virtualPiece): ​
  
 <code cpp> <code cpp>
-[_virtualPiece, ​"D30"] call BIS_ARTY_F_SetVirtualGun;​+[_virtualPiece, ​D30] call BIS_ARTY_F_SetVirtualGun;​
 </​code>​ </​code>​
  
-The Secop Manager takes advantage of the virtual artillery system in cases where a real artillery battery is not specified during the addition of the "Artillery Barrage" ​secop request.+The Secop Manager takes advantage of the virtual artillery system in cases where a real artillery battery is not specified during the addition of the Artillery Barrage” secop request.
  
-Keep in mind that virtual artillery will operate in spawn and non-spawn mode as well. Shells are being spawned at either end of the trajectory in both cases.+Keep in mind that virtual artillery will operate in spawn and non-spawn mode as well. Shells are being spawned at either end of the trajectory in both cases. ​
  
  
 ====== Using ARTY with the Secop Manager ====== ====== Using ARTY with the Secop Manager ======
  
-{{ http://tactical.nekromantix.com/images/wiki/​ARTY_somlink.jpg }}+{{ https://pmc.editing.wiki/​images/​ARTY_somlink.jpg }}
  
 The Secop manager or (SOM) is currently the simplest way to take advantage of the artillery system. To use this, you must have a Secop Manager gamelogic synced to the player. If you want to use SOM with a real artillery battery, you must have constructed a battery using either real or virtual artillery. The Secop manager or (SOM) is currently the simplest way to take advantage of the artillery system. To use this, you must have a Secop Manager gamelogic synced to the player. If you want to use SOM with a real artillery battery, you must have constructed a battery using either real or virtual artillery.
Line 140: Line 138:
   - Adjust fire - Fire two HE rounds at the target. ​   - Adjust fire - Fire two HE rounds at the target. ​
  
-When using a physical or virtual artillery battery, a list of one or more of these FM types (by ID) will need to be included. For instance, if I wanted to have SOM call on my artillery battery (with RIPPER as the Artillery Module logic), I would run the following:+When using a physical or virtual artillery battery, a list of one or more of these FM types (by ID) will need to be included. For instance, if I wanted to have SOM call on my artillery battery (with RIPPER as the Artillery Module logic), I would run the following: ​
  
 <code cpp> <code cpp>
Line 148: Line 146:
 The above will allow the two fire for effect missions and the adjust fire mission to be called by the SOM. The above will allow the two fire for effect missions and the adjust fire mission to be called by the SOM.
  
-However, the SOM will also run fire missions without an artillery battery specified. When you add this type of support request, it will utilize spawned virtual artillery pieces set in spawn mode, so you don't need to worry about the position of the battery—SOM will generate it automatically. Adding this type of support request is accomplished without passing parameters to the SOM as follows:+However, the SOM will also run fire missions without an artillery battery specified. When you add this type of support request, it will utilize spawned virtual artillery pieces set in spawn mode, so you don't need to worry about the position of the battery—SOM will generate it automatically. Adding this type of support request is accomplished without passing parameters to the SOM as follows: ​
  
 <code cpp> <code cpp>
Line 169: Line 167:
 | GRAD_CDF, GRAD_INS, GRAD_RU | BM-21 "​Grad"​ (Former Soviet Union) | ARTY_40Rnd_120mmHE_BM21 | HE | 1,7,9 | | GRAD_CDF, GRAD_INS, GRAD_RU | BM-21 "​Grad"​ (Former Soviet Union) | ARTY_40Rnd_120mmHE_BM21 | HE | 1,7,9 |
  
 +
 +====== Frequently Asked Questions ======
 +
 +**I tried using the Secop Module method and it doesn'​t work. Why?**
 +
 +You may have to wait for the Secop Module to load properly. Spooner provided a helpful example of one useful way to get this to work:
 +<code cpp>
 +// Assumes you have called your SecOp module "​socom"​.
 +waitUntil { not isNil { socom getVariable "​initDone"​} };
 +waitUntil { socom getVariable "​initDone"​ };
 + 
 +// The request commands in the biki are fine.
 +[["​artillery_barrage"​],​ player, [[]]] call BIS_SOM_addSupportRequestFunc;​
 +</​code>​
 +
 +**Why does the MLRS blow up when I try to use it as a player?**
 +
 +You need to add an Artillery Module magazine with the rocket artillery for it to work properly. Try doing the following in the init field of your MLRS:
 +<code cpp>
 +this addMagazine "​ARTY_12Rnd_227mmHE_M270";​
 +</​code>​
 +
 +Feel free to remove the current magazines before doing this. 
 +
 +**Why can't I get the targeting system to work?**
 +
 +Ensure that you have one of the listed Artillery Module magazines loaded into the vehicle you are using.
 +
 +
 +====== Example Missions ======
 +
 +**How to use the Artillery Module and the Secop Manager with a physical MLRS battery**
 +
 +This mission puts a MLRS battery on the Southeast corner island. From there, you can put fire on most of the map by using the Secop Manager'​s support request. To add another support request, use the radio option. Pay attention to the trigger that adds the Secop Request.
 +
 +[[http://​dev-heaven.net/​attachments/​download/​864/​ArtyDemo_MLRS_SOM.zip|ArtyDemo_MLRS_SOM.zip]] By Headspace.
 +
 +**How to use Virtual Artillery pieces with the Secop Manager**
 +
 +This mission is very similar to the above, but it uses "​Virtual"​ MLRS batteries instead. The init field of the Artillery Module gamelogic describes how to tell the virtual artillery pieces what type of artillery to simulate.
 +
 +[[http://​dev-heaven.net/​attachments/​download/​865/​ArtyDemo_MLRS_SOM_VIRTUAL.zip|ArtyDemo_MLRS_SOM_VIRTUAL.zip]] By Headspace
 +
 +
 +====== Notes ======
 +
 +Easier way to use arty is with SOCOM, but the BIS Wiki example is less than detailed enough to work. You must wait until the socom is fully iniated before setting up the fire missions (again, the instructions assume you will put the code in a radio trigger, which makes sense in a test mission, but not a real mission):
 +<code cpp>
 +// Assumes you have called your SOCOM module "​socom"​.
 +waitUntil { not isNil { socom getVariable "​initDone"​} };
 +waitUntil { socom getVariable "​initDone"​ };
 +
 +// The request commands in the bis wiki are fine.
 +[["​artillery_barrage"​],​ player, [[]]] call BIS_SOM_addSupportRequestFunc;​
 +</​code>​
 +
 +You will get a hint that the mission type has been added, then communication->​socom->​request artillery will allow you to click on the map to place arty (and clearly shows min/max ranges). This is definitely the best way to use artillery, IMHO.
arma2/editor_modules/artillery.1243788219.txt.gz · Last modified: 2009-05-31 16:43 (external edit)