Addons & Mods Depot > ArmA - Configs & Scripting

Light cones?

<< < (3/3)

DeanosBeano:
 The easiest way is to add a turret as already mentioned. Searchlight is actually a weapon that is turned on and off by firing the weapon.
 I have used it on several vehicles  simply copy the searchlight from the mlods and scale it to fit your vehicle .

 and add the turret in the model .cfg and the cpp.


 
--- Code: ---class Turrets  {

class LeftDoor_Gun  : NewTurret {
startEngine = false;
outGunnerMayFire = true;
primaryGunner = 1;
body = "LeftGun_Turret";
gun = "LeftGun";
animationSourceBody = "LeftGun_Turret";
animationSourceGun = "LeftGun";
commanding = -1;
proxyIndex = 1;
gunnerName = "Spotter";
memoryPointsGetInGunner = "pos_gunner";
memoryPointsGetInGunnerDir = "pos_gunner_dir";
memoryPointGun = "machinegun";
memoryPointGunnerOptics = "gunnerview_1";
memoryPointGunnerOutOptics = "gunnerview_1";
gunBeg = "end"; // endpoint of the gun
gunEnd = "chamber_1"; // chamber of the gun
selectionFireAnim = "zasleh";
gunnerAction = "UH60_Gunner";
gunnerInAction = "UH60_Gunner";
weapons[] = {Searchlight};// here is the weapon searchlight
magazines[] = {};
minElev=-10;
minTurn=-180; maxTurn=+180; initTurn=0;
gunnerOpticsModel = "\ca\weapons\optika_empty";
gunnerForceOptics = True;


};
};
--- End code ---

Delta Hawk:
@DeanosBeano, from my understanding, a turret that is useable by the driver would mean everytime you steer, the turret will follow, which I want to aviod.  The Alley and Take down lights more than make up for it however.  If you are experianced with turret class, configs and animations, I'd like to ask you for some help with a very special project.

@Gnat, thanks!  I implemented this feature the other day and my car changed dramatically at night.  This new update for the cars will leave many breathless.

DeanosBeano:
 Normally the Passenger uses the searchlight in my addons , but for driver use , you simply apply the source as "user" in the model.cfg this allows you to use Keydown to operate the turret when your driver. when applying the user source you simply require a script ,that when _x button is pressed turret turns by .1 of a degree or .01 depending on what speed you set the animation. simialryl you define other leys for - degree and two more for up down angle.
 it seems you have found a way using gnats and this maybe over complicated for your needs though, however its always a good thing to know for future.

Delta Hawk:
Well Gnat, it was worth a try, but when ever I turn the lights on for the car, the red, white and blue lights created by the lightbars and stuff don't show anymore.

Gnat:
Well, that should be unrelated. Its possibly a model.cfg problem or a named selection issue.
Would need a couple more details to help ........

Navigation

[0] Message Index

[*] Previous page

Go to full version