Merge pull request #4 from jonpas/docpass11_2

Documentation Pass 11 Additions 2
This commit is contained in:
Josuan Albin 2015-08-25 08:36:38 +02:00
commit f035aa4eb3
15 changed files with 409 additions and 334 deletions

View File

@ -1,7 +1,7 @@
---
layout: wiki
title: Carry and Drag framework
description:
title: Dragging/Carrying Framework
description: Explains how to set-up dragging and carrying of objects with the ACE3 dragging and carrying system.
group: framework
order: 5
parent: wiki
@ -12,84 +12,83 @@ parent: wiki
```c++
class CfgVehicles {
class MyVehicle {
// Dragging
ace_dragging_canDrag = 1; // Can be dragged (0-no, 1-yes)
ace_dragging_dragPosition[] = {0, 1.2, 0}; // Offset of the model from the body while dragging (same as attachTo)
ace_dragging_dragDirection = 0; // Model direction while dragging (same as setDir after attachTo)
ace_dragging_canDrag = 1; // can this object be dragged?; 1 yes, 0 no (0 default)
ace_dragging_dragPosition[] = {0,1.2,0} // Offset of the model from the body while dragging, comparable to the offset in attachTo (It's the same actually)
ace_dragging_dragDirection = 0; // how much degrees is the model rotatated after dragging it (a global setDir after attachTo)
ace_dragging_canCarry = 1; // can this object be carried?; 1 yes, 0 no (0 default)
ace_dragging_carryPosition[] = {0,1.2,0}; // Same as drag, but for carrying objects
ace_dragging_carryDirection = 0; // Same as drag, but for carrying objects
// Carrying
ace_dragging_canCarry = 1; // Can be carried (0-no, 1-yes)
ace_dragging_carryPosition[] = {0, 1.2, 0}; // Offset of the model from the body while dragging (same as attachTo)
ace_dragging_carryDirection = 0; // Model direction while dragging (same as setDir after attachTo)
};
};
```
## 2. Functions
**NOTE THAT THE FOLLOWING FUNCTIONS ARE NOT PUBLIC AND THUS MAY CHANGE IN THE FUTURE.**</br>
<div class="panel callout">
<h5>Note:</h5>
<p>The following functions are NOT public and are likely to change in the future!</p>
</div>
Also note that if the item is too heavy you won't be able to carry / drag it, the mass is also affected by what's inside it.</br>
To bypass this empty the object and / or use setMass.</br>
You will **not** be able to carry / drag objects that are too heavy, the mass is also affected by what is inside the object. To bypass this empty the object and/or use `setMass`.
### 2.1 Enabling / disabling dragging
`ace_dragging_fnc_setDraggable.` </br>
Enable the object to be dragged. </br>
`ace_dragging_fnc_setDraggable`
| Arguments | |
--------------| -------- |
0 | Any object (Object)
1: | true to enable dragging, false to disable (Bool)
2:| Position offset for attachTo command (Array, optional; default: [0,0,0])
3: | Direction in degree to rotate the object after attachTo (Number, optional; default: 0)
Return value: NONE </br>
| Arguments | Type | Optional (default value)
- | --------- | ---- | ------------------------
0 | Any object | Object | Required
1 | Enable dragging, true to enable, false to disable | Boolean | Required
2 | Position to offset the object from player | Array | Optional (default: `[0, 0, 0]`)
3 | Direction in degree to rotate the object | Number | Optional (default: `0`)
**R** | None | None | Return value
#### 2.1.1 example 1:
```
[foo,true,[0,2,0],45] call ace_dragging_fnc_setDraggable
```
| Arguments | |
--------------| -------- |
0:| foo (my object)
1:| true (dragging is enabled)
2:| `[0,2,0]` (0 meters sideways, 2 meters forward, 0 meters upwards)
3:| 45 (the object is rotated by 45°)
#### 2.1.1 Example 1
#### 2.1.2 example 2
```
[bar,false,[3,-2,2],20] call ace_dragging_fnc_setDraggable
```
`[foo, true, [0, 2, 0], 45] call ace_dragging_fnc_setDraggable;`
| Arguments | Explanation
- | --------- | -----------
0 | `foo` | My object
1 | `true` | Dragging is enabled
2 | `[0,2,0]` | 0 meters sideways, 2 meters forward, 0 meters upwards
3 | `45` | Rotated by 45°
#### 2.1.2 Example 2
`[bar, false, [3, -2, 2], 20] call ace_dragging_fnc_setDraggable;`
| Arguments | Explanation
- | --------- | -----------
0 | `bar` | My object
1 | `false` | Dragging is disabled
2 | `[3, -2, 2]` | 3 meters sideways, 2 meters backwards, 2 meters upwards
3 | `20` | Rotated by 20°
| Arguments | |
--------------| -------- |
0:| bar (object)
1:| false (dragging is disabled)
2:| 3 meters sideways, -2 meters backwards, 2 meters upwards
3:| the object is rotated by 20°
### 2.2 Enabling / disabling carrying
`ace_dragging_fnc_setCarryable.` </br>
Enable the object to be carried. </br>
| Arguments | |
--------------| -------- |
0 | Any object (Object)
1:| true to enable carrying, false to disable (Bool)
2:| Position offset for attachTo command (Array, optional; default: [0,1,1])
3:| Direction in degree to rotate the object after attachTo (Number, optional; default: 0)
Return value: NONE </br>
`ace_dragging_fnc_setCarryable`
| Arguments | Type | Optional (default value)
- | --------- | ---- | ------------------------
0 | Any object | Object | Required
1 | Enable carrying, true to enable, false to disable | Boolean | Required
2 | Position to offset the object from player | Array | Optional (default: `[0, 1, 1]`)
3 | Direction in degree to rotate the object | Number | Optional (default: `0`)
**R** | None | None | Return value
#### 2.1.1 example 1:
```
[foo,true,[0,3,1],10] call ace_dragging_fnc_setCarryable
```
| Arguments | |
--------------| -------- |
0:| foo (my object)
1:| true (carrying is enabled)
2:| `[0,2,0]` (0 meters sideways, 3 meters forward, 1 meters upwards)
3:| 10 (the object is rotated by 10°)
#### 2.2.1 Example
`[foo, true, [0, 3, 1], 10] call ace_dragging_fnc_setCarryable;`
| Arguments | Explanation
- | --------- | -----------
0 | `foo` | My object
1 | `true`| Carrying is enabled
2 | `[0,2,0]` | 0 meters sideways, 3 meters forward, 1 meter upwards
3 | `10` | Rotated by 10°

View File

@ -1,77 +1,119 @@
---
layout: wiki
title: Fragmentation framework
description: The fragmentation system (ace_frag) in ACE3 is a significant improvement over the fragmentation system in ACE2.
title: Fragmentation Framework
description: Explains how to set-up fragmentation system for explosives using ACE3 fragmentation system.
group: framework
parent: wiki
order: 7
---
The fragmentation system (ace_frag) in ACE3 is a significant improvement over the fragmentation system in ACE2. Previously the system relied on fuzzy math from the values of `indirectHit` and `indirectHitRange` in CfgAmmo to calculate roughly the velocity and range of fragmentation. This had some serious drawbacks, especially in the case of smaller explosives such as hand grenades and 40mm grenades where casualty production was lower than desired.
## 1. Overview
The fragmentation system in ACE3 is a significant improvement over the fragmentation system in ACE2. Previously the system relied on fuzzy math from the values of `indirectHit` and `indirectHitRange` in `CfgAmmo` to calculate roughly the velocity and range of fragmentation. This had some serious drawbacks, especially in the case of smaller explosives such as hand grenades and 40mm grenades where casualty production was lower than desired.
In ACE3 the system has moved away from what "feels" right to actual explosive engineering equations, primarily the [Gurney equations](http://en.wikipedia.org/wiki/Gurney_equations). This allows us to get close to the actual fragmentation velocities that would be produced by an explosive configuration similar to type of ammo we are simulating.
The system for the end-developer is easy to use, and only requires minimal research into the type of ammo being represented. I will describe how to do this in this ticket.
The system for the end-developer is easy to use, and only requires minimal research into the type of ammo being represented.
Below is an example set of explosives configuration properties for sys_frag (in this case an M67 hand grenade):
## 2. Config Values
```c++
ace_frag_metal = 210; // metal in grams
ace_frag_charge = 185; // explosive in grams
ace_frag_gurney_c = 2843; // Gurney velocity constant for explosive type. See: http://en.wikipedia.org/wiki/Gurney_equations
ace_frag_gurney_k = 3/5; // Gurney shape factor, in this case a sphere. See: http://en.wikipedia.org/wiki/Gurney_equations
class CfgAmmo {
class MyGrenade {
ace_frag_enabled = 1; // Enable fragmentation (0-disabled, 1-enabled)
ace_frag_metal = 210; // Amount of metal being fragmented (grams) - information below
ace_frag_charge = 185; // Amount of explosive filler (grams) - information below
ace_frag_gurney_c = 2843; // Gurney velocity constant for explosive type - information below
ace_frag_gurney_k = 3/5; // Gurney shape factor - information below
ace_frag_classes[] = {"ACE_frag_large"}; // Type of fragments - information below
ace_frag_skip = 0; // (Optional) Skip fragmentation for this ammo type (0-disabled, 1-enabled) - information below
ace_frag_force = 1; // (Optional) Force fragmentation system (0-disabled, 1-enabled) - information below
};
};
```
`ace_frag_metal` is the amount of metal being fragmented (generally taken as the entire weight of the warhead, though in some cases you might want to only include the fragmentation jacket or body. `ace_frag_charge` is the amount of explosive filler in the warhead. `ace_frag_metal` and `ace_frag_charge` are dimensionless values, as long as they are both in the same unit (for example kg/kg g/g lbs/lbs).
### 1.1 Metal amount
`ace_frag_gurney_c` is the Gurney constant for explosive force. You can find a list of common explosive types below. If you can not find it here, or want more accurate numbers, just google the type of explosive and Gurney constant and you can find substantial information. This is *NOT* the detonation velocity of the explosive, do not confuse them!
`ace_frag_metal`
| Type | Speed |
|------------------|----------|
|Composition B | 2700 m/s |
|Composition C-3 | 2680 m/s |
|Cyclotol 75/25 | 2790 m/s |
|HMX | 2800 m/s |
|LX-14 | 2970 m/s |
|Octol 75/25 | 2800 m/s |
|PBX 9404 | 2900 m/s |
|PBX 9502 | 2377 m/s |
|PETN | 2930 m/s |
|RDX | 2830 m/s |
|Tetryl | 2500 m/s |
|TNT | 2440 m/s |
|Tritonal | 2320 m/s |
Amount of metal being fragmented (generally taken as the entire weight of the warhead, though in some cases you might want to only include the fragmentation jacket or body.
Dimensionless value, as long as same unit as `ace_frag_charge` (for example `kg/kg` or `g/g` or `lbs/lbs`).
`ace_frag_gurney_k` is the shape factor for the explosive configuration. You should choose it based on the general configuration of explosives/metal in the warhead. Most grenades for example are a sphere. Artillery and aircraft bombs are a cylinder. Mines generally a flat plate. Below is a list of the three common shapes and their factors.
### 1.2 Explosives filler amount
```
Sphere = 3/5
Cylinder = 1/2
Plate = 3/5
```
`ace_frag_charge`
There are other configurations but these are the most common. If you are interested in others check out the wikipedia link given above. Most of these will not correctly function in sys_frag though due to additional variables for the equation.
Amount of explosive filler in the warhead. `ace_frag_metal` and `ace_frag_charge` are dimensionless values, as long as they are both in the same unit (for example kg/kg g/g lbs/lbs).
In addition to these variables there are different types of fragmentation fragments to choose from, and they can be defined in the config value `ace_frag_classes[]`. Below are a list of the types.
Dimensionless value, as long as same unit as `ace_frag_metal` (for example `kg/kg` or `g/g` or `lbs/lbs`).
```
ACE_frag_tiny
ACE_frag_tiny_HD
ACE_frag_small
ACE_frag_small_HD
ACE_frag_medium
ACE_frag_medium_HD
ACE_frag_large
ACE_frag_large_HD
ACE_frag_huge
ACE_frag_huge_HD
```
### 1.3 Gurney velocity constant
`ace_frag_gurney_c`
Gurney constant for explosive force. You can find a list of common explosive types below. If you can not find it here, or want more accurate numbers, just google the type of explosive and Gurney constant and you can find substantial information. This is **not** the detonation velocity of the explosive, do not confuse them!
Type | Speed
--------------- | --------
Composition B | 2700 m/s
Composition C-3 | 2680 m/s
Cyclotol 75/25 | 2790 m/s
HMX | 2800 m/s
LX-14 | 2970 m/s
Octol 75/25 | 2800 m/s
PBX 9404 | 2900 m/s
PBX 9502 | 2377 m/s
PETN | 2930 m/s
RDX | 2830 m/s
Tetryl | 2500 m/s
TNT | 2440 m/s
Tritonal | 2320 m/s
### 1.4 Gurney shape factor
`ace_frag_gurney_k`
Shape factor for the explosive configuration. You should choose it based on the general configuration of explosives/metal in the warhead. Most grenades for example are a sphere. Artillery and aircraft bombs are a cylinder. Mines generally a flat plate. Below is a list of the three common shapes and their factors.
Shape | Factor
-------- | ------
Sphere | 3/5
Cylinder | 1/2
Plate | 3/5
There are other configurations but these are the most common. If you are interested in others check out the wikipedia link given above. Most of these will not correctly function in ACE3 though due to additional variables for the equation.
### 1.5 Fragments type
`ace_frag_classes[]`
There are different types of fragmentation fragments to choose from, and they can be defined in this config value.
| Type
| ----
| ACE_frag_tiny
| ACE_frag_tiny_HD
| ACE_frag_small
| ACE_frag_small_HD
| ACE_frag_medium
| ACE_frag_medium_HD
| ACE_frag_large
| ACE_frag_large_HD
| ACE_frag_huge
| ACE_frag_huge_HD
The tinier the piece of fragmentation the shorter the distance of travel. The `_HD` variants are all even higher drag versions. Grenades generally should use the `_HD` variants. Experimentation here is important.
The final information needed is a couple of entries for forcing or ignoring fragmentation for this ammo.
### 1.6 Ignore fragmentation
If you set `ace_frag_skip` to 1 then you will skip fragmentation for ammo of this type. This is useful for things that might cause high network load, such as FFAR rockets, or possibly even 40mm grenades from AGLs. Experimentation under network conditions is required.
`ace_frag_skip`
If you set `ace_frag_force` to 1 it will force the fragmentation system to use frag on this ammo, ignoring sys_frags internal qualifications based on hit values.
Setting this to `1` will skip fragmentation for ammo of this type. This is useful for things that might cause high network load, such as FFAR rockets, or possibly even 40mm grenades from AGLs. Experimentation under network conditions is required.
### 1.7 Force fragmentation
`ace_frag_force`
Settings this to `1` will force the fragmentation system to use frag on this ammo, ignoring internal qualifications based on hit values.

View File

@ -1,22 +1,35 @@
---
layout: wiki
title: Goggles framework
description:
title: Goggles Framework
description: Explains how to set-up goggles with ACE3 goggles system.
group: framework
order: 5
parent: wiki
---
## 1.
## 1. Config Values
```c++
class CfgGlasses {
class None;
class G_bananas:None{
ACE_TintAmount=COLOUR*2; // Amount of tint, the color is picked from ACE_Color
ACE_Color[] = {0,0,-1}; // If anyone knows please do tell
ACE_Resistance = 1; // Resistance to breaking.
class MyGoggles {
ace_color[] = {0, 0, -1}; // Post-proccess color
ace_tintAmount = 8; // Amount of tint applied to the color
ace_resistance = 1; // Resistance to breaking (0 or 1 or 2)
ace_protection = 0; // Provides protection (0-no, 1-yes)
ace_overlay = ""; // (Optional) Default overlay image path ("" for none)
ace_overlayDirt = "A3\Ui_f\data\igui\rsctitles\HealthTextures\dust_upper_ca.paa"; // (Optional) Dirt overlay image path
ace_overlayCracked = "mod\textures\HUD\Cracked.paa"; // (Optional) Cracked overlay image path
ace_dustPath = "mod\textures\fx\dust\dust1.paa"; // (Optional) Dust overlay image path
};
};
```
## 2. Events
### 2.1 Listenable
Event Name | Description | Passed Parameter(s) | Locality
---------- | ----------- | ------------------- | --------
`"GlassesChanged"` | Glasses Changed | `[_glassesClass]` | Local
`"GlassesCracked"` | Glasses Cracked | `[_unit]` | Local

View File

@ -1,25 +1,21 @@
---
layout: wiki
title: Hearing framework
description:
title: Hearing Framework
description: Explains how to set-up headgear with ACE3 hearing system.
group: framework
order: 5
parent: wiki
---
## 1. Config Values
## 1. Adding ace_hearing support for helmets
```c++
class CfgWeapons {
class H_HelmetB;
class H_superHelmet: H_HelmetB {
GVAR(protection) = 0.80; // Protection against deafening (0 = less, 1 = more)
GVAR(lowerVolume) = 0.60; // Muffling of the sound (0 = less, 1 = more)
class MyHelmet {
ace_hearing_protection = 0.80; // Protection against deafening (0 to 1, higher means more protection)
ace_hearing_lowerVolume = 0.60; // Muffling of the sound (0 to 1, higher means more muffling)
};
};
```
### 1.1 Notes
- The protection is a multiplier and not an absolute value, you can still be deafened with a value of 1.
- Same as above for the sound muffling.
The protection/muffling is a multiplier and not an absolute value, you can still be deafened/muffled with a value of 1.

View File

@ -1,20 +1,26 @@
---
layout: wiki
title: huntIR framework
description: Explains how to add huntIR support to your weapons
title: HuntIR Framework
description: Explains how to add HuntIR support to a weapon.
group: framework
order: 5
parent: wiki
---
## 1. Adding huntIR support for your weapons
## 1. Config Values
```c++
class CfgWeapons {
class Rifle_Base_F;
class your_rifle_base_class: Rifle_Base_F {
class your_gl_class: UGL_F {
magazines[] = {<all of your other UGL mags>,"ACE_HuntIR_M203"};
class MyRifle {
class MyGL: UGL_F {
magazines[] = {
// All default UGL magazines
"MyFirstMag",
"MySecondMag",
"MyLastMag",
// HUntIR magazine
"ACE_HuntIR_M203"
};
};
};
};

View File

@ -1,24 +1,23 @@
---
layout: wiki
title: javelin framework
description:
title: Javelin Framework
description: Explains how to set-up Javelin-style locking system to a launcher.
group: framework
order: 5
parent: wiki
---
## 1. Adding javelin style locking to your Launcher
## 1. Config Values
```c++
class CfgWeapons {
class your_launcher : launch_O_Titan_F {
ace_javelin_enabled = 1; // enable javelin style locking
weaponInfoType = "ACE_RscOptics_javelin";
modelOptics = "\z\ace\addons\javelin\data\reticle_titan.p3d";
canLock = 0; // disable vanilla locking
lockingTargetSound[] = {"",0,1}; // locking sound
lockedTargetSound[] = {"",0,1}; // target acquired sound
class MyLauncher {
ace_javelin_enabled = 1; // Enable Javelin-style locking (0-disabled, 1-enabled)
weaponInfoType = "ACE_RscOptics_javelin"; // Inteface
modelOptics = "\z\ace\addons\javelin\data\reticle_titan.p3d"; // Optics model
canLock = 0; // Disable vanilla locking (0-disabled, 1-enabled)
lockingTargetSound[] = {"", 0, 1}; // Locking sound
lockedTargetSound[] = {"", 0, 1}; // Target acquired sound
};
};
```

View File

@ -1,7 +1,7 @@
---
layout: wiki
title: Advanced Missile Guidance framework
description: The ACE3 Advanced Missile Guidance Framework provides a setup of configuration settings, functions and a execution framework for addon makers to integrate with the missile guidance and targeting mechanisms of ACE3.
title: Advanced Missile Guidance Framework
description: The ACE3 Advanced Missile Guidance Framework provides a setup of configuration settings, functions and a execution framework for mod makers to integrate with the missile guidance and targeting mechanisms of ACE3.
group: framework
order: 5
parent: wiki
@ -9,100 +9,109 @@ parent: wiki
## 1. Overview
The ACE3 Advanced Missile Guidance Framework provides a setup of configuration settings, functions and a execution framework for addon makers to integrate with the missile guidance and targeting mechanisms of ACE3. It also provides for mod makers to create their own custom guidance methods within the framework.
The ACE3 Advanced Missile Guidance Framework provides a setup of configuration settings, functions and an execution framework for mod makers to integrate with the missile guidance and targeting mechanisms of ACE3. It also provides the mod makers to create their own custom guidance methods within the framework.
The framework provides all the functionality needed for guidance; from laser locking, target specification and selection, to handling the fired events and tracking and steering the vehicle based on provided parameters. This way, all that needs to be defined in addons is the appropriate CfgAmmo entries for the missile.
The framework provides all the functionality needed for guidance; from laser locking, target specification and selection, to handling the fired events and tracking and steering the vehicle based on provided parameters. This way, all that needs to be defined in mods is the appropriate `CfgAmmo` entries for the missile.
The framework also provides addon makers and scripters with the ability to configure custom seeker types and attack profiles, which are defined below. This allows for complete control of the guidance, locking and flight of a missile at the discretion of the addon maker.
The framework also provides mod makers and scripters with the ability to configure custom seeker types and attack profiles, which are defined below. This allows for complete control of the guidance, locking and flight of a missile at the discretion of the mod maker.
ACE3 provides a full suite of base concepts and guidance for the majority of modern missile weaponry avialable today; these includes all basic types of seekers (SALH/SACLOS/Optic/Thermal/etc) - as well as the different common attack profiles utilized with guided munitions (such as top-down attacks).
ACE3 provides a full suite of base concepts and guidance for the majority of modern missile weaponry avialable today; these includes all basic types of seekers (SALH, SACLOS, Optic, Thermal ...) as well as the different common attack profiles utilized with guided munitions (such as top-down attack).
Finally, flight profiles and mechanics for realistic missile simulations are also implemented; allowing for lock-steering bump guidance flight such as with the M47 Dragon or GBU steering fins, or finely tuned direct flight guidance which is currently avialable with other missile types.
Finally, flight profiles and mechanics for realistic missile simulations are also implemented; allowing for lock-steering bump guidance flight such as with the M47 Dragon or GBU steering fins, or finely tuned direct flight guidance which is currently available with other missile types.
## 2. Details
## 2. Components
The framework is broken up into 3 major components: Locking Types, Seeker Types and Attack Profiles. In combination, these components build out the entire process of launching, locking and going terminal flight against targets.
### 2.1 Components
#### 2.1 Locking Types
Locking types provide the basic functionality of targeting which will be based to a seeker type, providing target acquisition for seekers. This provides the basic functionality for providing pre-determined targets for a seeker, or allowing the seeker to perform its own target acquisition and locking. Additionally, the seeker may reference back into the locking type in order to re-perform target acquisition.
#### 2.1.1 Locking Types
Locking types provide the basic functionality of targeting which will be based to a seeker type, providing target aquisition for seekers. This provides the basic functionality for providing pre-determined targets for a seeker, or allowing the seeker to perform its own target aquisition and locking. Additionally, the seeker may reference back into the locking type in order to re-perform target aquisition.
#### 2.1.2 Seeker Types
#### 2.2 Seeker Types
Each seeker is generally assumed to be the logic for the seeker head unit within any given munition. Seekers within this framework provide the basic targeting functionality for the entire framework. The locking type will provide a generic target to the seeker, or the seeker may aquire a target on its own. The seeker then provides a target, either an object or a ASL position, which is then passed further into the framework. This target (or position) should be the actual current target position for the missiles flight. Seekers are required to perform all limitations and checks within their systems, although various limitations have been provided in this framework such as LOS FOV, laser guidance, etc.
#### 2.1.3 Attack Profiles
#### 2.3 Attack Profiles
An attack profile adjusts the current target flight location to create the actual flight path of the missile. The attack profile is provided with all parameters of the system, including the returned target of the seeker. Using this information, the attack profile then will adjust the *direct flight target position* to specifically direct where and how the missile shall flight.
## 3. How it all ties together
The system is executed in a linear series of calls to each step of the process, and feeding back the return from that step to the next step. Execution is conducted using Locking->Seeker->Profile, iteratively every frame of execution. Flight times are adjusted to accTime values and FPS lag, giving consistent flight.
The system is executed in a linear series of calls to each step of the process, and feeding back the return from that step to the next step. Execution is conducted using Locking -> Seeker -> Profile, iteratively every frame of execution. Flight times are adjusted to `accTime` values and FPS lag, giving consistent flight.
On each step of execution, a target specification array [targetObj, targetPos] is passed to the locking type, which then will return a possible modified target array. Next, this modified data is passed to the seeker type - which then, in turn, returns a position vector to the current "seeked" target position (ASL). Last, this target position is passed to the attack profile, who then returns an "adjusted attack position (ASL)", which is the location the missile should *currently* be homing on for flight.
On each step of execution, a target specification array `[targetObj, targetPos]` is passed to the locking type, which then will return a possible modified target array. Next, this modified data is passed to the seeker type - which then, in turn, returns a position vector to the current "seeked" target position (ASL). Last, this target position is passed to the attack profile, which then returns an "adjusted attack position" (ASL), which is the location the missile should *currently* be homing on for flight.
In the simplest sense, the entire system provides the flight trajectory of the missile homing directly on the "adjusted attack position"; thus, an attack profile would ajust this position to direct the missile. For example, Top down attacks return the adjusted attack position high above the target, until entering their terminal stages, which then changes the position to be directly ontop of the target - thus "walking the missile" along its flight path and to the kill.
In the simplest sense, the entire system provides the flight trajectory of the missile homing directly on the "adjusted attack position"; thus, an attack profile would ajust this position to direct the missile. For example, top down attacks return the adjusted attack position high above the target, until entering their terminal stages, which then changes the position to be directly on top of the target - thus "walking the missile" along its flight path and to the impact.
## 4. Adding AMG to a missile
## 4. Config Values
### 4.1 Enabling guidance on Ammo Types
```c++
class CfgAmmo {
class MissileBase;
class MyMissileType : MissileBase {
// Turn off arma crosshair-guidance
manualControl = 0;
class MyMissile {
manualControl = 0; // Turn off vanilla crosshair guidance
// Begin ACE guidance Configs
class ace_missileguidance {
enabled = 1;
enabled = 1; // Enable missile guidance (0-disabled, 1-enabled)
minDeflection = 0.00025; // Minium flap deflection for guidance
maxDeflection = 0.001; // Maximum flap deflection for guidance
incDeflection = 0.0005; // The incrmeent in which deflection adjusts.
minDeflection = 0.00025; // Minimum flap deflection for guidance
maxDeflection = 0.001; // Maximum flap deflection for guidance
incDeflection = 0.0005; // The increment in which deflection adjusts
canVanillaLock = 0; // Can this default vanilla lock? Only applicable to non-cadet modes. All 'recruit' games use vanilla locking
canVanillaLock = 0; // Enable vanilla lock, only applicable to non-cadet modes, 'recruit' always uses vanilla locking (0-disabled, 1-enabled)
// Seeker type and settings for munitions
defaultSeekerType = "SALH";
seekerTypes[] = { "SALH", "LIDAR", "SARH", "Optic", "Thermal", "GPS", "SACLOS", "MCLOS" };
defaultSeekerType = "SALH"; // Default seeker type
seekerTypes[] = {"SALH", "LIDAR", "SARH", "Optic", "Thermal", "GPS", "SACLOS", "MCLOS"}; // Seeker types available
defaultSeekerLockMode = "LOAL";
seekerLockModes[] = { "LOAL", "LOBL" };
defaultSeekerLockMode = "LOAL"; // Default seeker lock mode
seekerLockModes[] = {"LOAL", "LOBL"}; // Seeker lock modes available
seekerAngle = 90; // Angle in front of the missile which can be searched
seekerAccuracy = 1; // seeker accuracy multiplier
seekerAngle = 90; // Angle in front of the missile which can be searched
seekerAccuracy = 1; // Seeker accuracy multiplier
seekerMinRange = 1;
seekerMaxRange = 2500; // Range from the missile which the seeker can visually search
seekerMinRange = 1; // Minimum range from the missile which the seeker can visually search
seekerMaxRange = 2500; // Maximum from the missile which the seeker can visually search
// Attack profile type selection
defaultAttackProfile = "LIN";
attackProfiles[] = { "LIN", "DIR", "MID", "HI" };
defaultAttackProfile = "LIN"; // Default attack profile
attackProfiles[] = {"LIN", "DIR", "MID", "HI"}; // Attack profiles available
};
```
## 5. Creating your own custom seekers and attack profiles
### 5.1 Adding seeker types and attack profiles
### 4.2 Custom Seeker Types
```c++
class ace_missileguidance_attackProfiles{
class ace_missileguidance_attackProfiles {
class MyAttackProfile {
name = "";
visualName = "";
description = "";
name = ""; // Name
visualName = ""; // Visual name
description = ""; // Description
functionName = "my_fnc_doAttackProfile";
};
};
class ace_missileguidance_seekerTypes {
class MySeekerType {
name = "";
visualName = "";
description = "";
functionName = "my_fnc_doSeekerType";
functionName = "my_fnc_doSeekerType"; // Function that handles the seeker type
};
};
```
### 4.3 Custom Attack Profiles
```c++
class ace_missileguidance_seekerTypes {
class MySeekerType {
name = ""; // Name
visualName = ""; // Visual name
description = ""; // Description
functionName = "my_fnc_doAttackProfile"; // Function that handles the attack profile
};
};
```
## 5. Events
### 5.1 Listenable
Event Name | Description | Passed Parameter(s) | Locality
---------- | ----------- | ------------------- | --------
`"ace_missileguidance_handoff"` | Missile handed off | `[_target, _args]` | Global

View File

@ -1,24 +1,21 @@
---
layout: wiki
title: nightvision framework
description:
title: Night Vision Framework
description: Explains how to set-up night vision goggles with ACE3 night vision system.
group: framework
order: 5
parent: wiki
---
## 1. Configuring your NVGs
## 1. Config Values
```c++
class CfgWeapons {
class Binocular;
class your_nvgs: Binocular {
displayName = "your nvg"; // name displayed in the inventory
ACE_NightVision_grain = 0.75; // amount of grain (dots) on the screen (0= less)
ACE_NightVision_blur = 0.055; // blur amount, (0= less) keep low
ACE_NightVision_radBlur = 0.001; // radial blur amount (0=less) keep low
class MyNightVision {
displayName = "Banana NVGs"; // Name displayed in the inventory
ace_nightVision_grain = 0.75; // Amount of grain (dots) on the screen (more means more grain) - can be higher than 1
ace_nightVision_blur = 0.055; // Blur amount (more means more blur) - keep low values!
ace_nightVision_radBlur = 0.001; // Radial blur amount (more means more blur) - keep low values!
};
};
```
- There's no escape here, you'll have to fiddle with the values to find the value that please you.
- `ACE_NightVision_grain` can be higher than 1, it's on 2.25 for gen1 goggles for example.

View File

@ -1,48 +1,78 @@
---
layout: wiki
title: overheating framework
description:
title: Overheating Framework
description: Explains how to set-up weapon overheating with ACE3 overheating system.
group: framework
order: 5
parent: wiki
---
## 1. Adding barrel switching
## 1. Config Values
### 1.1 Barrel Switching
```c++
class CfgWeapons {
class Rifle_Long_Base_F; // base class for LMGs and MMGs
class your_MMG: Rifle_Long_Base_F {
// Dispersion, SlowdownFactor and JamChance arrays have 4 values for different temperatures, which are interpolated between.
// These values correspond to temperatures Converted to real life values: 0: 0°C, 1: 333°C, 2: 666°C, 3: 1000°C.
ACE_Overheating_allowSwapBarrel = 1; // 1 to enable barrel swap. 0 to disable. Meant for machine guns where you can easily swap the barrel without dismantling the whole weapon.
// Dispersion in radians. First value is for temp. 0, second for temp. 1 and so on. Values inbetween get interpolated. Negative values get ignored and can be used to move the starting point to hotter temperatures.
ACE_Overheating_Dispersion[] = {0, -0.001, 0.001, 0.004};
// How much the projectile gets slowed down before leaving the barrel. 0.9 means the bullet will lose 10% velocity. Values inbetween get interpolated. Numbers greater 1 increase the velocity, smaller 1 decrease it.
ACE_Overheating_SlowdownFactor[] = {1, 1, 1, 0.9};
// Chance to jam the weapon. 0.0003 means 3 malfunctions on 10,000 rounds fired at this temperature. Values inbetween get interpolated. Negative values get ignored and can be used to move the starting point to hotter temperatures.
// When no reliable data exists for temperature vs. jam chance except MRBS, the following uniform criteria was adopted: [0, 1/MRBS, 5/MRBS, 25/MRBS].
ACE_Overheating_JamChance[] = {0, 0.0003, 0.0015, 0.0075};
class MyMG {
ace_overheating_allowSwapBarrel = 1; // Enable barrel swap (0-disabled, 1-enabled) - information below
ace_overheating_dispersion[] = {0, -0.001, 0.001, 0.004}; // Bullet dispersion (in radians) - information below
ace_overheating_slowdownFactor[] = {1, 1, 1, 0.9}; // Slowdown factor inside the barrel - information below
ace_overheating_jamChance[] = {0, 0.0003, 0.0015, 0.0075}; // Jam chance - information below
};
};
```
## 2. Adding custom animations
#### 1.1.1 Temperatures
`ace_overheating_dispersion[]`
`ace_overheating_slowdownFactor[]`
`ace_overheating_jamChance[]`
Above arrays have 4 values for different temperatures, which are interpolated between. These values correspond to temperatures converted to real life values from.
Config | Real Life
------ | ---------
0 | 0°C
1 | 333°C
2 | 666°C
3 | 1000°C
### 1.1.2 Barrel Swapping
`ace_overheating_allowSwapBarrel`
Meant for machine guns where you can easily swap the barrel without dismantling the whole weapon.
### 1.1.3 Dispersion
`ace_overheating_dispersion[]`
Dispersion in radians. First value is for temperature 0, second for temperature 1 and so on. Values in-between get interpolated. Negative values are ignored and can be used to move the starting point to hotter temperatures.
### 1.1.4 Slowdown Factor
`ace_overheating_slowdownFactor[]`
How much the projectile gets slowed down before leaving the barrel. `0.9` means the bullet will lose 10% velocity. Values in-between get interpolated. Numbers greater than `1` increase the velocity, smaller decrease it.
### 1.1.5 Jam Chance
`ace_overheating_jamChance[]`
Chance to jam the weapon. `0.0003` means 3 malfunctions on 10,000 rounds fired at this temperature. Values in-between get interpolated. Negative values are ignored and can be used to move the starting point to hotter temperatures.
When no reliable data exists for temperature versus jam chance except MRBS, the following uniform criteria was adopted.
`[0, 1/MRBS, 5/MRBS, 25/MRBS]`
### 1.2 Custom Animations
```c++
class CfgWeapons {
class Rifle_Long_Base_F;
class your_MMG: Rifle_Long_Base_F {
ACE_clearJamAction = "GestureReload"; // Custom jam clearing action. Default uses reload animation.
ACE_checkTemperatureAction = "Gear"; // Custom check temperature action. Default uses gear animation.
ACE_clearJamAction = ""; // Custom jam clearing action. Use empty string to undefine.
class MyMG {
ace_clearJamAction = "GestureReload"; // Custom jam clearing action, default uses reload animation
ace_checkTemperatureAction = "Gear"; // Custom check temperature action, default uses gear animation
ace_clearJamAction = ""; // Custom jam clearing action, use empty string to undefine
};
};
```

View File

@ -1,22 +1,19 @@
---
layout: wiki
title: Parachute framework
description:
title: Parachute Framework
description: Explains how to set-up a parachute with ACE3 parachute system.
group: framework
order: 5
parent: wiki
---
## 1. Adding a reserve parachute to an existing parachute
## 1. Adding reserve parachute to existing parachute
```c++
class CfgVehicles {
class banana_parachute; // your parachute base class
class banana_parachute_02: banana_parachute { // your parachute class
ace_hasReserveParachute = 1; // 1 = enabled, 0 = disabled
ace_reserveParachute = "ACE_ReserveParachute"; // classname of the reserve parachute
class BananaParachute {
ace_hasReserveParachute = 1; // Add reserve parachute (1-enabled, 0-disabled)
ace_reserveParachute = "ACE_ReserveParachute"; // Classname of the reserve parachute
};
};
```

View File

@ -1,7 +1,7 @@
---
layout: wiki
title: reloadlaunchers framework
description:
title: Reload Launchers Framework
description: Explains how to set-up launchers with ACE3 reload launchers system.
group: framework
order: 5
parent: wiki
@ -11,11 +11,16 @@ parent: wiki
```c++
class CfgWeapons {
class Launcher_Base_F; // launcher base class
class yourlauncher: Launcher_Base_F { // launcher class
ACE_reloadlaunchers_enabled = 1; // enable third party reload (your buddies reloading for you)
class MyLauncher {
ace_reloadlaunchers_enabled = 1; // Allow your buddies reloading for you (0-disabled, 1-enabled)
};
};
```
## 2. Events
### 2.1 Listenable
Event Name | Description | Passed Parameter(s) | Locality
---------- | ----------- | ------------------- | --------
`"reloadLauncher"` | Launcher reloaded | `[_unit, _target, _weapon, _magazine]` | Target

View File

@ -1,28 +1,27 @@
---
layout: wiki
title: Scopes framework
description:
title: Scopes Framework
description: Explains how to set-up scopes with ACE3 scope adjustment system.
group: framework
order: 5
parent: wiki
---
## 1. Adding scope adjustement support
## 1. Adding scope adjustment support
```c++
class CfgWeapons {
class ItemCore;
class InventoryOpticsItem_Base_F;
class InventoryOpticsItem_Base_F; // ItemInfo base class
class yourHighPoweredScope : ItemCore {
ACE_ScopeAdjust_Vertical[] = { -4, 30 }; // max vertical adjustement limits
ACE_ScopeAdjust_Horizontal[] = { -6, 6 }; // max horizontal adjustement limits
ACE_ScopeAdjust_VerticalIncrement = 0.1; // vertical incrementation
ACE_ScopeAdjust_HorizontalIncrement = 0.1; // horizontal incrementation
class ItemInfo : InventoryOpticsItem_Base_F {
class YourScope {
ace_scopeAdjust_vertical[] = {-4, 30}; // Maxmimum vertical adjustment limits
ace_scopeAdjust_horizontal[] = {-6, 6}; // Maximum horizontal adjustment limits
ace_scopeAdjust_verticalIncrement = 0.1; // Vertical increment
ace_scopeAdjust_horizontalIncrement = 0.1; // Horizontal increment
class ItemInfo: InventoryOpticsItem_Base_F {
class OpticsModes {
class Snip {
discreteDistance[] = { 100 };
discreteDistance[] = {100};
discreteDistanceInitIndex = 0;
};
};

View File

@ -17,20 +17,22 @@ Part of this settings framework are global settings and client settings. Both us
Settings are entries in the config that get translated to `missionNamespace` global variables. An example settings entry looks like this:
```c++
class ACE_module_sampleSetting {
// Following 2 entries are redundant if isClientSettable = 0
displayName = "$STR_ACE_Common_SettingName"; // Stringtable entry with the setting name
description = "$STR_ACE_Common_SettingDescription"; // Stringtable entry with the setting description
class ACE_Settings {
class ACE_module_sampleSetting {
// Following 2 entries are redundant if isClientSettable = 0
displayName = "$STR_ACE_Common_SettingName"; // Stringtable entry with the setting name
description = "$STR_ACE_Common_SettingDescription"; // Stringtable entry with the setting description
isClientSettable = 1; // Show in client options menu (0-no, 1-yes)
typeName = "SCALAR"; // Type (BOOL/SCALAR/STRING/ARRAY/COLOR)
value = 1; // Value
isClientSettable = 1; // Show in client options menu (0-no, 1-yes)
typeName = "SCALAR"; // Type (BOOL/SCALAR/STRING/ARRAY/COLOR)
value = 1; // Value
// Following entry is redundant if typeName is NOT "SCALAR"
values[] = {"Disabled", "Enabled", "Only Cursor", "Only On Keypress", "Only Cursor and KeyPress"}; // (Optional) Stringtable entries that describe the options
// Following entry is redundant if typeName is NOT "SCALAR"
values[] = {"Disabled", "Enabled", "Only Cursor", "Only On Keypress", "Only Cursor and KeyPress"}; // (Optional) Stringtable entries that describe the options
// Following entry is present only in export
force = 0; // Force the setting (0-no, 1-yes), exported settings are forced by default
// Following entry is present only in export
force = 0; // Force the setting (0-no, 1-yes), exported settings are forced by default
};
};
```
@ -82,17 +84,19 @@ class ACE_Settings {
#### 3.1.1 Notes
- If a setting is forced it cannot be changed further down the line, see `2. Load order` for the hierarchy.
- Client settings can be forced, include them while exporting (the button is right next to export on the UI)
- Client settings can be forced, include while exporting (the button is next to export on the UI)
- You can use `ACE_common_forceAllSettings` to force settings in a mission, it will lock **all** the settings (which are not already forced) to the values they are set in either modules or server config
- example of `ACE_common_forceAllSettings`
```c++
//^^ rest of your description.ext
//------------------------- ACE settings
Example of `ACE_common_forceAllSettings`:
```c++
class ACE_Settings {
class ACE_common_forceAllSettings {
value = 1;
typeName = "BOOL";
};
```
};
```
### 3.2 Loading up the server config

View File

@ -1,47 +1,26 @@
---
layout: wiki
title: Sitting framework
description:
title: Sitting Framework
description: Explains how to set-up sitting furniture with ACE3 sitting system.
group: framework
order: 5
parent: wiki
---
## 1. adding sitting support to a chair
## 1. Adding sitting support to a chair
<div class="panel callout">
<h5>Note:</h5>
<p>Unfinished! What you see below will not work in ACE 3.2.1</p>
</div>
```c++
class CfgVehicles {
#define MACRO_SEAT_ACTION \ // better use a macro, nobody wants to type this two times or more, right ?
class ACE_Actions { \
class ACE_MainActions { \
displayName = "$STR_ACE_Interaction_MainAction"; \
selection = ""; \
distance = 1.5; \
condition = "true"; \
class ACE_sitting_Sit { \
displayName = "$STR_ACE_Sitting_Sit"; \
condition = "_this call ace_sitting_fnc_canSit"; \
statement = "_this call ace_sitting_fnc_sit"; \
showDisabled = 0; \
priority = 0; \
icon = "z\ace\sitting\UI\sit_ca.paa"; \
}; \
}; \
};
class ThingX; // base class for objects
class yourChair: ThingX { // your chair class
XEH_ENABLED; // enable XEH on that object class
MACRO_SEAT_ACTION // add the interaction
ACE_sitting_canSit = 1; // enable sitting
ACE_sitting_sitDirection = 180; // sitting direction in degrees
ACE_sitting_sitPosition[] = {0, -0.1, -0.45}; // sitting position in a X Y Z plane
ACE_sitting_sitRotation = 10; // maximum rotation possible in degrees, left and right.
class MyChair {
ace_sitting_canSit = 1; // Enable sitting (0-disabled, 1-enabled)
ace_sitting_sitDirection = 180; // Initial sitting direction (in degrees)
ace_sitting_sitPosition[] = {0, -0.1, -0.45}; // Sitting position in model space
ace_sitting_sitRotation = 10; // Maximum rotation possible in degrees, left and right.
};
};
```
- No escape possible here, you'll have to fiddle with the position direction and rotation to have a normal pose.
- For the sitRotation 10 is use for chairs with arms, 45 for the ones without.

View File

@ -1,7 +1,7 @@
---
layout: wiki
title: How to report an issue
description: If you've found an issue with ACE3 please read this entry before reporting it.
description: If you have found an issue with ACE3 please read this entry before reporting it.
group: user
order: 10
parent: wiki
@ -9,13 +9,13 @@ parent: wiki
### Before reporting
If you've found an issue with ACE3 please make sure that ACE3 is really the cause of the problem. To do this try to reproduce the issue with using only `@cba_a3` and `@ACE3` on a newly created mission.
If you have found an issue with ACE3 please make sure that ACE3 is really the cause of the problem. To do this try to reproduce the issue with using only `@CBA_A3` and `@ace` on a newly created mission.
Indicate if the issue appears on stable or development version. In case it is the development version, please also include the commit SHA-1 hash.
<div class="panel callout">
<h5>Please note:</h5>
<p>It's not a valid to simply remove <code>@ACE3</code> from the mod list to confirm that ACE3 is the culprit.</p>
<p>It's not a valid to simply remove <code>@ace</code> from the mod list to confirm that ACE3 is the culprit.</p>
<p>If the error happens when using a <b>third-party mod</b> contact the author of the appropriate mod and report the issue there.</p>
</div>
@ -24,29 +24,29 @@ Indicate if the issue appears on stable or development version. In case it is th
Head over to the <a href="{{ site.githubUrl }}/issues" target="_blank">ACE3 GitHub issue tracker</a> and press the <a href="{{ site.githubUrl }}/issues/new" target="_blank">"New issue"</a> button in the top right corner. Add a descriptive title and copy the following issue template in to the text area:
```
*PRO-TIP :The english language allows individuals to correct each other's mistakes in a respectful manner.*
*PRO-TIP: The english language allows individuals to correct each other's mistakes in a respectful manner.*
ACE3 Version: 3.x.x
(indicate if stable or dev, if dev indicate the commit the version is based on)
**Mods:**
* @cba_a3
* @ace3
* `@CBA_A3`
* `@ace`
**Placed ACE3 Modules:**
* *Add the list of modules you have placed on the map. Use 'None' if the error occurs without using any modules.*
**Description:**
*Add a detailed description of the error. This makes it easier for us to fix the issue.*
* Add a detailed description of the error. This makes it easier for us to fix the issue.*
**Steps to reproduce:**
* *Add the steps needed to reproduce the issue.*
**Where did the issue occur?**
*A possible answer might be "Multiplayer", "Singleplayer"*
* A possible answer might be "Multiplayer" or "Singleplayer" or "Editor"*
**RPT log file:**
*Add a link (pastebin.com) to the client or server RPT file.*
* Add a link (pastebin.com) to the client or server RPT file.*
```
A video of the issue might be helpful in resolving it faster.