Blueblood
Member-
Content Count
24 -
Joined
-
Last visited
-
Medals
Everything posted by Blueblood
-
Arma 2 Teleport 2 People Limit
Blueblood replied to Loreansz's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You could use inlist then use count to get the number of people in a trigger then compare it to 2 ill write it up for you when im home. -
Set damage and first aid module
Blueblood replied to CMajor28's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You can use setUnconscious _unit setUnconscious true Not sure if he will wake up, if he does just make a while loop -
Searching for a players name
Blueblood replied to Blueblood's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Sweet, Just what I needed thanks -
Searching for a players name
Blueblood posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I had a look around for this and found a few threads but they didn't really help me. I want to be able to compare the in-game names of every player that joins the mission to a predefined name. I know that this is possible with UID's but I would prefer to have the name. Any help would be greatly appreciated! -
I have managed to get the Construction Interface working fine but, I have no idea how to set it up so that items can be placed close to each other. If you place a small wall you can't place another one beside it without leaving a gap. Is there anyway to set it up so that you can place items directly beside each other?
-
Error: Typed string expected object
Blueblood replied to Blueblood's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks it worked! Didn't even think about that. -
Error: Typed string expected object
Blueblood posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I'm trying to create a simple script so that instructors can move targets in a kill house. It was simple enough until I encountered a problem, I'm using a format on a variable so that I can use the same script on every target, In-game the targets are named Tar_1, Tar_2, Tar_3 and so on. I've replicated the same format in a hint and it displays the correct name but when its used with attachTo it gives me the error: Typed string expected object. Here are the addActions: Tar1A = Tar_1 addAction [("<t color=""#FF0000"">" + "Move Target" + "</t>"),"MoveTar.sqf",1]; Tar2A = Tar_2 addAction [("<t color=""#FF0000"">" + "Move Target" + "</t>"),"MoveTar.sqf",2]; Tar3A = Tar_3 addAction [("<t color=""#FF0000"">" + "Move Target" + "</t>"),"MoveTar.sqf",3]; And here is the script to move the target: private ["_Player","_TarNumber","_Target"]; _TarNumber = _this select 3; _Target = format [Tar_%1, _TarNumber]; hint format ["Tar_%1", _TarNumber]; _Target attachTo [player,[0,1,1]]; Any help would be greatly appreciated. -
Error: Typed string expected object
Blueblood replied to Blueblood's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Didn't work -
How can I execute a script on every player login?
Blueblood replied to freakingfred's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
If you put "Local player" inside the condition of a trigger without speech marks it will activate on every player -
preloadCamera - How to use?
Blueblood replied to jts_2009's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You may need to place a preload module on the map -
How to make units eject
Blueblood replied to gerix's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You don't need to specify that its a vehicle so you would use para2 action ["Eject", _cargoPlane]; instead of para2 action ["Eject", vehicle _cargoPlane]; You probably got the "vehicle _cargoPlane" part from the wiki Here. What that does in that instance is ejects him from whatever vehicle he is in, So he could eject from a car and not just the specified C130-J. If you wanted to implement this into your script you would use: para2 action ["Eject", vehicle para2]; -
Checking for an ACE backpack
Blueblood posted a topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I've had a look around for this but I can't seem to find anything about this, I need a way to check if a player has an ACE backpack. I've used the "unitBackpack" command but it will always return a Null Object for ACE backpacks. The reason I need this is for a Fallujah FOB, I'm adding the action to load-up the players backpack with either Light Medical Gear (For non medics) or Full Medical Gear (For medics) I know how to actually add the items but I don't want any script errors whenever someone tries to use it without a backpack. Here is the script: private ["_player","_loadouttype","_player"]; _player = _this select 0; if (HERE IS WHERE I NEED TO CHECK IF THE PLAYER HAS A BACKPACK, EITHER WITH CODE IN HERE OR WITH A VARIABLE) exitWith{hint "You have no backpack!";}; _loadouttype = _this select 3; If (_loadouttype == 1) then { sleep 3; [_player, "ACE_epinephrine", 2] call ACE_fnc_PackMagazine; [_player, "ACE_Morphine", 2] call ACE_fnc_PackMagazine; [_player, "ACE_LargeBandage", 3] call ACE_fnc_PackMagazine; [_player, "ACE_Bandage", 5] call ACE_fnc_PackMagazine; [_player, "ACE_Medkit", 1] call ACE_fnc_PackMagazine; [_player, "ACE_Tourniquet", 1] call ACE_fnc_PackMagazine; hint "Light Medical Gear Loaded!"; }; If (_loadouttype == 2) then { sleep 3; [_player, "ACE_epinephrine", 10] call ACE_fnc_PackMagazine; [_player, "ACE_Morphine", 10] call ACE_fnc_PackMagazine; [_player, "ACE_LargeBandage", 10] call ACE_fnc_PackMagazine; [_player, "ACE_Bandage", 15] call ACE_fnc_PackMagazine; [_player, "ACE_Medkit", 5] call ACE_fnc_PackMagazine; [_player, "ACE_Tourniquet", 2] call ACE_fnc_PackMagazine; hint "Full Medical Gear Loaded!"; }; Any help would be greatly appreciated, Thanks in advance! -
Checking for an ACE backpack
Blueblood replied to Blueblood's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Thanks man! The Function Index will be very useful! -
Convoys Extreme Frustration
Blueblood replied to JohnKalo's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
The AI will detect roads, there is no need to "Draw" a path with waypoints. Simply place a waypoint from A to B and the group leader will decide which way to follow, if mode is set to "Careless" or "Safe" then he will take the most direct route that follows the roads. Hope this helps, but AI have always been a massive pain in the ass. -
Add stuff to ACE Backpacl (Advanced Combat Enivroment)
Blueblood replied to Green-'s topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
For ACE backpacks your need to call an ACE Function: [player, "ACE_Bandage", 1] call ACE_fnc_PackMagazine; -
Little Bird Deathmatch - messages to clients
Blueblood replied to allarvendla's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I don't really understand the question? -
ARMA II Combined AI Arty SideChat Problem
Blueblood replied to khaosmatical's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You can just remove those lines, it will have no effect. Here is the same script without the chat // ------------------------------------------------------------------- //Whollysteve combined AI arty script // //FORWARD-OBSERVER // //from //Nou's Forward Observer Script v0.5 and //[ZSU]Blake aka Blakeace's AI Artillery Framework v1.00 //15/05/2010 // //USAGE //One Forward observer; artillery battery synched to an arty module. thats it. //Put the folder with bith scripts into the mission folder (or mydocs>arma2>scripts for use in the editor) //The map is unpacked to allow for use in the editor, just drop it into mydocs>arma2>missions. // //Put the following into the FO init box: //stuff = [FO_NAME,ARTY_MODULE_NAME,WAIT_TIME,FIRE_AT_SIDE,RANGE,TYPE,SPREAD,ADJUSTS,SALVO,SKILL,VEL_COMPENSATOR,PREP_VALUE] execVM "fo\forward_observer.sqf"; //eg: stuff = [this,ARTY,1,west,1000,"HE",200,2,8,5,10,0] execVM "ForwardObserver\ForwardObserver.sqf"; // //FO_NAME : Name of the Forward Observer //ARTY_MODULE_NAME : Name of the Arty Module synced to your battery //WAIT_TIME : How often does the FO search for targets (1) //FIRE_AT_SIDE : Whose parade do you want to rain on (EAST,WEST,INS) //RANGE : How far out from the FO to look for targets (1000) //TYPE : Type of shot "HE","WP","SMOKE","SADARM","LASER" //SPREAD : Salvo dispersion radius (100) //ADJUSTS : Number of ranging rounds (2) //SALVO : Number of shots in the salvo //SKILL : How good is the arty battery 0-10 bad-good (5) //VEL_COMPENSATOR : Takes into account moving targets (10) //PREP_VALUE : Is the unit already ranged in 0 no, 1 yes (0) // //Some general values are given in brackets // //ENJOY // //THANKS TO: Nou's (Forward Observer Script v0.5) and [ZSU]Blake aka Blakeace (AI Artillery Framework v1.00) for the two great scripts that were the main basis for this piece of work. // //made with Notepad++ // ------------------------------------------------------------------- _battery = _this select 0; _target = _this select 1; _targetCount = _this select 2; _fo = _this select 3; _fm = _this select 4; _type = _this select 5; _spread = _this select 6; //ground spread radius; _adjustments = _this select 7; _pieces = count (units (_battery getVariable "ARTY_LEAD")); _rounds = _this select 8; _skill = _this select 9; //0-10 bad-good skilled; _adjmult = _this select 10; //speed adjuster (10 on foot, 20 for vehicles); _prep = _this select 11; // are they ranged in 0/1 ; if (_prep == 1) then { if(_rounds > 2 and ((ceil (random 15) > 3))) then { //fire initial salvo; //static aimpoint; _targetPos = getPosASL _target; _mrk0 = createMarker ["MortarTarget",_targetPos]; _mrk0 setMarkerColor "ColorBlack"; _mrk0 setMarkerShape "ICON"; _mrk0 setMarkerType "mil_objective"; [_battery, true] call BIS_ARTY_F_SetShellSpawn; // Turn spawn mode on [_battery, ((round (_rounds*12.5)) min 50)] call BIS_ARTY_F_SetDispersion; [_battery, _targetPos, ["IMMEDIATE", "HE", 0, ceil (_rounds/2)]] call BIS_ARTY_F_ExecuteTemplateMission; waitUntil {_battery getVariable "ARTY_ONMISSION"}; waitUntil {!(_battery getVariable "ARTY_ONMISSION")}; waitUntil {_battery getVariable "ARTY_SPLASH"}; sleep ((10-_skill)*2); }; }; if(_rounds > 2 and ((ceil (random 15) > 2))) then { // Do adjust fire mission! // Number of adjustments to do. while {_adjustments > 0} do { _adjustX = ((round (random 50)) + (_adjustments*75)); _adjustY = ((round (random 50)) + (_adjustments*75)); if( round (random 1) == 0) then { _adjustY = _adjustY*-1; }; if( round (random 1) == 0) then { _adjustX = _adjustX*-1; }; _targetPos = getPosASL _target; _mrk1 = createMarker ["MortarTarget",_targetPos]; _mrk1 setMarkerColor "ColorWhite"; _mrk1 setMarkerShape "ICON"; _mrk1 setMarkerType "mil_objective"; _adjustPoint = [((_targetPos select 0) + _adjustX), ((_targetPos select 1) + _adjustY), _targetPos select 2]; [_battery, _adjustPoint, ["IMMEDIATE", "WP", 0, 1]] call BIS_ARTY_F_ExecuteTemplateMission; waitUntil {_battery getVariable "ARTY_ONMISSION"}; waitUntil {!(_battery getVariable "ARTY_ONMISSION")}; waitUntil {_battery getVariable "ARTY_SPLASH"}; sleep ((10-_skill)*3); _adjustments = _adjustments - 1; }; }; sleep ((10-_skill)*3); //ffe start; //aimpoint adjusted for target speed and direction; _adjmax = 300; _adjmin = -300; _error = (10-_skill)*10; _Yadj = speed (_target) * cos (direction (_target)) * _adjmult; if (_Yadj > _adjmax) then {_Yadj = _adjmax}; if (_Yadj < _adjmin) then {_Yadj = _adjmin}; _Xadj = speed (_target) * sin (direction (_target)) * _adjmult; if (_Xadj > _adjmax) then {_Xadj = _adjmax}; if (_Xadj < _adjmin) then {_Xadj = _adjmin}; _impact = [(getpos (_target) select 0) + _Xadj+(random _error - _error/2), (getpos (_target) select 1) + _Yadj+(random _error - _error/2), getpos (_target) select 2]; _mrk2 = createMarker ["MortarTarget",_targetPos]; _mrk2 setMarkerColor "ColorBlack"; _mrk2 setMarkerShape "ICON"; _mrk2 setMarkerType "mil_objective"; [_battery, true] call BIS_ARTY_F_SetShellSpawn; // Turn spawn mode on; [_battery, _spread] call BIS_ARTY_F_SetDispersion; [_battery, _impact, ["IMMEDIATE",_type, 0,_rounds]] call BIS_ARTY_F_ExecuteTemplateMission; //ffe end; waitUntil {_battery getVariable "ARTY_ONMISSION"}; waitUntil {!(_battery getVariable "ARTY_ONMISSION")}; waitUntil {_battery getVariable "ARTY_SPLASH"}; sleep 10; _fo setVariable ["FO_MissionComplete", true, true]; deleteMarker _mrk0; deleteMarker _mrk1; deleteMarker _mrk2; //Put the following into the FO init box: //stuff = [FO_NAME,ARTY_MODULE_NAME,WAIT_TIME,FIRE_AT_SIDE,RANGE,TYPE,SPREAD,ADJUSTS,SALVO,SKILL,VEL_COMPENSATOR,PREP_VALUE] execVM "fo\forward_observer.sqf"; //eg: stuff = [this,ARTY,1,west,1000,"HE",200,2,8,5,10,1] execVM "ForwardObserver\ForwardObserver.sqf"; // //FO_NAME : Name of the Forward Observer //ARTY_MODULE_NAME : Name of the Arty Module synced to your battery //WAIT_TIME : How often does the FO search for targets (1) //FIRE_AT_SIDE : Whose parade do you want to rain on (EAST,WEST,INS) //RANGE : How far out from the FO to look for targets (1000) //TYPE : Type of shot "HE","WP","SMOKE","SADARM","LASER" //SPREAD : Salvo dispersion radius (100) //ADJUSTS : Number of ranging rounds (2) //SALVO : Number of shots in the salvo //SKILL : How good is the arty battery 0-10 bad-good (5) //VEL_COMPENSATOR : Takes into account moving targets (10) //PREP_VALUE : Is the unit already ranged in 0 no, 1 yes (0) // //Some general values are given in brackets // //ENJOY // //THANKS TO: Nou's (Forward Observer Script v0.5) and [ZSU]Blake aka Blakeace (AI Artillery Framework v1.00) for the two great scripts that were the main basis for this piece of work. // //made with Notepad++ // ------------------------------------------------------------------- sleep 5; // This needs to be figured out better, probably needs to watch the arty modules and see when they are done with init. _fo = _this select 0; _battery = _this select 1; _wait = _this select 2; //this is in minutes, min 1 minutes; _side = _this select 3; _range = _this select 4; //search radius; _type = _this select 5; //round type HE,WP,SMOKE,SADARM,LASER; _spread = _this select 6; //spread radius; _adjustments = _this select 7; //number of ranging rounds; _rounds = _this select 8; _skill = _this select 9; //0-10 bad-good skilled; _adjmult = _this select 10; //speed adjuster; _prep = _this select 11; //prep value; _isAssigned = _fo getVariable "FO_Assigned"; _forceMultiplier = 1; _lastMission = [-10000,-10000,0]; if (_wait < 0.5) then { _wait = 0.5; }; if (isNil "_isAssigned") then { _fo setVariable ["FO_Assigned", 1, true]; while {(alive _fo and [_battery] call BIS_ARTY_F_StillViable)} do { _mostCount = 0; _target = null; _units = nearestObjects [_fo, ["LandVehicle", "CAManBase"], _range]; { if (side _x == _side and alive _x) then { _liveCount = 0; _objects = []; _near = nearestObjects [_x, ["LandVehicle", "CAManBase"], 100]; _liveCount = 0; _objects = []; { if(side _x == _side and alive _x and (damage _x) < 0.5) then { _liveCount = _liveCount + 1; _objects = _objects + [_x]; }; } forEach _near; if(_liveCount > _mostCount and (_x distance _lastMission) > 120) then { _forceMultiplier = 1; _tanks = "Tank" countType _objects; _forceMultiplier = _forceMultiplier + (_tanks * 0.33); _apcs = "Wheeled_APC" countType _objects; _forceMultiplier = _forceMultiplier + (_apcs * 0.25); _mostCount = _liveCount; _lastMission = getPos _x; if((leader _x) != _x and ((leader _x) distance _x) <= 100) then { _target = leader _x; } else { _target = _x; }; }; sleep 0.025; } } forEach _units; if( isNil "_target") then { _lastMission = [-10000,-10000,0]; } else { _fo setVariable ["FO_MissionComplete", false, true]; stuff = [_battery,_target,_mostCount,_fo,_forceMultiplier,_type,_spread,_adjustments,_rounds,_skill,_adjmult,_prep] execVM "ForwardObserver\FireMission.sqf"; waitUntil { _fo getVariable "FO_MissionComplete"; }; }; sleep (round (_wait*60)); } } else { }; -
Need Help with RemoveAction
Blueblood replied to elijk88's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
I just noticed what I wrote, I'm sorry about that I must have been tried That needs to go in the Condition field. -
1. To give a player a backpack use - backpack class names can be found Here. this addBackpack "TK_RPG_Backpack_EP1"; 2. To insert items use this addMagazineCargoGlobal ["30Rnd_556x45_Stanag",3]; 3. You can only have a launcher and a backpack if your using ACE I think, I only really play with ACE. 4. I think you may need to take them out but again, I'm not sure on that
-
A trigger dilemma...
Blueblood replied to JohnKalo's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Ok, group the Trigger to the Player and set it too "Present", in the conditions field put: this and vehicle player isKindOf "MAZ_543_SCUD_TK_EP1" and it should activate only when that player is present and is inside the scud. -
Making a Group Invincible via Trigger
Blueblood replied to person915's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
Something like this should work. {_x allowdamage false} foreach units group1 -
How do you add something to a objects init box when spawning from a SQF
Blueblood replied to avibird 1's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You wouldn't necessarily need to you could just do it within the script using the local variable so. man1 = GroupA createUnit ["US_Soldier_SL_EP1", _pos, [], 0, "FORM"]; man1 addWeapon "classname" Myaction = man1 addAction "add action or if you really want to use Init field you can use man1 setVehicleInit "this addWeapon ""classname"";"; processInitCommands; I don't really use init commands when creating a unit as they sometimes won't work for me. -
Need Help with RemoveAction
Blueblood replied to elijk88's topic in ARMA 2 & OA : MISSIONS - Editing & Scripting
You could put this in the trigger/a second trigger with same size area. Blufor Present, Repeated (If you want) Activation - this and ((getpos (thislist select 0)) select 1 < 11) Trigger - (thislist select 0) removeAction _gest1; OR Trigger - nul = execVM "ActRem.sqf"; The hint will be displayed globally, so If its multiplayer you might want to remove it. Sorry if it doesn't work, I'm in school and can't test it. If it doesn't ill post a working solution here when I get home.