mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Experiment
This commit is contained in:
parent
0aaabfde7c
commit
604cd122d3
@ -53,14 +53,22 @@ if (((velocity _unit) select 2 < -5) && {(vehicle _unit == _unit)}) then {
|
||||
_projectile = "falling";
|
||||
_this set [4, "falling"];
|
||||
};
|
||||
if (_unit getVariable [QGVAR(isFalling), false] && {!(_selectionName in ["", "leg_l", "leg_r"])}) exitWith {0};
|
||||
if (_unit getVariable [QGVAR(isFalling), false]) then {
|
||||
if (_selectionName == "") then {
|
||||
_selectionName = ["leg_l", "leg_r"] select (floor(random 2));
|
||||
if !(_selectionName in ["", "leg_l", "leg_r"]) then {
|
||||
if (_selectionName == "body") then {
|
||||
_newDamage = _newDamage * 0.1;
|
||||
} else {
|
||||
_newDamage = _newDamage * 0.5;
|
||||
};
|
||||
} else {
|
||||
if (_selectionName == "") then {
|
||||
_selectionName = ["leg_l", "leg_r"] select (floor(random 2));
|
||||
_this set [1, _selectionName];
|
||||
};
|
||||
_newDamage = _newDamage * 0.7;
|
||||
};
|
||||
_this set [1, _selectionName];
|
||||
_newDamage = _newDamage * 0.7;
|
||||
};
|
||||
diag_log format["[handleDamage_caching] Projectile: %1; Velocity: %2 m/s; SelectionName: %3; newDamage: %4", _projectile, (velocity _unit) select 2, _selectionName, _newDamage];
|
||||
|
||||
// Finished with the current frame, reset variables
|
||||
// Note: sometimes handleDamage spans over 2 or even 3 frames.
|
||||
|
@ -28,6 +28,7 @@ _typeOfDamage = _this select 4;
|
||||
_openWounds = _unit getvariable[QGVAR(openWounds), []];
|
||||
_woundID = _unit getvariable[QGVAR(lastUniqueWoundID), 1];
|
||||
|
||||
diag_log format ["HandleDamageWounds,%1,%2,%3,%4", _selectionName, _damage, _typeOfDamage, _woundID];
|
||||
_extensionOutput = "ace_medical" callExtension format ["HandleDamageWounds,%1,%2,%3,%4", _selectionName, _damage, _typeOfDamage, _woundID];
|
||||
|
||||
_painToAdd = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user