axeman Posted January 20, 2015 Report Share Posted January 20, 2015 _attachTest={ while{alive player}do{ _trgt = cursortarget; _nr = nearestObjects [getPos player, [], 10]; if!(isNull _trgt)then{ _trgt setdamage 1; }; if(count _nr > 0)then{ { if(_x != player)then{ _x setdamage 1; }; }forEach _nr; }; uisleep 0.5;}; }; [] spawn _attachTest; player allowdamage false; Ok, so testing something out and ended up creating the wrecking code: Paste into arma 3 editor and rampage. happydayz 1 Link to comment Share on other sites More sharing options...
KiloSwiss Posted January 21, 2015 Report Share Posted January 21, 2015 CODE player addEventHandler ["Fired", { private["_projectile","_pos","_dir","_vel","_animal"]; _projectile = (_this select 6); _pos = visiblePosition _projectile; _dir = direction _projectile; _vel = velocity _projectile; deleteVehicle _projectile; {_vel set [_forEachIndex, (_x * 0.05)]}forEach _vel; _animal = [ "Rabbit_F", "Snake_random_F", "Turtle_F", "Hen_random_F", "Cock_random_F", "Goat_random_F", "Sheep_random_F" ]; _animal = createAgent [_animal select (random (count _animal -1)), _pos, [], 0, "CAN_COLLIDE"]; _animal setVariable ["BIS_fnc_animalBehaviour_disable", true]; _animal allowDamage false; _animal addEventHandler["handleDamage",{false}]; _animal setPos _pos; _animal setDir _dir; _animal setVelocity _vel; _animal spawn { private "_start"; _start = time; if(typeOf _this == "Turtle_F")then{systemChat "I Like Turtles"}; waitUntil{sleep 1; ({_x == 0}count velocity _this == 3 || time - _start > 5)}; _this removeAllEventHandlers "handleDamage"; _this allowDamage true; doStop _this; while{alive _this}do{ sleep 1; _this moveTo (position player); }; }; }]; Have fun ;) GasT, axeman, Nic and 1 other 4 Link to comment Share on other sites More sharing options...
DrScandalous Posted January 21, 2015 Report Share Posted January 21, 2015 CODE player addEventHandler ["Fired", { private["_projectile","_pos","_dir","_vel","_animal"]; _projectile = (_this select 6); _pos = visiblePosition _projectile; _dir = direction _projectile; _vel = velocity _projectile; deleteVehicle _projectile; {_vel set [_forEachIndex, (_x * 0.05)]}forEach _vel; _animal = [ "Rabbit_F", "Snake_random_F", "Turtle_F", "Hen_random_F", "Cock_random_F", "Goat_random_F", "Sheep_random_F" ]; _animal = createAgent [_animal select (random (count _animal -1)), _pos, [], 0, "CAN_COLLIDE"]; _animal setVariable ["BIS_fnc_animalBehaviour_disable", true]; _animal allowDamage false; _animal addEventHandler["handleDamage",{false}]; _animal setPos _pos; _animal setDir _dir; _animal setVelocity _vel; _animal spawn { private "_start"; _start = time; if(typeOf _this == "Turtle_F")then{systemChat "I Like Turtles"}; waitUntil{sleep 1; ({_x == 0}count velocity _this == 3 || time - _start > 5)}; _this removeAllEventHandlers "handleDamage"; _this allowDamage true; doStop _this; while{alive _this}do{ sleep 1; _this moveTo (position player); }; }; }]; Have fun ;) Not gonna lie. My favorite are the turtles. They look godram majestic. Link to comment Share on other sites More sharing options...
KiloSwiss Posted January 21, 2015 Report Share Posted January 21, 2015 Yes indeed, they do.Hint:Keep an eye on the chat section in the Video ;)Greez KiloSwissbtw.Why do You full quote the previous post? Link to comment Share on other sites More sharing options...
spartan Posted January 23, 2015 Report Share Posted January 23, 2015 I like this, does that mean we can have pet killer rabbits.....aghhh the we beasties ! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now