Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- _this setDamage 0.9;
- _this allowDamage false;
- if(!isServer) exitWith {};
- _anims=["InBaseMoves_Lean1"]; // PUT ANIMS HERE
- _positions=[];
- _num = 0;
- _maxNum = 10;
- while {_num < _maxNum } do {
- _marker = format["tp_%1",_num];
- if ((getMarkerType _marker) != "" ) then {
- _positions set[count _positions, getMarkerPos _marker];
- _maxNum = _num + 10;
- };
- _num = _num + 1;
- };
- {
- _this disableAi _x;
- } forEach ["TARGET","AUTOTARGET","MOVE","ANIM","FSM"];
- _newMove = {
- kng_freeze_anim = (_anims call BIS_fnc_selectRandom);
- };
- call _newMove;
- _this spawn {
- while{true} do {
- _this switchMove "InBaseMoves_Lean1";
- _this switchMove kng_freeze_anim;
- sleep .05;
- };
- };
- while{true} do {
- _r=floor(random(100));
- if(_r>10 && count _positions>0) then {
- call _newMove;
- _this setPos (_positions call BIS_fnc_selectRandom);
- sleep 30+random(40);
- } else {
- call _newMove;
- _dist = 5;
- _t = (playableUnits call BIS_fnc_selectRandom);
- _pos = getPos _t;
- _dir = getDir _t;
- _pos set[0,(_pos select 0)+sin(_dir)*_dist];
- _pos set[1,(_pos select 1)+cos(_dir)*_dist];
- _this setPos _pos;
- _this setDir (_dir-180);
- sleep 0.5;
- };
- };
Advertisement
Add Comment
Please, Sign In to add comment