-
Content Count
9181 -
Joined
-
Last visited
-
Medals
-
Medals
Everything posted by kylania
-
Shooting from HMMWV passenger seats.
kylania replied to LibertyBull's topic in ARMA 2 & OA : ADDONS - Configs & Scripting
Works in VBS2: -
Respawning on LHD
kylania replied to Durka-Durka's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Is this map Utes and the LHD in question the default one? If so, 15.6 - 16 is perfect for most of the deck area. If you're using ArmATech's LHD spawner on Chernarus or you've manually placed it you'll need to play around with the heights though I think. -
Loop it :)
-
heli transport service with 1.03?
kylania replied to der.hannes's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
The init.sqf Meatball. I noticed that the code stopped working in 1.03 as well, my demo mission didn't work. Odd. -
Removing Driver (not G-cards)
kylania replied to RazorHead1's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
What vehicle is it? nuxil's idea would work, but then you'd have some dude standing around, and if he's grouped would probably be told to get back in unless you unassign him, which just adds more complexity to what's a very simple thing if we only knew what vehicle you're talking about. :) -
Removing Driver (not G-cards)
kylania replied to RazorHead1's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Why wouldn't you use an empty vehicle? What are you trying to do exactly? -
Desperate for help.
kylania replied to Trevon's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Step One: Use no scripts. Step Two: Make a simple encounter using just the editor Step Three: If Step Two made your head hurt, just play the game. :) If not, read this forum extensively and learn. -
Heli/Plane Spawn (Crashing)
kylania replied to Nemorz's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
A variable with an underscore ahead of it is a "local" variable (ie: _input or _myLocalVariable) and is only valid within it's specific "code block". So in these scripts you can refer to something as _thing but outside (globally) other scripts won't know what you're talking about. In short, use _variableName for variables you only need within the single script, anything you'll be referring to elsewhere you'll want to use variableName which would be a global variable everything can see. In BlackAlpha's example this code creates the chopper: //Create vehicle using above start position; set a random direction (360); use above type; use above group. _data = [_startpos, random 360, _type, _grp] call BIS_fnc_spawnVehicle; _chopper = _data select 0; _chopper will be the chopper's object only for that script. If he'd used chopper = _data select 0; then he'd be able to refer to the object "chopper" (the helo) elsewhere in the mission. -
If you're running it on a server the server would need it as well.
-
onmapsingleclick problem
kylania replied to Chaos's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
No, you don't need both, you just seem to be writing code in some strange mixture of SQS (the #marker stuff, that was used in SQS for goTo and is vile. :P) and SQF (sleep 2;) so I was showing you the difference between the two syntax. -
onmapsingleclick problem
kylania replied to Chaos's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Did you somehow completely miss my TWO answers to this question already posted? Completely ditch your goto mess and use the code I posted earlier. Here's your code, including the dialog and dynamic marker creation: markmoved = true; MV_EAGLE1 sideChat "this is eagle one... standing by for orders, over."; sleep 2; hint "Click on map for extract LZ"; onMapSingleClick "LZmarker = createMarker[""LZE"",_pos];""LZE"" setMarkerShape ""ICON"";""LZE"" setMarkerType ""mil_pickup"";""LZE"" setMarkerColor ""ColorGreen"";;markmoved=false"; waitUntil{!markmoved}; onMapSingleClick ""; hint ""; _pickup = getMarkerPos "LZE"; MV_EAGLE1 doMove _pickup; But really, to be honest you'd be much better off using the SOM module and transport option than trying to reinvent the wheel this way since once you get this part done you're gonna have to add in landing, waiting, and bringing you somewhere. All of that is automated with the SOM module. -
Heli/Plane Spawn (Crashing)
kylania replied to Nemorz's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Are there already Russian units on the map? If not you'll need to create a "Center" for them. Either via createCenter or simply place an OPFOR Rifleman on the map anywhere and make him "Probability of Presence" = 0%. To test this spawn the helo right next to your player on the ground so you can see if the crew is created or not. -
Heli/Plane Spawn (Crashing)
kylania replied to Nemorz's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Use moveInDriver instead of the non-existent getInDriver. Or use Functions and the BIS_fnc_spawnvehicle function. 1 line of code vs 5. :) -
I'd suggest moving the radio triggers to the bottom of the radio list (Juliet and up instead of Alpha and down) if not turning this into a Communications or addAction menu system which might be preferable. Claiming the most common Radio actions seems a little invasive. Otherwise, great suite of scripts! :)
-
Vehicle drop from C130
kylania replied to frattonstation's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
This is a rewrite of some code from another thread. Basically I rewrote the script to use more BIS functions and map click to select the drop zone. Just preplace the "ingress" marker where you want them to spawn and the "egress" marker where you want them to delete. [color="SeaGreen"]////////////////////////////////////////////////////////////////// // Function file for Armed Assault // Created by: 1ID-CPL. Venori ////////////////////////////////////////////////////////////////// // Preplace Functions module, "egress" and "ingress" markers on the map. /* null = ["ingressMarkerName","egressMarkerName",["HMMWV","reammobox"]] execVM "SD_Airdrop.sqf"; */[/color] [color="SeaGreen"]// Input[/color] _in = _this select 0; // ingress marker name _out = _this select 1; // egress marker name _items = _this select 2; // Item array SD_item1 = _items select 0; // First item SD_item2 = _items select 1; // Second item [color="SeaGreen"]// Config[/color] _mapMarkText = "Click on the map to designate the supply drop LZ"; _closeMapMessage = "Close the map to initiate drop procedure"; _droppoint = "SD_DropMarker"; _dropMarkerType = "SupplyVehicle"; _incomingMessage = "This is eagle one, we are inbound with supply drop, please stand by..."; _triggerDistance = 200; [color="SeaGreen"]// Map click to determine where the supplies will be dropped.[/color] SD_dropmarked = true; hint _mapMarkText; _mapString = format["SD_DropMarker = createMarker [""%1"", _pos]; ""%1"" setMarkerType ""%2"";;SD_dropmarked=false",_droppoint, _dropMarkerType]; onMapSingleClick _mapString; waitUntil{!SD_dropmarked}; onMapSingleClick ""; [color="SeaGreen"]// Wait till they close the map to continue.[/color] hint _closeMapMessage; waitUntil{!visibleMap}; hintSilent ""; [color="SeaGreen"]// Have the player toss smoke to mark the spot.[/color] player playAction "ThrowGrenade"; sleep 2; SD_smokePot = "Fuel_can" createVehicle (getMarkerPos _droppoint); [sD_smokePot, [0.4,0.8,0.4]] spawn { _sh=_this select 0; _col=_this select 1; _c1=_col select 0; _c2=_col select 1; _c3=_col select 2; sleep (3+random 1); _source = "#particlesource" createVehicleLocal getpos _sh; _source setParticleParams [["\Ca\Data\ParticleEffects\Universal\Universal", 16, 7, 48], "", "Billboard", 1, 20, [0, 0, 0], [0.2, 0.1, 0.1], 0, 1.277, 1, 0.025, [0.1, 2, 6], [[_c1, _c2, _c3, 0.2], [_c1, _c2, _c3, 0.05], [_c1, _c2, _c3, 0]], [1.5,0.5], 1, 0.04, "", "", _sh]; _source setParticleRandom [2, [0, 0, 0], [0.25, 0.25, 0.25], 0, 0.5, [0, 0, 0, 0.1], 0, 0, 10]; _source setDropInterval 0.03; _source2 = "#particlesource" createVehicleLocal getpos _sh; _source2 setParticleParams [["\Ca\Data\ParticleEffects\Universal\Universal", 16, 12, 8, 0], "", "Billboard", 1, 20, [0, 0, 0], [0.2, 0.1, 0.1], 0, 1.277, 1, 0.025, [0.1, 2, 6], [[_c1, _c2, _c3, 1], [_c1, _c2, _c3, 0.5], [_c1, _c2, _c3, 0]], [0.2], 1, 0.04, "", "", _sh]; _source2 setParticleRandom [2, [0, 0, 0], [0.25, 0.25, 0.25], 0, 0.5, [0, 0, 0, 0.2], 0, 0, 360]; _source2 setDropInterval 0.03; }; [color="SeaGreen"]// Create the group and spawn 2 C130s named SD_c1 and SD_c2[/color] SD_dg = creategroup west; _dp = [[(getMarkerPos _in) select 0, (getMarkerPos _in) select 1, 50], 270, "C130J", SD_dg] call BIS_fnc_spawnVehicle; sleep 2; _dp2 = [[(getMarkerPos _in) select 0, (getMarkerPos _in) select 1, 50], 270, "C130J", SD_dg] call BIS_fnc_spawnVehicle; SD_c1 = _dp select 0; SD_c2 = _dp2 select 0; SD_planelist = [sD_c1,SD_c2]; [color="SeaGreen"]// Make them fly pretty.[/color] SD_dg setFormation "COLUMN"; SD_c1 flyinHeight 150; SD_c2 flyinHeight 200; [color="SeaGreen"] // Set the first waypoint to where the marker was placed, second to the egress point.[/color] _wp = SD_dg addWaypoint [getMarkerpos _droppoint, 1]; _wp1 = SD_dg addWaypoint [getMarkerPos _out, 2]; [color="SeaGreen"]// Delete the crew and planes once they hit the egress point.[/color] [sD_dg, 2] setWaypointStatements ["true", "{{deleteVehicle _x} forEach crew _x;} foreach units SD_dg; {deletevehicle _x} foreach SD_planelist;"]; [color="SeaGreen"]// Spawn code for organized drop. First plane hits the marker and drops the first item and three seconds later the trailing plane drops it's cargo. // This is to prevent a turn towards egress from failing to bring the second plane close enough to the trigger to activate.[/color] SD_dropCode = {[sD_c1,SD_item1] call BIS_fnc_supplyDrop; sleep 3; [sD_c2,SD_item2] call BIS_fnc_supplyDrop; deleteVehicle SD_smokePot;}; [color="SeaGreen"]// Set up the trigger for the first plane at the location of the drop marker.[/color] _dt = createTrigger ["EmptyDetector", [0,0,0]]; _dt setTriggerArea [0, 0, 0, true]; _dt setTriggerActivation ["NONE", "PRESENT", false]; _triggerStatements = format["SD_c1 distance (getMarkerPos ""%1"") <= %2;",_droppoint,_triggerDistance]; _dt setTriggerStatements [_triggerStatements, "[] spawn SD_dropCode;", ""]; [color="SeaGreen"] // Alert player that the supply drop is incoming.[/color] sleep 5; (driver SD_c1) sideChat _incomingMessage; -
The objStatus and obj_1 = true stuff is for the ArmA style objectives and briefings, don't need to do that anymore. I'm a little confused about your mission and how it works? Am I correct in this summary:
-
music?
kylania replied to TechnoTerrorist303's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
It's a file you create in your mission folder, like any SQF or SQS file. -
Intro camera help "IT WON'T END"
kylania replied to GTO's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
JDog is saying you should notice that you created a camera called "_camera" but you're trying to destroy a camera called "_cam". Hence the camera you started with isn't destroyed. Try camDestroy _camera at the end. -
Assuming you have properly setup your briefing.sqf, try something like this in your first objective's trigger: tskObjective1 setTaskState "SUCCEEDED"; hint "Objective 1 is complete!"; player setCurrentTask tskObjective2; If they failed it, as in he dies, you can use FAILED instead of SUCCEEDED.
-
onmapsingleclick problem
kylania replied to Chaos's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Replace what you have with this: SQS: markmoved=true hint "Click on map for extract LZ" onMapSingleClick """LZE"" setMarkerpos _pos;markmoved=false" @!markmoved onMapSingleClick "" hint "" _pickup = getMarkerPos "LZE" MV_EAGLE1 doMove _pickup SQF: markmoved = true; hint "Click on map for extract LZ"; onMapSingleClick """LZE"" setMarkerpos _pos;markmoved=false"; waitUntil{!markmoved}; onMapSingleClick ""; hint ""; _pickup = getMarkerPos "LZE"; MV_EAGLE1 doMove _pickup; -
Disable for everyone: In your Description.ext: showMap = 0; Disable for single unit: In unit's init field: this removeWeapon "ItemMap";
-
respawn player / delete missions
kylania replied to Elbows's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Elbows, you didn't have to read the 333 page manual, you could have just Ctrl-F and searched the document for "respawn" and found your answer in section 7.5 The different ways to respawn page 227, or you could have searched here on the forums. Granted the forum search would have been more difficult to figure out, but eventually you might have found your way here: http://community.bistudio.com/wiki/Description.ext#Respawn... And yes, this is probably going to be the response to people that ignore the "SEARCH BEFORE POSTING" sticky in this forum or upfront admit that they have documentation handy but aren't going to bother using it. This is a community supported help forum in which BIS only posts infrequently. So you're asking other players for answers. While there's plenty of us quite willing to answer questions and help people become better scripters we're all busy with our own work, lives and scripting (not to mention trying to play the game once and awhile!) that if we see someone that's not even bothering to Ctrl-F, we probably will shun them or something, since they seemingly aren't worth the effort of helping. Insulting the people who you're expecting to do your work for you isn't a good first step. Read more, listen more, explore more, try things out more then ask questions. Some of the best answers in this forum have come from the scripting rock stars have seen someone that put forth their best effort to figure something out and just missed it, then they are given great answers that explain how to do what they tried and how to do it better. -
Add Unit To Group
kylania replied to IndeedPete's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
http://community.bistudio.com/wiki/join [unit] join group; -
running an sqs from inside an sqf?
kylania replied to {USI}_Zombie's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Personally I'd make one SQF script that takes 2 arguments, unitName and unitLoadoutCode. Then have part of the SQF script strip all weapons/items and add in the common items everyone gets, then use a case statement to finish the outfitting. like: [u1,"teamLead"] execVM unitOutfit.sqf; -
*bash* Welcome! :)