Jump to content

demonized

Member
  • Content Count

    2658
  • Joined

  • Last visited

  • Medals

Everything posted by demonized

  1. on act: (vehicle player) setFuel 0; triggers beheave local in MP so should be no problem there.
  2. demonized

    Help with landing UAV

    maybe this command works for UAV too: http://community.bistudio.com/wiki/landAt
  3. clients can spawn AI no problem, if downed pilot is found on player/client, and he spawns the units no problem. the above condition will never fire on the server, however this will, but only once until all players are above 2 meter again. ({(getPos _x select 2) < 2} count playableUnits) != 0
  4. try using (units _from) orderGetIn false; after the unassignVehicle part.
  5. Save this as scriptName.sqf and when you need to spawn anything, run this code: _null = ["markerName",500] execVM "scriptName.sqf"; markerName is where they spawn and the area they will patrrol, 500 is the ca diameter from center of marker wich they will patrol, (will patrol within this range). scriptName.sqf // BIS_TK_INS cfgGroups infantry, group will be selected randomly from this. _TK_INS_groups = ["TK_INS_Group", "TK_INS_Patrol", "TK_INS_AATeam", "TK_INS_ATTeam"]; waituntil {!isnil "bis_fnc_init"}; _markerPos = getMarkerPos (_this select 0); _grp = [_markerPos, east, (configFile >> "CfgGroups" >> "East" >> "BIS_TK_INS" >> "Infantry" >> (_TK_INS_groups select (floor(random(count _TK_INS_groups)))))] call BIS_fnc_spawnGroup; [_grp, _markerPos, (_this select 1)] call bis_fnc_taskPatrol; Edit: remember to place the functions module on map.
  6. if all zombies are for example opfor, you could simply run a continous loop to add the reveal to them, a little change to celerys code. For example, if all zombies are opfor (EAST) and are spawned randomly throughout the mission: save script and run it from init.sqf or a init somewhere. Will reveal units closer than 300 to teamleader to all opfor teams each 10 seconds, no need to specify groups as script updates each turn (10 seconds) if (!isServer) exitWith {}; while {true} do { { if (side _x == east AND (count (units _x)) > 0) then { _grp = _x; { if ( ((leader _grp) distance _x) < 300) then { _grp reveal [_x,4]; }; } forEach allUnits; }; } foreach allGroups; sleep 10; };
  7. yeah, i just guessed first with getText civilian instead of number before i checked Six config browser :D Edit: however there was required some additional code since vehicles seems to be taken first in thisList so passengers exited vehicle upon delete and trigger never reactivated, hence the iskindof and crew part of code. And the condition part needed to be so or use a global variable to turn on / off trigger since empty bluefor vehicles registrers as civilian and they also stopped the trigger from reactivating.
  8. Edit 2: tested in SinglePlayer civilian present repeated trigger. condition: ({(getNumber (configFile >> "CfgVehicles" >> (typeOf _x) >> "side")) == 3} count thisList) > 0 on act: { if (!isNull _x AND (getNumber (configFile >> "CfgVehicles" >> (typeOf _x) >> "side")) == 3) then { if (!(_x isKindOf "Man")) then {{_x setPos (getPos _x); deleteVehicle _x} foreach crew _x}; _x setPos (getPos _x); deleteVehicle _x; }; } foreach thisList; Edit again, added _x setPos (getPos _x); to code outside iskindof check, reason: bus filled with civvis failed to delete all and caused massive FPS drop. Now working without lag.
  9. I use _null all the time in outer editor fields, have been for years, never been a issue for me. It will however not do if you need to reference it with scriptDone command after, wich is bugged somewhat in latest patch anyway.
  10. you could also just use a spawn in the init waiting for the function to be ready for use. place a variable = true; at end of the compiled file. use spawn in init of units or the script that handles the inits. _null = this spawn {waitUntil {!isNil "variable"}; lobj1 = [ [getpos [b]_this[/b] select 0, getpos [b]_this[/b] select 1, 2], [0.0, 0.5, 0.5], 0.05] call Fnc_CreateLight}; Now every units init will wait for function to be ready, then run as expected. And as Sickboy pointed out, this is used in editor, and translates to _this inside the spawn.
  11. if its MP, then triggers beheave like local triggers for players afaik. so a simple condition: (getPos player select 2) < 2 and on act: nul = [player] execVM "spawnGroundHostiles.sqf"; should suffice, though you should add in type check or use setVariable getVariable to differenciate "downed pilots" and "CSAR" units, else script will fire for each of players below 2, unless that does not matter for you. If triggers are set to repeatedly, downed players need to be out of trigger area before it can activate again ofc..
  12. _au = {alive _x AND side _x in [WEST,EAST]} count [url="http://community.bistudio.com/wiki/list"]list[/url] triggerName;
  13. To reuse any variable, simply assign it to something else, but im obviously not getting the question right here. Can you give some more context?
  14. Cant help you with the actual problems you have, but here is where to post any Domination related questions, your best bet of a working solution. http://forums.bistudio.com/showthread.php?t=104827
  15. One way to work around the custom end is to fake it with a new unit on killed eventhandler. Demo mission OA required
  16. demonized

    Couple of questions

    same way as units, press delete when mouse is over marker in editor ;)
  17. reworked script, using a very primitive respawn. Demo mission OA required Edit: Link updated with vehicle fix.
  18. demonized

    Couple of questions

    1: use descriptive titles, yours will not help anyone else trying to search forums for a answer. 2: use search: http://forums.bistudio.com/search.php all questions have been answered in lenght numerous times, atleast 1 and 2. for 3 press markers in editor and youll see the marker you mention.
  19. ye youre right, brainfart there :)
  20. demonized

    Dead AI ?

    makes any AI dead: this setDammage 1; although i think there are a small amount of static dead/bodybags used in A2...
  21. in patch 1.60 knowsabout command is altered to force a number, i think you could force 0 in knowsabout value, though wiki is not yet updated with 1.60 info, so youll need to roam the beta or RC topics for instructions. i think it was something like this: spotterName knowsAbout [targetName,0];
  22. Follow F2k Sel´s instructions with description.ext and use the eventhandler example below. But here is how you auto assign the eventhandlers to all opfor by simply placing this code in 1 unit init or init.sqf, so you dont have to manually paste the code in all units. Though i wonder if its correct syntax used? differs from wiki and what i know. { if (side _x == east) then { _x addEventHandler ["killed", "{if (_this select 1 == _x) then {_x say ['ahh',0]} } count units group player "]; }; } foreach allUnits; Basically what code does: Its same code as F2K Sel posted (hint removed), it goes over all units in mission, if unit is a east unit it will get the eventhandler. make sure to alter the 'ahh' to whatever sound file you use. Also: You mention you want the 6 sounds to be dynamic, i asume you mean a random sound is played each time. If so, this is how you do instead of above code. What the 1 number in the say command wiki example is i have no idea, also it seems say uses 3 params??? typo in wiki maybe? or optional... Anywho, you see code goes through all units once, if side is east then eventhandler is assigned to unit. eventhandker checks if the killer is in player group, then if so it selects 1 soundname from the _sounds array(these are the sounds you have in description.ext and then it plays that sound, it will be a random sound every time. { if (side _x == east) then { _x addEventHandler ["killed", { _killer = _this select 1; if ( _killer in (units (group player)) ) then { _sounds = ["ahh","got_him","boojaa","u_rock",suck_it_biatch","whos_next"]; _sound = _sounds select (floor(random(count _sounds))); _killer say [_sound,1,5]; }; ]; }; } foreach allUnits;
  23. have you tried the disableAI "FSM" command? it is present in patch 1.60.
×