Arma 3
WORM DEMO
DiaZuuu 30 Jul 2020 @ 11:25pm
Worm ace damage fix
I figure out how to make Worm inflict ace damage, that was surprisingly easy...

Everything thanks to this code: _worm_impact = ["impact_30","impact_27"] call BIS_fnc_selectRandom; private _randomDamage = 1; private _bodyPart = ["head","body","arm_r","arm_l","leg_r","leg_l"] selectRandomWeighted [0.5,1,1,1,1,1]; [player, _randomDamage , _bodyPart, "vehiclecrash"] call ace_medical_fnc_addDamageToUnit;

Everything you need to do is copy and paste this in worm_attack.sqf and you done :D

In sqf file this should look like this: (That's only example don't use this!!!)

// by ALIAS

private ["_crater_impact"];

if (!hasInterface) exitWith {};

_head_worm = _this select 0;
_tail_worm = _this select 1;

enableCamShake true;
_worm_impact = ["impact_30","impact_27"] call BIS_fnc_selectRandom; private _randomDamage = 1; private _bodyPart = ["head","body","arm_r","arm_l","leg_r","leg_l"] selectRandomWeighted [0.5,1,1,1,1,1]; [player, _randomDamage , _bodyPart, "vehiclecrash"] call ace_medical_fnc_addDamageToUnit;
_head_worm say3D [_worm_impact, 500];
Terakhir diedit oleh DiaZuuu; 2 Agu 2020 @ 3:45am
< >
Menampilkan 1-5 dari 5 komentar
Ritalin 16 Jan 2021 @ 11:09pm 
This works but it isn't localized to the areas of attacks. Doesn't matter where you were on the map, you get random damage.
DiaZuuu 17 Jan 2021 @ 6:12am 
Thanks for finding this bug, unfortunately I don't know how to fix it
Louis 8 Apr 2022 @ 3:23am 
Sorry I'm late to this! But use this instead

// by ALIAS

private ["_crater_impact"];

if (!hasInterface) exitWith {};

_head_worm = _this select 0;
_tail_worm = _this select 1;

enableCamShake true;
_worm_impact = ["impact_30","impact_27"] call BIS_fnc_selectRandom;
private _randomDamage = 1;
{_selection = selectRandom ["body","head","hand_r","hand_l","leg_r","leg_l"];
[_x, 0.2, _selection, "vehiclecrash"] call ace_medical_fnc_addDamageToUnit} forEach (_head_worm nearEntities ["man", 10]);
_head_worm say3D [_worm_impact, 500];
Louis 8 Apr 2022 @ 3:24am 
The above script has a range you can change, its the 10 next to "man" in the nearEntities section, this can be lowered or raised to your preference, also, the damage is set low for testing. you can up this from 0.2 if you choose
DiaZuuu 8 Apr 2022 @ 7:11am 
Nice, thank you for fixing it!
< >
Menampilkan 1-5 dari 5 komentar
Per halaman: 1530 50