You can add as many guns as you want to a vehicle. These guns are functional and can shoot (Left Control or Left Mouse Button) and are moveable (SHIFT + mouse).
Firstly name your gun (the parts you want to move with must be attached to it)
fc_gun. There are two important parts for this to work.
cam(camera - the place where the camera will be when pressing SHIFT)
src(source - the place where the bullet flare will start from)
tar(target - the place where the bullet flare will go to)
Generally, it’s a good idea to keep the
tar slightly above
src and in a straight line.
Remember without these the guns won’t work.. The bullet will damage any entity it reaches first in its path.
tar must be two dummy objects added as childs of
These are the only things you need to get the gun working but you can customize some of the properties of the gun too.
- Damage: Add a suffix
_d(damage)to change how much damage the gun will do per shot. By default, it’s 50.
- Rotation lock: You can lock how much the gun can rotate too. To control up, down, left or right rotation add child under
rl_right=(rotation). The values for rotation are 0 to 180. Setting it to 180 would allow full rotation and setting to 0 will disable gun rotations. By default 180 is used for all.
- Fire time: You can also control the wait time between gunshots. Just add suffix
_ms(milliseconds). Setting it to 0 will make it fire rapidly while adding higher values will slow this process. By default, it’s 0.
- Rotation multiplier: To add a multiplier to the rotation speed add a suffix like this,
_m(value). It’s 0.5 by default.