Jump to content

Rawshark

Member
  • Content Count

    76
  • Joined

  • Last visited

  • Medals

Community Reputation

10 Good

2 Followers

About Rawshark

  • Rank
    Corporal

Recent Profile Visitors

1065 profile views
  1. I have setup a Mobile HQ where a trigger spawned vehicle can be interacted with via addAction and be set as an infantry spawn point. However, doing so seems to create a respawn marker on the map: Example . Is there any way to remove this from the map or make it invisible? For context, I am calling in a BIS_fnc_addRespawnPosition via a script from an addAction that looks like this: params ["_target", "_caller", "_id", "_args"]; [ side _caller, _target, "MHQ" ] call BIS_fnc_addRespawnPosition; [(_this select 0) removeaction (_this select 2)]; I don't have a clue as to how to proceed from here in hiding that respawn marker. Any help would be amazing, ty!!!
  2. Of course! All this time and it was the brackets that stumped me 😅Thanks for the help
  3. Rawshark

    CBRN Script

    Heya, this is an awesome script! I do want to check though that the features say but you also point out that ACE is needed for medical pain integration. I take it that this means the script wont work if I run ACE without the medical module? Just a very quick test showed that some functionality is lost (checking exposure) with the loss of the medical menu but I thought I would check with you anyway. Thanks again!
  4. Thanks, I might try and do it via a script. Ideally though looking to execute it via a trigger and "ToolKit" in _items as part of the trigger condition doesn't work to activate the hint.
  5. The idea here is that on picking up a toolkit I want a named trigger deleted. I have tried debugging via hints to see if I can get a trigger to activate by picking up a toolkit that would be placed in a player's backpack via "ToolKit" in backpackItems player; but the hint doesn't fire. Anyone know how I could get this to work? Thanks
  6. Hey all, I found this bit of code from the forums pulled from the Eastwinds campaign used to make a designated street lamp flicker. The scrip works as intended for a single street lamp as defined by the script but I am having a heck of a time trying to adapt the code to have the same effect on multiple street lights. // Script Adapted from BIS 'EAST WIND' Campaign // Define #define ON 0 #define OFF 0.97 #define LIGHT "light_1_hitpoint" #define DUMMY "BIS_effectDummy" #define DESTROYED "BIS_lightDestroyed" #define SAMPLE "electricity_loop" #define HELIPAD "Land_HelipadEmpty_F" // Parameters private ["_position", "_type", "_timing", "_delay", "_condition"]; _position = [nearestObject getMarkerPos "Lamp_A"] call BIS_fnc_param; _type = [_this, 1, "Land_LampShabby_F", [""]] call BIS_fnc_param; _timing = [_this, 2, [0.25, 0.50], [[]]] call BIS_fnc_param; _delay = [_this, 3, [1, 2], [[]]] call BIS_fnc_param; _condition = [_this, 4, { true }, [{}]] call BIS_fnc_param; // Find Related Objects private "_object"; _object = nearestObject [_position, _type]; // Make Sure Object Found if (isNull _object) exitWith { ["Object at position (%1), of type (%2) not found", _position, _type] call BIS_fnc_error; }; // Light Starts Off _object setHit [LIGHT, OFF]; //Hit Event Handler _object addEventhandler ["Hit", { (_this select 0) setvariable [DESTROYED, true]; }]; // Effect private "_setState"; _setState = { private ["_object", "_on"]; _object = [_this, 0, objNull, [objNull]] call BIS_fnc_param; _on = [_this, 1, true, [true]] call BIS_fnc_param; // The Dummy Object private "_dummy"; _dummy = objNull; // Has the Dummy Object Been Created? if (isNil { _object getVariable DUMMY }) then { // Create Dummy Object private "_dummy"; _dummy = createVehicle [HELIPAD, position _object, [], 0, "CAN_COLLIDE"]; // Attach to Light Object _dummy attachTo [_object, [0,0,2]]; // Store _object setVariable [DUMMY, _dummy]; } else { _dummy = _object getVariable DUMMY; }; // Effect On Or Off if (_on) then { // Play Effect _dummy setDamage 0; _dummy say3D SAMPLE; _object setHit [LIGHT, ON]; } else { // Destroy Effect _dummy setDamage 1; _object setHit [LIGHT, OFF]; }; }; // Flag private "_lightOn"; _lightOn = false; // Main Loop while _condition do { // Exit If Destroyed if (!isNil { _object getvariable DESTROYED }) exitWith { // Light Off _object setHit [LIGHT, OFF]; // Log ["Light object (%1) was destroyed", _object] call BIS_fnc_log; }; // Blinking Loop for "_i" from 0 to 5 do { // Set State if (_lightOn) then { [_object, false] call _setState; _lightOn = false; } else { [_object, true] call _setState; _lightOn = true; }; // Timing sleep (_timing call BIS_fnc_randomNum); }; // Sleep sleep (_delay call BIS_fnc_randomNum); }; // Does It Exist? if (!isNil { _object getVariable DUMMY }) then { // The Dummy private "_dummy"; _dummy = _object getVariable DUMMY; // Detach And Delete detach _dummy; deleteVehicle _dummy; }; // Return true; The way the script is written, it seems the lamp needs to be defined via a marker. In order to effect multiple lamps I tried defining multiple markers via an array _lamps = [Lamp_A, Lamp_B, Lamp_C] and tried calling the position via the array but that doesn't seem to work. The only way ive gotten it to work is to run multiple versions of the script, each defining a different marker but that is terribly inefficient and is probably not great on the network load. Anyone have any ideas how this script could be tidied up to effect multiple lamps?
  7. Thank you so much. Will just insert it to initPlayerLocal and see how it goes. 😀 Thanks again!
  8. Hey Pierre, Thanks for the reply! Does the following look about right? I didnt get any errors when in the editor but haven't as of yet tested it in MP. findDisplay 12 displayCtrl 51 ctrlAddEventHandler ["Draw",{ { if (_x getVariable ["ACE_unconcious",false]) then { _this select 0 drawIcon ['\A3\ui_f\data\igui\cfg\actions\heal_ca.paa',[1,0,0,1],position _x,24,24,0,name _x,1,0.03,'TahomaB','right'] }; false } count allPlayers }]; Also if I may ask, for a dedicated server would this be better off in an init.sqf or initPlayerLocal.sqf? Thanks again for the help!
  9. Sorry for the bump. Would still love any help as I haven't been able to get it to work.
  10. I was wondering if it was possible to create a script where, once a player goes down, their unconscious position could be marked on the map for all playable units to see. Scouring the internet I found a script where the positions would be revealed to the medics on the map findDisplay 12 displayCtrl 51 ctrlAddEventHandler ["Draw",{ if ([player] call ace_medical_fnc_isMedic) then { { if (_x getVariable ["ACE_unconcious",false]) then { _this select 0 drawIcon ['\A3\ui_f\data\igui\cfg\actions\heal_ca.paa',[1,0,0,1],position _x,24,24,0,name _x,1,0.03,'TahomaB','right'] }; false } count allPlayers }; }] So, to make modify it a bit further would it be possible to edit it like so to make the positions be visible to all playable units? findDisplay 12 displayCtrl 51 ctrlAddEventHandler ["Draw",{ if (player) then { { if (_x getVariable ["ACE_unconcious",false]) then { _this select 0 drawIcon ['\A3\ui_f\data\igui\cfg\actions\heal_ca.paa',[1,0,0,1],position _x,24,24,0,name _x,1,0.03,'TahomaB','right'] }; false } count allPlayers }; }]
  11. Thanks for the reply but this is for a workshop mission (Antistasi). I could probably unpbo the file and do it that way maybe but I was hoping there was a more straightforward way via the CBA setting to just override the clients. I'll look into importing setting though, thanks
  12. I've recently setup a dedicated server and installed Ace on to the mission. Problem is even logged on as admin I cannot seem to make the server override the client settings. So I figured the next option is to force the override via the cba_setting.sqf but I don't exactly know what to put in that file. I took a look in CBA setting github page, do I just enter 'On Server 2 Force: Server > All' into the sqf?
  13. @stburr91 Well, I'll be...that is actually what I was after! It looks a breeze to implement even without the Vop objects (I was just going to re-purpose the ACE vehicle keys anyway). Thanks my dude!
  14. Cheers thanks, I think I see what needs to be done now. Thanks for the advice.
  15. @wogz187 Hey thanks for the link, having taken a look at GOM's post I am not entirely sure how I can best adapt it for my needs. From GOM's post: Unless I am misunderstanding something (again, I am not very good at this) but it looks like the script is: a) checking if a player is the owner of the building b) adds the "unlock door" option to the scroll menu if the player is the owner of the building -else- it fires the systemchat with "This door is locked!"; If that's correct, then, so far so good! However, I am not building a big mission, I am just trying to keep access to a single building restricted until a player interacts with it after collecting a key. In which case, how exactly do I adapt GOM's script to reflect that via this "ownership" method? Would something like this work: mission initialises with target building locked -> player picks up the key (eg: a notebook) -> this sets the player as the owner of the building? GOM mentions: _building = cursorObject; _owner = player; //this sets the player as owner and locks all doors and adds all respective actions _init = [_building,_owner] call GOM_fnc_initBuildingDoors; As someone struggling with scripting...how do you run this script mid-mission? Can't this be done via triggers? I am a bit puzzled still, sorry!
×