Jump to content

Attach a laser sight to sharks?


Havoc302

Recommended Posts

This would require epoch side edits, correct me if i'm wrong, but without looking i'm pretty sure the server spawns it. Now i can write code that does it, but this will require editing the server epoch files which are strictly forbidden and won't allow me to put it here ^^

 

 

2nd issue is that a laserpointer is a weaponattachement not an object.

 

But the greatwhite is a character that comes from the "hunter", so we might be able to give him a weapon wih a laster pointer on ^^ if he accepts it xp

Link to comment
Share on other sites

addweapon and doTarget/dofire commands did do nothing.

But one could use some cheap tricks like:
- Use a weaponHolder (addWeaponCargo to add a gun to it) to attach a weapon to the shark.
- Use "_shark setVariable ["BIS_fnc_animalBehaviour_disable", true];" together with doTarget to let the shark aim at a player (this might not work so set the direction manually using BIS_fnc_dirTo).
- As long as aimedAtTarget returns more than 0 (this might again not work), draw a red Line from the attached weaponHolder object to the player, using drawLine3D in a onEachFrame EventHandler.
- Apply some damage to the player as long as the line does not intersect with other objects (check using lineIntersects and terrainIntersect).

Have fun creating a Laser Shark

Greez KiloSwiss

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...