mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Merge branch 'master' into repair
Conflicts: addons/interaction/CfgVehicles.hpp
This commit is contained in:
commit
1ad2a5cdf1
2
.gitignore
vendored
2
.gitignore
vendored
@ -4,3 +4,5 @@ release/*
|
||||
texHeaders.bin
|
||||
*.swp
|
||||
*.swo
|
||||
*.biprivatekey
|
||||
Thumbs.db
|
||||
|
14
.travis.yml
Normal file
14
.travis.yml
Normal file
@ -0,0 +1,14 @@
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
language: python
|
||||
python:
|
||||
- "3.4"
|
||||
before_script:
|
||||
- pip install pygithub
|
||||
- pip install pygithub3
|
||||
script:
|
||||
- python3 tools/deploy.py
|
||||
env:
|
||||
global:
|
||||
- secure: "KcJQbknBOdC5lA4nFGKPXVRVIGLDXDRzC8XkHuXJCE9pIR/wbxbkvx8fHKcC6SC9eHgzneC3+o4m4+CjIbVvIwDgslRbJ8Y59i90ncONmdoRx1HUYHwuYWVZm9HJFjCsIbrEqhSyyKS+PB3WZVOLbErtNHsgS8f43PTh5Ujg7Vg="
|
44
AUTHORS.txt
44
AUTHORS.txt
@ -17,34 +17,48 @@ Janus
|
||||
Kieran
|
||||
NouberNou
|
||||
PabstMirror <pabstmirror@gmail.com>
|
||||
Ruthberg
|
||||
Ruthberg <ulteq@web.de>
|
||||
SilentSpike <SilentSpike100@gmail.com>
|
||||
tpM
|
||||
ViperMaul
|
||||
VKing <kauestad@gmail.com>
|
||||
Walter Pearce <jaynus@gmail.com>
|
||||
|
||||
# CONTRIBUTORS
|
||||
11RDP-LoupVert <loupvert@11rdp.fr>
|
||||
[BIG]Bull
|
||||
11RDP-LoupVert <loupvert@11rdp.fr>
|
||||
ACCtomeek <tomeek99@gmail.com>
|
||||
adam3adam <br.ada@seznam.cz>
|
||||
Adanteh
|
||||
aeroson
|
||||
Aggr094 <bastards4glory@gmail.com>
|
||||
alef <alefor@gmail.com>
|
||||
Aleksey EpMAK Yermakov <epmak777@gmail.com>
|
||||
Alganthe <alganthe@live.fr>
|
||||
Anthariel <Contact@storm-simulation.com>
|
||||
Asgar Serran <piechottaf@web.de>
|
||||
Bla1337
|
||||
BlackPixxel
|
||||
BlackQwar
|
||||
Brakoviejo
|
||||
Brisse <brisse@outlook.com>
|
||||
BullHorn <bullhorn7@gmail.com>
|
||||
Clon1998 <ps.patti1998@gmail.com>
|
||||
Codingboy
|
||||
Coren <coren4@gmail.com>
|
||||
Crusty
|
||||
Dharma Bellamkonda <dharma.bellamkonda@gmail.com>
|
||||
Dimaslg <dimaslg@telecable.es>
|
||||
eRazeri
|
||||
evromalarkey <evromalarkey@gmail.com>
|
||||
Falke75
|
||||
Ferenczi
|
||||
Ferenzi
|
||||
Filip Basara <filip.basara93@googlemail.com> (Logo)
|
||||
Filip Basara <filip.basara93@googlemail.com>
|
||||
FreeZbe <freeseb@gmail.com>
|
||||
geraldbolso1899
|
||||
Ghost
|
||||
Gianmarco Varriale (TeamNuke) <admin@forhost.org>
|
||||
GieNkoV <gienkov.grzegorz@gmail.com>
|
||||
gpgpgpgp
|
||||
Grzegorz
|
||||
@ -52,34 +66,38 @@ Hamburger SV
|
||||
Harakhti <shadowdragonphd@gmail.com>
|
||||
havena <silveredenis@gmail.com>
|
||||
Hawkins
|
||||
jokoho48
|
||||
jokoho482 <jokoho482@gmail.com>`
|
||||
Jonpas <jonpas33@gmail.com>
|
||||
Kavinsky <nmunozfernandez@gmail.com>
|
||||
Kllrt <kllrtik@gmail.com>
|
||||
legman <juicemelon@msn.com>
|
||||
Legolasindar "Viper" <legolasindar@gmail.com>
|
||||
licht-im-Norden87 <lichtimnorden87@gmail.com>
|
||||
Macusercom <macusercom@gmail.com>
|
||||
MarcBook
|
||||
meat <p.humberdroz@gmail.com>
|
||||
Michail Nikolaev
|
||||
nic547 <nic547@outlook.com>
|
||||
nikolauska <nikolauska1@gmail.com>
|
||||
nomisum <nomisum@gmail.com>
|
||||
OnkelDisMaster <onkeldismaster@gmail.com>
|
||||
oscarmolinadev
|
||||
pokertour
|
||||
Professor <lukas.trneny@wo.cz>
|
||||
rakowozz
|
||||
ramius86 <pasini86@hotmail.com>
|
||||
Raspu86
|
||||
Riccardo Petricca <petriccarcc@gmail.com>
|
||||
Robert Boklahánics <bokirobi@gmail.com>
|
||||
ramius86 <pasini86@hotmail.com>
|
||||
simon84
|
||||
ruPaladin <happyworm24@rambler.ru>
|
||||
simon84 <badguy360th@gmail.com>
|
||||
Sniperwolf572 <tenga6@gmail.com>
|
||||
SzwedzikPL <szwedzikpl@gmail.com>
|
||||
Tachi <zaveruha007@gmail.com>
|
||||
Toaster <jonathan.pereira@gmail.com>
|
||||
Tonic
|
||||
Tourorist <tourorist@gmail.com>
|
||||
Valentin Torikian <valentin.torikian@gmail.com>
|
||||
VyMajoris(W-Cephei)<vycanismajoriscsa@gmail.com>
|
||||
Winter <simon@agius-muscat.net>
|
||||
zGuba
|
||||
Aleksey EpMAK Yermakov <epmak777@gmail.com>
|
||||
ruPaladin <happyworm24@rambler.ru>
|
||||
BlackPixxel
|
||||
Asgar Serran <piechottaf@web.de>
|
||||
Kavinsky <nmunozfernandez@gmail.com>
|
||||
Coren <coren4@gmail.com>
|
||||
OnkelDisMaster <onkeldismaster@gmail.com>
|
||||
|
6
LICENSE
6
LICENSE
@ -1,4 +1,4 @@
|
||||
Copyright (C) 2014 Felix "KoffeinFlummi" Wiegand
|
||||
Copyright (C) 2015 Felix "KoffeinFlummi" Wiegand
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@ -22,6 +22,10 @@ source code of the individual modules.
|
||||
When publishing a derivative of this product you may not use a name that
|
||||
might create the impression that your version is an official release.
|
||||
|
||||
Some folders of this project may contain a seperate LICENSE file. Should
|
||||
that be the case, everything in that folder and all subfolders is subject
|
||||
to that license instead.
|
||||
|
||||
|
||||
============================================================================
|
||||
Full Gnu General Public License Text
|
||||
|
87
README.md
87
README.md
@ -1,48 +1,83 @@
|
||||
<p align="center">
|
||||
<img src="https://github.com/acemod/ACE3/blob/master/extras/assets/logo/black/ACE3-Logo.jpg" height="80" />
|
||||
<img src="https://github.com/acemod/ACE3/blob/master/extras/assets/logo/black/ACE3-Logo.jpg"
|
||||
height="112">
|
||||
</p>
|
||||
<p align="center">
|
||||
<a href="https://github.com/acemod/ACE3/releases">
|
||||
<img src="http://img.shields.io/badge/release-3.0-green.svg?style=flat" alt="ACE version">
|
||||
<img src="https://img.shields.io/badge/Version-3.1.1-blue.svg"
|
||||
alt="ACE version">
|
||||
</a>
|
||||
<a href="#">
|
||||
<img src="http://img.shields.io/badge/download-22_MB-blue.svg?style=flat" alt="ACE download">
|
||||
<a href="https://github.com/acemod/ACE3/releases/download/v3.1.1/ace3_3.1.1.zip">
|
||||
<img src="http://img.shields.io/badge/Download-51.7_MB-green.svg"
|
||||
alt="ACE download">
|
||||
</a>
|
||||
<a href="https://github.com/acemod/ACE3/issues">
|
||||
<img src="http://img.shields.io/github/issues/acemod/ACE3.svg?style=flat" alt="ACE issues">
|
||||
<img src="http://img.shields.io/github/issues-raw/acemod/ACE3.svg?label=Issues"
|
||||
alt="ACE issues">
|
||||
</a>
|
||||
<a href="http://forums.bistudio.com/showthread.php?191716-ACE3-A-collaborative-merger-between-AGM-CSE-and-ACE&p=2935435&viewfull=1#post2935435">
|
||||
<img src="https://img.shields.io/badge/BIF-Thread-lightgrey.svg"
|
||||
alt="BIF thread">
|
||||
</a>
|
||||
<a href="https://github.com/acemod/ACE3/blob/master/LICENSE">
|
||||
<img src="http://img.shields.io/badge/license-GPLv2-red.svg?style=flat" alt="ACE license">
|
||||
<img src="http://img.shields.io/badge/License-GPLv2-red.svg"
|
||||
alt="ACE license">
|
||||
</a>
|
||||
</p>
|
||||
<p align="center"><sup><strong>Requires the latest version of <a href="http://www.armaholic.com/page.php?id=18767">CBA A3</a> | <a href="#">BIF thread</a></strong></sup></p>
|
||||
<p align="center"><sup><strong>Requires the latest version of <a href="http://www.armaholic.com/page.php?id=18767">CBA A3</a>. Visit us on <a href="https://www.facebook.com/ACE3Mod">Facebook</a> | <a href="https://www.youtube.com/c/ACE3Mod">YouTube</a> | <a href="https://twitter.com/ACE3Mod">Twitter</a> | <a href="http://www.reddit.com/r/arma/search?q=ACE&restrict_sr=on&sort=new&t=all">Reddit</a></strong></sup></p>
|
||||
|
||||
**ACE3** is a joint effort by the teams behind **ACE2**, **AGM** and **CSE** to improve the realism and authenticity of Arma 3.
|
||||
|
||||
This mod is entirely **open-source**, and everyone is free to propose changes or maintain their own, customized version as long as they make their changes open to the public in accordance with the GNU General Public License (for more information check the license file attached to this project).
|
||||
The project is entirely **open-source** and all contributions are welcome. Feel free to maintain your own custom version, so long as the changes you make are open to the public in accordance with the GNU General Public License ([GPLv2](https://github.com/acemod/ACE3/blob/master/LICENSE)).
|
||||
|
||||
The mod is **built modularly** — almost any PBO can be removed, thus a team can maintain its own tailored version of ACE, which excludes a select number of components that they don't like, or which conflict with other add-ons. Components themselves, like e.g. the medical system, also include various customization options, allowing mission designers to tweak the overall experience.
|
||||
The mod is **built modularly**, so almost any included PBO can be easily removed from the configuration. This way, a team can maintain its own tailored version of ACE by simply excluding any components they don't need, or those possibly in conflict with other add-ons. Modules themselves, e.g. the medical system, also include various customization options, allowing mission designers to tweak the overall experience.
|
||||
|
||||
### Features
|
||||
* Improved medical system
|
||||
* Logistics system including cargo transport and vehicle maintenance
|
||||
* Explosives system including different trigger types
|
||||
### Core features
|
||||
* Brand new 3D interaction/action system
|
||||
* Performance and reliability framework
|
||||
* Focus on modularity and customization
|
||||
* New flexible client and server settings & configuration
|
||||
* Improved medical system with various levels (basic/advanced) focus on gameplay/realism
|
||||
* Proper & consistent network-synced weather
|
||||
* Wind and weather-based ballistics
|
||||
* Captivity system
|
||||
* Realistic names for vehicles and weapons
|
||||
* Realistic ballistics including wind and humidity
|
||||
* Backblast simulation
|
||||
* A fire control system for armored vehicles and helicopters
|
||||
***and more...***
|
||||
* Explosives system, including different trigger types
|
||||
* Map screen improvements – marker placement and map tools
|
||||
* Advanced missile guidance and laser designation
|
||||
|
||||
#### Guides & How-Tos
|
||||
If you installed ACE3, but have trouble understanding how it all works, or where to start — see [Getting Started](https://github.com/acemod/ACE3/blob/master/documentation/user/getting-started.md).
|
||||
#### Additional features
|
||||
* Carrying and dragging
|
||||
* Realistic names for vehicles and weapons
|
||||
* A fire control system (FCS) for armored vehicles and helicopters
|
||||
* Realistic ballistics/FCS calculated in C/C++ extensions
|
||||
* Backblast area and overpressure simulation
|
||||
* Disposable launchers
|
||||
* Realistic G-forces
|
||||
* Vehicle locking
|
||||
* Realistic night and thermal vision modes
|
||||
* Magazine repacking
|
||||
* Realistic weapon overheating mechanic
|
||||
* Combat deafness (temporary loss of hearing) simulation
|
||||
* Improved ragdoll physics
|
||||
* Improved interactions for AARs and ammo bearers
|
||||
* Adjustable sniper scopes
|
||||
* No idle animation with lowered weapon
|
||||
* No talking player avatar
|
||||
* Jumping over obstacles, climbing over walls and cutting down fences
|
||||
* Vector, MicroDAGR and Kestrel devices<br>
|
||||
***and much more...***
|
||||
|
||||
### Guides & how-tos
|
||||
If you installed ACE3 but have trouble understanding how it all works, or where to start, read this first:
|
||||
* [Getting started](http://ace3mod.com/wiki/user/getting-started.html)
|
||||
|
||||
#### Contributing
|
||||
If you want to help put with the ongoing development, you can do so by looking for possible bugs or by contributing new features. To contribute something to ACE, simply fork this repository and submit your pull requests for review by other collaborators. In the process, please add yourself to the author array of any .pbo you will be editing and the AUTHORS.txt file; including a valid email address.
|
||||
You can help out with the ongoing development by looking for potential bugs in our code base, or by contributing new features. To contribute something to ACE, simply fork this repository and submit your pull requests for review by other collaborators. Remember to add yourself to the author array of any PBO you will be editing and the [`AUTHORS.txt`](https://github.com/acemod/ACE3/blob/master/AUTHORS.txt) file; including a valid email address.
|
||||
|
||||
To report a bug, propose a feature, or suggest a change to the existing one — please, use our [Issue Tracker](https://github.com/acemod/ACE3/issues). See [this link](http://ace3mod.com/wiki/user/how-to-report-an-issue.html) for details.
|
||||
Please, use our [Issue Tracker](https://github.com/acemod/ACE3/issues) to report a bug, propose a feature, or suggest changes to the existing ones. See also:
|
||||
* [How to report an issue](http://ace3mod.com/wiki/user/how-to-report-an-issue.html)
|
||||
* [How to make a feature request](http://ace3mod.com/wiki/user/how-to-make-a-feature-request.html)
|
||||
|
||||
#### Testing & Building
|
||||
If you want to help us test the latest development changes, feel free to download our master branch, using either git — if familiar with the process — or directly, by following [this link](https://github.com/acemod/ACE3/archive/master.zip).
|
||||
|
||||
To find out how to set up your development environment and build a version of ACE for testing, follow [these instructions](https://github.com/acemod/ACE3/blob/master/documentation/development/setting-up-the-development-environment.md).
|
||||
#### Testing & building
|
||||
To help us test the latest development changes, download our master branch ([directly](https://github.com/acemod/ACE3/archive/master.zip), or [with git](https://help.github.com/articles/fetching-a-remote/)), then assemble a test build:
|
||||
* [Setting up the development environment](http://ace3mod.com/wiki/development/setting-up-the-development-environment.html) – step-by-step instructions on how to properly setup and build a version of ACE for testing purposes.
|
||||
|
Binary file not shown.
Binary file not shown.
BIN
ace_break_line.dll
Normal file
BIN
ace_break_line.dll
Normal file
Binary file not shown.
BIN
ace_clipboard.dll
Normal file
BIN
ace_clipboard.dll
Normal file
Binary file not shown.
BIN
ace_fcs.dll
BIN
ace_fcs.dll
Binary file not shown.
BIN
ace_medical.dll
Normal file
BIN
ace_medical.dll
Normal file
Binary file not shown.
BIN
ace_parse_imagepath.dll
Normal file
BIN
ace_parse_imagepath.dll
Normal file
Binary file not shown.
1
addons/advanced_ballistics/$PBOPREFIX$
Normal file
1
addons/advanced_ballistics/$PBOPREFIX$
Normal file
@ -0,0 +1 @@
|
||||
z\ace\addons\advanced_ballistics
|
@ -5,23 +5,29 @@ class ACE_Settings {
|
||||
typeName = "BOOL";
|
||||
value = 0;
|
||||
};
|
||||
class GVAR(alwaysSimulateForSnipers) {
|
||||
displayName = "Always Enabled For Snipers";
|
||||
description = "Always enables advanced ballistics when high power optics are used";
|
||||
class GVAR(simulateForSnipers) {
|
||||
displayName = "Enabled For Snipers";
|
||||
description = "Enables advanced ballistics for non local snipers (when using high power optics)";
|
||||
typeName = "BOOL";
|
||||
value = 1;
|
||||
};
|
||||
class GVAR(disabledInFullAutoMode) {
|
||||
displayName = "Disabled In FullAuto Mode";
|
||||
description = "Disables the advanced ballistics during full auto fire";
|
||||
class GVAR(simulateForGroupMembers) {
|
||||
displayName = "Enabled For Group Members";
|
||||
description = "Enables advanced ballistics for non local group members";
|
||||
typeName = "BOOL";
|
||||
value = 0;
|
||||
};
|
||||
class GVAR(onlyActiveForLocalPlayers) {
|
||||
displayName = "Disabled For Non Local Players";
|
||||
description = "Disables the advanced ballistics for bullets coming from other players (enable this if you encounter frame drops during heavy firefights in multiplayer)";
|
||||
class GVAR(simulateForEveryone) {
|
||||
displayName = "Enabled For Everyone";
|
||||
description = "Enables advanced ballistics for all non local players (enabling this may degrade performance during heavy firefights in multiplayer)";
|
||||
typeName = "BOOL";
|
||||
value = 1;
|
||||
value = 0;
|
||||
};
|
||||
class GVAR(disabledInFullAutoMode) {
|
||||
displayName = "Disabled In FullAuto Mode";
|
||||
description = "Disables advanced ballistics during full auto fire";
|
||||
typeName = "BOOL";
|
||||
value = 0;
|
||||
};
|
||||
/* // TODO: We currently do not have firedEHs on vehicles
|
||||
class GVAR(vehicleGunnerEnabled) {
|
||||
@ -57,7 +63,7 @@ class ACE_Settings {
|
||||
};
|
||||
class GVAR(simulationRadius) {
|
||||
displayName = "Simulation Radius";
|
||||
description = "Defines the radius (in meters) in which advanced ballistics are applied";
|
||||
description = "Defines the radius around the player (in meters) at which advanced ballistics are applied to projectiles";
|
||||
typeName = "SCALAR";
|
||||
value = 3000;
|
||||
};
|
||||
|
@ -2,7 +2,7 @@ class CfgVehicles {
|
||||
class ACE_Module;
|
||||
class GVAR(ModuleSettings): ACE_Module {
|
||||
scope = 2;
|
||||
displayName = "Advanced Ballistics";
|
||||
displayName = CSTRING(DisplayName);
|
||||
icon = QUOTE(PATHTOF(UI\Icon_Module_Wind_ca.paa));
|
||||
category = "ACE";
|
||||
function = QUOTE(DFUNC(initModuleSettings));
|
||||
@ -12,29 +12,35 @@ class CfgVehicles {
|
||||
author = "Ruthberg";
|
||||
class Arguments {
|
||||
class enabled {
|
||||
displayName = "Advanced Ballistics";
|
||||
description = "Enables advanced ballistics";
|
||||
displayName = CSTRING(enabled_DisplayName);
|
||||
description = CSTRING(enabled_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 0;
|
||||
};
|
||||
class alwaysSimulateForSnipers {
|
||||
displayName = "Always Enabled For Snipers";
|
||||
description = "Always enables advanced ballistics when high power optics are used";
|
||||
class simulateForSnipers {
|
||||
displayName = CSTRING(simulateForSnipers_DisplayName);
|
||||
description = CSTRING(simulateForSnipers_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class simulateForGroupMembers {
|
||||
displayName = CSTRING(simulateForGroupMembers_DisplayName);
|
||||
description = CSTRING(simulateForGroupMembers_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 0;
|
||||
};
|
||||
class simulateForEveryone {
|
||||
displayName = CSTRING(simulateForEveryone_DisplayName);
|
||||
description = CSTRING(simulateForEveryone_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 0;
|
||||
};
|
||||
class disabledInFullAutoMode {
|
||||
displayName = "Disabled In FullAuto Mode";
|
||||
description = "Disables the advanced ballistics during full auto fire";
|
||||
displayName = CSTRING(disabledInFullAutoMod_DisplayName);
|
||||
description = CSTRING(disabledInFullAutoMod_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 0;
|
||||
};
|
||||
class onlyActiveForLocalPlayers {
|
||||
displayName = "Disabled For Non Local Players";
|
||||
description = "Disables the advanced ballistics for bullets coming from other players (enable this if you encounter frame drops during heavy firefights in multiplayer)";
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
/* // TODO: We currently do not have firedEHs on vehicles
|
||||
class vehicleGunnerEnabled {
|
||||
displayName = "Enabled For Vehicle Gunners";
|
||||
@ -44,35 +50,38 @@ class CfgVehicles {
|
||||
};
|
||||
*/
|
||||
class ammoTemperatureEnabled {
|
||||
displayName = "Enable Ammo Temperature Simulation";
|
||||
description = "Muzzle velocity varies with ammo temperature";
|
||||
displayName = CSTRING(ammoTemperatureEnabled_DisplayName);
|
||||
description = CSTRING(ammoTemperatureEnabled_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class barrelLengthInfluenceEnabled {
|
||||
displayName = "Enable Barrel Length Simulation";
|
||||
description = "Muzzle velocity varies with barrel length";
|
||||
displayName = CSTRING(barrelLengthInfluenceEnabled_DisplayName);
|
||||
description = CSTRING(barrelLengthInfluenceEnabled_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class bulletTraceEnabled {
|
||||
displayName = "Enable Bullet Trace Effect";
|
||||
description = "Enables a bullet trace effect to high caliber bullets (only visible when looking through high power optics)";
|
||||
displayName = CSTRING(bulletTraceEnabled_DisplayName);
|
||||
description = CSTRING(bulletTraceEnabled_Description);
|
||||
typeName = "BOOL";
|
||||
defaultValue = 1;
|
||||
};
|
||||
class simulationInterval {
|
||||
displayName = "Simulation Interval";
|
||||
description = "Defines the interval between every calculation step";
|
||||
displayName = CSTRING(simulationInterval_DisplayName);
|
||||
description = CSTRING(simulationInterval_Description);
|
||||
typeName = "NUMBER";
|
||||
defaultValue = 0.0;
|
||||
};
|
||||
class simulationRadius {
|
||||
displayName = "Simulation Radius";
|
||||
description = "Defines the radius (in meters) in which advanced ballistics are applied";
|
||||
displayName = CSTRING(simulationRadius_DisplayName);
|
||||
description = CSTRING(simulationRadius_Description);
|
||||
typeName = "NUMBER";
|
||||
defaultValue = 3000;
|
||||
};
|
||||
};
|
||||
class ModuleDescription {
|
||||
description = CSTRING(Description);
|
||||
};
|
||||
};
|
||||
};
|
@ -1,17 +1,13 @@
|
||||
class RscTitles
|
||||
{
|
||||
class RscTurretDial
|
||||
{
|
||||
class RscTitles {
|
||||
class RscTurretDial {
|
||||
idd=-1;
|
||||
onLoad="with uiNameSpace do { RscTurretDial = _this select 0 };";
|
||||
movingEnable=0;
|
||||
duration=5;
|
||||
fadeIn="false";
|
||||
fadeOut="false";
|
||||
class controls
|
||||
{
|
||||
class RscTurretDial
|
||||
{
|
||||
class controls {
|
||||
class RscTurretDial {
|
||||
idc=132949;
|
||||
type=0;
|
||||
style=128;
|
||||
@ -28,18 +24,15 @@ class RscTitles
|
||||
};
|
||||
};
|
||||
|
||||
class RscProtractor
|
||||
{
|
||||
class RscProtractor {
|
||||
idd=-1;
|
||||
onLoad="with uiNameSpace do { RscProtractor = _this select 0 };";
|
||||
movingEnable=0;
|
||||
duration=60;
|
||||
fadeIn="false";
|
||||
fadeOut="false";
|
||||
class controls
|
||||
{
|
||||
class RscProtractorBase
|
||||
{
|
||||
class controls {
|
||||
class RscProtractorBase {
|
||||
idc=132950;
|
||||
type=0;
|
||||
style=48;
|
||||
@ -54,8 +47,7 @@ class RscTitles
|
||||
sizeEx=0.027;
|
||||
text="";
|
||||
};
|
||||
class RscProtractorMarker : RscProtractorBase
|
||||
{
|
||||
class RscProtractorMarker : RscProtractorBase {
|
||||
idc=132951;
|
||||
};
|
||||
};
|
||||
|
@ -4,36 +4,14 @@
|
||||
|
||||
GVAR(currentbulletID) = -1;
|
||||
|
||||
GVAR(bulletDatabase) = [];
|
||||
GVAR(bulletDatabaseStartTime) = [];
|
||||
GVAR(bulletDatabaseSpeed) = [];
|
||||
GVAR(bulletDatabaseFrames) = [];
|
||||
GVAR(bulletDatabaseLastFrame) = [];
|
||||
GVAR(bulletDatabaseHDeflect) = [];
|
||||
GVAR(bulletDatabaseSpinDrift) = [];
|
||||
GVAR(bulletDatabaseOccupiedIndices) = [];
|
||||
GVAR(bulletDatabaseFreeIndices) = [];
|
||||
|
||||
GVAR(WindInfo) = false;
|
||||
GVAR(WindInfoStart) = time;
|
||||
|
||||
GVAR(Protractor) = false;
|
||||
GVAR(ProtractorStart) = time;
|
||||
|
||||
// Those are only used in the pure sqf version (extension free PFH)
|
||||
GVAR(SimulationPrecision) = 2;
|
||||
GVAR(WindEnabled) = true;
|
||||
GVAR(SpinDriftEnabled) = true;
|
||||
GVAR(CoriolisEnabled) = true;
|
||||
GVAR(EoetvoesEnabled) = true;
|
||||
GVAR(AdvancedAirDragEnabled) = true;
|
||||
GVAR(TransonicRegionEnabled) = true;
|
||||
GVAR(AtmosphericDensitySimulationEnabled) = true;
|
||||
GVAR(ProtractorStart) = ACE_time;
|
||||
|
||||
GVAR(currentGrid) = 0;
|
||||
GVAR(INIT_MESSAGE_ENABLED) = false;
|
||||
GVAR(initMessageEnabled) = false;
|
||||
|
||||
/* @TODO: Remove this until verisoning is in sync with cmake/build versioning
|
||||
GVAR(extensionAvailable) = true;
|
||||
/* @TODO: Remove this until versioning is in sync with cmake/build versioning
|
||||
GVAR(extensionVersion) = ("ace_advanced_ballistics" callExtension "version");
|
||||
GVAR(extensionAvailable) = (GVAR(extensionVersion) == EXTENSION_REQUIRED_VERSION);
|
||||
if (!GVAR(extensionAvailable)) exitWith {
|
||||
|
@ -6,12 +6,12 @@ PREP(calculateAmmoTemperatureVelocityShift);
|
||||
PREP(calculateAtmosphericCorrection);
|
||||
PREP(calculateBarrelLengthVelocityShift);
|
||||
PREP(calculateRetardation);
|
||||
PREP(calculateRoughnessLength);
|
||||
PREP(calculateStabilityFactor);
|
||||
PREP(calculateWindSpeed);
|
||||
PREP(displayProtractor);
|
||||
PREP(handleFired);
|
||||
PREP(initializeTerrainExtension);
|
||||
PREP(initModuleSettings);
|
||||
PREP(readAmmoDataFromConfig);
|
||||
PREP(readWeaponDataFromConfig);
|
||||
|
||||
ADDON = true;
|
||||
|
@ -5,7 +5,7 @@ class CfgPatches {
|
||||
units[] = {};
|
||||
weapons[] = {};
|
||||
requiredVersion = REQUIRED_VERSION;
|
||||
requiredAddons[] = {"ace_ballistics", "ace_weather", "ace_modules"};
|
||||
requiredAddons[] = {"ace_ballistics", "ace_weather"};
|
||||
author[] = {"Ruthberg"};
|
||||
authorUrl = "https://github.com/ulteq";
|
||||
VERSION_CONFIG;
|
||||
|
@ -4,7 +4,7 @@
|
||||
* Calculates the ammo temperature induced muzzle velocity shift
|
||||
*
|
||||
* Arguments:
|
||||
* 0: ammo - classname <string>
|
||||
* 0: muzzle velocity shift lookup table - m/s <ARRAY>
|
||||
* 1: temperature - degrees celcius <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
@ -15,17 +15,11 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_ammo", "_temperature", "_muzzleVelocityTable", "_muzzleVelocityShift", "_temperatureIndexA", "_temperatureIndexB", "_temperatureRatio"];
|
||||
_ammo = _this select 0;
|
||||
private ["_muzzleVelocityShiftTable", "_temperature", "_muzzleVelocityShift", "_temperatureIndexA", "_temperatureIndexB", "_temperatureRatio"];
|
||||
_muzzleVelocityShiftTable = _this select 0;
|
||||
_temperature = _this select 1;
|
||||
|
||||
_muzzleVelocityTable = [];
|
||||
|
||||
if (isArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_ammoTempMuzzleVelocityShifts")) then {
|
||||
_muzzleVelocityTable = getArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_ammoTempMuzzleVelocityShifts");
|
||||
};
|
||||
|
||||
if (count _muzzleVelocityTable != 11) exitWith { 0 };
|
||||
if (count _muzzleVelocityShiftTable != 11) exitWith { 0 };
|
||||
|
||||
_temperatureIndexA = floor((_temperature + 15) / 5);
|
||||
_temperatureIndexA = 0 max _temperatureIndexA;
|
||||
@ -37,6 +31,6 @@ _temperatureIndexB = _temperatureIndexB min 10;
|
||||
|
||||
_temperatureRatio = ((_temperature + 15) / 5) - floor((_temperature + 15) / 5);
|
||||
|
||||
_muzzleVelocityShift = (_muzzleVelocityTable select _temperatureIndexA) * (1 - _temperatureRatio) + (_muzzleVelocityTable select _temperatureIndexB) * _temperatureRatio;
|
||||
_muzzleVelocityShift = (_muzzleVelocityShiftTable select _temperatureIndexA) * (1 - _temperatureRatio) + (_muzzleVelocityShiftTable select _temperatureIndexB) * _temperatureRatio;
|
||||
|
||||
_muzzleVelocityShift
|
||||
|
@ -4,9 +4,10 @@
|
||||
* Calculates the muzzle velocity shift caused by different barrel lengths
|
||||
*
|
||||
* Arguments:
|
||||
* 0: ammo - classname <string>
|
||||
* 0: weapon - classname <string>
|
||||
* 1: muzzle velocity - m/s <NUMBER>
|
||||
* 0: barrel length - mm
|
||||
* 1: muzzle velocity lookup table - m/s <ARRAY>
|
||||
* 2: barrel length lookup table - mm <ARRAY>
|
||||
* 3: muzzle velocity - m/s <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* 0: muzzle velocity shift - m/s <NUMBER>
|
||||
@ -16,25 +17,13 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_ammo", "_weapon", "_barrelLength", "_muzzleVelocityTable", "_barrelLengthTable", "_muzzleVelocity", "_lowerIndex", "_upperIndex", "_barrelLengthRatio", "_muzzleVelocityNew"];
|
||||
_ammo = _this select 0;
|
||||
_weapon = _this select 1;
|
||||
_muzzleVelocity = _this select 2;
|
||||
|
||||
_barrelLength = getNumber(configFile >> "cfgWeapons" >> _weapon >> "ACE_barrelLength");
|
||||
private ["_barrelLength", "_muzzleVelocityTable", "_barrelLengthTable", "_muzzleVelocity", "_lowerIndex", "_upperIndex", "_barrelLengthRatio", "_muzzleVelocityNew"];
|
||||
_barrelLength = _this select 0;
|
||||
_muzzleVelocityTable = _this select 1;
|
||||
_barrelLengthTable = _this select 2;
|
||||
_muzzleVelocity = _this select 3;
|
||||
|
||||
if (_barrelLength == 0) exitWith { 0 };
|
||||
|
||||
_muzzleVelocityTable = [];
|
||||
_barrelLengthTable = [];
|
||||
|
||||
if (isArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_muzzleVelocities")) then {
|
||||
_muzzleVelocityTable = getArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_muzzleVelocities");
|
||||
};
|
||||
if (isArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_barrelLengths")) then {
|
||||
_barrelLengthTable = getArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_barrelLengths");
|
||||
};
|
||||
|
||||
if (count _muzzleVelocityTable != count _barrelLengthTable) exitWith { 0 };
|
||||
if (count _muzzleVelocityTable == 0 || count _barrelLengthTable == 0) exitWith { 0 };
|
||||
if (count _muzzleVelocityTable == 1) exitWith { (_muzzleVelocityTable select 0) - _muzzleVelocity };
|
||||
|
@ -4,10 +4,10 @@
|
||||
* Calculates the stability factor of a bullet
|
||||
*
|
||||
* Arguments:
|
||||
* 0: caliber - inches <NUMBER>
|
||||
* 1: bullet length - inches <NUMBER>
|
||||
* 2: bullet mass - grains <NUMBER>
|
||||
* 3: barrel twist - inches <NUMBER>
|
||||
* 0: caliber - mm <NUMBER>
|
||||
* 1: bullet length - mm <NUMBER>
|
||||
* 2: bullet mass - grams <NUMBER>
|
||||
* 3: barrel twist - mm <NUMBER>
|
||||
* 4: muzzle velocity shift - m/s <NUMBER>
|
||||
* 5: temperature - degrees celcius <NUMBER>
|
||||
* 6: barometric Pressure - hPA <NUMBER>
|
||||
@ -17,6 +17,7 @@
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_caliber", "_bulletLength", "_bulletMass", "_barrelTwist", "_muzzleVelocity", "_temperature", "_barometricPressure", "_l", "_t", "_stabilityFactor"];
|
||||
_caliber = _this select 0;
|
||||
@ -31,15 +32,14 @@ _barometricPressure = _this select 6;
|
||||
_t = _barrelTwist / _caliber;
|
||||
_l = _bulletLength / _caliber;
|
||||
|
||||
_stabilityFactor = 30 * _bulletMass / (_t^2 * _caliber^3 * _l * (1 + _l^2));
|
||||
_stabilityFactor = 7587000 * _bulletMass / (_t^2 * _caliber^3 * _l * (1 + _l^2));
|
||||
|
||||
_muzzleVelocity = _muzzleVelocity * 3.2808399;
|
||||
if (_muzzleVelocity > 1120) then {
|
||||
_stabilityFactor = _stabilityFactor * (_muzzleVelocity / 2800) ^ (1/3);
|
||||
if (_muzzleVelocity > 341.376) then {
|
||||
_stabilityFactor = _stabilityFactor * (_muzzleVelocity / 853.44) ^ (1/3);
|
||||
} else {
|
||||
_stabilityFactor = _stabilityFactor * (_muzzleVelocity / 1120) ^ (1/3);
|
||||
_stabilityFactor = _stabilityFactor * (_muzzleVelocity / 341.376) ^ (1/3);
|
||||
};
|
||||
|
||||
_stabilityFactor = _stabilityFactor * (_temperature + 273) / (15 + 273) * 1013.25 / _barometricPressure;
|
||||
_stabilityFactor = _stabilityFactor * KELVIN(_temperature) / KELVIN(15) * 1013.25 / _barometricPressure;
|
||||
|
||||
_stabilityFactor
|
||||
|
@ -1,78 +0,0 @@
|
||||
/*
|
||||
* Author: Ruthberg
|
||||
*
|
||||
* Calculates the true wind speed at a given world position
|
||||
*
|
||||
* Arguments:
|
||||
* 0: _this - world position <posASL>
|
||||
*
|
||||
* Return Value:
|
||||
* 0: wind speed - m/s <NUMBER>
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_windSpeed", "_windDir", "_height", "_newWindSpeed", "_windSource", "_roughnessLength"];
|
||||
|
||||
fnc_polar2vect = {
|
||||
private ["_mag2D"];
|
||||
_mag2D = (_this select 0) * cos((_this select 2));
|
||||
[_mag2D * sin((_this select 1)), _mag2D * cos((_this select 1)), (_this select 0) * sin((_this select 2))];
|
||||
};
|
||||
|
||||
_windSpeed = vectorMagnitude ACE_wind;
|
||||
_windDir = (ACE_wind select 0) atan2 (ACE_wind select 1);
|
||||
|
||||
// Wind gradient
|
||||
if (_windSpeed > 0.05) then {
|
||||
_height = (ASLToATL _this) select 2;
|
||||
_height = 0 max _height min 20;
|
||||
if (_height < 20) then {
|
||||
_roughnessLength = _this call FUNC(calculateRoughnessLength);
|
||||
_windSpeed = _windSpeed * ln(_height / _roughnessLength) / ln(20 / _roughnessLength);
|
||||
};
|
||||
};
|
||||
|
||||
// Terrain effect on wind
|
||||
if (_windSpeed > 0.05) then {
|
||||
_newWindSpeed = 0;
|
||||
{
|
||||
_windSource = [100, _windDir + 180, _x] call fnc_polar2vect;
|
||||
if (!(terrainIntersectASL [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 9) * _windSpeed;
|
||||
};
|
||||
_windSource = [100, _windDir + 180 + _x, 0] call fnc_polar2vect;
|
||||
if (!(terrainIntersectASL [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 9) * _windSpeed;
|
||||
};
|
||||
_windSource = [100, _windDir + 180 - _x, 0] call fnc_polar2vect;
|
||||
if (!(terrainIntersectASL [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 9) * _windSpeed;
|
||||
};
|
||||
} forEach [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10];
|
||||
_windSpeed = _newWindSpeed;
|
||||
};
|
||||
|
||||
// Obstacle effect on wind
|
||||
if (_windSpeed > 0.05) then {
|
||||
_newWindSpeed = 0;
|
||||
{
|
||||
_windSource = [20, _windDir + 180, _x] call fnc_polar2vect;
|
||||
if (!(lineIntersects [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 2) * _windSpeed;
|
||||
};
|
||||
_windSource = [20, _windDir + 180 + _x, 0] call fnc_polar2vect;
|
||||
if (!(lineIntersects [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 2) * _windSpeed;
|
||||
};
|
||||
_windSource = [20, _windDir + 180 - _x, 0] call fnc_polar2vect;
|
||||
if (!(lineIntersects [_this, _this vectorAdd _windSource])) exitWith {
|
||||
_newWindSpeed = cos(_x * 2) * _windSpeed;
|
||||
};
|
||||
} forEach [0, 5, 10, 15, 20, 25, 30, 35, 40, 45];
|
||||
_windSpeed = _newWindSpeed;
|
||||
};
|
||||
_windSpeed = 0 max _windSpeed;
|
||||
|
||||
_windSpeed
|
@ -45,12 +45,12 @@ GVAR(Protractor) = true;
|
||||
|
||||
1 cutRsc ["RscProtractor", "PLAIN", 1, false];
|
||||
|
||||
__ctrl1 ctrlSetScale 0.75;
|
||||
__ctrl1 ctrlSetScale 1;
|
||||
__ctrl1 ctrlCommit 0;
|
||||
__ctrl1 ctrlSetText QUOTE(PATHTOF(UI\protractor.paa));
|
||||
__ctrl1 ctrlSetTextColor [1, 1, 1, 1];
|
||||
|
||||
__ctrl2 ctrlSetScale 0.75;
|
||||
__ctrl2 ctrlSetScale 1;
|
||||
__ctrl2 ctrlSetPosition [(_refPosition select 0), (_refPosition select 1) - 0.0012 * _inclinationAngle, (_refPosition select 2), (_refPosition select 3)];
|
||||
__ctrl2 ctrlCommit 0;
|
||||
__ctrl2 ctrlSetText QUOTE(PATHTOF(UI\protractor_marker.paa));
|
||||
|
@ -19,7 +19,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_unit", "_weapon", "_mode", "_ammo", "_magazine", "_caliber", "_bullet", "_abort", "_index", "_opticsName", "_opticType", "_bulletTraceVisible", "_temperature", "_barometricPressure", "_atmosphereModel", "_bulletMass", "_bulletLength", "_airFriction", "_dragModel", "_muzzleVelocity", "_muzzleVelocityCoef", "_muzzleAccessory", "_initSpeedCoef", "_muzzleVelocityShift", "_bulletVelocity", "_bulletSpeed", "_bulletLength", "_barrelTwist", "_twistDirection", "_stabilityFactor", "_transonicStabilityCoef"];
|
||||
private ["_unit", "_weapon", "_mode", "_ammo", "_magazine", "_caliber", "_bullet", "_abort", "_AmmoCacheEntry", "_WeaponCacheEntry", "_opticsName", "_opticType", "_bulletTraceVisible", "_temperature", "_barometricPressure", "_bulletMass", "_bulletLength", "_muzzleVelocity", "_muzzleVelocityShift", "_bulletVelocity", "_bulletSpeed", "_bulletLength", "_barrelTwist", "_stabilityFactor"];
|
||||
_unit = _this select 0;
|
||||
_weapon = _this select 1;
|
||||
_mode = _this select 3;
|
||||
@ -35,128 +35,94 @@ if (!([_unit] call EFUNC(common,isPlayer))) exitWith {};
|
||||
if (underwater _unit) exitWith {};
|
||||
if (!(_ammo isKindOf "BulletBase")) exitWith {};
|
||||
if (_unit distance ACE_player > GVAR(simulationRadius)) exitWith {};
|
||||
if (GVAR(onlyActiveForLocalPlayers) && _unit != ACE_player) then { _abort = true; };
|
||||
//if (!GVAR(vehicleGunnerEnabled) && !(_unit isKindOf "Man")) then { _abort = true; }; // TODO: We currently do not have firedEHs on vehicles
|
||||
if (GVAR(disabledInFullAutoMode) && getNumber(configFile >> "cfgWeapons" >> _weapon >> _mode >> "autoFire") == 1) then { _abort = true; };
|
||||
|
||||
if (_abort && alwaysSimulateForSnipers) then {
|
||||
if (!GVAR(simulateForEveryone) && !(local _unit)) then {
|
||||
// The shooter is non local
|
||||
_abort = true;
|
||||
if (GVAR(simulateForSnipers)) then {
|
||||
if (currentWeapon _unit == primaryWeapon _unit && count primaryWeaponItems _unit > 2) then {
|
||||
_opticsName = (primaryWeaponItems _unit) select 2;
|
||||
_opticType = getNumber(configFile >> "cfgWeapons" >> _opticsName >> "ItemInfo" >> "opticType");
|
||||
_opticType = getNumber(configFile >> "CfgWeapons" >> _opticsName >> "ItemInfo" >> "opticType");
|
||||
_abort = _opticType != 2; // We only abort if the non local shooter is not a sniper
|
||||
};
|
||||
};
|
||||
if (GVAR(simulateForGroupMembers) && _abort) then {
|
||||
_abort = (group ACE_player) != (group _unit);
|
||||
};
|
||||
};
|
||||
//if (!GVAR(vehicleGunnerEnabled) && !(_unit isKindOf "Man")) then { _abort = true; }; // We currently do not have firedEHs on vehicles
|
||||
if (GVAR(disabledInFullAutoMode) && getNumber(configFile >> "CfgWeapons" >> _weapon >> _mode >> "autoFire") == 1) then { _abort = true; };
|
||||
|
||||
if (_abort || !(GVAR(extensionAvailable))) exitWith {
|
||||
[_bullet, getNumber(configFile >> "cfgAmmo" >> _ammo >> "airFriction")] call EFUNC(winddeflection,updateTrajectoryPFH);
|
||||
[_bullet, getNumber(configFile >> "CfgAmmo" >> _ammo >> "airFriction")] call EFUNC(winddeflection,updateTrajectoryPFH);
|
||||
};
|
||||
|
||||
_airFriction = getNumber(configFile >> "cfgAmmo" >> _ammo >> "airFriction");
|
||||
_muzzleVelocity = getNumber(configFile >> "cfgMagazines" >> _magazine >> "initSpeed");
|
||||
_muzzleVelocityCoef = getNumber(configFile >> "cfgWeapons" >> _weapon >> "initSpeed");
|
||||
if (_muzzleVelocityCoef > 0) then {
|
||||
_muzzleVelocity = _muzzleVelocityCoef;
|
||||
_AmmoCacheEntry = uiNamespace getVariable format[QGVAR(%1), _ammo];
|
||||
if (isNil {_AmmoCacheEntry}) then {
|
||||
_AmmoCacheEntry = _ammo call FUNC(readAmmoDataFromConfig);
|
||||
};
|
||||
if (_muzzleVelocityCoef < 0) then {
|
||||
_muzzleVelocity = _muzzleVelocity * (-1 * _muzzleVelocityCoef);
|
||||
_WeaponCacheEntry = uiNamespace getVariable format[QGVAR(%1), _weapon];
|
||||
if (isNil {_WeaponCacheEntry}) then {
|
||||
_WeaponCacheEntry = _weapon call FUNC(readWeaponDataFromConfig);
|
||||
};
|
||||
|
||||
_muzzleAccessory = "";
|
||||
switch (currentWeapon _unit) do {
|
||||
case primaryWeapon _unit: { _muzzleAccessory = (primaryWeaponItems _unit) select 0; };
|
||||
case handgunWeapon _unit: { _muzzleAccessory = (handgunItems _unit) select 0; };
|
||||
};
|
||||
|
||||
if (_muzzleAccessory != "" && isNumber(configFile >> "cfgWeapons" >> _muzzleAccessory >> "ItemInfo" >> "MagazineCoef" >> "initSpeed")) then {
|
||||
_initSpeedCoef = getNumber(configFile >> "cfgWeapons" >> _muzzleAccessory >> "ItemInfo" >> "MagazineCoef" >> "initSpeed");
|
||||
_muzzleVelocity = _muzzleVelocity * _initSpeedCoef;
|
||||
};
|
||||
_bulletVelocity = velocity _bullet;
|
||||
_muzzleVelocity = vectorMagnitude _bulletVelocity;
|
||||
|
||||
if (GVAR(barrelLengthInfluenceEnabled)) then {
|
||||
_muzzleVelocityShift = [_ammo, _weapon, _muzzleVelocity] call FUNC(calculateBarrelLengthVelocityShift);
|
||||
_muzzleVelocityShift = [_WeaponCacheEntry select 2, _AmmoCacheEntry select 10, _AmmoCacheEntry select 11, _muzzleVelocity] call FUNC(calculateBarrelLengthVelocityShift);
|
||||
if (_muzzleVelocityShift != 0) then {
|
||||
_bulletVelocity = velocity _bullet;
|
||||
_bulletSpeed = vectorMagnitude _bulletVelocity;
|
||||
_bulletVelocity = _bulletVelocity vectorAdd ((vectorNormalized _bulletVelocity) vectorMultiply (_muzzleVelocityShift * (_bulletSpeed / _muzzleVelocity)));
|
||||
_bulletVelocity = _bulletVelocity vectorAdd ((vectorNormalized _bulletVelocity) vectorMultiply (_muzzleVelocityShift));
|
||||
_bullet setVelocity _bulletVelocity;
|
||||
_muzzleVelocity = _muzzleVelocity + _muzzleVelocityShift;
|
||||
};
|
||||
};
|
||||
|
||||
if (GVAR(ammoTemperatureEnabled)) then {
|
||||
_temperature = GET_TEMPERATURE_AT_HEIGHT((getPosASL _unit) select 2);
|
||||
_muzzleVelocityShift = [_ammo, _temperature] call FUNC(calculateAmmoTemperatureVelocityShift);
|
||||
_temperature = ((getPosASL _unit) select 2) call EFUNC(weather,calculateTemperatureAtHeight);
|
||||
_muzzleVelocityShift = [_AmmoCacheEntry select 9, _temperature] call FUNC(calculateAmmoTemperatureVelocityShift);
|
||||
if (_muzzleVelocityShift != 0) then {
|
||||
_bulletVelocity = velocity _bullet;
|
||||
_bulletSpeed = vectorMagnitude _bulletVelocity;
|
||||
_bulletVelocity = _bulletVelocity vectorAdd ((vectorNormalized _bulletVelocity) vectorMultiply (_muzzleVelocityShift * (_bulletSpeed / _muzzleVelocity)));
|
||||
_bulletVelocity = _bulletVelocity vectorAdd ((vectorNormalized _bulletVelocity) vectorMultiply (_muzzleVelocityShift));
|
||||
_bullet setVelocity _bulletVelocity;
|
||||
_muzzleVelocity = _muzzleVelocity + _muzzleVelocityShift;
|
||||
};
|
||||
};
|
||||
|
||||
_bulletTraceVisible = false;
|
||||
if (GVAR(bulletTraceEnabled) && cameraView == "GUNNER" && currentWeapon ACE_player == primaryWeapon ACE_player && count primaryWeaponItems ACE_player > 2) then {
|
||||
if (GVAR(bulletTraceEnabled) && cameraView == "GUNNER") then {
|
||||
if (currentWeapon ACE_player in ["ACE_Vector", "Binocular", "Rangefinder", "Laserdesignator"]) then {
|
||||
_bulletTraceVisible = true;
|
||||
} else {
|
||||
if (currentWeapon ACE_player == primaryWeapon ACE_player && count primaryWeaponItems ACE_player > 2) then {
|
||||
_opticsName = (primaryWeaponItems ACE_player) select 2;
|
||||
_opticType = getNumber(configFile >> "cfgWeapons" >> _opticsName >> "ItemInfo" >> "opticType");
|
||||
_bulletTraceVisible = (_opticType == 2 || currentWeapon ACE_player in ["ACE_Vector", "Binocular", "Rangefinder", "Laserdesignator"]);
|
||||
_opticType = getNumber(configFile >> "CfgWeapons" >> _opticsName >> "ItemInfo" >> "opticType");
|
||||
_bulletTraceVisible = _opticType == 2;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
_caliber = getNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_caliber");
|
||||
_bulletLength = getNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_bulletLength");
|
||||
_bulletMass = getNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_bulletMass");
|
||||
_barrelTwist = getNumber(configFile >> "cfgWeapons" >> _weapon >> "ACE_barrelTwist");
|
||||
_caliber = _AmmoCacheEntry select 1;
|
||||
_bulletLength = _AmmoCacheEntry select 2;
|
||||
_bulletMass = _AmmoCacheEntry select 3;
|
||||
_barrelTwist = _WeaponCacheEntry select 0;
|
||||
_stabilityFactor = 1.5;
|
||||
|
||||
if (_caliber > 0 && _bulletLength > 0 && _bulletMass > 0 && _barrelTwist > 0) then {
|
||||
_temperature = GET_TEMPERATURE_AT_HEIGHT((getPosASL _unit) select 2);
|
||||
_temperature = ((getPosASL _unit) select 2) call EFUNC(weather,calculateTemperatureAtHeight);
|
||||
_barometricPressure = ((getPosASL _bullet) select 2) call EFUNC(weather,calculateBarometricPressure);
|
||||
_stabilityFactor = [_caliber, _bulletLength, _bulletMass, _barrelTwist, _muzzleVelocity, _temperature, _barometricPressure] call FUNC(calculateStabilityFactor);
|
||||
};
|
||||
|
||||
_twistDirection = 1;
|
||||
if (isNumber(configFile >> "cfgWeapons" >> _weapon >> "ACE_twistDirection")) then {
|
||||
_twistDirection = getNumber(configFile >> "cfgWeapons" >> _weapon >> "ACE_twistDirection");
|
||||
if (_twistDirection != -1 && _twistDirection != 0 && _twistDirection != 1) then {
|
||||
_twistDirection = 1;
|
||||
};
|
||||
};
|
||||
|
||||
_transonicStabilityCoef = 0.5;
|
||||
if (isNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_transonicStabilityCoef")) then {
|
||||
_transonicStabilityCoef = getNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_transonicStabilityCoef");
|
||||
};
|
||||
|
||||
_dragModel = 1;
|
||||
_ballisticCoefficients = [];
|
||||
_velocityBoundaries = [];
|
||||
_atmosphereModel = "ICAO";
|
||||
if (GVAR(AdvancedAirDragEnabled)) then {
|
||||
if (isNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_dragModel")) then {
|
||||
_dragModel = getNumber(configFile >> "cfgAmmo" >> _ammo >> "ACE_dragModel");
|
||||
if (!(_dragModel in [1, 2, 5, 6, 7, 8])) then {
|
||||
_dragModel = 1;
|
||||
};
|
||||
};
|
||||
if (isArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_ballisticCoefficients")) then {
|
||||
_ballisticCoefficients = getArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_ballisticCoefficients");
|
||||
};
|
||||
if (isArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_velocityBoundaries")) then {
|
||||
_velocityBoundaries = getArray(configFile >> "cfgAmmo" >> _ammo >> "ACE_velocityBoundaries");
|
||||
};
|
||||
if (isText(configFile >> "cfgAmmo" >> _ammo >> "ACE_standardAtmosphere")) then {
|
||||
_atmosphereModel = getText(configFile >> "cfgAmmo" >> _ammo >> "ACE_standardAtmosphere");
|
||||
};
|
||||
};
|
||||
|
||||
#ifdef USE_ADVANCEDBALLISTICS_DLL
|
||||
GVAR(currentbulletID) = (GVAR(currentbulletID) + 1) % 10000;
|
||||
|
||||
"ace_advanced_ballistics" callExtension format["new:%1:%2:%3:%4:%5:%6:%7:%8:%9:%10:%11:%12:%13:%14:%15:%16:%17:%18", GVAR(currentbulletID), _airFriction, _ballisticCoefficients, _velocityBoundaries, _atmosphereModel, _dragModel, _stabilityFactor, _twistDirection, _muzzleVelocity, _transonicStabilityCoef, getPosASL _bullet, EGVAR(weather,Latitude), EGVAR(weather,currentTemperature), EGVAR(weather,Altitude), EGVAR(weather,currentHumidity), overcast, floor(time), time - floor(time)];
|
||||
"ace_advanced_ballistics" callExtension format["new:%1:%2:%3:%4:%5:%6:%7:%8:%9:%10:%11:%12:%13:%14:%15:%16:%17:%18", GVAR(currentbulletID), _AmmoCacheEntry select 0, _AmmoCacheEntry select 6, _AmmoCacheEntry select 7, _AmmoCacheEntry select 8, _AmmoCacheEntry select 5, _stabilityFactor, _WeaponCacheEntry select 1, _muzzleVelocity, _AmmoCacheEntry select 4, getPosASL _bullet, EGVAR(weather,Latitude), EGVAR(weather,currentTemperature), EGVAR(weather,Altitude), EGVAR(weather,currentHumidity), overcast, floor(ACE_time), ACE_time - floor(ACE_time)];
|
||||
|
||||
[{
|
||||
private ["_index", "_bullet", "_caliber", "_bulletTraceVisible", "_bulletVelocity", "_bulletPosition"];
|
||||
EXPLODE_4_PVT(_this select 0,_bullet,_caliber,_bulletTraceVisible,_index);
|
||||
private ["_args", "_index", "_bullet", "_caliber", "_bulletTraceVisible", "_bulletVelocity", "_bulletPosition"];
|
||||
_args = _this select 0;
|
||||
_bullet = _args select 0;
|
||||
_caliber = _args select 1;
|
||||
_bulletTraceVisible = _args select 2;
|
||||
_index = _args select 3;
|
||||
|
||||
_bulletVelocity = velocity _bullet;
|
||||
_bulletPosition = getPosASL _bullet;
|
||||
@ -167,217 +133,10 @@ if (GVAR(AdvancedAirDragEnabled)) then {
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
if (_bulletTraceVisible && _bulletSpeed > 600) then {
|
||||
drop ["\A3\data_f\ParticleEffects\Universal\Refract","","Billboard",1,0.1,getPos _bullet,[0,0,0],0,1.275,1,0,[0.4*_caliber,0.2*_caliber],[[0,0,0,0.6],[0,0,0,0.4]],[1,0],0,0,"","",""];
|
||||
if (_bulletTraceVisible && _bulletSpeed > 500) then {
|
||||
drop ["\A3\data_f\ParticleEffects\Universal\Refract","","Billboard",1,0.1,getPos _bullet,[0,0,0],0,1.275,1,0,[0.02*_caliber,0.01*_caliber],[[0,0,0,0.65],[0,0,0,0.2]],[1,0],0,0,"","",""];
|
||||
};
|
||||
|
||||
call compile ("ace_advanced_ballistics" callExtension format["simulate:%1:%2:%3:%4:%5:%6:%7", _index, _bulletVelocity, _bulletPosition, ACE_wind, ASLToATL(_bulletPosition) select 2, floor(time), time - floor(time)]);
|
||||
call compile ("ace_advanced_ballistics" callExtension format["simulate:%1:%2:%3:%4:%5:%6:%7", _index, _bulletVelocity, _bulletPosition, ACE_wind, ASLToATL(_bulletPosition) select 2, floor(ACE_time), ACE_time - floor(ACE_time)]);
|
||||
|
||||
}, GVAR(simulationInterval), [_bullet, _caliber, _bulletTraceVisible, GVAR(currentbulletID)]] call CBA_fnc_addPerFrameHandler;
|
||||
#else
|
||||
_index = count GVAR(bulletDatabase);
|
||||
if (count GVAR(bulletDatabaseFreeIndices) > 0) then {
|
||||
_index = GVAR(bulletDatabaseFreeIndices) select 0;
|
||||
GVAR(bulletDatabaseFreeIndices) = GVAR(bulletDatabaseFreeIndices) - [_index];
|
||||
};
|
||||
|
||||
GVAR(bulletDatabase) set[_index, [_bullet, _caliber, _airFriction, _muzzleVelocity, _stabilityFactor, _transonicStabilityCoef, _twistDirection, _unit, _bulletTraceVisible, _ballisticCoefficients, _velocityBoundaries, _atmosphereModel, _dragModel, _index]];
|
||||
GVAR(bulletDatabaseStartTime) set[_index, time];
|
||||
GVAR(bulletDatabaseSpeed) set[_index, 0];
|
||||
GVAR(bulletDatabaseFrames) set[_index, 1];
|
||||
GVAR(bulletDatabaseLastFrame) set[_index, time];
|
||||
GVAR(bulletDatabaseHDeflect) set[_index, 0];
|
||||
GVAR(bulletDatabaseSpinDrift) set[_index, 0];
|
||||
|
||||
if ((GVAR(bulletDatabaseOccupiedIndices) pushBack _index) == 0) then {
|
||||
[{
|
||||
private ["_bulletDatabaseEntry", "_bullet", "_caliber", "_muzzleVelocity", "_frames", "_speed", "_airFriction", "_airFrictionRef", "_dragModel", "_atmosphereModel", "_ballisticCoefficient", "_ballisticCoefficients", "_velocityBoundaries", "_airDensity", "_stabilityFactor", "_transonicStabilityCoef", "_twistDirection", "_unit", "_bulletTraceVisible", "_index", "_temperature", "_humidity", "_deltaT", "_TOF", "_bulletPosition", "_bulletVelocity", "_bulletSpeed", "_trueVelocity", "_trueSpeed", "_bulletSpeedAvg", "_wind", "_drag", "_dragRef", "_vect", "_accel", "_accelRef", "_centripetalAccel", "_pressure", "_pressureDeviation", "_windSourceObstacle", "_windSourceTerrain", "_height", "_roughnessLength", "_bulletDir", "_horizontalDeflection", "_horizontalDeflectionPartial", "_spinDrift", "_spinDriftPartial"];
|
||||
|
||||
{
|
||||
_bulletDatabaseEntry = (GVAR(bulletDatabase) select _x);
|
||||
if (!alive (_bulletDatabaseEntry select 0)) then {
|
||||
_index = _bulletDatabaseEntry select 13;
|
||||
GVAR(bulletDatabaseOccupiedIndices) = GVAR(bulletDatabaseOccupiedIndices) - [_index];
|
||||
GVAR(bulletDatabaseFreeIndices) pushBack _index;
|
||||
};
|
||||
true
|
||||
} count GVAR(bulletDatabaseOccupiedIndices);
|
||||
|
||||
if (count GVAR(bulletDatabaseOccupiedIndices) == 0) exitWith {
|
||||
GVAR(bulletDatabase) = [];
|
||||
GVAR(bulletDatabaseStartTime) = [];
|
||||
GVAR(bulletDatabaseSpeed) = [];
|
||||
GVAR(bulletDatabaseFrames) = [];
|
||||
GVAR(bulletDatabaseLastFrame) = [];
|
||||
GVAR(bulletDatabaseHDeflect) = [];
|
||||
GVAR(bulletDatabaseSpinDrift) = [];
|
||||
GVAR(bulletDatabaseOccupiedIndices) = [];
|
||||
GVAR(bulletDatabaseFreeIndices) = [];
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
{
|
||||
_bulletDatabaseEntry = GVAR(bulletDatabase) select _x;
|
||||
_bullet = _bulletDatabaseEntry select 0;
|
||||
_caliber = _bulletDatabaseEntry select 1;
|
||||
_airFriction = _bulletDatabaseEntry select 2;
|
||||
_muzzleVelocity = _bulletDatabaseEntry select 3;
|
||||
_stabilityFactor = _bulletDatabaseEntry select 4;
|
||||
_transonicStabilityCoef = _bulletDatabaseEntry select 5;
|
||||
_twistDirection = _bulletDatabaseEntry select 6;
|
||||
_unit = _bulletDatabaseEntry select 7;
|
||||
_bulletTraceVisible = _bulletDatabaseEntry select 8;
|
||||
_ballisticCoefficients = _bulletDatabaseEntry select 9;
|
||||
_velocityBoundaries = _bulletDatabaseEntry select 10;
|
||||
_atmosphereModel = _bulletDatabaseEntry select 11;
|
||||
_dragModel = _bulletDatabaseEntry select 12;
|
||||
_index = _bulletDatabaseEntry select 13;
|
||||
|
||||
_TOF = time - (GVAR(bulletDatabaseStartTime) select _index);
|
||||
|
||||
_bulletVelocity = velocity _bullet;
|
||||
_bulletPosition = getPosASL _bullet;
|
||||
|
||||
_bulletSpeed = vectorMagnitude _bulletVelocity;
|
||||
_bulletDir = (_bulletVelocity select 0) atan2 (_bulletVelocity select 1);
|
||||
|
||||
_speed = (GVAR(bulletDatabaseSpeed) select _index);
|
||||
GVAR(bulletDatabaseSpeed) set[_index, _speed + _bulletSpeed];
|
||||
|
||||
_frames = (GVAR(bulletDatabaseFrames) select _index);
|
||||
GVAR(bulletDatabaseFrames) set[_index, _frames + 1];
|
||||
|
||||
_bulletSpeedAvg = (_speed / _frames);
|
||||
|
||||
if ((GVAR(SimulationPrecision) < 2) || {_frames % GVAR(SimulationPrecision) == _index % GVAR(SimulationPrecision)}) then {
|
||||
_deltaT = time - (GVAR(bulletDatabaseLastFrame) select _index);
|
||||
GVAR(bulletDatabaseLastFrame) set[_index, time];
|
||||
|
||||
_trueVelocity = _bulletVelocity;
|
||||
_trueSpeed = _bulletSpeed;
|
||||
_wind = [0, 0, 0];
|
||||
if (GVAR(WindEnabled) && (vectorMagnitude ACE_wind) > 0) then {
|
||||
_windSourceObstacle = _bulletPosition vectorDiff ((vectorNormalized ACE_wind) vectorMultiply 10);
|
||||
_windSourceTerrain = _bulletPosition vectorDiff ((vectorNormalized ACE_wind) vectorMultiply 100);
|
||||
|
||||
if (!(lineIntersects [_bulletPosition, _windSourceObstacle]) && !(terrainIntersectASL [_bulletPosition, _windSourceTerrain])) then {
|
||||
_wind = ACE_wind;
|
||||
_height = ASLToATL(_bulletPosition) select 2;
|
||||
_height = 0 max _height min 20;
|
||||
if (_height < 20) then {
|
||||
_roughnessLength = _bulletPosition call FUNC(calculateRoughnessLength);
|
||||
_wind = _wind vectorMultiply (ln(_height / _roughnessLength) / ln(20 / _roughnessLength));
|
||||
};
|
||||
|
||||
_trueVelocity = _bulletVelocity vectorDiff _wind;
|
||||
_trueSpeed = vectorMagnitude _trueVelocity;
|
||||
};
|
||||
};
|
||||
|
||||
_airFrictionRef = _airFriction;
|
||||
if (GVAR(AdvancedAirDragEnabled) && (count _ballisticCoefficients) == (count _velocityBoundaries) + 1) then {
|
||||
_dragRef = _deltaT * _airFrictionRef * _bulletSpeed * _bulletSpeed;
|
||||
_accelRef = (vectorNormalized _bulletVelocity) vectorMultiply (_dragRef);
|
||||
_bulletVelocity = _bulletVelocity vectorDiff _accelRef;
|
||||
|
||||
_ballisticCoefficient = (_ballisticCoefficients select 0);
|
||||
for "_i" from (count _velocityBoundaries) - 1 to 0 step -1 do {
|
||||
if (_bulletSpeed < (_velocityBoundaries select _i)) exitWith {
|
||||
_ballisticCoefficient = (_ballisticCoefficients select (_i + 1));
|
||||
};
|
||||
};
|
||||
|
||||
if (GVAR(AtmosphericDensitySimulationEnabled)) then {
|
||||
_pressure = (_bulletPosition select 2) call EFUNC(weather,calculateBarometricPressure);
|
||||
_temperature = GET_TEMPERATURE_AT_HEIGHT(_bulletPosition select 2);
|
||||
_humidity = EGVAR(weather,currentHumidity);
|
||||
_airDensity = STD_AIR_DENSITY_ICAO;
|
||||
if (_humidity > 0) then {
|
||||
private ["_pSat", "_vaporPressure", "_partialPressure"];
|
||||
// Saturation vapor pressure calculated according to: http://wahiduddin.net/calc/density_algorithms.htm
|
||||
_pSat = 6.1078 * 10 ^ ((7.5 * _temperature) / (_temperature + 237.3));
|
||||
_vaporPressure = _humidity * _pSat;
|
||||
_partialPressure = (_pressure * 100)- _vaporPressure;
|
||||
|
||||
_airDensity = (_partialPressure * DRY_AIR_MOLAR_MASS + _vaporPressure * WATER_VAPOR_MOLAR_MASS) / (UNIVERSAL_GAS_CONSTANT * KELVIN(_temperature));
|
||||
} else {
|
||||
_airDensity = (_pressure * 100) / (SPECIFIC_GAS_CONSTANT_DRY_AIR * KELVIN(_temperature));
|
||||
};
|
||||
if (_atmosphereModel == "ICAO") then {
|
||||
_ballisticCoefficient = (STD_AIR_DENSITY_ICAO / _airDensity) * _ballisticCoefficient;
|
||||
} else {
|
||||
_ballisticCoefficient = (STD_AIR_DENSITY_ASM / _airDensity) * _ballisticCoefficient;
|
||||
};
|
||||
};
|
||||
|
||||
_drag = _deltaT * ([_dragModel, _ballisticCoefficient, _trueSpeed] call FUNC(calculateRetardation));
|
||||
_accel = (vectorNormalized _trueVelocity) vectorMultiply (_drag);
|
||||
_bulletVelocity = _bulletVelocity vectorDiff _accel;
|
||||
} else {
|
||||
if (GVAR(AtmosphericDensitySimulationEnabled)) then {
|
||||
_pressureDeviation = (_bulletPosition select 2) call EFUNC(weather,calculateBarometricPressure) - 1013.25;
|
||||
_temperature = GET_TEMPERATURE_AT_HEIGHT(_bulletPosition select 2);
|
||||
_humidity = EGVAR(weather,currentHumidity);
|
||||
_airFriction = _airFriction + ((_temperature - 15) * 0.0000015 + _humidity * 0.0000040 + _pressureDeviation * -0.0000009);
|
||||
};
|
||||
|
||||
if (_airFriction != _airFrictionRef || vectorMagnitude _wind > 0) then {
|
||||
_dragRef = _deltaT * _airFrictionRef * _bulletSpeed * _bulletSpeed;
|
||||
_accelRef = (vectorNormalized _bulletVelocity) vectorMultiply (_dragRef);
|
||||
_bulletVelocity = _bulletVelocity vectorDiff _accelRef;
|
||||
|
||||
_drag = _deltaT * _airFriction * _trueSpeed * _trueSpeed;
|
||||
_accel = (vectorNormalized _trueVelocity) vectorMultiply (_drag);
|
||||
_bulletVelocity = _bulletVelocity vectorAdd _accel;
|
||||
};
|
||||
};
|
||||
|
||||
if (GVAR(CoriolisEnabled) && _bulletSpeedAvg > 0) then {
|
||||
_horizontalDeflection = 0.0000729 * (_unit distanceSqr _bullet) * sin(EGVAR(weather,Latitude)) / _bulletSpeedAvg;
|
||||
_horizontalDeflectionPartial = _horizontalDeflection - (GVAR(bulletDatabaseHDeflect) select _index);
|
||||
GVAR(bulletDatabaseHDeflect) set[_index, _horizontalDeflection];
|
||||
_vect = [sin(_bulletDir + 90) * _horizontalDeflectionPartial, cos(_bulletDir + 90) * _horizontalDeflectionPartial, 0];
|
||||
|
||||
_bulletPosition = _bulletPosition vectorAdd _vect;
|
||||
};
|
||||
|
||||
/*
|
||||
// Negligible effect on the trajectory
|
||||
if (GVAR(EoetvoesEnabled)) then {
|
||||
_centripetalAccel = 2 * 0.0000729 * (_muzzleVelocity / -32.2) * cos(EGVAR(weather,Latitude)) * sin(_bulletDir);
|
||||
_accel = [0, 0, -(_centripetalAccel * _deltaT)];
|
||||
|
||||
_bulletVelocity = _bulletVelocity vectorAdd _accel;
|
||||
};
|
||||
//*/
|
||||
|
||||
if (GVAR(SpinDriftEnabled)) then {
|
||||
_spinDrift = _twistDirection * 0.0254 * 1.25 * (_stabilityFactor + 1.2) * _TOF ^ 1.83;
|
||||
_spinDriftPartial = _spinDrift - (GVAR(bulletDatabaseSpinDrift) select _index);
|
||||
GVAR(bulletDatabaseSpinDrift) set[_index, _spinDrift];
|
||||
_vect = [sin(_bulletDir + 90) * _spinDriftPartial, cos(_bulletDir + 90) * _spinDriftPartial, 0];
|
||||
|
||||
_bulletPosition = _bulletPosition vectorAdd _vect;
|
||||
};
|
||||
};
|
||||
|
||||
if (GVAR(TransonicRegionEnabled) && _transonicStabilityCoef < 1) then {
|
||||
if (_bulletSpeed < 345 && _bulletSpeedAvg > 340 && _bulletSpeed > 335) then {
|
||||
_accel = [(random 0.8) - 0.4, (random 0.8) - 0.4, (random 0.8) - 0.4];
|
||||
_accel = _accel vectorMultiply (1 - _transonicStabilityCoef);
|
||||
_bulletVelocity = _bulletVelocity vectorAdd _accel;
|
||||
};
|
||||
};
|
||||
|
||||
if (_bulletTraceVisible && _bulletSpeed > 600 && _bullet distanceSqr _unit > 400) then {
|
||||
drop ["\A3\data_f\ParticleEffects\Universal\Refract","","Billboard",1,0.1,getPos _bullet,[0,0,0],0,1.275,1,0,[0.4*_caliber,0.2*_caliber],[[0,0,0,0.6],[0,0,0,0.4]],[1,0],0,0,"","",""];
|
||||
};
|
||||
|
||||
_bullet setVelocity _bulletVelocity;
|
||||
_bullet setPosASL _bulletPosition;
|
||||
true
|
||||
} count GVAR(bulletDatabaseOccupiedIndices);
|
||||
|
||||
}, GVAR(simulationInterval), []] call CBA_fnc_addPerFrameHandler;
|
||||
};
|
||||
#endif
|
||||
|
@ -26,9 +26,10 @@ if !(_activated) exitWith {};
|
||||
[_logic, QGVAR(ammoTemperatureEnabled), "ammoTemperatureEnabled"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(barrelLengthInfluenceEnabled), "barrelLengthInfluenceEnabled"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(bulletTraceEnabled), "bulletTraceEnabled"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(onlyActiveForLocalPlayers), "onlyActiveForLocalPlayers"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(simulateForEveryone), "simulateForEveryone"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(disabledInFullAutoMode), "disabledInFullAutoMode"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(alwaysSimulateForSnipers), "alwaysSimulateForSnipers"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(simulateForSnipers), "simulateForSnipers"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(simulateForGroupMembers), "simulateForGroupMembers"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(simulationInterval), "simulationInterval"] call EFUNC(common,readSettingFromModule);
|
||||
[_logic, QGVAR(simulationRadius), "simulationRadius"] call EFUNC(common,readSettingFromModule);
|
||||
|
||||
|
@ -13,15 +13,16 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
if (!hasInterface) exitWith {};
|
||||
if (!GVAR(enabled)) exitWith {};
|
||||
if (!GVAR(extensionAvailable)) exitWith {};
|
||||
|
||||
private ["_initStartTime", "_mapSize", "_mapGrids", "_gridCells", "_x", "_y", "_gridCenter", "_gridHeight", "_gridNumObjects", "_gridSurfaceIsWater"];
|
||||
|
||||
_initStartTime = time;
|
||||
_initStartTime = ACE_time;
|
||||
_mapSize = getNumber (configFile >> "CfgWorlds" >> worldName >> "MapSize");
|
||||
|
||||
if (("ace_advanced_ballistics" callExtension format["init:%1:%2", worldName, _mapSize]) == "Terrain already initialized") exitWith {
|
||||
if (GVAR(INIT_MESSAGE_ENABLED)) then {
|
||||
if (GVAR(initMessageEnabled)) then {
|
||||
systemChat "AdvancedBallistics: Terrain already initialized";
|
||||
};
|
||||
};
|
||||
@ -39,8 +40,8 @@ GVAR(currentGrid) = 0;
|
||||
_initStartTime = _args select 2;
|
||||
|
||||
if (GVAR(currentGrid) >= _gridCells) exitWith {
|
||||
if (GVAR(INIT_MESSAGE_ENABLED)) then {
|
||||
systemChat format["AdvancedBallistics: Finished terrain initialization in %1 seconds", ceil(time - _initStartTime)];
|
||||
if (GVAR(initMessageEnabled)) then {
|
||||
systemChat format["AdvancedBallistics: Finished terrain initialization in %1 seconds", ceil(ACE_time - _initStartTime)];
|
||||
};
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Author: Ruthberg
|
||||
*
|
||||
* Reads the ammo class config and updates the config cache
|
||||
*
|
||||
* Arguments:
|
||||
* 0: ammo - classname <string>
|
||||
*
|
||||
* Return Value:
|
||||
* 0: [_airFriction, _caliber, _bulletLength, _bulletMass, _transonicStabilityCoef, _dragModel, _ballisticCoefficients, _velocityBoundaries, _atmosphereModel, _ammoTempMuzzleVelocityShifts, _muzzleVelocityTable, _barrelLengthTable] <ARRAY>
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_ammo", "_airFriction", "_caliber", "_bulletLength", "_bulletMass", "_transonicStabilityCoef", "_dragModel", "_ballisticCoefficients", "_velocityBoundaries", "_atmosphereModel", "_ammoTempMuzzleVelocityShifts", "_muzzleVelocityTable", "_barrelLengthTable", "_result"];
|
||||
_ammo = _this;
|
||||
|
||||
_airFriction = getNumber(configFile >> "CfgAmmo" >> _ammo >> "airFriction");
|
||||
_caliber = getNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_caliber");
|
||||
_bulletLength = getNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_bulletLength");
|
||||
_bulletMass = getNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_bulletMass");
|
||||
_transonicStabilityCoef = 0.5;
|
||||
if (isNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_transonicStabilityCoef")) then {
|
||||
_transonicStabilityCoef = getNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_transonicStabilityCoef");
|
||||
};
|
||||
_dragModel = 1;
|
||||
_ballisticCoefficients = [];
|
||||
_velocityBoundaries = [];
|
||||
_atmosphereModel = "ICAO";
|
||||
if (isNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_dragModel")) then {
|
||||
_dragModel = getNumber(configFile >> "CfgAmmo" >> _ammo >> "ACE_dragModel");
|
||||
if (!(_dragModel in [1, 2, 5, 6, 7, 8])) then {
|
||||
_dragModel = 1;
|
||||
};
|
||||
};
|
||||
if (isArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_ballisticCoefficients")) then {
|
||||
_ballisticCoefficients = getArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_ballisticCoefficients");
|
||||
};
|
||||
if (isArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_velocityBoundaries")) then {
|
||||
_velocityBoundaries = getArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_velocityBoundaries");
|
||||
};
|
||||
if (isText(configFile >> "CfgAmmo" >> _ammo >> "ACE_standardAtmosphere")) then {
|
||||
_atmosphereModel = getText(configFile >> "CfgAmmo" >> _ammo >> "ACE_standardAtmosphere");
|
||||
};
|
||||
_ammoTempMuzzleVelocityShifts = [];
|
||||
if (isArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_ammoTempMuzzleVelocityShifts")) then {
|
||||
_ammoTempMuzzleVelocityShifts = getArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_ammoTempMuzzleVelocityShifts");
|
||||
};
|
||||
_muzzleVelocityTable = [];
|
||||
_barrelLengthTable = [];
|
||||
if (isArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_muzzleVelocities")) then {
|
||||
_muzzleVelocityTable = getArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_muzzleVelocities");
|
||||
};
|
||||
if (isArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_barrelLengths")) then {
|
||||
_barrelLengthTable = getArray(configFile >> "CfgAmmo" >> _ammo >> "ACE_barrelLengths");
|
||||
};
|
||||
|
||||
_result = [_airFriction, _caliber, _bulletLength, _bulletMass, _transonicStabilityCoef, _dragModel, _ballisticCoefficients, _velocityBoundaries, _atmosphereModel, _ammoTempMuzzleVelocityShifts, _muzzleVelocityTable, _barrelLengthTable];
|
||||
|
||||
uiNamespace setVariable [format[QGVAR(%1), _ammo], _result];
|
||||
|
||||
_result
|
@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Author: Ruthberg
|
||||
*
|
||||
* Reads the weapon class config and updates the config cache
|
||||
*
|
||||
* Arguments:
|
||||
* 0: weapon - classname <string>
|
||||
*
|
||||
* Return Value:
|
||||
* 0: [_barrelTwist, _twistDirection, _barrelLength] <ARRAY>
|
||||
*
|
||||
* Return value:
|
||||
* None
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_weapon", "_barrelTwist", "_twistDirection", "_barrelLength", "_result"];
|
||||
_weapon = _this;
|
||||
|
||||
_barrelTwist = getNumber(configFile >> "CfgWeapons" >> _weapon >> "ACE_barrelTwist");
|
||||
_twistDirection = 1;
|
||||
if (isNumber(configFile >> "CfgWeapons" >> _weapon >> "ACE_twistDirection")) then {
|
||||
_twistDirection = getNumber(configFile >> "CfgWeapons" >> _weapon >> "ACE_twistDirection");
|
||||
if (_twistDirection != -1 && _twistDirection != 0 && _twistDirection != 1) then {
|
||||
_twistDirection = 1;
|
||||
};
|
||||
};
|
||||
_barrelLength = getNumber(configFile >> "CfgWeapons" >> _weapon >> "ACE_barrelLength");
|
||||
|
||||
_result = [_barrelTwist, _twistDirection, _barrelLength];
|
||||
|
||||
uiNamespace setVariable [format[QGVAR(%1), _weapon], _result];
|
||||
|
||||
_result
|
@ -1,4 +1,4 @@
|
||||
["ACE3", QGVAR(ProtractorKey), localize "STR_ACE_AdvancedBallistics_ProtractorKey",
|
||||
["ACE3 Equipment", QGVAR(ProtractorKey), localize LSTRING(ProtractorKey),
|
||||
{
|
||||
// Conditions: canInteract
|
||||
if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
|
@ -1,8 +1,6 @@
|
||||
#define COMPONENT advanced_ballistics
|
||||
#include "\z\ace\addons\main\script_mod.hpp"
|
||||
|
||||
#define USE_ADVANCEDBALLISTICS_DLL
|
||||
|
||||
#ifdef DEBUG_ENABLED_ADVANCEDBALLISTICS
|
||||
#define DEBUG_MODE_FULL
|
||||
#endif
|
||||
@ -23,6 +21,5 @@
|
||||
#define SPECIFIC_GAS_CONSTANT_DRY_AIR 287.058
|
||||
#define STD_AIR_DENSITY_ICAO 1.22498
|
||||
#define STD_AIR_DENSITY_ASM 1.20885
|
||||
#define GET_TEMPERATURE_AT_HEIGHT(h) (EGVAR(weather,currentTemperature) - 0.0065 * (h))
|
||||
|
||||
#define EXTENSION_REQUIRED_VERSION "1.0"
|
||||
|
@ -1,8 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Edited with tabler. -->
|
||||
<Project name="ACE">
|
||||
<Package name="AdvancedBallistics">
|
||||
<Key ID="STR_ACE_AdvancedBallistics_WindInfoKey">
|
||||
<Package name="Advanced_Ballistics">
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_WindInfoKey">
|
||||
<English>Show Wind Info</English>
|
||||
<Polish>Pokaż inf. o wietrze</Polish>
|
||||
<Italian>Mostra indicazioni del vento</Italian>
|
||||
@ -10,8 +9,11 @@
|
||||
<French>Afficher les info sur le vent</French>
|
||||
<Spanish>Mostrar información del viento</Spanish>
|
||||
<German>Windinformationen anzeigen</German>
|
||||
<Hungarian>Széladatok mutatása</Hungarian>
|
||||
<Czech>Zobrazit informace o větru</Czech>
|
||||
<Portuguese>Mostrar Informação do Vento</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_AdvancedBallistics_ProtractorKey">
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_ProtractorKey">
|
||||
<English>Show Protractor</English>
|
||||
<Polish>Pokaż kątomierz</Polish>
|
||||
<Italian>Mostra il rapportatore</Italian>
|
||||
@ -19,6 +21,199 @@
|
||||
<French>Afficher le rapporteur</French>
|
||||
<Spanish>Mostrar transportador</Spanish>
|
||||
<German>Winkelmesser anzeigen</German>
|
||||
<Hungarian>Szögmérő mutatása</Hungarian>
|
||||
<Czech>Zobrazit úhloměr</Czech>
|
||||
<Portuguese>Mostrar Transferidor</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_DisplayName">
|
||||
<English>Advanced Ballistics</English>
|
||||
<Polish>Zaawansowana balistyka</Polish>
|
||||
<Spanish>Balística avanzada</Spanish>
|
||||
<German>Erweiterte Ballistik</German>
|
||||
<Czech>Pokročilá balistika</Czech>
|
||||
<Portuguese>Balística avançada</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_enabled_DisplayName">
|
||||
<English>Advanced Ballistics</English>
|
||||
<Polish>Zaawansowana balistyka</Polish>
|
||||
<Spanish>Balística avanzada</Spanish>
|
||||
<German>Erweiterte Ballistik</German>
|
||||
<Czech>Pokročilá balistika</Czech>
|
||||
<Portuguese>Balística avançada</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_enabled_Description">
|
||||
<English>Enables advanced ballistics</English>
|
||||
<Polish>Aktywuje zaawansowaną balistykę</Polish>
|
||||
<Spanish>Activa la balística avanzada</Spanish>
|
||||
<German>Aktiviert die erweiterte Ballistik</German>
|
||||
<Czech>Aktivuje pokročilou balistiku</Czech>
|
||||
<Portuguese>Ativa balística avançada</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForSnipers_DisplayName">
|
||||
<English>Enabled For Snipers</English>
|
||||
<Spanish>Activada para francotiradores</Spanish>
|
||||
<Polish>Akt. dla snajperów</Polish>
|
||||
<German>Für Scharfschützen aktiviert</German>
|
||||
<Czech>Povoleno pro odstřelovače</Czech>
|
||||
<Portuguese>Ativar para caçadores</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForSnipers_Description">
|
||||
<English>Enables advanced ballistics for non local snipers (when using high power optics)</English>
|
||||
<Spanish>Activa la balística avanzada para francotiradores no locales (cuando se usa una mira telescópica)</Spanish>
|
||||
<Polish>Aktywuje zaawansowaną balistykę dla nielokalnych snajperów (kiedy używają optyki)</Polish>
|
||||
<German>Aktiviert die erweiterte Ballistik für nicht lokale Scharfschützen (bei Benutzung von Optiken mit starker Vergrößerung)</German>
|
||||
<Czech>Aktivuje pokročilou balistiku pro nelokální odstřelovače (když používá výkonnou optiku)</Czech>
|
||||
<Portuguese>Ativa balística avançada para caçadores não locais (quando usando miras telescópicas)</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForGroupMembers_DisplayName">
|
||||
<English>Enabled For Group Members</English>
|
||||
<Spanish>Activada para miembros de grupo</Spanish>
|
||||
<Polish>Akt. dla czł. grupy</Polish>
|
||||
<German>Für Gruppenmitglieder aktiviert</German>
|
||||
<Czech>Povoleno pro členy skupiny</Czech>
|
||||
<Portuguese>Ativada para membros do grupo</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForGroupMembers_Description">
|
||||
<English>Enables advanced ballistics for non local group members</English>
|
||||
<Spanish>Activada la balística avanzada para miembros de grupo no locales</Spanish>
|
||||
<Polish>Aktywuje zaawansowaną balistykę dla nielokalnych członków grupy</Polish>
|
||||
<German>Aktiviert die erweiterte Ballistik für nicht lokale Gruppenmitglieder</German>
|
||||
<Czech>Aktivuje pokročilou balistiku pro nelokální členy skupiny</Czech>
|
||||
<Portuguese>Ativa balística avançada para membros de grupo não locais</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForEveryone_DisplayName">
|
||||
<English>Enabled For Everyone</English>
|
||||
<Spanish>Activada para todos</Spanish>
|
||||
<Polish>Akt. dla wszystkich</Polish>
|
||||
<German>Für jeden aktiviert</German>
|
||||
<Czech>Povoleno pro všechny</Czech>
|
||||
<Portuguese>Ativada para todos</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulateForEveryone_Description">
|
||||
<English>Enables advanced ballistics for all non local players (enabling this may degrade performance during heavy firefights in multiplayer)</English>
|
||||
<Spanish>Activada la balística avanzada para todos los jugadores no locales (activarlo puede degradar el rendimiento durante grandes tiroteos en multijugador).</Spanish>
|
||||
<Polish>Aktywuje zaawansowaną balistykę dla wszystkich nielokalnych graczy (aktywacja tej opcji może spodowować spory spadek wydajności podczas ciężkiej wymiany ognia)</Polish>
|
||||
<German>Aktiviert die erweiterte Ballistik für alle nicht lokalen Spieler (das Aktivieren dieser Funktion kann zur Beeinträchtigung des Spielerlebnisses im Multiplayer führen)</German>
|
||||
<Czech>Aktivovat pokročilou balistiku pro všechny nelokální hráče (aktivace této možnosti způsobuje pokles snímu za sekundu během těžké přestřelky v multiplayeru)</Czech>
|
||||
<Portuguese>Ativa balística avançada para todos os jogadores não locais (ativando isso pode degradar a performance durante troca de tiros intensas no multiplayer)</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_alwaysSimulateForGroupMembers_DisplayName">
|
||||
<English>Always Enabled For Group Members</English>
|
||||
<Polish>Zawsze akt. dla czł. grupy</Polish>
|
||||
<Spanish>Siempre activada para miembros de grupo</Spanish>
|
||||
<German>Für Gruppenmitglieder immer aktiviert</German>
|
||||
<Czech>Vždy povoleno pro členy skupiny</Czech>
|
||||
<Portuguese>Sempre ativada para membros do grupo</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_alwaysSimulateForGroupMembers_Description">
|
||||
<English>Always enables advanced ballistics when a group member fires</English>
|
||||
<Polish>Aktywuje zaawansowaną balistykę dla wszystkich członków grupy</Polish>
|
||||
<Spanish>Activada la balística avanzada siempre cuando miembros de grupo disparan</Spanish>
|
||||
<German>Aktiviert die erweiterte Ballistik immer, wenn ein Gruppenmitglied schießt</German>
|
||||
<Czech>Aktivuje pokročilou balistiku pro členy skupiny</Czech>
|
||||
<Portuguese>Sempre ative balística avançada quando um membro do grupo disparar</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_disabledInFullAutoMod_DisplayName">
|
||||
<English>Disabled In FullAuto Mode</English>
|
||||
<Polish>Wył. podczas ognia auto.</Polish>
|
||||
<Spanish>Desactivada en modo automático</Spanish>
|
||||
<German>Beim vollautomatischen Feuern deaktiviert</German>
|
||||
<Czech>Zakázáno v automatickém režimu střelby</Czech>
|
||||
<Portuguese>Desabilitar no modo automático</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_disabledInFullAutoMod_Description">
|
||||
<English>Disables the advanced ballistics during full auto fire</English>
|
||||
<Polish>Dezaktywuje zaawansowaną balistykę podczas ognia automatycznego</Polish>
|
||||
<Spanish>Desactivada la balística avanzada durante el fuego automático</Spanish>
|
||||
<German>Deaktiviert die erweiterte Ballistik beim vollautomatischen Feuern</German>
|
||||
<Czech>Zákáže pokročilou balistiku během střelby v režimu automat</Czech>
|
||||
<Portuguese>Desabilitar a balística avançada durante fogo automático</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_ammoTemperatureEnabled_DisplayName">
|
||||
<English>Enable Ammo Temperature Simulation</English>
|
||||
<Polish>Symulacja temp. amunicji</Polish>
|
||||
<Spanish>Activar simulación de temperatura de munición</Spanish>
|
||||
<German>Simulation der Munitionstemperatur aktivieren</German>
|
||||
<Czech>Povolit simulaci teploty munice</Czech>
|
||||
<Portuguese>Ativar simulação de temperatura de munição</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_ammoTemperatureEnabled_Description">
|
||||
<English>Muzzle velocity varies with ammo temperature</English>
|
||||
<Polish>Prędkość wylotowa pocisku jest zależna od temperatury amunicji</Polish>
|
||||
<Spanish>La velocidad de salida varía con la temperatura de la munición</Spanish>
|
||||
<German>Munitionstemperatur hat Einfluss auf die Mündungsgeschwindigkeit</German>
|
||||
<Czech>Úsťová rychlost je závislá na teplotě munice</Czech>
|
||||
<Portuguese>A velocidade de saída varia com a temperatura da munição</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_barrelLengthInfluenceEnabled_DisplayName">
|
||||
<English>Enable Barrel Length Simulation</English>
|
||||
<Polish>Symulacja długości lufy</Polish>
|
||||
<Spanish>Habilitar la simulación de longitud del cañón</Spanish>
|
||||
<German>Simulation der Lauflänge aktivieren</German>
|
||||
<Czech>Povolit simulaci délky hlavně</Czech>
|
||||
<Portuguese>Ativar a simulação de comprimento do cano</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_barrelLengthInfluenceEnabled_Description">
|
||||
<English>Muzzle velocity varies with barrel length</English>
|
||||
<Polish>Prędkość wylotowa pocisku jest zależna od długości lufy</Polish>
|
||||
<Spanish>La velocidad de salidal varía con la longitud del cañón</Spanish>
|
||||
<German>Lauflänge beeinflusst Mündungsgeschwindigkeit</German>
|
||||
<Czech>Úsťová rychlost je závislá na délce hlavně</Czech>
|
||||
<Portuguese>A velocidade de saída caria com o comprimento do cano</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_bulletTraceEnabled_DisplayName">
|
||||
<English>Enable Bullet Trace Effect</English>
|
||||
<Polish>Efekt smugi pocisku</Polish>
|
||||
<Spanish>Activar el efecto trazador de la bala</Spanish>
|
||||
<German>Geschossspureffekt aktivieren</German>
|
||||
<Czech>Povolit efekt trasírek</Czech>
|
||||
<Portuguese>Ativa efeito traçante de projétil</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_bulletTraceEnabled_Description">
|
||||
<English>Enables a bullet trace effect to high caliber bullets (only visible when looking through high power optics)</English>
|
||||
<Polish>Aktywuje efekt smugi pocisku dla pocisków wysokokalibrowych (widoczne tylko podczas patrzenia przez optykę)</Polish>
|
||||
<Spanish>Activa el efecto trazador de la balas de gran calibre (solo visible cuando se mira a través de una mira telescópica)</Spanish>
|
||||
<German>Aktiviere Geschossspureffekt für hohe Kaliber (bei Benutzung von Optiken mit starker Vergrößerung)</German>
|
||||
<Czech>Aktivuje efekt trasírek z vysokokaliberních zbraní (viditelné pouze skrze výkonnou optiku)</Czech>
|
||||
<Portuguese>Ativa o efeito traçante de projétil para projéteis de alto calibre (somente visível quando observado por miras telescópicas)</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulationInterval_DisplayName">
|
||||
<English>Simulation Interval</English>
|
||||
<Polish>Interwał symulacji</Polish>
|
||||
<Spanish>Intervalo de simulación</Spanish>
|
||||
<German>Simulationsintervall</German>
|
||||
<Czech>Interval simulace</Czech>
|
||||
<Portuguese>Intervalo da simulação</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulationInterval_Description">
|
||||
<English>Defines the interval between every calculation step</English>
|
||||
<Polish>Określa interwał pomiędzy każdym krokiem kalkulacji</Polish>
|
||||
<Spanish>Define el intervalo entre cada cálculo</Spanish>
|
||||
<German>Legt das Intervall zwischen den Berechnungsschritten fest</German>
|
||||
<Czech>Určuje interval mezi každým výpočtem</Czech>
|
||||
<Portuguese>Define o intervalo entre cada cálculo</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulationRadius_DisplayName">
|
||||
<English>Simulation Radius</English>
|
||||
<Polish>Zasięg symulacji</Polish>
|
||||
<Spanish>Radio de simulación</Spanish>
|
||||
<German>Simulationsradius</German>
|
||||
<Czech>Rozsah simulace</Czech>
|
||||
<Portuguese>Raio de simulação</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_simulationRadius_Description">
|
||||
<English>Defines the radius around the player (in meters) at which advanced ballistics are applied to projectiles</English>
|
||||
<Polish>Określa obszar naokoło gracza (w metrach), na którym zaawansowana balistyka jest aplikowana dla pocisków</Polish>
|
||||
<Spanish>Define el radio alrededor del jugador (en metros) en el cual se aplica la balística avanzada a los proyectiles</Spanish>
|
||||
<German>Gibt den Radius (in Metern) um den Spieler an, bei dem die erweiterte Ballistik auf Geschosse angewendet wird</German>
|
||||
<Czech>Určuje oblast kolem hráče (v metrech), kde je pokročilá balistika použita na projektil</Czech>
|
||||
<Portuguese>Define o raio ao redor do jogador (em metros) onde a balística avançada será aplicada aos projéteis</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Advanced_Ballistics_Description">
|
||||
<English></English>
|
||||
<Polish>Moduł ten pozwala aktywować zaawansowaną balistykę biorącą przy obliczeniach trajektorii lotu pocisku pod uwagę takie rzeczy jak temperatura powietrza, ciśnienie atmosferyczne, wilgotność powietrza, siły Coriolisa i Eotvosa, grawitację a także broń z jakiej wykonywany jest strzał oraz rodzaj amunicji. Wszystko to sprowadza się na bardzo dokładne odwzorowanie balistyki.</Polish>
|
||||
<Czech>Tento modul umožňuje aktivovat pokročilou balistiku, která vypočítává trajektorii kulky a bere do úvahy věci jako je teplota vzduchu, atmosférický tlak, vlhkost vzduchu, gravitaci, typ munice a zbraň, ze které je náboj vystřelen. To vše přispívá k velmi přesné balistice.</Czech>
|
||||
<Portuguese>Este módulo permite que você ative cálculos de balística avançada, fazendo a trajetória do projétil levar em consideração coisas como temperatura do ar, pressão atmosférica, umidade, força de Coriolis, a gravidade, o modelo da arma no qual o disparo é realizado e o tipo de munição. Tudo isso acrescenta-se a um balística muito precisa.</Portuguese>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
@ -21,7 +21,8 @@ class CfgAISkill {
|
||||
courage[] = {0,0, 1,0.7}; // {0,0,1,1};
|
||||
endurance[] = {0,0, 1,0.7}; // {0,0,1,1};
|
||||
general[] = {0,0, 1,0.9}; // {0,0,1,1};
|
||||
reloadSpeed[] = {0,0, 1,0.8}; // {0,0,1,1};
|
||||
// apparently breaks rapid firing in single fire mode for players
|
||||
//reloadSpeed[] = {0,0, 1,0.8}; // {0,0,1,1};
|
||||
spotDistance[] = {0,0, 1,0.9}; // {0,0.2,1,0.4};
|
||||
spotTime[] = {0,0, 1,0.7}; // {0,0,1,0.7};
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
#define COMPONENT ai
|
||||
#include "\z\ace\Addons\main\script_mod.hpp"
|
||||
#include "\z\ace\addons\main\script_mod.hpp"
|
||||
|
||||
#ifdef DEBUG_ENABLED_AI
|
||||
#define DEBUG_MODE_FULL
|
||||
@ -9,4 +9,4 @@
|
||||
#define DEBUG_SETTINGS DEBUG_SETTINGS_AI
|
||||
#endif
|
||||
|
||||
#include "\z\ace\Addons\main\script_macros.hpp"
|
||||
#include "\z\ace\addons\main\script_macros.hpp"
|
@ -176,8 +176,8 @@ class CfgVehicles {
|
||||
};
|
||||
class CargoRamp_Open: DoorL1_Open {
|
||||
userActionID = 52;
|
||||
displayName = "$STR_ACE_Aircraft_OpenCargoRamp";
|
||||
textToolTip = "$STR_ACE_Aircraft_OpenCargoRamp";
|
||||
displayName = CSTRING(OpenCargoRamp);
|
||||
textToolTip = CSTRING(OpenCargoRamp);
|
||||
position = "action_cargoramp";
|
||||
radius = 3.0;
|
||||
condition = "this animationPhase ""cargoramp_open"" < 0.5 AND Alive(this)";
|
||||
@ -185,8 +185,8 @@ class CfgVehicles {
|
||||
};
|
||||
class CargoRamp_Close: DoorL1_Close {
|
||||
userActionID = 55;
|
||||
displayName = "$STR_ACE_Aircraft_CloseCargoRamp";
|
||||
textToolTip = "$STR_ACE_Aircraft_CloseCargoRamp";
|
||||
displayName = CSTRING(CloseCargoRamp);
|
||||
textToolTip = CSTRING(CloseCargoRamp);
|
||||
position = "action_cargoramp";
|
||||
radius = 3.0;
|
||||
condition = "this animationPhase ""cargoramp_open"" > 0.5 AND Alive(this)";
|
||||
|
@ -29,7 +29,7 @@ class CfgWeapons {
|
||||
reloadTime = 0.1;
|
||||
};
|
||||
class Burst: Mode_Burst {
|
||||
displayName = "$STR_ACE_Aircraft_CMFlareLauncher_Burst_Name";
|
||||
displayName = CSTRING(CMFlareLauncher_Burst_Name);
|
||||
};
|
||||
};
|
||||
|
||||
@ -50,12 +50,12 @@ class CfgWeapons {
|
||||
};
|
||||
|
||||
class ACE_gatling_20mm_Comanche: gatling_20mm {
|
||||
displayName = "$STR_ACE_Aircraft_gatling_20mm_Name";
|
||||
displayName = CSTRING(gatling_20mm_Name);
|
||||
|
||||
class manual: manual {
|
||||
reloadTime = 0.04;
|
||||
dispersion = 0.006;
|
||||
displayName = "$STR_ACE_Aircraft_gatling_20mm_Name";
|
||||
displayName = CSTRING(gatling_20mm_Name);
|
||||
};
|
||||
class close: close {
|
||||
reloadTime = 0.04;
|
||||
|
@ -891,9 +891,12 @@ class Heli_Attack_01_base_F: Helicopter_Base_F {
|
||||
|
||||
class OpticsIn
|
||||
{
|
||||
class WideUnstabalized
|
||||
{
|
||||
opticsDisplayName = "WU";
|
||||
delete Narrow;
|
||||
delete Medium;
|
||||
delete Wide;
|
||||
|
||||
class ACE_WideUnstabilized {
|
||||
opticsDisplayName = "W NS";
|
||||
initAngleX = 0;
|
||||
minAngleX = -35;
|
||||
maxAngleX = 10;
|
||||
@ -910,8 +913,7 @@ class Heli_Attack_01_base_F: Helicopter_Base_F {
|
||||
horizontallyStabilized = 1;
|
||||
gunnerOpticsModel = "\A3\Weapons_F_Beta\Reticle\Heli_Attack_01_Optics_Gunner_wide_F";
|
||||
};
|
||||
class Wide
|
||||
{
|
||||
class ACE_Wide: ACE_WideUnstabilized {
|
||||
opticsDisplayName = "W";
|
||||
initAngleX = 0;
|
||||
minAngleX = -35;
|
||||
@ -929,8 +931,7 @@ class Heli_Attack_01_base_F: Helicopter_Base_F {
|
||||
horizontallyStabilized = 1;
|
||||
gunnerOpticsModel = "\A3\Weapons_F_Beta\Reticle\Heli_Attack_01_Optics_Gunner_wide_F";
|
||||
};
|
||||
class Medium: Wide
|
||||
{
|
||||
class ACE_Medium: ACE_Wide {
|
||||
opticsDisplayName = "M";
|
||||
initFov = 0.093;
|
||||
minFov = 0.093;
|
||||
@ -940,8 +941,7 @@ class Heli_Attack_01_base_F: Helicopter_Base_F {
|
||||
horizontallyStabilized = 1;
|
||||
gunnerOpticsModel = "\A3\Weapons_F_Beta\Reticle\Heli_Attack_01_Optics_Gunner_medium_F";
|
||||
};
|
||||
class Narrow: Wide
|
||||
{
|
||||
class ACE_Narrow: ACE_Wide {
|
||||
opticsDisplayName = "N";
|
||||
initFov = 0.029;
|
||||
minFov = 0.029;
|
||||
@ -952,8 +952,7 @@ class Heli_Attack_01_base_F: Helicopter_Base_F {
|
||||
gunnerOpticsModel = "\A3\Weapons_F_Beta\Reticle\Heli_Attack_01_Optics_Gunner_narrow_F";
|
||||
|
||||
};
|
||||
class Narrower: Wide
|
||||
{
|
||||
class ACE_Narrower: ACE_Wide {
|
||||
opticsDisplayName = "Z";
|
||||
initFov = 0.01;
|
||||
minFov = 0.01;
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
class CfgPatches {
|
||||
class ADDON {
|
||||
units[] = {"ACE_Comanche_Test"};
|
||||
units[] = {};
|
||||
weapons[] = {};
|
||||
requiredVersion = REQUIRED_VERSION;
|
||||
requiredAddons[] = {"ace_common"};
|
||||
|
@ -29,23 +29,25 @@
|
||||
<English>Open Cargo Door</English>
|
||||
<German>Laderampe öffnen</German>
|
||||
<Spanish>Abrir compuerta de carga</Spanish>
|
||||
<French>Ourvir rampe cargo</French>
|
||||
<French>Ourvir la rampe</French>
|
||||
<Polish>Otwórz drzwi ładowni</Polish>
|
||||
<Czech>Otevřít nákladní prostor</Czech>
|
||||
<Hungarian>Rakodórámpa nyitása</Hungarian>
|
||||
<Russian>Открыть грузовой отсек</Russian>
|
||||
<Italian>Apri la porta del cargo</Italian>
|
||||
<Italian>Apri la rampa di carico</Italian>
|
||||
<Portuguese>Abrir porta de carga</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_Aircraft_CloseCargoRamp">
|
||||
<English>Close Cargo Door</English>
|
||||
<German>Laderampe schließen</German>
|
||||
<Spanish>Cerrar compuerta de carga</Spanish>
|
||||
<French>Fermer rampe cargo</French>
|
||||
<French>Fermer la rampe</French>
|
||||
<Polish>Zamknij drzwi ładowni</Polish>
|
||||
<Czech>Zavřít nákladní prostor</Czech>
|
||||
<Hungarian>Rakodórámpa zárása</Hungarian>
|
||||
<Russian>Закрыть грузовой отсек</Russian>
|
||||
<Italian>Chiudi la porta del cargo</Italian>
|
||||
<Italian>Chiudi la rampa di carico</Italian>
|
||||
<Portuguese>Fechar porta de carga</Portuguese>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
||||
|
1
addons/apl/$PBOPREFIX$
Normal file
1
addons/apl/$PBOPREFIX$
Normal file
@ -0,0 +1 @@
|
||||
z\ace\addons\apl
|
7
addons/apl/CfgEventHandlers.hpp
Normal file
7
addons/apl/CfgEventHandlers.hpp
Normal file
@ -0,0 +1,7 @@
|
||||
/*
|
||||
class Extended_PreInit_EventHandlers {
|
||||
class ADDON {
|
||||
init = QUOTE(call COMPILE_FILE(XEH_preInit));
|
||||
};
|
||||
};
|
||||
*/
|
110
addons/apl/LICENSE
Normal file
110
addons/apl/LICENSE
Normal file
@ -0,0 +1,110 @@
|
||||
ARMA PUBLIC LICENSE
|
||||
https://www.bistudio.com/community/licenses/arma-public-license
|
||||
|
||||
Brief summary of this Licence
|
||||
|
||||
PLEASE, NOTE THAT THIS SUMMARY HAS NO LEGAL EFFECT AND IS ONLY OF AN INFORMATORY NATURE DESIGNED FOR YOU TO GET THE BASIC INFORMATION ABOUT THE CONTENT OF THIS LICENCE. THE ONLY LEGALLY BINDING PROVISIONS ARE THOSE IN THE ORIGINAL AND FULL TEXT OF THIS LICENCE.
|
||||
|
||||
With this licence you are free to adapt (i.e. modify, rework or update) and share (i.e. copy, distribute or transmit) the material under the following conditions:
|
||||
|
||||
Attribution - You must attribute the material in the manner specified by the author or licensor (but not in any way that suggests that they endorse you or your use of the material).
|
||||
Noncommercial - You may not use this material for any commercial purposes.
|
||||
Arma Only - You may not convert or adapt this material to be used in other games than Arma.
|
||||
|
||||
By exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Arma Public License ("Public License"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions.
|
||||
|
||||
Section 1 - Definitions
|
||||
|
||||
Adapted Material means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image.
|
||||
Adapter's License means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License.
|
||||
ArmaOnly means primarily intended for or directed towards the use in any of existing and future Arma games, including but not limited to Arma: Cold War Assault, Arma, Arma 2 and Arma 3 and its official sequels and expansion packs.
|
||||
Copyright and Similar Rights means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights.
|
||||
Effective Technological Measures means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements.
|
||||
Exceptions and Limitations means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material.
|
||||
Licensed Material means the artistic or literary work, database, or other material to which the Licensor applied this Public License.
|
||||
Licensed Rights means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license.
|
||||
Licensor means the individual(s) or entity(ies) granting rights under this Public License.
|
||||
NonCommercial means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange.
|
||||
Share means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them.
|
||||
Sui Generis Database Rights means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world.
|
||||
You means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning.
|
||||
|
||||
Section 2 – Scope
|
||||
|
||||
License grant
|
||||
Subject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to:
|
||||
reproduce and Share the Licensed Material, in whole or in part, for NonCommercial and ArmaOnly purposes only; and
|
||||
produce, reproduce, and Share Adapted Material for NonCommercial and ArmaOnly purposes only.
|
||||
Exceptions and Limitations. For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions.
|
||||
Term. The term of this Public License is specified in Section 6(a).
|
||||
Media and formats; technical modifications allowed. The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material.
|
||||
Downstream recipients.
|
||||
Offer from the Licensor – Licensed Material. Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License.
|
||||
No downstream restrictions. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material.
|
||||
No endorsement. Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(a)(i).
|
||||
Other rights
|
||||
Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise.
|
||||
Patent and trademark rights are not licensed under this Public License.
|
||||
To the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial and ArmaOnly purposes.
|
||||
|
||||
Section 3 – License Conditions
|
||||
|
||||
Your exercise of the Licensed Rights is expressly made subject to the following conditions.
|
||||
|
||||
Attribution
|
||||
|
||||
If You Share the Licensed Material (including in modified form), You must:
|
||||
retain the following if it is supplied by the Licensor with the Licensed Material:
|
||||
identification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated);
|
||||
a copyright notice;
|
||||
a notice that refers to this Public License;
|
||||
a notice that refers to the disclaimer of warranties;
|
||||
a URI or hyperlink to the Licensed Material to the extent reasonably practicable;
|
||||
indicate if You modified the Licensed Material and retain an indication of any previous modifications; and
|
||||
indicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License.
|
||||
You may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information.
|
||||
If requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(a) to the extent reasonably practicable.
|
||||
If You Share Adapted Material You produce, the Adapter’s License You apply must not prevent recipients of the Adapted Material from complying with this Public License.
|
||||
|
||||
Section 4 – Sui Generis Database Rights
|
||||
|
||||
Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material:
|
||||
|
||||
for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial and ArmaOnly purposes only;
|
||||
if You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material; and
|
||||
You must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database.
|
||||
|
||||
Section 5 – Disclaimer of Warranties and Limitation of Liability
|
||||
|
||||
Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.
|
||||
To the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.
|
||||
The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability.
|
||||
|
||||
Section 6 – Term and Termination
|
||||
|
||||
This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically.
|
||||
|
||||
Where Your right to use the Licensed Material has terminated under Section 6(a), it reinstates:
|
||||
automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or
|
||||
upon express reinstatement by the Licensor.
|
||||
|
||||
For the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License.
|
||||
For the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License.
|
||||
Sections 1, 5, 6, 7, and 8 survive termination of this Public License.
|
||||
|
||||
Section 7 – Other Terms and Conditions
|
||||
|
||||
The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed.
|
||||
Any arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License.
|
||||
|
||||
Section 8 – Interpretation
|
||||
|
||||
For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License.
|
||||
To the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions.
|
||||
No term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor.
|
||||
Nothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority.
|
||||
|
||||
Bohemia Interactive Notices
|
||||
|
||||
Bohemia Interactive a.s. is not a party to this License, and makes no warranty whatsoever in connection with the Licensed Material. Bohemia Interactive a.s. will not be liable to You or any party on any legal theory for any damages whatsoever, including without limitation any general, special, incidental or consequential damages arising in connection to this license. Notwithstanding the foregoing two (2) sentences, Bohemia Interactive a.s. may elect to apply the Public License to material it publishes and in those instances it becomes the "Licensor".
|
||||
Except for the limited purpose of indicating to the public that the Licensed Material is shared under this Public License, Bohemia Interactive a.s. does not authorize the use by either party of the trademarks "Arma", "Bohemia Interactive" or any related trademark or logo of Arma or Bohemia Interactive without the prior written consent of Bohemia Interactive a.s.
|
BIN
addons/apl/LWTS_optic.p3d
Normal file
BIN
addons/apl/LWTS_optic.p3d
Normal file
Binary file not shown.
5
addons/apl/XEH_preInit.sqf
Normal file
5
addons/apl/XEH_preInit.sqf
Normal file
@ -0,0 +1,5 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
ADDON = false;
|
||||
|
||||
ADDON = true;
|
BIN
addons/apl/bodybag.p3d
Normal file
BIN
addons/apl/bodybag.p3d
Normal file
Binary file not shown.
15
addons/apl/config.cpp
Normal file
15
addons/apl/config.cpp
Normal file
@ -0,0 +1,15 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
class CfgPatches {
|
||||
class ADDON {
|
||||
units[] = {};
|
||||
weapons[] = {};
|
||||
requiredVersion = REQUIRED_VERSION;
|
||||
requiredAddons[] = {"ace_main"};
|
||||
author[] = {"Bohemia Interactive"};
|
||||
authorUrl = "http://ace3mod.com";
|
||||
VERSION_CONFIG;
|
||||
};
|
||||
};
|
||||
|
||||
#include "CfgEventHandlers.hpp"
|
79
addons/apl/data/Jezek_kov.rvmat
Normal file
79
addons/apl/data/Jezek_kov.rvmat
Normal file
@ -0,0 +1,79 @@
|
||||
ambient[]={1.000000,1.000000,1.000000,1.000000};
|
||||
diffuse[]={1.000000,1.000000,1.000000,1.000000};
|
||||
forcedDiffuse[]={0.000000,0.000000,0.000000,0.000000};
|
||||
emmisive[]={0.000000,0.000000,0.000000,1.000000};
|
||||
specular[]={1.000000,1.000000,1.000000,1.000000};
|
||||
specularPower=83.900002;
|
||||
PixelShaderID="Super";
|
||||
VertexShaderID="Super";
|
||||
class Stage1 {
|
||||
texture="z\ace\addons\apl\data\jezek_texture_NOHQ.tga";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage2 {
|
||||
texture="#(argb,8,8,3)color(0.5,0.5,0.5,1,DT)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage3 {
|
||||
texture="#(argb,8,8,3)color(0,0,0,0,MC)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage4 {
|
||||
texture="#(argb,8,8,3)color(1,1,1,1,AS)";
|
||||
uvSource="tex";
|
||||
class uvTransform
|
||||
{
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage5 {
|
||||
texture="z\ace\addons\apl\data\jezek_texture_SMDI.tga";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage6 {
|
||||
texture="#(ai,32,128,1)fresnel(1.85,0.64)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage7 {
|
||||
texture="a3\data_f\env_land_co.paa";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
BIN
addons/apl/data/barbwire_a_co.paa
Normal file
BIN
addons/apl/data/barbwire_a_co.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/barbwire_a_nohq.paa
Normal file
BIN
addons/apl/data/barbwire_a_nohq.paa
Normal file
Binary file not shown.
78
addons/apl/data/barbwire_a_ns.rvmat
Normal file
78
addons/apl/data/barbwire_a_ns.rvmat
Normal file
@ -0,0 +1,78 @@
|
||||
ambient[]={1.000000,1.000000,1.000000,1.000000};
|
||||
diffuse[]={1.000000,1.000000,1.000000,1.000000};
|
||||
forcedDiffuse[]={0.000000,0.000000,0.000000,0.000000};
|
||||
emmisive[]={0.000000,0.000000,0.000000,1.000000};
|
||||
specular[]={1.000000,1.000000,1.000000,0.000000};
|
||||
specularPower=16.000000;
|
||||
PixelShaderID="Super";
|
||||
VertexShaderID="Super";
|
||||
class Stage1 {
|
||||
texture="z\ace\addons\apl\data\BarbWire_A_NOHQ.tga";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage2 {
|
||||
texture="#(argb,8,8,3)color(0.5,0.5,0.5,1,DT)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage3 {
|
||||
texture="#(argb,8,8,3)color(0,0,0,0,MC)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage4 {
|
||||
texture="#(argb,8,8,3)color(1,1,1,1,AS)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage5 {
|
||||
texture="#(argb,8,8,3)color(0,0,1,1,SMDI)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage6 {
|
||||
texture="#(ai,32,128,1)fresnel(0.01,0.01)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
||||
class Stage7 {
|
||||
texture="#(argb,8,8,3)color(0,0,0,1,CO)";
|
||||
uvSource="tex";
|
||||
class uvTransform {
|
||||
aside[]={1.000000,0.000000,0.000000};
|
||||
up[]={0.000000,1.000000,0.000000};
|
||||
dir[]={0.000000,0.000000,0.000000};
|
||||
pos[]={0.000000,0.000000,0.000000};
|
||||
};
|
||||
};
|
@ -8,7 +8,7 @@ PixelShaderID="Super";
|
||||
VertexShaderID="Super";
|
||||
class Stage1
|
||||
{
|
||||
texture="z\ace\addons\medical\data\bodybag_nohq.paa";
|
||||
texture="z\ace\addons\apl\data\bodybag_nohq.paa";
|
||||
uvSource="tex";
|
||||
class uvTransform
|
||||
{
|
||||
@ -80,7 +80,7 @@ class Stage6
|
||||
};
|
||||
class Stage7
|
||||
{
|
||||
texture="z\ace\addons\medical\data\env_co.paa";
|
||||
texture="z\ace\addons\apl\data\env_co.paa";
|
||||
uvSource="tex";
|
||||
class uvTransform
|
||||
{
|
8
addons/apl/data/default.rvmat
Normal file
8
addons/apl/data/default.rvmat
Normal file
@ -0,0 +1,8 @@
|
||||
ambient[]={1,1,1,1};
|
||||
diffuse[]={1,1,1,1};
|
||||
forcedDiffuse[]={0,0,0,0};
|
||||
emmisive[]={0,0,0,1};
|
||||
specular[]={0,0,0,0};
|
||||
specularPower=0;
|
||||
PixelShaderID="Normal";
|
||||
VertexShaderID="Basic";
|
BIN
addons/apl/data/default_vehicle_ti_ca.paa
Normal file
BIN
addons/apl/data/default_vehicle_ti_ca.paa
Normal file
Binary file not shown.
10
addons/apl/data/glass_House.bisurf
Normal file
10
addons/apl/data/glass_House.bisurf
Normal file
@ -0,0 +1,10 @@
|
||||
Density=2400;
|
||||
rough=0;
|
||||
dust=0;
|
||||
bulletPenetrability=50;
|
||||
soundEnviron=Empty;
|
||||
isWater=false;
|
||||
friction=0.1;
|
||||
restitution=0.1;
|
||||
impact = Hit_Glass;
|
||||
soundHit = glass;
|
1
addons/apl/data/glass_house.rvmat
Normal file
1
addons/apl/data/glass_house.rvmat
Normal file
@ -0,0 +1 @@
|
||||
surfaceInfo="z\ace\addons\apl\data\glass_House.bisurf";
|
BIN
addons/apl/data/jezek_texture_co.paa
Normal file
BIN
addons/apl/data/jezek_texture_co.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/jezek_texture_nohq.paa
Normal file
BIN
addons/apl/data/jezek_texture_nohq.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/jezek_texture_smdi.paa
Normal file
BIN
addons/apl/data/jezek_texture_smdi.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/metal4_weapons_vehicles_int_512_dt.paa
Normal file
BIN
addons/apl/data/metal4_weapons_vehicles_int_512_dt.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/optics_bg_blurred_round_ca.paa
Normal file
BIN
addons/apl/data/optics_bg_blurred_round_ca.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/optics_bg_square_ca.paa
Normal file
BIN
addons/apl/data/optics_bg_square_ca.paa
Normal file
Binary file not shown.
10
addons/apl/data/plastic.bisurf
Normal file
10
addons/apl/data/plastic.bisurf
Normal file
@ -0,0 +1,10 @@
|
||||
Density=1380;
|
||||
rough=0.1;
|
||||
dust=0;
|
||||
bulletPenetrability=150;
|
||||
soundEnviron=Empty;
|
||||
isWater=false;
|
||||
friction=0.7;
|
||||
restitution=0.3;
|
||||
impact = default_Mat;
|
||||
soundHit = plastic;
|
4
addons/apl/data/plastic.rvmat
Normal file
4
addons/apl/data/plastic.rvmat
Normal file
@ -0,0 +1,4 @@
|
||||
surfaceInfo="z\ace\addons\apl\data\plastic.bisurf";
|
||||
|
||||
diffuse[]={0.5,0.5,1.0,1.000000};
|
||||
ambient[]={0.5,0.5,1.0,1.000000};
|
BIN
addons/apl/data/plastic_512_dt.paa
Normal file
BIN
addons/apl/data/plastic_512_dt.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/plech.paa
Normal file
BIN
addons/apl/data/plech.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/twis_m16_ca.paa
Normal file
BIN
addons/apl/data/twis_m16_ca.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/vehicle_destr1024_1024_mc.paa
Normal file
BIN
addons/apl/data/vehicle_destr1024_1024_mc.paa
Normal file
Binary file not shown.
BIN
addons/apl/data/vehicle_destr1024_1024_smdi.paa
Normal file
BIN
addons/apl/data/vehicle_destr1024_1024_smdi.paa
Normal file
Binary file not shown.
1
addons/apl/functions/script_component.hpp
Normal file
1
addons/apl/functions/script_component.hpp
Normal file
@ -0,0 +1 @@
|
||||
#include "\z\ace\addons\apl\script_component.hpp"
|
12
addons/apl/script_component.hpp
Normal file
12
addons/apl/script_component.hpp
Normal file
@ -0,0 +1,12 @@
|
||||
#define COMPONENT APL
|
||||
#include "\z\ace\addons\main\script_mod.hpp"
|
||||
|
||||
#ifdef DEBUG_ENABLED_APL
|
||||
#define DEBUG_MODE_FULL
|
||||
#endif
|
||||
|
||||
#ifdef DEBUG_SETTINGS_APL
|
||||
#define DEBUG_SETTINGS DEBUG_SETTINGS_APL
|
||||
#endif
|
||||
|
||||
#include "\z\ace\addons\main\script_macros.hpp"
|
BIN
addons/apl/sounds/padak_let.wss
Normal file
BIN
addons/apl/sounds/padak_let.wss
Normal file
Binary file not shown.
1
addons/atragmx/$PBOPREFIX$
Normal file
1
addons/atragmx/$PBOPREFIX$
Normal file
@ -0,0 +1 @@
|
||||
z\ace\addons\atragmx
|
@ -4,13 +4,13 @@ class CfgVehicles {
|
||||
class ACE_SelfActions {
|
||||
class ACE_Equipment {
|
||||
class GVAR(open) {
|
||||
displayName = "$STR_ACE_ATragMX_OpenATragMXDialog";
|
||||
displayName = CSTRING(OpenATragMXDialog);
|
||||
condition = QUOTE(call FUNC(can_show));
|
||||
statement = QUOTE(call FUNC(create_dialog));
|
||||
showDisabled = 0;
|
||||
priority = 2;
|
||||
icon = PATHTOF(UI\ATRAG_Icon.paa);
|
||||
exceptions[] = {"notOnMap", "isNotInside"};
|
||||
exceptions[] = {"notOnMap", "isNotInside", "isNotSitting"};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
@ -6,8 +6,8 @@ class CfgWeapons {
|
||||
class ACE_ATragMX: ACE_ItemCore {
|
||||
author = "Ruthberg";
|
||||
scope = 2;
|
||||
displayName = "$STR_ACE_ATragMX_Name";
|
||||
descriptionShort = "$STR_ACE_ATragMX_Description";
|
||||
displayName = CSTRING(Name);
|
||||
descriptionShort = CSTRING(Description);
|
||||
model = PATHTOF(data\tdsrecon.p3d);
|
||||
picture = PATHTOF(UI\ATRAG_Icon.paa);
|
||||
icon = "iconObject_circle";
|
||||
|
@ -142,6 +142,7 @@ class ATragMX_Display {
|
||||
name="ATragMX_Display";
|
||||
idd=-1;
|
||||
onLoad="uiNamespace setVariable ['ATragMX_Display', (_this select 0)]";
|
||||
onUnload=QUOTE(_this call FUNC(on_close_dialog));
|
||||
movingEnable=1;
|
||||
controlsBackground[]={};
|
||||
objects[]={};
|
||||
@ -151,7 +152,7 @@ class ATragMX_Display {
|
||||
type=0;
|
||||
font="TahomaB";
|
||||
SizeEX=0.025;
|
||||
idc=-1;
|
||||
idc=720000;
|
||||
style=48;
|
||||
x=0.55*safezoneW+safezoneX-0.256;
|
||||
y=0.265*safezoneH+safezoneY-0.1;
|
||||
@ -159,7 +160,7 @@ class ATragMX_Display {
|
||||
h=1.024*4/3;
|
||||
colorBackground[]={1,1,1,1};
|
||||
colorText[]={1,1,1,1};
|
||||
text=PATHTOF(UI\atrag.paa);
|
||||
text=PATHTOF(UI\atrag_d.paa);
|
||||
};
|
||||
class POWER: ATragMX_RscButton {
|
||||
idc=-1;
|
||||
@ -760,7 +761,7 @@ class ATragMX_Display {
|
||||
y=0.265*safezoneH+safezoneY+0.35;
|
||||
strings[]={"Height","Width"};
|
||||
values[]={1,0};
|
||||
onToolBoxSelChanged="GVAR(rangeAssistUseTargetHeight)=((_this select 1)==0)";
|
||||
onToolBoxSelChanged=QUOTE(GVAR(rangeAssistUseTargetHeight) = ((_this select 1) == 0));
|
||||
};
|
||||
class TEXT_TARGET_RANGE_ASSIST_TARGET_SIZE: TEXT_TARGET_RANGE_ASSIST_MEASUREMENT_METHOD {
|
||||
idc=7003;
|
||||
|
BIN
addons/atragmx/UI/ATRAG_N.paa
Normal file
BIN
addons/atragmx/UI/ATRAG_N.paa
Normal file
Binary file not shown.
@ -6,39 +6,41 @@ if ((profileNamespace getVariable ["ACE_ATragMX_profileNamespaceVersion", 0]) ==
|
||||
GVAR(gunList) = profileNamespace getVariable "ACE_ATragMX_gunList";
|
||||
} else {
|
||||
// Profile Name, Muzzle Velocity, Zero Range, Scope Base Angle, AirFriction, Bore Height, Scope Unit, Scope Click Unit, Scope Click Number, Maximum Elevation, Dialed Elevation, Dialed Windage, Mass, Bullet Diameter, Rifle Twist, BC, Drag Model, Atmosphere Model
|
||||
GVAR(gunList) = [["12.7x108mm" , 820, 100, 0.0657, -0.0006400, 3.81, 0, 2, 10, 120, 0, 0, 48.28, 12.7, 38.10, 0.630, 1, "ASM" ],
|
||||
GVAR(gunList) = [["12.7x108mm" , 820, 100, 0.0657485, -0.00063800, 3.81, 0, 2, 10, 120, 0, 0, 48.28, 12.7, 38.10, 0.630, 1, "ASM" ],
|
||||
|
||||
["12.7x99mm AMAX" , 860, 100, 0.0612, -0.0003740, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 38.10, 1.050, 1, "ASM" ],
|
||||
["12.7x99mm" , 900, 100, 0.0623, -0.0006000, 3.81, 0, 2, 10, 120, 0, 0, 41.92, 12.7, 38.10, 0.670, 1, "ASM" ],
|
||||
["12.7x99mm AMAX" , 860, 100, 0.0611565, -0.00036645, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 38.10, 1.050, 1, "ASM" ],
|
||||
["12.7x99mm" , 900, 100, 0.0582418, -0.00057503, 3.81, 0, 2, 10, 120, 0, 0, 41.92, 12.7, 38.10, 0.670, 1, "ASM" ],
|
||||
|
||||
["12.7x54mm" , 300, 100, 0.3395, -0.0001400, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 24.13, 1.050, 1, "ASM" ],
|
||||
["12.7x54mm" , 300, 100, 0.3394630, -0.00019268, 3.81, 0, 2, 10, 120, 0, 0, 48.60, 12.7, 24.13, 1.050, 1, "ASM" ],
|
||||
|
||||
[".408 Chey Tac" , 910, 100, 0.0571, -0.0003950, 3.81, 0, 2, 10, 120, 0, 0, 27.15, 10.4, 33.02, 0.970, 1, "ASM" ],
|
||||
[".408 Chey Tac" , 910, 100, 0.0569400, -0.00038944, 3.81, 0, 2, 10, 120, 0, 0, 27.15, 10.4, 33.02, 0.970, 1, "ASM" ],
|
||||
|
||||
["9.3×64mm" , 870, 100, 0.0619, -0.0010600, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 9.30, 35.56, 0.368, 1, "ASM" ],
|
||||
["9.3×64mm" , 870, 100, 0.0619295, -0.00108571, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 9.30, 35.56, 0.368, 1, "ASM" ],
|
||||
|
||||
[".338LM 250gr" , 880, 100, 0.0598, -0.0006060, 3.81, 0, 2, 10, 120, 0, 0, 16.20, 8.58, 25.40, 0.322, 7, "ICAO"],
|
||||
[".338LM 300gr" , 800, 100, 0.0677, -0.0005350, 3.81, 0, 2, 10, 120, 0, 0, 19.44, 8.58, 25.40, 0.381, 7, "ICAO"],
|
||||
[".338LM API526" , 880, 100, 0.0601, -0.0006730, 3.81, 0, 2, 10, 120, 0, 0, 16.39, 8.58, 25.40, 0.290, 7, "ICAO"],
|
||||
[".338LM 250gr" , 880, 100, 0.0598469, -0.00059133, 3.81, 0, 2, 10, 120, 0, 0, 16.20, 8.58, 25.40, 0.322, 7, "ICAO"],
|
||||
[".338LM 300gr" , 800, 100, 0.0677343, -0.00052190, 3.81, 0, 2, 10, 120, 0, 0, 19.44, 8.58, 25.40, 0.381, 7, "ICAO"],
|
||||
[".338LM API526" , 895, 100, 0.0588865, -0.00069611, 3.81, 0, 2, 10, 120, 0, 0, 16.39, 8.58, 25.40, 0.560, 1, "ASM" ],
|
||||
|
||||
[".300WM Mk248 Mod 0", 900, 100, 0.0584, -0.0008300, 3.81, 0, 2, 10, 120, 0, 0, 13.31, 7.80, 25.40, 0.268, 7, "ICAO"],
|
||||
[".300WM Mk248 Mod 1", 867, 100, 0.0611, -0.0008150, 3.81, 0, 2, 10, 120, 0, 0, 14.26, 7.80, 25.40, 0.310, 7, "ICAO"],
|
||||
[".300WM Berger OTM" , 853, 100, 0.0622, -0.0007600, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 7.80, 25.40, 0.368, 7, "ICAO"],
|
||||
[".300WM Mk248 Mod 0", 900, 100, 0.0584442, -0.00070530, 3.81, 0, 2, 10, 120, 0, 0, 13.31, 7.80, 25.40, 0.268, 7, "ICAO"],
|
||||
[".300WM Mk248 Mod 1", 867, 100, 0.0610738, -0.00061188, 3.81, 0, 2, 10, 120, 0, 0, 14.26, 7.80, 25.40, 0.310, 7, "ICAO"],
|
||||
[".300WM Berger OTM" , 853, 100, 0.0622179, -0.00053733, 3.81, 0, 2, 10, 120, 0, 0, 14.90, 7.80, 25.40, 0.368, 7, "ICAO"],
|
||||
|
||||
["7.62x54mmR" , 800, 100, 0.0692, -0.0010230, 3.81, 0, 2, 10, 120, 0, 0, 9.849, 7.92, 24.13, 0.400, 1, "ICAO"],
|
||||
["7.62x54mmR" , 800, 100, 0.0691878, -0.00100023, 3.81, 0, 2, 10, 120, 0, 0, 9.849, 7.92, 24.13, 0.400, 1, "ICAO"],
|
||||
|
||||
["7.62x51mm M80" , 810, 100, 0.0679, -0.0010350, 3.81, 0, 2, 10, 120, 0, 0, 9.525, 7.82, 25.40, 0.200, 7, "ICAO"],
|
||||
["7.62x51mm M118LR" , 820, 100, 0.0662, -0.0008525, 3.81, 0, 2, 10, 120, 0, 0, 11.34, 7.82, 25.40, 0.243, 7, "ICAO"],
|
||||
["7.62x51mm Mk319" , 820, 100, 0.0670, -0.0010300, 3.81, 0, 2, 10, 120, 0, 0, 8.424, 7.82, 25.40, 0.377, 1, "ICAO"],
|
||||
["7.62x51mm Subsonic", 320, 100, 0.3060, -0.0004910, 3.81, 0, 2, 10, 120, 0, 0, 12.96, 7.82, 25.40, 0.235, 7, "ICAO"],
|
||||
["7.62x51mm M80" , 810, 100, 0.0679374, -0.00100957, 3.81, 0, 2, 10, 120, 0, 0, 9.525, 7.82, 25.40, 0.200, 7, "ICAO"],
|
||||
["7.62x51mm M118LR" , 780, 100, 0.0710319, -0.00082828, 3.81, 0, 2, 10, 120, 0, 0, 11.34, 7.82, 25.40, 0.243, 7, "ICAO"],
|
||||
["7.62x51mm Mk319" , 910, 100, 0.0584524, -0.00102338, 3.81, 0, 2, 10, 120, 0, 0, 8.424, 7.82, 25.40, 0.377, 1, "ICAO"],
|
||||
["7.62x51mm M993" , 930, 100, 0.0570316, -0.00107148, 3.81, 0, 2, 10, 120, 0, 0, 8.230, 7.82, 25.40, 0.359, 1, "ICAO"],
|
||||
["7.62x51mm Subsonic", 320, 100, 0.3059680, -0.00049899, 3.81, 0, 2, 10, 120, 0, 0, 12.96, 7.82, 25.40, 0.235, 7, "ICAO"],
|
||||
|
||||
["6.5x39mm" , 800, 100, 0.0683, -0.0007850, 3.81, 0, 2, 10, 120, 0, 0, 7.970, 6.71, 22.86, 0.263, 7, "ICAO"],
|
||||
["6.5x47mm Lapua" , 800, 100, 0.0682, -0.0007710, 3.81, 0, 2, 10, 120, 0, 0, 9.007, 6.71, 22.86, 0.290, 7, "ICAO"],
|
||||
["6.5mm Creedmor" , 840, 100, 0.0637, -0.0006510, 3.81, 0, 2, 10, 120, 0, 0, 9.072, 6.71, 22.86, 0.317, 7, "ICAO"],
|
||||
["6.5x39mm" , 800, 100, 0.0683482, -0.00075308, 3.81, 0, 2, 10, 120, 0, 0, 7.970, 6.71, 22.86, 0.263, 7, "ICAO"],
|
||||
["6.5x47mm Lapua" , 800, 100, 0.0682221, -0.00067037, 3.81, 0, 2, 10, 120, 0, 0, 9.007, 6.71, 22.86, 0.290, 7, "ICAO"],
|
||||
["6.5mm Creedmor" , 840, 100, 0.0636501, -0.00060887, 3.81, 0, 2, 10, 120, 0, 0, 9.072, 6.71, 22.86, 0.317, 7, "ICAO"],
|
||||
|
||||
["5.56x45mm M855" , 870, 100, 0.0626, -0.0012650, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.151, 7, "ASM" ],
|
||||
["5.56x45mm Mk262" , 820, 100, 0.0671, -0.0011250, 3.81, 0, 2, 10, 120, 0, 0, 4.990, 5.70, 17.78, 0.361, 1, "ASM" ],
|
||||
["5.56x45mm Mk318" , 880, 100, 0.0616, -0.0011200, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.307, 1, "ASM" ]];
|
||||
["5.56x45mm M855" , 870, 100, 0.0626386, -0.00126466, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.151, 7, "ASM" ],
|
||||
["5.56x45mm Mk262" , 820, 100, 0.0671481, -0.00109563, 3.81, 0, 2, 10, 120, 0, 0, 4.990, 5.70, 17.78, 0.361, 1, "ASM" ],
|
||||
["5.56x45mm Mk318" , 880, 100, 0.0615937, -0.00123318, 3.81, 0, 2, 10, 120, 0, 0, 4.018, 5.70, 17.78, 0.307, 1, "ASM" ],
|
||||
["5.56x45mm M995" , 869, 100, 0.0626713, -0.00123272, 3.81, 0, 2, 10, 120, 0, 0, 4.536, 5.70, 17.78, 0.310, 1, "ASM" ]];
|
||||
|
||||
[] call FUNC(clear_user_data);
|
||||
profileNamespace setVariable ["ACE_ATragMX_gunList", GVAR(gunList)];
|
||||
|
@ -4,7 +4,6 @@ ADDON = false;
|
||||
|
||||
PREP(add_new_gun);
|
||||
PREP(calculate_range_card);
|
||||
PREP(calculate_scope_base_angle);
|
||||
PREP(calculate_solution);
|
||||
PREP(calculate_target_range_assist);
|
||||
PREP(calculate_target_solution);
|
||||
@ -68,5 +67,6 @@ PREP(update_target_data);
|
||||
PREP(update_target_selection);
|
||||
PREP(update_unit_selection);
|
||||
PREP(update_zero_range);
|
||||
PREP(on_close_dialog);
|
||||
|
||||
ADDON = true;
|
||||
|
@ -47,16 +47,16 @@ _temperature = GVAR(temperature);
|
||||
_barometricPressure = GVAR(barometricPressure);
|
||||
_relativeHumidity = GVAR(relativeHumidity);
|
||||
if (!GVAR(atmosphereModeTBH)) then {
|
||||
_barometricPressure = 1013.25 * exp(-(_altitude) / 7990);
|
||||
_barometricPressure = 1013.25 * (1 - (0.0065 * _altitude) / (273.15 + _temperature + 0.0065 * _altitude)) ^ 5.255754495;
|
||||
_relativeHumidity = 50;
|
||||
};
|
||||
|
||||
private ["_bulletLength", "_stabilityFactor"];
|
||||
_bulletLength = 1.8;
|
||||
_bulletLength = 45.72;
|
||||
_stabilityFactor = 1.5;
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,SpinDriftEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
if (_bulletDiameter > 0 && _bulletLength > 0 && _bulletMass > 0 && _barrelTwist > 0) then {
|
||||
_stabilityFactor = [_bulletDiameter / 10 / 2.54, _bulletLength, _bulletMass * 15.4323584, _barrelTwist / 2.54, _muzzleVelocity, _temperature, _barometricPressure] call EFUNC(advanced_ballistics,calculateStabilityFactor);
|
||||
_stabilityFactor = [_bulletDiameter, _bulletLength, _bulletMass, _barrelTwist * 10, _muzzleVelocity, _temperature, _barometricPressure] call EFUNC(advanced_ballistics,calculateStabilityFactor);
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -1,40 +0,0 @@
|
||||
/*
|
||||
* Author: Ruthberg
|
||||
* Calculates a new scope base angle
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Bullet mass <NUMBER>
|
||||
* 1: Bore height <NUMBER>
|
||||
* 2: air friction <NUMBER>
|
||||
* 3: muzzle velocity <NUMBER>
|
||||
* 4: zero range <NUMBER>
|
||||
*
|
||||
* Return Value:
|
||||
* scope base angle <NUMBER>
|
||||
*
|
||||
* Example:
|
||||
* call ace_atragmx_calculate_scope_base_angle
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_bulletMass", "_boreHeight", "_airFriction", "_muzzleVelocity", "_zeroRange"];
|
||||
_bulletMass = _this select 0;
|
||||
_boreHeight = _this select 1;
|
||||
_airFriction = _this select 2;
|
||||
_muzzleVelocity = _this select 3;
|
||||
_zeroRange = _this select 4;
|
||||
|
||||
private ["_scopeBaseAngle"];
|
||||
_scopeBaseAngle = 0;
|
||||
|
||||
private ["_temperature", "_barometricPressure", "_relativeHumidity"];
|
||||
_temperature = 15;
|
||||
_barometricPressure = 1013.25;
|
||||
_relativeHumidity = 0;
|
||||
|
||||
private ["_result"];
|
||||
_result = [_scopeBaseAngle, _bulletMass, _boreHeight, _airFriction, _muzzleVelocity, _temperature, _barometricPressure, _relativeHumidity, 1000, [0, 0], 0, 0, 0, _zeroRange, _airFriction, 1, "ICAO", false, 1.5, 0, 0, 0] call FUNC(calculate_solution);
|
||||
|
||||
_scopeBaseAngle + (_result select 0) / 60
|
@ -37,7 +37,7 @@
|
||||
* 8: Spin drift (MOA) <NUMBER>
|
||||
*
|
||||
* Example:
|
||||
* call ace_atragmx_calculate_target_range_assist
|
||||
* call ace_atragmx_calculate_solution
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
@ -106,7 +106,7 @@ private ["_wind1", "_wind2", "_windDrift"];
|
||||
_wind1 = [cos(270 - _windDirection * 30) * _windSpeed1, sin(270 - _windDirection * 30) * _windSpeed1, 0];
|
||||
_wind2 = [cos(270 - _windDirection * 30) * _windSpeed2, sin(270 - _windDirection * 30) * _windSpeed2, 0];
|
||||
_windDrift = 0;
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
_bc = [_bc, _temperature, _barometricPressure, _relativeHumidity, _atmosphereModel] call EFUNC(advanced_ballistics,calculateAtmosphericCorrection);
|
||||
};
|
||||
|
||||
@ -117,7 +117,7 @@ _speedAverage = 0;
|
||||
|
||||
private ["_eoetvoesMultiplier"];
|
||||
_eoetvoesMultiplier = 0;
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,EoetvoesEnabled), false]) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
_eoetvoesMultiplier = 2 * (0.0000729 * _muzzleVelocity / -9.80665) * cos(_latitude) * sin(_directionOfFire);
|
||||
};
|
||||
|
||||
@ -142,14 +142,12 @@ while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do {
|
||||
_trueSpeed = vectorMagnitude _trueVelocity;
|
||||
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false]) then {
|
||||
_drag = if (missionNamespace getVariable [QEGVAR(advanced_ballistics,extensionAvailable), false]) then {
|
||||
parseNumber(("ace_advanced_ballistics" callExtension format["retard:%1:%2:%3", _dragModel, _bc, _trueSpeed]))
|
||||
} else {
|
||||
([_dragModel, _bc, _trueSpeed] call EFUNC(advanced_ballistics,calculateRetardation))
|
||||
};
|
||||
_bulletAccel = (vectorNormalized _trueVelocity) vectorMultiply (-1 * _drag);
|
||||
};
|
||||
} else {
|
||||
_bulletAccel = _trueVelocity vectorMultiply (_trueSpeed * _airFriction);
|
||||
};
|
||||
@ -177,24 +175,21 @@ while {_TOF < 15 && (_bulletPos select 1) < _targetRange} do {
|
||||
_kineticEnergy = _kineticEnergy * 0.737562149;
|
||||
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (_bulletPos select 1) > 0) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,CoriolisEnabled), false]) then {
|
||||
// Coriolis
|
||||
_horizontalDeflection = 0.0000729 * ((_bulletPos select 1) ^ 2) * sin(_latitude) / _speedAverage;
|
||||
_horizontalCoriolis = - atan(_horizontalDeflection / (_bulletPos select 1));
|
||||
_windage1 = _windage1 + _horizontalCoriolis;
|
||||
_windage2 = _windage2 + _horizontalCoriolis;
|
||||
};
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,EoetvoesEnabled), false]) then {
|
||||
// Eoetvoes
|
||||
_verticalDeflection = (_bulletPos select 2) * _eoetvoesMultiplier;
|
||||
_verticalCoriolis = - atan(_verticalDeflection / (_bulletPos select 1));
|
||||
_elevation = _elevation + _verticalCoriolis;
|
||||
};
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,SpinDriftEnabled), false]) then {
|
||||
// Spin drift
|
||||
_spinDeflection = _twistDirection * 0.0254 * 1.25 * (_stabilityFactor + 1.2) * _TOF ^ 1.83;
|
||||
_spinDrift = - atan(_spinDeflection / (_bulletPos select 1));
|
||||
_windage1 = _windage1 + _spinDrift;
|
||||
_windage2 = _windage2 + _spinDrift;
|
||||
};
|
||||
};
|
||||
|
||||
GVAR(rangeCardData) set [_n, [_range, _elevation * 60, [_windage1 * 60, _windage2 * 60], _lead, _TOF, _bulletSpeed, _kineticEnergy]];
|
||||
_n = _n + 1;
|
||||
@ -217,23 +212,20 @@ _kineticEnergy = 0.5 * (_bulletMass / 1000 * (_bulletSpeed ^ 2));
|
||||
_kineticEnergy = _kineticEnergy * 0.737562149;
|
||||
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (_bulletPos select 1) > 0) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,CoriolisEnabled), false]) then {
|
||||
// Coriolis
|
||||
_horizontalDeflection = 0.0000729 * ((_bulletPos select 1) ^ 2) * sin(_latitude) / _speedAverage;
|
||||
_horizontalCoriolis = - atan(_horizontalDeflection / (_bulletPos select 1));
|
||||
_windage1 = _windage1 + _horizontalCoriolis;
|
||||
_windage2 = _windage2 + _horizontalCoriolis;
|
||||
};
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,EoetvoesEnabled), false]) then {
|
||||
// Eoetvoes
|
||||
_verticalDeflection = (_bulletPos select 2) * _eoetvoesMultiplier;
|
||||
_verticalCoriolis = - atan(_verticalDeflection / (_bulletPos select 1));
|
||||
_elevation = _elevation + _verticalCoriolis;
|
||||
};
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,SpinDriftEnabled), false]) then {
|
||||
// Spin drift
|
||||
_spinDeflection = _twistDirection * 0.0254 * 1.25 * (_stabilityFactor + 1.2) * _TOF ^ 1.83;
|
||||
_spinDrift = - atan(_spinDeflection / (_bulletPos select 1));
|
||||
_windage1 = _windage1 + _spinDrift;
|
||||
_windage2 = _windage2 + _spinDrift;
|
||||
};
|
||||
};
|
||||
|
||||
[_elevation * 60, [_windage1 * 60, _windage2 * 60], _lead, _TOF, _bulletSpeed, _kineticEnergy, _verticalCoriolis * 60, _horizontalCoriolis * 60, _spinDrift * 60]
|
||||
|
@ -47,16 +47,16 @@ _temperature = GVAR(temperature);
|
||||
_barometricPressure = GVAR(barometricPressure);
|
||||
_relativeHumidity = GVAR(relativeHumidity);
|
||||
if (!GVAR(atmosphereModeTBH)) then {
|
||||
_barometricPressure = 1013.25 * exp(-(_altitude) / 7990);
|
||||
_barometricPressure = 1013.25 * (1 - (0.0065 * _altitude) / (273.15 + _temperature + 0.0065 * _altitude)) ^ 5.255754495;
|
||||
_relativeHumidity = 50;
|
||||
};
|
||||
|
||||
private ["_bulletLength", "_stabilityFactor"];
|
||||
_bulletLength = 1.8;
|
||||
_bulletLength = 45.72;
|
||||
_stabilityFactor = 1.5;
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,SpinDriftEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
if (_bulletDiameter > 0 && _bulletLength > 0 && _bulletMass > 0 && _barrelTwist > 0) then {
|
||||
_stabilityFactor = [_bulletDiameter / 10 / 2.54, _bulletLength, _bulletMass * 15.4323584, _barrelTwist / 2.54, _muzzleVelocity, _temperature, _barometricPressure] call EFUNC(advanced_ballistics,calculateStabilityFactor);
|
||||
_stabilityFactor = [_bulletDiameter, _bulletLength, _bulletMass, _barrelTwist * 10, _muzzleVelocity, _temperature, _barometricPressure] call EFUNC(advanced_ballistics,calculateStabilityFactor);
|
||||
};
|
||||
};
|
||||
|
||||
|
@ -15,7 +15,10 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
//if (dialog) exitWith { false };
|
||||
#define __dsp (uiNamespace getVariable "ATragMX_Display")
|
||||
#define __ctrlBackground (__dsp displayCtrl 720000)
|
||||
|
||||
if (GVAR(active)) exitWith { false };
|
||||
if (underwater ACE_player) exitWith { false };
|
||||
if (!("ACE_ATragMX" in (uniformItems ACE_player)) && !("ACE_ATragMX" in (vestItems ACE_player))) exitWith { false };
|
||||
|
||||
@ -47,4 +50,13 @@ GVAR(showTargetSpeedAssistTimer) call FUNC(show_target_speed_assist_timer);
|
||||
lbAdd [6000, _x select 0];
|
||||
} forEach GVAR(gunList);
|
||||
|
||||
GVAR(active) = true;
|
||||
|
||||
GVAR(DialogPFH) = [{
|
||||
if (!GVAR(active)) exitWith {
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
__ctrlBackground ctrlSetText format [QUOTE(PATHTOF(UI\ATRAG_%1.paa)), ["N", "D"] select (call EFUNC(common,ambientBrightness))];
|
||||
}, 60, []] call cba_fnc_addPerFrameHandler;
|
||||
|
||||
true
|
||||
|
@ -15,6 +15,8 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
GVAR(active) = false;
|
||||
|
||||
GVAR(workingMemory) = +(GVAR(gunList) select 0);
|
||||
|
||||
GVAR(scopeUnits) = ["MILs", "TMOA", "SMOA", "Clicks"];
|
||||
|
5
addons/atragmx/functions/fnc_on_close_dialog.sqf
Normal file
5
addons/atragmx/functions/fnc_on_close_dialog.sqf
Normal file
@ -0,0 +1,5 @@
|
||||
#include "script_component.hpp"
|
||||
|
||||
uiNamespace setVariable ['ATragMX_Display', nil];
|
||||
GVAR(active) = false;
|
||||
[GVAR(DialogPFH)] call cba_fnc_removePerFrameHandler;
|
@ -59,8 +59,8 @@ if (GVAR(currentUnit) == 1) then {
|
||||
private ["_boreHeight", "_bulletMass", "_bulletDiameter", "_airFriction", "_rifleTwist", "_muzzleVelocity", "_zeroRange"];
|
||||
_boreHeight = parseNumber(ctrlText 120000);
|
||||
_bulletMass = parseNumber(ctrlText 120010);
|
||||
_bulletDiameter = parseNumber(ctrlText 120020);
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false])) then {
|
||||
_bulletDiameter = parseNumber(ctrlText 120020) * 10;
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
_airFriction = 0.1 max parseNumber(ctrlText 120030) min 2;
|
||||
} else {
|
||||
_airFriction = parseNumber(ctrlText 120030) / -1000;
|
||||
@ -71,7 +71,7 @@ _zeroRange = parseNumber (ctrlText 120060);
|
||||
if (GVAR(currentUnit) != 2) then {
|
||||
_boreHeight = _boreHeight * 2.54;
|
||||
_bulletMass = _bulletMass * 0.06479891;
|
||||
_bulletDiameter = _bulletDiameter * 10 * 2.54;
|
||||
_bulletDiameter = _bulletDiameter * 2.54;
|
||||
_rifleTwist = _rifleTwist * 2.54;
|
||||
_muzzleVelocity = _muzzleVelocity / 3.2808399;
|
||||
};
|
||||
@ -87,7 +87,7 @@ GVAR(workingMemory) set [5, _boreHeight];
|
||||
GVAR(workingMemory) set [12, _bulletMass];
|
||||
GVAR(workingMemory) set [13, _bulletDiameter];
|
||||
GVAR(workingMemory) set [14, _rifleTwist];
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
GVAR(workingMemory) set [15, _airFriction];
|
||||
} else {
|
||||
GVAR(workingMemory) set [4, _airFriction];
|
||||
@ -95,36 +95,6 @@ if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false])
|
||||
GVAR(workingMemory) set [1, _muzzleVelocity];
|
||||
GVAR(workingMemory) set [2, _zeroRange];
|
||||
|
||||
private ["_elevationCur", "_windageCur", "_clickSize", "_clickNumber", "_clickInterval"];
|
||||
_elevationCur = GVAR(workingMemory) select 10;
|
||||
_windageCur = GVAR(workingMemory) select 11;
|
||||
|
||||
switch (GVAR(currentScopeUnit)) do {
|
||||
case 0: {
|
||||
_elevationCur = _elevationCur * 3.38;
|
||||
_windageCur = _windageCur * 3.38;
|
||||
};
|
||||
case 2: {
|
||||
_elevationCur = _elevationCur / 1.047;
|
||||
_windageCur = _windageCur / 1.047;
|
||||
};
|
||||
case 3: {
|
||||
switch (GVAR(workingMemory) select 7) do {
|
||||
case 0: { _clickSize = 1; };
|
||||
case 1: { _clickSize = 1 / 1.047; };
|
||||
case 2: { _clickSize = 3.38; };
|
||||
};
|
||||
_clickNumber = GVAR(workingMemory) select 8;
|
||||
_clickInterval = _clickSize / _clickNumber;
|
||||
|
||||
_elevationCur = Round(_elevationCur / _clickInterval);
|
||||
_windageCur = Round(_windageCur / _clickInterval);
|
||||
};
|
||||
};
|
||||
|
||||
GVAR(workingMemory) set [10, _elevationCur];
|
||||
GVAR(workingMemory) set [11, _windageCur];
|
||||
|
||||
[] call FUNC(update_gun);
|
||||
[] call FUNC(update_gun_ammo_data);
|
||||
[] call FUNC(update_atmosphere);
|
||||
|
@ -30,7 +30,7 @@ if !(ctrlVisible 9000) then {
|
||||
if (!(GVAR(speedAssistTimer))) exitWith {
|
||||
GVAR(speedAssistTimer) = true;
|
||||
|
||||
ctrlSetText [8006, Str(Round((time - _startTime) * 10) / 10)];
|
||||
ctrlSetText [8006, Str(Round((ACE_time - _startTime) * 10) / 10)];
|
||||
|
||||
[] call FUNC(calculate_target_speed_assist);
|
||||
|
||||
@ -40,7 +40,7 @@ if !(ctrlVisible 9000) then {
|
||||
[_this select 1] call cba_fnc_removePerFrameHandler;
|
||||
};
|
||||
|
||||
ctrlSetText [9001, Str(Round((time - _startTime) * 10) / 10)];
|
||||
ctrlSetText [9001, Str(Round((ACE_time - _startTime) * 10) / 10)];
|
||||
|
||||
}, 0.1, [time]] call CBA_fnc_addPerFrameHandler;
|
||||
}, 0.1, [ACE_time]] call CBA_fnc_addPerFrameHandler;
|
||||
};
|
||||
|
@ -26,7 +26,7 @@ if (GVAR(currentUnit) != 2) then {
|
||||
} else {
|
||||
ctrlSetText [110, Str(Round(GVAR(workingMemory) select 12))];
|
||||
};
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
ctrlSetText [120, Str(Round((GVAR(workingMemory) select 15) * 1000) / 1000)];
|
||||
} else {
|
||||
ctrlSetText [120, Str(Round((GVAR(workingMemory) select 4) * -1000 * 1000) / 1000)];
|
||||
|
@ -30,9 +30,9 @@ if (GVAR(currentUnit) != 2) then {
|
||||
if (GVAR(currentUnit) != 2) then {
|
||||
ctrlSetText [120020, Str(Round((GVAR(workingMemory) select 13) / 10 / 2.54 * 1000) / 1000)];
|
||||
} else {
|
||||
ctrlSetText [120020, Str(Round((GVAR(workingMemory) select 13) * 1000) / 1000)];
|
||||
ctrlSetText [120020, Str(Round((GVAR(workingMemory) select 13) / 10 * 1000) / 1000)];
|
||||
};
|
||||
if ((missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) && (missionNamespace getVariable [QEGVAR(advanced_ballistics,AdvancedAirDragEnabled), false])) then {
|
||||
if (missionNamespace getVariable [QEGVAR(advanced_ballistics,enabled), false]) then {
|
||||
ctrlSetText [120030, Str(Round((GVAR(workingMemory) select 15) * 1000) / 1000)];
|
||||
} else {
|
||||
ctrlSetText [120030, Str(Round((GVAR(workingMemory) select 4) * -1000 * 1000) / 1000)];
|
||||
|
@ -15,7 +15,7 @@
|
||||
*/
|
||||
#include "script_component.hpp"
|
||||
|
||||
private ["_range", "_elevation", "_windage1", "_windage2", "_clickSize", "_clickNumber", "_clickInterval", "_lead", "_TOF", "_velocity", "_kineticEnergy", "_rangeOutput", "_elevationOutput", "_windageOutput", "_lastColumnOutput"];
|
||||
private ["_range", "_elevation", "_windage1", "_windage2", "_clickSize", "_clickNumber", "_clickInterval", "_lead", "_TOF", "_velocity", "_kineticEnergy", "_rangeOutput", "_elevationOutput", "_windageOutput", "_lastColumnOutput", "_speedOfSound"];
|
||||
_lastColumnOutput = "";
|
||||
|
||||
if (GVAR(showWind2) && GVAR(rangeCardCurrentColumn) == 0) then {
|
||||
@ -32,6 +32,8 @@ if (GVAR(currentUnit) == 1) then {
|
||||
|
||||
lnbClear 5007;
|
||||
|
||||
_speedOfSound = GVAR(temperature) call EFUNC(weather,calculateSpeedOfSound);
|
||||
|
||||
{
|
||||
_range = _x select 0;
|
||||
_elevation = _x select 1;
|
||||
@ -72,7 +74,7 @@ lnbClear 5007;
|
||||
_windageOutput = Str(Round(_windage1 * 100) / 100);
|
||||
|
||||
_rangeOutput = Str(_range);
|
||||
if (_velocity < 340.29) then {
|
||||
if (_velocity < _speedOfSound) then {
|
||||
_rangeOutput = _rangeOutput + "*";
|
||||
};
|
||||
|
||||
|
@ -1,11 +1,36 @@
|
||||
["ACE3", QGVAR(ATragMXDialogKey), localize "STR_ACE_ATragMX_ATragMXDialogKey",
|
||||
["ACE3 Equipment", QGVAR(ATragMXDialogKey), localize LSTRING(ATragMXDialogKey),
|
||||
{
|
||||
// Conditions: canInteract
|
||||
if !([ACE_player, objNull, []] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
|
||||
if !([ACE_player, objNull, ["notOnMap", "isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith)) exitWith {false};
|
||||
if (GVAR(active)) exitWith {
|
||||
closeDialog 0;
|
||||
false
|
||||
};
|
||||
// Statement
|
||||
[] call FUNC(create_dialog);
|
||||
false
|
||||
},
|
||||
{false},
|
||||
[0, [false, false, false]], false, 0] call CBA_fnc_addKeybind; // (empty default key)
|
||||
|
||||
|
||||
//Add deviceKey entry:
|
||||
private ["_conditonCode", "_toggleCode", "_closeCode"];
|
||||
_conditonCode = {
|
||||
[] call FUNC(can_show);
|
||||
};
|
||||
_toggleCode = {
|
||||
// Conditions: canInteract
|
||||
if !([ACE_player, objNull, ["notOnMap", "isNotInside", "isNotSitting"]] call EFUNC(common,canInteractWith)) exitWith {};
|
||||
if (GVAR(active)) exitWith {
|
||||
closeDialog 0;
|
||||
};
|
||||
// Statement
|
||||
[] call FUNC(create_dialog);
|
||||
};
|
||||
_closeCode = {
|
||||
if (GVAR(active)) exitWith {
|
||||
closeDialog 0;
|
||||
};
|
||||
};
|
||||
[(localize LSTRING(Name)), QUOTE(PATHTOF(UI\ATRAG_Icon.paa)), _conditonCode, _toggleCode, _closeCode] call EFUNC(common,deviceKeyRegisterNew);
|
||||
|
@ -11,4 +11,4 @@
|
||||
|
||||
#include "\z\ace\addons\main\script_macros.hpp"
|
||||
|
||||
#define ATRAGMX_PROFILE_NAMESPACE_VERSION 1.3
|
||||
#define ATRAGMX_PROFILE_NAMESPACE_VERSION 1.7
|
||||
|
@ -1,5 +1,4 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!-- Edited with tabler. -->
|
||||
<Project name="ACE">
|
||||
<Package name="ATragMX">
|
||||
<Key ID="STR_ACE_ATragMX_Name">
|
||||
@ -21,6 +20,10 @@
|
||||
<Spanish>Abrir ATragMX</Spanish>
|
||||
<French>Ouvrir ATragMX</French>
|
||||
<German>ATragMX öffnen</German>
|
||||
<Italian>Apri ATragMX</Italian>
|
||||
<Hungarian>ATragMX elővétele</Hungarian>
|
||||
<Czech>Otevřít ATragMX</Czech>
|
||||
<Portuguese>Abrir ATragMX</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_ATragMX_Description">
|
||||
<English>Rugged PDA with ATragMX</English>
|
||||
@ -28,6 +31,11 @@
|
||||
<Russian>Защищенный КПК с ATragMX</Russian>
|
||||
<Spanish>PDA rugerizada con ATragMX</Spanish>
|
||||
<German>Robuster PDA mit ATragMX</German>
|
||||
<French>PDA avec ATragMX</French>
|
||||
<Italian>PDA Robusto con ATragMX</Italian>
|
||||
<Hungarian>Megerősített PDA, ATragMX-el</Hungarian>
|
||||
<Czech>PDA s ATragMX</Czech>
|
||||
<Portuguese>PDA Robusto com ATragMX</Portuguese>
|
||||
</Key>
|
||||
<Key ID="STR_ACE_ATragMX_ATragMXDialogKey">
|
||||
<English>Open ATragMX</English>
|
||||
@ -36,6 +44,10 @@
|
||||
<Spanish>Abrir ATragMX</Spanish>
|
||||
<French>Ouvrir ATragMX</French>
|
||||
<German>ATragMX öffnen</German>
|
||||
<Italian>Apri ATragMX</Italian>
|
||||
<Hungarian>ATragMX elővétele</Hungarian>
|
||||
<Czech>Otevřít ATragMX</Czech>
|
||||
<Portuguese>Abrir ATragMX</Portuguese>
|
||||
</Key>
|
||||
</Package>
|
||||
</Project>
|
@ -1 +1 @@
|
||||
z\ace\Addons\attach
|
||||
z\ace\addons\attach
|
@ -3,7 +3,7 @@
|
||||
class ACE_Actions { \
|
||||
class ACE_MainActions { \
|
||||
class GVAR(AttachVehicle) { \
|
||||
displayName = "$STR_ACE_Attach_AttachDetach"; \
|
||||
displayName = CSTRING(AttachDetach); \
|
||||
condition = QUOTE(_this call FUNC(canAttach)); \
|
||||
insertChildren = QUOTE(_this call FUNC(getChildrenAttachActions)); \
|
||||
exceptions[] = {}; \
|
||||
@ -13,7 +13,7 @@
|
||||
distance = 4.5; \
|
||||
}; \
|
||||
class GVAR(DetachVehicle) { \
|
||||
displayName = "$STR_ACE_Attach_Detach"; \
|
||||
displayName = CSTRING(Detach); \
|
||||
condition = QUOTE(_this call FUNC(canDetach)); \
|
||||
statement = QUOTE(_this call FUNC(detach) ); \
|
||||
exceptions[] = {}; \
|
||||
@ -54,7 +54,7 @@ class CfgVehicles {
|
||||
class ACE_SelfActions {
|
||||
class ACE_Equipment {
|
||||
class GVAR(Attach) {
|
||||
displayName = "$STR_ACE_Attach_AttachDetach";
|
||||
displayName = CSTRING(AttachDetach);
|
||||
condition = QUOTE(_this call FUNC(canAttach));
|
||||
insertChildren = QUOTE(_this call FUNC(getChildrenAttachActions));
|
||||
exceptions[] = {"isNotDragging"};
|
||||
@ -64,7 +64,7 @@ class CfgVehicles {
|
||||
// hotkey = "T";
|
||||
};
|
||||
class GVAR(Detach) {
|
||||
displayName = "$STR_ACE_Attach_Detach";
|
||||
displayName = CSTRING(Detach);
|
||||
condition = QUOTE(_this call FUNC(canDetach));
|
||||
statement = QUOTE(_this call FUNC(detach));
|
||||
exceptions[] = {"isNotDragging"};
|
||||
@ -87,9 +87,9 @@ class CfgVehicles {
|
||||
class NVGMarker {
|
||||
diffuse[] = {0.006, 0.006, 0.006, 1};
|
||||
ambient[] = {0.005, 0.005, 0.005, 1};
|
||||
brightness = 0.2;
|
||||
brightness = 0.1;
|
||||
name = "pozicni blik";
|
||||
drawLightSize = 0.2;
|
||||
drawLightSize = 0.1;
|
||||
drawLightCenterSize = 0.003;
|
||||
activeLight = 0;
|
||||
blinking=1;
|
||||
@ -112,7 +112,7 @@ class CfgVehicles {
|
||||
magazines[] = {};
|
||||
nvTarget = 1;
|
||||
destrType = "DestructNo";
|
||||
brightness = 20;
|
||||
brightness = 10;
|
||||
};
|
||||
|
||||
class NATO_Box_Base;
|
||||
|
@ -5,10 +5,10 @@ class CfgWeapons {
|
||||
|
||||
class ACE_IR_Strobe_Item: ACE_ItemCore {
|
||||
ACE_attachable = "ACE_IR_Strobe_Effect";
|
||||
author = "$STR_ACE_Common_ACETeam";
|
||||
author = ECSTRING(common,ACETeam);
|
||||
scope = 2;
|
||||
displayName = "$STR_ACE_IrStrobe_Name";
|
||||
descriptionShort = "$STR_ACE_IrStrobe_Description";
|
||||
displayName = CSTRING(IrStrobe_Name);
|
||||
descriptionShort = CSTRING(IrStrobe_Description);
|
||||
model = "\A3\weapons_F\ammo\mag_univ.p3d";
|
||||
picture = PATHTOF(UI\irstrobe_item.paa);
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user