wingnutwn
Member-
Content Count
11 -
Joined
-
Last visited
-
Medals
Community Reputation
10 GoodAbout wingnutwn
-
Rank
Private First Class
-
GUI Teleport Menu with Map
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks 7erra, I think this one might be out of my range to figure out which is ok. I've played with a bunch of lines to see what happens. Started with the basics simple hint when lbselchanged not sure how to send that information to IDC 900 - maybe call a function? Anyways thanks for putting me in a direction. -
wingnutwn started following GUI Teleport Menu with Map
-
Looking for some advice on my GUI which I always seem to have problems understanding. I have created a GUI for a teleport script, I have a listbox that all the possible places to teleport to has below that teleport button and so on with a map inside the screen. what I would like to do is when I click on say the HQ in the listbox the map moves to the position.
-
Coding OBJ with Marker that is destructible.
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thank you for your expertise, I will give this a whirl and see if I can get it to work. Again, thanks. -
Coding OBJ with Marker that is destructible.
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Harsh, I like it. Yeah I'm old and teaching myself at least I just learned that I can setpos of _wngrpb1 to _loc rather then moveingunner from this and I should hint my variables. I'll get there maybe someday - maybe. And I'm playing with ESS (enemy spawning system) and trying to manipulate the spawning of things to my liking. Here is the script that I chose to play with. /* Enemy Spawning System (ESS) - by Enigx ESS_Launch.sqf */ params ["_fazioneESS","_sideInd","_ESSAreaMkr","_UNpatrol","_UNhouse","_sttc","_lghtarray","_hvyarray","_wnbarracksarray","_wnXYsize","_distance"]; _numFT = _UNpatrol select 0; _unitsXteamMax = _Unpatrol select 1; _groupInBuild = _UNhouse select 0; _numUnitInBuild = _UNhouse select 1; _NumStatic = _sttc select 0; _NumLghVeh = _lghtarray select 0;_patlght = _lghtarray select 1;_lghtProb = _lghtarray select 2; _NumHvyVeh = _hvyarray select 0;_pathvy = _hvyarray select 1;_numwnbarracks = _wnbarracksarray select 0; _mkrX = _wnXYsize select 0; _mkrY = _wnXYsize select 1; private ["_temparrayUn","_temparrayStc","_temparrayLghVeh","_temparrayHvyVeh","_temparraywnbarracks","_grpB","_grpC","_grpD","_grpE","_newpos","_UnInVeh"]; systemchat format ['%1',_fazioneESS]; _mPos = getMarkerPos _ESSAreaMkr; _mkrAgl = markerDir _ESSAreaMkr; // Initiate the ESS zone and activation trigger //_ESSAreaMkr setMarkerAlpha 1; //_essActivated = createTrigger ["EmptyDetector",_mPos]; //_essActivated setTriggerArea [2000,2000,0,FALSE,150]; //_essActivated setTriggerActivation ["ANYPLAYER","PRESENT",false]; //_essActivated setTriggerTimeout [1, 1, 1, true]; //_essActivated setTriggerStatements ["this","",""]; //waituntil {triggeractivated _essActivated}; // wait until players in area // Impose sleep time to avoid overlapping spawn calling _TempSpawn = 0.1; // definition of the faction to be used _temparrayUn = ([_fazioneESS] call ESS_fnc_getunit) select 0; _temparrayStc = ([_fazioneESS] call ESS_fnc_getunit) select 1; _temparrayLghVeh = ([_fazioneESS] call ESS_fnc_getunit) select 2; _temparrayHvyVeh = ([_fazioneESS] call ESS_fnc_getunit) select 3; _temparraywnbarracks = ([_fazioneESS] call ESS_fnc_getunit) select 4; // Spawn of patrolling units for "_i" from 1 to _numFT do { sleep _TempSpawn; _p1 = [_ESSAreaMkr] call SHK_pos; sleep _TempSpawn; _p2 = [_ESSAreaMkr] call SHK_pos; sleep _TempSpawn; _p3 = [_ESSAreaMkr] call SHK_pos; sleep _TempSpawn; _p4 = [_ESSAreaMkr] call SHK_pos; sleep _TempSpawn; _p5 = [_ESSAreaMkr] call SHK_pos; sleep _TempSpawn; _nFT = floor(random _unitsXteamMax); private _EnemyFireTeam = []; for "_k" from 0 to _nFT do { _EnemyFireTeam pushBack (selectRandom _temparrayUn); }; null = ["O_G_Offroad_01_F",0, _EnemyFireTeam, [_p1,_p2,_p3,_p4,_p5],_sideInd] execVM "ESS_system\functions\ESS_Enemy_patrol_V2.sqf"; sleep _TempSpawn; }; // Spawn of units in buildings for "_i" from 1 to _groupInBuild do { sleep _TempSpawn; _pB = [_ESSAreaMkr] call SHK_pos; _grpB = createGroup [_sideInd, true]; for "_j" from 0 to floor(random(_numUnitInBuild)) do { _UnB = _grpB createUnit [selectRandom _temparrayUn, _pB, [], 0, "FORM"]; [_UnB] join _grpB; }; 0 = [_pB, units _grpB, 50,false,false,true,false] execVM "ESS_system\functions\Zen_OccupyHouse.sqf"; }; // Spawn of static turrets for "_i" from 1 to _NumStatic do { sleep _TempSpawn; _pC=[_ESSAreaMkr,50] call ESS_fnc_findSafePos; _staticOBJ = createVehicle [selectRandom _temparrayStc, _pC,[], 0,"FORM"]; wn_enemy_static append [_staticOBJ]; _grpC = createGroup [_sideInd, true]; _UnC = _grpC createUnit [selectRandom _temparrayUn, _pC, [], 0, "FORM"]; [_UnC] join _grpC; _UnC moveingunner _staticOBJ; }; // Spawn of light vehicles if (_patlght == 0) then { for "_i" from 1 to _NumLghVeh do { sleep _TempSpawn; _pD = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _VehLghClass = selectRandom _temparrayLghVeh; _VehLgh = createVehicle [_VehLghClass, _pD, [], 0, "NONE"]; wn_enemy_light append [_VehLgh]; _grpD = createGroup [_sideInd, true]; _dvrD = _grpD createUnit [selectRandom _temparrayUn, _pD, [], 0, "FORM"]; _gnrD = _grpD createUnit [selectRandom _temparrayUn, _pD, [], 0, "FORM"]; [_dvrD,_gnrD] join _grpD; _dvrD moveInDriver _VehLgh; if ((!isNull gunner _VehLgh) || (_VehLgh emptyPositions "gunner">0)) then {_gnrD moveInGunner _VehLgh;} else {_gnrD moveincargo _VehLgh;}; _chance = random 100; if (_chance < _lghtProb) then { _numCrewTot = ([_VehLghClass, true] call BIS_fnc_crewCount); _numCrew = ([_VehLghClass, false] call BIS_fnc_crewCount); _numCargo = _numCrewTot - _numCrew -1; for "_k" from 1 to _numCargo do { _crewD = _grpD createUnit [selectRandom _temparrayUn, _pD, [], 0, "FORM"]; [_crewD] join _grpD; _crewD moveInAny _VehLgh; }; }; }; } else { for "_i" from 1 to _NumLghVeh do { sleep _TempSpawn; _pp1 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _pp2 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _pp3 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _pp4 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _pp5 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; _VehLghClass = selectRandom _temparrayLghVeh; _chance = random 100; if (_chance < _lghtProb) then { _numCrewTot = ([_VehLghClass, true] call BIS_fnc_crewCount); _numCrew = ([_VehLghClass, false] call BIS_fnc_crewCount); _numCargo = _numCrewTot - _numCrew -1; _VehLgh = createVehicle [_VehLghClass, _pp1, [], 0, "NONE"]; wn_enemy_light append [_VehLgh]; _grpF = createGroup [_sideInd, true]; _dvrF = _grpF createUnit [selectRandom _temparrayUn, _pp1, [], 0, "FORM"]; _gnrF = _grpF createUnit [selectRandom _temparrayUn, _pp1, [], 0, "FORM"]; [_dvrF,_gnrf] join _grpF; _dvrF moveInDriver _VehLgh; if ((!isNull gunner _VehLgh) || (_VehLgh emptyPositions "gunner">0)) then {_gnrF moveInGunner _VehLgh;} else {_gnrF moveincargo _VehLgh;}; for "_k" from 1 to _numCargo do { _crewF = _grpF createUnit [selectRandom _temparrayUn, _pp1, [], 0, "FORM"]; [_crewF] join _grpF; _crewF moveInAny _VehLgh; }; _VehLgh limitSpeed 30; _EnGrp = group _VehLgh; _wpts = [_pp1,_pp2,_pp3,_pp4,_pp5]; for "_k" from 0 to 4 do { _wp = _EnGrp addWaypoint [_wpts select _k, 0]; _wp setWaypointType "MOVE"; _wp setWaypointBehaviour "SAFE"; _wp setWaypointCombatMode "YELLOW"; _wp setWaypointSpeed "LIMITED"; }; _wp = _EnGrp addWaypoint [[(_pp5 # 0)+2,(_pp5 # 1)+2,0], 0]; _wp setWaypointType "CYCLE"; } else { null = [_VehLghClass,1, [selectRandom _temparrayUn,selectRandom _temparrayUn], [_pp1,_pp2,_pp3,_pp4,_pp5],_sideInd] execVM "ESS_system\functions\ESS_Enemy_patrol_V2.sqf"; }; sleep _TempSpawn; }; }; // Spawn of heavy vehicles if (_pathvy == 0) then { for "_i" from 1 to _NumHvyVeh do { sleep _TempSpawn; _pE = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _VehHvy = createVehicle [selectRandom _temparrayHvyVeh, _pE, [], 0, "NONE"]; wn_enemy_heavy append [_VehHvy]; _grpE = createGroup [_sideInd, true]; _dvrE = _grpE createUnit [selectRandom _temparrayUn, _pE, [], 0, "FORM"]; _gnrE = _grpE createUnit [selectRandom _temparrayUn, _pE, [], 0, "FORM"]; [_dvrE,_gnrE] join _grpE; _gnrE moveInDriver _VehHvy; if ((!isNull gunner _VehHvy) || (_VehHvy emptyPositions "gunner">0)) then {_gnrE moveInGunner _VehHvy;} else {_gnrE moveincargo _VehHvy;}; }; } else { for "_i" from 1 to _NumHvyVeh do { sleep _TempSpawn; _ppv1 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _ppv2 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _ppv3 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _ppv4 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; sleep _TempSpawn; _ppv5 = [_ESSAreaMkr,50] call ESS_fnc_findSafePos; null = [selectRandom _temparrayHvyVeh,1, [selectRandom _temparrayUn,selectRandom _temparrayUn], [_ppv1,_ppv2,_ppv3,_ppv4,_ppv5],_sideInd] execVM "ESS_system\functions\ESS_Enemy_patrol_V2.sqf"; sleep _TempSpawn; }; }; sleep _TempSpawn; // Spawn Barracks wn_barracks = _numwnbarracks; for "_i" from 1 to _numwnbarracks do { sleep _TempSpawn; _wn_b_marker = format ['Bunker_%1',_i]; _loc = [_ESSAreaMkr, 50] call ESS_fnc_findSafePos; _marker = createMarker [_wn_b_marker,_loc]; _wn_b_marker setMarkerType "mil_objective";_wn_b_marker setMarkerText "Barracks";_wn_b_marker setMarkerAlpha 0.4;_wn_b_marker setMarkerColor "ColorBlack"; wn_barracks_pos append _loc; // _wn_barracks = [_loc, random(360), call (compile (preprocessFileLineNumbers "comp\wn_barracks.sqf"))] call BIS_fnc_ObjectsMapper; _wn_barracks = createVehicle [selectRandom _temparraywnbarracks,_loc,[],0,"CAN_COLLIDE"]; _wngrpb = createGroup [east, true]; _wngrpb1 = _wngrpb createUnit [selectRandom _temparrayUn, _loc, [], 0, "FORM"]; _wngrpb1 moveingunner _wn_barracks; }; I have added things on lines 8,11,12,96,112,150,189 and 216-232. 216-232 was my question. I wanted to make barracks which I'm using " _wnbarracks_type = ["Land_BagBunker_01_large_green_F", "Land_BagBunker_Large_F"];" code pulling from another script to randomly pick one or the other and placing it on a random position. Ultimately when the barracks is destroyed it would give you points. Good talk and thanks for the motivation! -
Coding OBJ with Marker that is destructible.
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Thanks Pierre, and I love you addons! So I got the code to work and do what I want it to do. wn_barracks = _numwnbarracks; for "_i" from 1 to _numwnbarracks do { _wn_b_marker = format ['Bunker_%1',_i]; _loc = [_ESSAreaMkr, 50] call ESS_fnc_findSafePos; _marker = createMarker [_wn_b_marker,_loc]; _wn_b_marker setMarkerType "mil_objective";_wn_b_marker setMarkerText "Barracks";_wn_b_marker setMarkerAlpha 0.4;_wn_b_marker setMarkerColor "ColorRed"; wn_barracks_pos append _loc; _wn_barracks = createVehicle [selectRandom _temparraywnbarracks,_loc]; _wngrpb = createGroup [east, true]; _wngrpb1 = _wngrpb createUnit [selectRandom _temparrayUn, _loc, [], 0, "FORM"]; _wngrpb1 moveingunner _wn_barracks; }; Now I need to figure out how to make the _wn_barracks = createVehicle [selectRandom _temparraywnbarracks,_loc]; which are to bag_bunkers to be destroyable. Then I can figure out how to do a !alive bag_bunker count thing. Anyways thanks for looking at it, and if you have any ideas on how to set the attributes in the above scope to make them destroyable please let me know. I'm thinking I need to give them each a variable just like the markers so I can "check them"? -
Coding OBJ with Marker that is destructible.
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
I was afraid you would want to see it haha hint 'Creating Barracks'; "wn_barracks_marker" setMarkerShape "ICON";"wn_barracks_marker" setMarkerType "mil_warning";"wn_barracks_marker" setMarkerBrush "SOLID";"wn_barracks_marker" setMarkerDir 0;"wn_barracks_marker" setMarkerColor "ColorRed";"wn_barracks_marker" setMarkerText "Enemy Barracks"; missionNamespace setVariable ["wn_barracks_pos",[]]; wn_barracks = _numwnbarracks; for "_i" from 1 to _numwnbarracks do { _loc = [_ESSAreaMkr, 50] call ESS_fnc_findSafePos; wn_barracks_pos append _loc; _wn_barracks = createVehicle [selectRandom _temparraywnbarracks,_loc]; // _wn_barracks_marker = createMarker ["wn_barracks_marker",_loc]; _wngrpb = createGroup [east, true]; _wngrpb1 = _wngrpb createUnit [selectRandom _temparrayUn, _loc, [], 0, "FORM"]; _wngrpb1 moveingunner _wn_barracks; switch (_i) do { case "1" : {_wn_barracks_marker1 = createMarker ["wn_barracks_marker",_loc]}; case "2" : {_wn_barracks_marker2 = createMarker ["wn_barracks_marker",_loc]}; case "3" : {_wn_barracks_marker3 = createMarker ["wn_barracks_marker",_loc]}; case "4" : {_wn_barracks_marker4 = createMarker ["wn_barracks_marker",_loc]}; case "5" : {_wn_barracks_marker5 = createMarker ["wn_barracks_marker",_loc]}; case "6" : {_wn_barracks_marker6 = createMarker ["wn_barracks_marker",_loc]}; }; }; -
Coding OBJ with Marker that is destructible.
wingnutwn posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I'm trying to create _x barracks, make them destructible and set markers on them. I can make the barracks and save the positions in an array, I can't seem to make markers on them (only 1 is creating) and they buildings are not destructible. So any of you real coders want to write up some code I would sure appreciate it so I can learn how to do it, if its even possible. Maybe I'm trying to do too much in one "for "_i" from 1 to _numwnbarracks do {"? Thanks in advance. -
CAS being called from cfgCommand
wingnutwn replied to wingnutwn's topic in ARMA 3 - MISSION EDITING & SCRIPTING
Larrow, thank you that work flawlessly. -
Hoping one of you pro-programmers can help me out. I'm trying to call (3) different cas types in MP from the CFGCommand menu. This works great from launching a server from EDEN but once it goes dedicated not so much. INIT.SQF wncas2 = [ ["Cas",false], ["CAS Gun and Run",[2],"",-5,[["expression","[cursorTarget,300,'B_Plane_CAS_01_F',0] execVM 'scripts\casgun.sqf';"]],"1","1"], ["CAS Gun and Missle",[3],"",-5,[["expression","[cursorTarget,300,'B_Plane_CAS_01_F',1] execVM 'scripts\casgr.sqf';"]],"1","1"], ["CAS Missle",[4],"",-5,[["expression","[cursorTarget,300,'B_Plane_Fighter_01_Stealth_F',2] execVM 'scripts\casmissle.sqf';"]],"1","1"] ]; CASGUN.SQF hint "CAS Gun and Run Strike inbound!"; _position = screenToWorld [0.5,0.5]; _direction = round(random 360); _logic = "Logic" createVehicleLocal _position; _logic enableSimulationGlobal false; _logic hideObjectGlobal true; _logic setDir _direction; _logic setVariable ["vehicle",_vehicle]; _logic setVariable ["type",_type]; [_logic,nil,true] spawn BIS_fnc_moduleCAS; [_logic] Spawn { sleep 5; deleteVehicle (_this select 0); Yeah I know my coding and formatting is terrible - I'm old. I have tried using remoteExec and remoteExecCall again it works great locally. This idea stems from Xeno's domination scripts which are way over my paygrade. And now that I'm posting this I'm missing a } at then end - would that break it? Thanks for any suggestions.
-
Fast Sea Frame - FSF-1 - Sea Fighter
wingnutwn replied to [aps]gnat's topic in ARMA 2 & OA - ADDONS & MODS: COMPLETE
Yep I know I'm a new guy, especially at the coding, I have downloaded just about all your scripts (from several sites) looking for your Lash.sqf file, any help on its location, and I guess along with the Position.sqf, which sounds like it would be easier to use. Now for the compliments, Thank you for all of your hard work, really makes adding new content easy and interesting. Wing -
ARMA2 & OA's Steam Thread: All Steam Q's/discussions go here [covered by Dwarden]
wingnutwn replied to gimpymoo's topic in ARMA 2 & OA - TROUBLESHOOTING
Resolved....