Thumbs upRaiin Menu V1 [DayZ SA Menu]

Posts 115 of 124 · Page 1 of 9
Raiin Menu V1 [DayZ SA Menu]
There is no point to keeping this private since Lystic made all our scripts public...
I'm not going to promise any updates, but I may improve this later. Please do not ask me to how to use it or for any other script related problems.

Features can be found in the picture below, but I will post them if needed.



Updates
-[1/16/2014]: Updated Menu size and positioning to fit better on different resolutions/sizes.

Code:
raiinMenu = {
W34p0ns = ["Mosin9130","ShotgunIzh43","FNX45","M4A1","BaseballBat","FirefighterAxe","WoodAxe"];
amm0 = ["Ammo_12ga_Pellets","Ammo_12ga_Slug","Ammo_45FMJ","Ammo_556","Ammo_556_20Rnd","Ammo_762","Ammo_762_20Rnd","M_CMAG_10Rnd","M_CMAG_10Rnd_Green","M_CMAG_20Rnd","M_CMAG_20Rnd_Green","M_CMAG_30Rnd","M_CMAG_30Rnd_Green","M_CMAG_40Rnd","Container_AmmoBox300Rnd","M_FNX45_15Rnd","M_STANAG_30Rnd","M_STANAG_30Rnd_Coupled"];
Att4chm3nt = ["Attachment_Bayonet_M9A1","Attachment_Bayonet_Mosin","Attachment_Bipod_Atlas","Attachment_Buttstock_M4CQB","Attachment_Buttstock_M4MP","Attachment_Buttstock_M4OE","Attachment_Handguard_M4MP","Attachment_Handguard_M4MP_Green","Attachment_Handguard_M4Plastic","Attachment_Handguard_M4RIS","Attachment_Light_Universal","Attachment_Suppressor_556","Attachment_Optic_ACOG","Attachment_Optic_BUIS","Attachment_Optic_FNP45_MRD","Attachment_Optic_Longrange","Attachment_Optic_M4CarryHandle","Attachment_Optic_M4T3NRDS","Attachment_Optic_M68","Attachment_Optic_PUScope"];
F0od_Dr1nk = ["Drink_Canteen","Drink_SodaZlutaKlasik","Drink_SodaZlutaKolaloka","Drink_SodaZlutaMalinovka","Drink_WaterBottle","Food_BoxCerealCrunchin","Food_CanBakedBeans","Food_CanSardines","Food_CanSpaghetti","Food_CanTuna","Food_PowderedMilk","Food_Rice","Fruit_AppleFresh","Fruit_AppleRotten","Fruit_BananaFresh","Fruit_BananaRotten","Fruit_KiwiFresh","Fruit_KiwiRotten","Fruit_OrangeFresh","Fruit_OrangeRotten"];
M3d1c4l = ["Medical_Bandage","Medical_BandageDressing","Medical_BloodBag_Empty","Medical_BloodTest_Kit","Medical_CharcoalTablets","Medical_Defibrillator","Medical_DisinfectantAlcohol","Medical_DisinfectantSpray","Medical_Epinephrine","Medical_InjectionVial","Medical_Morphine","Medical_PainkillrTablets","Medical_PurificationTablets","Medical_SalineBag","Medical_StartKit","Medical_Syringe","Medical_TetracyclineAntibiotics","Medical_TransfusionKit","Medical_VitaminBottle"];
T0ol_it3ms = ["Pen_Black","Pen_Blue","Pen_Green","Pen_Red","PipeWrench","Tool_CanOpener","Tool_Crowbar","Tool_FireExtinguisher","Tool_Hammer","Tool_HandcuffKeys","Tool_Handcuffs","Tool_KitchenKnife","Tool_Pliers","Tool_Screwdriver","Tool_Shovel","Tool_Wrench"];
B4ckp4cks = ["BagHunting","BagMountain_Blue","BagMountain_Green","BagMountain_Orange","BagMountain_Red","BagTaloon_Blue","BagTaloon_Green","BagTaloon_Orange","BagTaloon_Violet"];
It3m5 = ["Map_ChernarusE","Map_ChernarusN","Map_ChernarusNE","Map_ChernarusNW","Map_ChernarusS","Map_ChernarusSE","Map_ChernarusSW","Map_ChernarusW","Compass","MiscItem_WalkieTalkie","Consumable_Battery9V","Consumable_DuctTape","Consumable_Firewood","Consumable_GasCanisterLarge","Consumable_GasCanisterMedium","Consumable_GasCanisterSmall","Consumable_Matchbox","Consumable_Paper","Consumable_Stone","Container_FirstAidKit","Container_Protector_Small","Cooker_PortableStove","Cookware_Pot","Crafting_BurlapSack","Crafting_Rope","Crafting_WoodenStick","Light_PortableLamp"];
Cl0th1ng = ["Headtorch_Black","Headtorch_Grey","HikingBoots_Base","HikingBoots_Low_Base","Hoodie_Black","Hoodie_Blue","Hoodie_Brown","Hoodie_Green","Hoodie_Grey","Hoodie_Red","HoxtonMask","HunterPants_Autumn","HunterPants_Brown","HunterPants_Spring","HunterPants_Summer","HunterPants_Winter","Jeans_Black","Jeans_Blue","Jeans_BlueDark","Jeans_Brown","Jeans_Green","Jeans_Grey","JoggingShoes_Base","TShirtBeige","TShirtBlack","TShirtBlue","TShirtGreen","TShirtGrey","TShirtOrangeWhiteStripes","TShirtRed","TShirtRedBlackStripes","TShirtWhite","TTsKO_Jacket_Camo","TacticalShirtBlack","TacticalShirtGrey","TacticalShirtOlive","TacticalShirtTan","TacticalVest","JungleBoots_Base","LeatherShoes_Base","WorkingBoots_Base","CombatBoots_Base","WorkingGloves_Beige","WorkingGloves_Black","MotoHelmet_Black","MotoHelmet_Blue","MotoHelmet_Green","MotoHelmet_Red","MotoHelmet_White","UKAssVest_Black","UKAssVest_Camo","UKAssVest_Khaki","UKAssVest_Olive","UshankaBlack","UshankaBlue","PoliceVest","PressVest_Blue","PressVest_LightBlue","RadarCap_Black","RadarCap_Blue","RadarCap_Brown","RadarCap_Green","RadarCap_Red","Raincoat_Green","Raincoat_Orange","Raincoat_Yellow","RocketAviators","Shirt_CheckBlue","Shirt_CheckBlueBright","Shirt_CheckGreen","Shirt_CheckRed","Shirt_CheckWhite","Shirt_PlaneBlack","UshankaGreen","Wellies_Base","WolfMask","NioshFaceMask","WorkingGloves_Brown","WorkingGloves_Yellow","ZmijovkaCap_Black","MilitaryBoots_Base","ZmijovkaCap_Blue","ZmijovkaCap_Brown","ZmijovkaCap_Green","ZmijovkaCap_Red","ttsko_pants_Beige","AthleticShoes_Base","BallisticHelmet","CargoPants_Beige","DallasMask","GasMask","Glasses_Designer","CargoPants_Black","CargoPants_Blue","CargoPants_Green","CargoPants_Grey","ChestHolster"];
A11 = W34p0ns + amm0 + Att4chm3nt + F0od_Dr1nk + M3d1c4l + T0ol_it3ms + B4ckp4cks + It3m5 + Cl0th1ng;


infammo = {
	if (isnil ("infammoON")) then 
	{
		infammoON = 0;
	};
	if (infammoON==0) then
	{
		systemchat "Infinite Ammo ON!";
		infammoON=1;
	}
	else
	{
		infammoON=0;
		systemchat "Infinite Ammo OFF!";
	};
	sCode = " while {infammoON==1} do{(vehicle player) setVehicleAmmo 1;sleep 0.1;};";
	[] spawn compile sCode;
};

killme = {
	while{alive player} do {
		player setVelocity[0,0,1000];
		sleep 0.2;
		player setVelocity[0,0,-1000];
		sleep 0.3;
	};
};

executer = {
	closedialog 0;
	sleep 0.1;
	createdialog 'rscdisplaynote';
	sleep 0.2;
	disableSerialization;
	ctrlSetText[1600,'Execute'];
	ctrlSettext[1601,'Exit'];
	ctrlSetText[1300,'Bowens Script Executer'];
	buttonSetAction[1600,'_text = (ctrlText 1400);[] spawn compile _text;'];
};

dropnear = {
	 _list = position player nearEntities 999999999;
	 _msg = ("Found: "+(str (count _list))+" players.");
	 systemchat _msg;
	 {
		  if (name _x != "tim.young94" || name _x != "Distraught" || name _x != "Raiin") then {
				_x attachto [player,[0,5,12]];
		  };
	 } foreach _list;
	 sleep 3;
	 {detach _x} foreach _list;
	 systemchat "Dropped them mothafkers";
};

disarmnear = {
	if(toggle_6) then {hint "Disarm Near Units ON!";} else {hint "Disarm Near Units OFF!";};
	while{toggle_6} do {
		_list = player nearEntities 100;
		{
			if(_x != player) then {
				if((name _x != "Raiin") && (name _x != "TornBush") && (name _x != "bowen")) then {
					dropItems = _x;
					publicVariableServer "dropItems";
				};
			};
		} forEach _list;
		sleep 0.1;
	};
};	

removegrass = {
	if(toggle_5) then {
		setTerrainGrid 50.0;hint "Terrain Hack ON";
	} else {
		setTerrainGrid 12.5;hint "Terrain Hack OFF";
	};
};

nocollide = {
	if(toggle_4) then {hint "NO COLLIDE ON";} else {hint "NO COLLIDE OFF";};
	_objects = [];
	while{toggle_4} do {
		_list = player nearObjects 50;
		{
			if !(_x in _objects) then {
				player disableCollisionWith _x;
				_objects = _objects + [_x];
			};
		} forEach _list;
		sleep 10;
	};
	{
		player enableCollisionWith _x;
		_objects = _objects - [_x];
	} forEach _objects;
};

timeday = {
	if (isnil ("loop1")) then {loop1 = 0;};
	if (loop1==0) then {loop1=1;cutText [format["Enabled Loop"], "PLAIN DOWN"];hint "Enabled Loop";}else
		{loop1=0;cutText [format["Disabled Loop"], "PLAIN DOWN"];hint "Disabled Loop";};
		while {loop1==1} do
		{
			setDate [2012, 9, 1, 14, 0];
			sleep 7;
		};
};

esp2ez = {
		toggleESP = {
			tarDis = 800;

			if (isNil 'espOn') then
			{
				espOn = 0;
			};

			if (espOn == 0) then
			{
				espOn = 1;
				hint 'ESP ON';
				_a = [];
				while {espOn == 1} do
				{
					_entities = (position player nearObjects ["SurvivorBase",850]);
					_count = count _entities;
					{
						if (((_x in _a) && !(alive _x)) or ((_x in _a) && ((player distance _x) > tarDis))) then {_a = _a - [_x];};
						if ((_x != player) && (name _x != '') && !(_x in _a) && ((player distance _x) <= tarDis)) then
						{
							_a = _a + [_x];
							[_x] spawn drawESP;
							sleep 1;
						};
					} forEach _entities;
					sleep 30;
				};
			} else {
				espOn = 0;
				hint 'ESP OFF';
			};
		};		
		drawESP = {
			disableSerialization;
			if (isNil 'ESP_Count') then {ESP_Count = 2733;};
			ESP_Count cutRsc ['rscDynamicText', 'PLAIN'];
			ESP_Count = ESP_Count + 1;
			_ctrl = ((uiNamespace getvariable 'BIS_dynamicText') displayctrl 9999);
			_ctrl ctrlShow true; _ctrl ctrlEnable true; _ctrl ctrlSetFade 0;
			_unit = _this select 0;
			while {(alive _unit) && ((player distance _unit) < tarDis)} do
			{
				if (espOn == 0) exitWith {_ctrl ctrlShow false; _ctrl ctrlEnable false;};
				_pos = [(getPosATL _unit) select 0, (getPosATL _unit) select 1, ((getPosATL _unit) select 2) + 2];
				_pos2D = WorldToScreen _pos;
				_health = round(((_unit getVariable['blood',0])/5000)*100);
				_hand = currentWeapon _unit;
				_wName = getText(configFile >> "cfgWeapons" >> _hand >> "displayName");
				if(_wName == "") then {
					_wName = _hand;
				};
				if (count _pos2D > 0) then
				{
					_ctrl ctrlSetPosition [(_pos2D select 0) - (safezoneW / 2), (_pos2D select 1), safezoneW, safezoneH];
					_text = parseText format ['<t size=''0.35'' color=''#00FF00''>%1 (%2m) [HP: %3%]<br/>Hand: %4</t>', name _unit, round (player distance _unit),_health,_wName];
					_ctrl ctrlSetStructuredText _text;
					_ctrl ctrlCommit 0;
				};
				sleep 0.05;
			};
			_ctrl ctrlShow false;
			_ctrl ctrlEnable false;
		};
		[] spawn toggleESP;
};

fastwalk = {
	_doWait = false;
	if(toggle_1) then {hint "SPEED WALK ON!";} else {hint "SPEED WALK OFF!";};
	while{toggle_1} do {
		if(_doWait) then {sleep 0.1;_doWait = false;};
		if(inputAction "MoveForward" > 0|| inputAction "MoveFastForward" > 0|| inputAction "MoveSlowForward" > 0 || inputAction "EvasiveForward" > 0) then {
			_distance = 0.7;
			_dir = getdir vehicle player;
			_pos = getposasl vehicle player;
			if ((_pos select 2) > 5) then 
			{
				_pos = [(_pos select 0)+_distance*sin(_dir),(_pos select 1)+_distance*cos(_dir),(_pos select 2)];
			}
			else
			{
				_pos = [(_pos select 0)+_distance*sin(_dir),(_pos select 1)+_distance*cos(_dir),getTerrainHeightASL [(_pos select 0),(_pos select 1)]-.1];
			};
			player setPosASL _pos;
			_doWait = true;
		} else {
			if(inputAction "MoveBack" > 0|| inputAction "EvasiveBack" > 0) then {
				_distance = -0.7;
				_dir = getdir vehicle player;
				_pos = getposasl vehicle player;
				if ((_pos select 2) > 5) then 
				{
					_pos = [(_pos select 0)+_distance*sin(_dir),(_pos select 1)+_distance*cos(_dir),(_pos select 2)];
				}
				else
				{
					_pos = [(_pos select 0)+_distance*sin(_dir),(_pos select 1)+_distance*cos(_dir),getTerrainHeightASL [(_pos select 0),(_pos select 1)]-.1];
				};
				player setPosASL _pos;
				_doWait = true;
			};
		};
		sleep 0.001;
	};
};

raiinswalker = {
	walkloc = ["nwaf","cherno","swaf","swmb","balota","cherno_resident","cherno_resident_2","dubky","oaks"];
	nwaf = [4611,10477];
	cherno = [7000, 2500];
	cherno_resident = [5932,2572];
	cherno_resident_2 = [6167,3217];
	dubky = [6528,3555];
	oaks = [6528,3555];
	swaf = [4815,2565];
	swmb = [4817,2223];
	balota = [4406,2435];
	getX = {
		closeDialog 0;
		disableSerialization;
		createDialog "RscDisplayChat";
		systemchat "<Autowalker>: CMDS -> nwaf - North West Airfield | cherno - Chenarus";
		systemchat "<Autowalker>: CMDS -> swaf - South West Airfield | swmb - South West Military Barracks";
		systemchat "<Autowalker>: CMDS -> balota - Balota";
		systemchat "<AutoWalker>: Type your X coordinate in chat and press ESCAPE (enter 'exit' to quit)";
		_doloop = true;
		_checkChat =true;
		while{_doloop} do {
			waitUntil{!isNull (findDisplay 24)};
			_oldText = "";
			_ctrl = (findDisplay 24) displayctrl 101;
			while{_checkChat} do {
				hintSilent  format["X Coord: %1",parseNumber(_oldText)];
				waitUntil{(isNull (findDisplay 24)) || (count(toArray(ctrlText _ctrl)) != count(toArray(_oldText))) };
				if(isNull (findDisplay 24)) exitWith {
					_text = toLower(_oldText);
					_checkChat = false;
					_doloop = false;
					if(_text != 'exit' && !(_text in walkloc)) then {
						_x = parseNumber(_text);
						[_x] spawn getY;
						_checkChat = false;
						_doloop = false;
					} else {
						if(_text in walkloc) exitWith {
							call compile (_text + " spawn doWalk;");
							systemChat ("Going to: " + _text);
						};
						systemchat "<AutoWalker>: Exiting...";
					};
				};
				_oldText = ctrlText _ctrl;

			};
			waitUntil{isNull (findDisplay 24)};
		};
	};
	getY = {
		disableSerialization;
		systemchat "<AutoWalker>: Type your Y coordinate in chat and press ESCAPE";
		_x = _this select 0;
		_doloop = true;
		_checkChat =true;
		while{_doloop} do {
			waitUntil{!isNull (findDisplay 24)};
			_oldText = "";
			_ctrl = (findDisplay 24) displayctrl 101;
			while{_checkChat} do {
				hintSilent  format["Y Coord: %1",parseNumber(_oldText)];
				waitUntil{(isNull (findDisplay 24)) or (count(toArray(ctrlText _ctrl)) != count(toArray(_oldText))) };
				if(isNull (findDisplay 24)) exitWith {
					_text = _oldText;
					if(toLower(_text) != 'exit') then {
						_y = parseNumber(_text);
						[_x,_y] spawn doWalk;
						_checkChat = false;
						_doloop = false;
					} else {
						systemchat "<AutoWalker>: Exiting...";
						_checkChat = false;
						_doloop = false;
					};
				};
				_oldText = ctrlText _ctrl;

			};
			waitUntil{isNull (findDisplay 24)};
		};
	};
	doWalk = {
		  _despos = [(_this select 0),(_this select 1)];
		  _speed = 6.5;
		_mypos = position player;
		_decx = ((_despos select 0) < (_mypos select 0));
		_decy = ((_despos select 1) < (_mypos select 1));
		_xdis = abs((_mypos select 0) - (_despos select 0));
		_ydis = abs((_mypos select 1) - (_despos select 1));
		_hyp = sqrt(_xdis^2 + _ydis^2);
		_ix = (_xdis/(_hyp/_speed));
		_iy = (_ydis/(_hyp/_speed));

		systemchat ("Starting Walk. Moving at "+(str _speed)+"m/s.");
		
		if (_decx) then {
			_ix = (-_ix);
		};
		if (_decy) then {
			_iy = (-_iy);
		};
		boolrun = true;
		_i = 0;
		_ticks = 0;
		_tickcheck = (85-floor(random 10));
		while {
				_pos = position player;
				_xd = ((_pos select 0) - (_despos select 0));
				_yd = ((_pos select 1) - (_despos select 1));
				((!(_xd < 15 && _xd > -15) || !(_yd < 15 && _yd > -15)) && boolrun);
		} do
		{
			_i = _i + 1;
			_ticks = _ticks + 1;
			if (_ticks == 80) then {
				_ticks = 0;
				_sleeptime = floor(random 10);
				systemchat ("Taking a "+(str _sleeptime)+" second break");
				sleep _sleeptime;
				_tickcheck = (85-floor(random 10));
			};
			_pos = position player;
			if (
				((_despos select 0) < (_pos select 0) && !_decx) ||
				((_despos select 0) > (_pos select 0) && _decx)
			) then 
			{
				_ix = 0;
				if (_iy != 0) then {
					if (!_decy) then {
						_iy = _speed;
					} else {
						_iy = -_speed;
					};
				};
			};
			if (
				((_despos select 1) < (_pos select 1) && !_decy) ||
				((_despos select 1) > (_pos select 1) && _decy)
			) then
			{
				_iy = 0;
				if (_ix != 0) then {
					if (!_decx) then {
						_ix = _speed;
					} else {
						_ix = -_speed;
					};
				};
			};

				
			_newpos = [((_pos select 0)+_ix), ((_pos select 1) + _iy),_pos select 2];
			player setpos _newpos;
			sleep 1;
			_newpos = position player;
			_travelspeed = (((_pos distance _newpos)/1000)*60*60);
			_msgpos = [round (_newpos select 0),round (_newpos select 1),round (_newpos select 2)];
			systemchat ("Raiin AutoWalker: Position: "+(str _msgpos)+"."+str _i + " runs. " + str round _travelspeed + "km/h.");
			
					
			if (
				((_newpos select 0) < (_pos select 0) && !_decx && _ix != 0) || 
				((_newpos select 1) < (_pos select 1) && !_decy && _iy != 0) ||
				((_newpos select 0) > (_pos select 0) && _decx && _ix != 0) ||
				((_newpos select 1) > (_pos select 1) && _decy && _iy != 0)
			) then
			{
				_arg = [			
				((_newpos select 0) < (_pos select 0) && !_decx && _ix != 0),
				((_newpos select 1) < (_pos select 1) && !_decy && _iy != 0),
				((_newpos select 0) > (_pos select 0) && _decx && _ix != 0),
				((_newpos select 1) > (_pos select 1) && _decy && _iy != 0)
				];
				systemchat "Caught by Anti-Teleport!";
				sleep 2;
				disableuserinput false;
				systemchat str _arg;
				_mypos = position player;
				_decx = ((_despos select 0) < (_mypos select 0));
				_decy = ((_despos select 1) < (_mypos select 1));
				_xdis = abs((_mypos select 0) - (_despos select 0));
				_ydis = abs((_mypos select 1) - (_despos select 1));
				_hyp = sqrt(_xdis^2 + _ydis^2);
				_ix = (_xdis/(_hyp/_speed));
				_iy = (_ydis/(_hyp/_speed));
				
				if (_decx) then {
					_ix = (-_ix);
				};
				if (_decy) then {
					_iy = (-_iy);
				};
			};
		};
		systemchat "Script Finished";
	};
	call getX;
};

magnet = {
	hint "START!";
	_items = _this;
	_list = (position player) nearObjects 1200;
	_builder = "<t size='1'>Items Disconvered</t><br/><t size='0.5'>";
	_attached = [];
	{
		_type = typeOf(_x);
		_name = getText(configFile >> "cfgVehicles" >> _type >> "displayName");
		if(_name == "") then {
			_name = getText(configFile >> "cfgWeapons" >> _type >> "displayName");
		};
		if(_name == "") then {
			_name = getText(configFile >> "cfgMagazines" >> _type >> "displayName");
		};
		if(_type in _items) then {
			_builder = _builder + _name + "<br/>";
			_x attachTo [player,[0,0,0]];
			_attached = _attached + [_x];
		};
	} forEach _list;
	_builder = _builder + "You have 60 seconds to loot!";
	hint parseText _builder;
	sleep 60;
	{
		detach _x;
	} forEach _attached;
	Hint "Looting Complete!";
};

wmagnet = {
	W34p0ns spawn magnet;
};
amagnet = {
	amm0 spawn magnet;
};
atmagnet = {
	Att4chm3nt spawn magnet;
};
fmagnet = {
	F0od_Dr1nk spawn magnet;
};
mmagnet = {
	M3d1c4l spawn magnet;
};
tmagnet = {
	T0ol_it3ms spawn magnet;
};
bmagnet = {
	B4ckp4cks spawn magnet;
};
imagnet = {
	It3m5 spawn magnet;
};
cmagnet = {
	Cl0th1ng spawn magnet;
};
almagnet = {
	A11 spawn magnet;
};

toggle_1 = false;
toggle_2 = false;
toggle_3 = false;
toggle_4 = false;
toggle_5 = false;
toggle_6 = false;
toggle_7 = false;
toggle_8 = false;
toggle_9 = false;
toggle_10 = false;

magMenu = [];
genSubMenu = {hint "holder";};

menuScripts = [
	["Magnet Menu",{tempArray = magMenu;magMenu spawn genSubMenu;},false,"",true],
	["Suicide",killme,false,"",false],
	["Bowen Executer",executer,false,"",false],
	["Drop Near",dropnear,false,"",false],
	["AutoWalker",raiinswalker,true,"",false],
	["Fast Walk",fastwalk,true,"toggle_1",false],
	["ESP",esp2ez,true,"toggle_2",false],
	["Infinite Ammo",infammo,true,"toggle_7",false],
	["No Collide",nocollide,true,"toggle_4",false],
	["No Grass",removegrass,true,"toggle_5",false],
	["Disarm Enemies",disarmnear,true,"toggle_6",false],
	["Time Day",timeday,true,"toggle_3",false]
];

magMenu = [
	["Weapon Magnet",wmagnet,false,""],
	["Ammo Magnet",amagnet,false,""],
	["Attachment Magnet",atmagnet,false,""],
	["Food & Drink Magnet",fmagnet,false,""],
	["Medical Magnet",mmagnet,false,""],
	["Weapon Magnet",tmagnet,false,""],
	["Backpack Magnet",bmagnet,false,""],
	["Item Magnet",imagnet,false,""],
	["Clothing Magnet",cmagnet,false,""],
	["All Item Magnet",almagnet,false,""]];

shiftMenu = {
	if ((typeName _this) == "ARRAY") then {
		_control = _this select 0;
		_pos = ctrlPosition _control;
		_control ctrlSetPosition [(_pos select 0)+0.5, (_pos select 1),(_pos select 2)+(_this select 1), (_pos select 3) + (_this select 2)];
		_control ctrlCommit 0;
	} else {
		_control = _this;
		_pos = ctrlPosition _control;
		_control ctrlSetPosition [(_pos select 0)+0.5, (_pos select 1),(_pos select 2), (_pos select 3)];
		_control ctrlCommit 0;
	};
};

fixMenu = {
	_display = _this;
	
	_controlScripts = (_display displayCtrl 1021);
	_pos = ctrlPosition _controlScripts;
	_controlPlayers = (_display displayCtrl 1002);
	_controlPlayers ctrlSetPosition [(_pos select 0)+(_pos select 2)+0.06, (_pos select 1)];
	_controlPlayersBG = (_display displayCtrl 1022);
	_controlPlayersBG ctrlSetPosition [(_pos select 0)+(_pos select 2)+0.06, (_pos select 1)];
	_controlPlayers ctrlCommit 0;
	_controlPlayersBG ctrlCommit 0;
	
	[(_display displayCtrl 1021),0.05,0] call shiftMenu;
	(_display displayCtrl 1022) call shiftMenu;
	
	_mcontrol = (_this displayCtrl 1001);
	_mpos = ctrlPosition _mcontrol;
	_control = (_display displayCtrl 1023);
	_pos = ctrlPosition _control;
	_widthScripts = ctrlPosition (_display displayCtrl 1021) select 2;
	_widthPlayers = ctrlPosition (_display displayCtrl 1022) select 2;
	_control ctrlSetText "Raiin's Menu";
	_control ctrlSetPosition [(_mpos select 0)+0.5, (_pos select 1)-0.1, (_widthScripts + _widthPlayers + 0.01),0.1];
	_control ctrlCommit 0;
	
	(_display displayCtrl 1013) ctrlShow false;
	(_display displayCtrl 1013) ctrlSetScale 3;
	(_display displayCtrl 1013) ctrlCommit 1;
};

genPlayers = {
	_control = (_this displayCtrl 1002);
	_control call shiftMenu;
	_control lbAdd "Players:";
	_control lbSetColor [0, [0, 1, 0, 0.5]];
	_control lbAdd "-----------------------------";
	_control lbSetColor [1, [0, 1, 0, 0.5]];
	_list = player nearEntities ["SurvivorBase",850];
	{
		_control lbAdd format["%1",name _x];
	}forEach _list;
};

dbClicked = {
	disableserialization;
	_index = _this;
	_item  = tempArray select _index;
	_text = _item select 0;
	_cmd = _item select 1;
	_isToggle = _item select 2;
	_toggleVar = _item select 3;
	if(_isToggle) then {
		call compile format["%1 = !%1",_toggleVar];
		_bool= call compile _toggleVar;
		if(_bool) then {
			lbSetColor [1001,_index,[0,1,0,1]];
		} else {
			lbSetColor [1001,_index,[1,0,0,1]];
		};
	};
	systemChat ("Raiin Menu: Started " + _text);
	[] spawn _cmd;
};

genScripts = {
	_control = (_this displayCtrl 1001);
	_control ctrlRemoveAllEventHandlers "LBSelChanged";
	_control ctrlRemoveAllEventHandlers "LBDblClick";
	_control ctrlRemoveAllEventHandlers "MouseButtonDown";
	_control ctrlRemoveAllEventHandlers "KeyDown";
	_control ctrlAddEventHandler ["LBDblClick","(_this select 1) spawn dbClicked;"];
	_control ctrlCommit 0;
	_control = (_this displayCtrl 1001);
	_pos = ctrlPosition _control;
	[_control,0.05,0] call shiftMenu;
	disableSerialization;
	_display = _this;
	_left = _display displayctrl 1001;
	_counter = 0;
	lbClear _left;
	{
		_left lbAdd (_x select 0);
		if((_x select 2)) then {
			_bool= call compile (_x select 3);
			if(_bool) then {
				_left lbSetColor [_counter,[0,1,0,1]];
			} else {
				_left lbSetColor [_counter,[1,0,0,1]];
			};
		} else {
			if (_x select 4) then {
				_left lbSetColor [_counter,[0,0,0.75,1]];
			} else {
				_left lbSetColor [_counter,[1,1,1,1]];
			};
		};
		_counter = _counter + 1;
	} forEach menuScripts;
	_left ctrlCommit 0;
};

genSubMenu = {
	disableSerialization;
	_display = findDisplay 129;
	_left = _display displayctrl 1001;
	_subscripts = _this;
	_counter = 0;
	lbClear _left;
	{
		_left lbAdd (_x select 0);
		if((_x select 2)) then {
			_bool= call compile (_x select 3);
			if(_bool) then {
				_left lbSetColor [_counter,[0,1,0,1]];
			} else {
				_left lbSetColor [_counter,[1,0,0,1]];
			};
		} else {
			if (_x select 4) then {
				_left lbSetColor [_counter,[0,0,0.75,1]];
			} else {
				_left lbSetColor [_counter,[1,1,1,1]];
			};
		};
		_counter = _counter + 1;
	} forEach _subscripts;
	_left ctrlCommit 0;
};

startMenu = {
	_ok = createDialog "RscDisplayDiary";
	disableSerialization;
	waitUntil{!isNull (findDisplay 129)};
	_display = findDisplay 129;
	
	_display call fixMenu;
	_display call genScripts;
	_display call genPlayers;
	tempArray = menuScripts;
	if (_ok) then {
	};
	disableUserInput false;
};

[] spawn {
	_count = 0;
	while{true} do {
		if(inputAction "NightVision" > 0) then {
			if(isNull (findDisplay 129)) then {
				[] spawn startMenu;
			};
			sleep 0.5;
		};
		sleep 0.001;
		_count = _count + 1;
	};
};
systemchat "Raiin Menu Initiated. Press N to open.";
};

[] spawn raiinMenu;
Credits:
-Raiin
-Bowen [Some scripts]
-Lystic [Function Structure/Some Scripts]

***Notice***
Redistribution and/or modification of this script is permitted for non-commercial use and must retain credits of any source used from this release.
it would be great if i knew how to use it XD
Thanks it would be great if you could tell me how to get unbanned on dayz battleye SA
Quote Originally Posted by xxTyuzixx View Post
Thanks it would be great if you could tell me how to get unbanned on dayz battleye SA
Get a new steam account, buy the game again. Problem solved
Quote Originally Posted by Confin3d View Post
Get a new steam account, buy the game again. Problem solved
Is there another way? Ill pay 20$ for a new key so i at least save 10$
Quote Originally Posted by xxTyuzixx View Post
Is there another way? Ill pay 20$ for a new key so i at least save 10$
No.

/10characters
It would help alot of people of you make the sqf yourself and upload it on here.
Quote Originally Posted by hidudeshi View Post
It would help alot of people of you make the sqf yourself and upload it on here.
Copy the script, paste into notepad, save as "script.sqf".
Quote Originally Posted by ProRaiin View Post
Copy the script, paste into notepad, save as "script.sqf".
I know but many people don't know.
Quote Originally Posted by ProRaiin View Post
Copy the script, paste into notepad, save as "script.sqf".
This will help alot understand how to use it
what exactly do each of these features do? Like amybe a sentence or 2 on each would be nice.
Updated
-[1/16/2014]: Updated Menu size and positioning to fit better on different resolutions/sizes.
Quote Originally Posted by reeferuk1 View Post
wheres the download link?
The "code" is the thing..
Quote Originally Posted by reeferuk1 View Post
wheres the download link?
I posted the script in the bottom of the thead..
Still..how to use the autowalker? I want to go to Elektro for example..


I usually get the "Caught by anti teleport" message and return to my orginial position.
Posts 115 of 124 · Page 1 of 9
This thread is closed for replies.

Similar Threads

Tags for this Thread

Need help?