Browse Source

first push for aat scripts

also first test ofr global variable file. Has getter and setters,where they have exception handling.
Namenai 7 years ago
parent
commit
c75e84d992

+ 8 - 0
Scripts/scripts/zeus3denScripts/globalFnc/namEnableConfigAAT/getnamEnableConfigAAT.sqf

@@ -0,0 +1,8 @@
+try
+{
+namEnableConfigAAT;
+}
+catch
+{
+hint ("getnamEnableConfigAAT not working, badger Namenai to fix it.");
+}

+ 10 - 0
Scripts/scripts/zeus3denScripts/globalFnc/namEnableConfigAAT/setnamEnableConfigAAT.sqf

@@ -0,0 +1,10 @@
+try
+{
+
+	params["_value"];
+	namEnableConfigAAT=_value;
+}
+catch
+{
+	hint ("possible wrong or no parameter sent, badger Namenai to fix it.");
+};

+ 4 - 0
Scripts/scripts/zeus3denScripts/globalVars/globalVar.sqf

@@ -0,0 +1,4 @@
+//These are global variables
+
+namEnableConfigAAT=false;//for AAT,vehicle variants. has setter and getters  under (namEnableConfigAAT/getnamEnableConfigAAT) and (namEnableConfigAAT/setnamEnableConfigAAT)
+namEnableLaatCrashable=false;

+ 3 - 1
Scripts/scripts/zeus3denScripts/namenaisInit.sqf

@@ -1,5 +1,7 @@
-//last update 3/15/2018 3:23 pm est by namenai
+//last update 3/25/2018 11:18 pm est by namenai
 
+//global variables that are used
+	[] execVM "scripts\zeus3denScripts\globalVars\globalVar.sqf";
 
 //laat weapons,adds weapons and wingtip smoke
 	[] execVM "scripts\zeus3denScripts\vehicleBased\vehicleVariants\airBased\LAAT\laatClaymore.sqf";

+ 19 - 4
Scripts/scripts/zeus3denScripts/readme.txt

@@ -1,4 +1,4 @@
-last update 3/17/2018 1:25 pm est by namenai
+last update 3/25/2018 11:44 AM  est by namenai
 
 Here is the file path of various scripts,if its not listed here then its probably 1)scripts being prepped or 2) we forgot :P
 
@@ -12,6 +12,12 @@ Here is the file path of various scripts,if its not listed here then its probabl
 ---X means tied to a ---H, no need to really apply it.
 ---F free script,meaning you can either use in 3den or zeus if you need it.
 
+---S means this variable has setters
+---G means this variable has getters
+
+---P This function must have a parameter
+
+---EXP has exception handling
 
 */
 ///////////////         END KEY              ////////////////////
@@ -20,9 +26,18 @@ Here is the file path of various scripts,if its not listed here then its probabl
 //Or if you want to not have all the bells and whistles  just put // infront of the below line if its in init.sqf, or remove it
 [] execVM "scripts\zeus3denScripts\namenaisInit.sqf";
 
-
-
-//Vehicle scripts
+//Global Variables
+	//This is the global variable file ---G---S
+		[] execVM "scripts\zeus3denScripts\globalVars\globalVar.sqf";
+		
+//Global Functions
+	//namEnableConfigAAT 
+		//getter ---EXP
+			[] execVM "scripts\zeus3denScripts\globalFnc\namEnableConfigAAT\getnamEnableConfigAAT.sqf";
+		//setter ---P ---EXP
+			[] execVM "scripts\zeus3denScripts\globalFnc\namEnableConfigAAT\setnamEnableConfigAAT.sqf";
+
+//Vehicle Based
 	//vehicleVariants
 		//airBased
 			//laat weapon,no need to worry as it will auto apply ---H

+ 53 - 0
Scripts/scripts/zeus3denScripts/vehicleBased/vehicleVariants/landBased/AAT/aatBase.sqf

@@ -0,0 +1,53 @@
+//AAT adds an option for AAT
+rexiAttMohawk=
+	{
+		params["_vic"];
+
+		if(namEnableConfigAAT) then
+		{
+			(_vic) setobjecttextureglobal [0,"optre_vehicles\pelican\data\falcon_gun_CO.paa"];
+			(_vic) setobjecttextureglobal [1,"optre_vehicles\pelican\data\falcon_gun_CO.paa"];
+		
+			//by default will add the new gusn
+			_vic addWeaponTurret ["Cannon_EWEBSWBFgun", [0]];
+			for [{_i=0}, {_i<3}, {_i=_i+1}] do
+			{
+				_vic addMagazineTurret ["1000Rnd_Laser_Cannon_EWEBSWBF" ,[0]];
+			
+			};//
+			
+			//gives ability to remove weapons
+			_vic  addAction ["<t color='#47FF1A'>Remove AI Coxial Turret </t>",                
+			{
+				_aat = _this select 0;
+				
+				_aat RemoveWeaponTurret ["Cannon_EWEBSWBFgun", [0]];
+				for [{_i=0}, {_i<3}, {_i=_i+1}] do
+				{
+						_aat RemoveMagazineTurret ["1000Rnd_Laser_Cannon_EWEBSWBF" ,[0]];
+				
+				};
+				
+			}];//
+			
+			//gives ability to add weapons
+			_vic  addAction ["<t color='#47FF1A'>Add AI Coxial Turret </t>",                
+			{
+				_aat = _this select 0;
+				
+				_aat addWeaponTurret ["Cannon_EWEBSWBFgun", [0]];
+				for [{_i=0}, {_i<3}, {_i=_i+1}] do
+				{
+						_aat addMagazineTurret ["1000Rnd_Laser_Cannon_EWEBSWBF" ,[0]];
+				
+				};
+				
+			}];//
+			
+		}//end if 
+		else
+		{
+		};		
+	};//end aatcoxial meme
+    
+    ["O_SWOP_AAT_1", "init",rexiAttMohawk, true, [], true] call CBA_fnc_addClassEventHandler;