iV - Ghost 50 Posted June 14, 2018 How can I make a addAction on an object working underwater? Seems only in MP it isn't working. Share this post Link to post Share on other sites
HazJ 1288 Posted June 14, 2018 What did you try? Can we see your addAction code... Did you create action on server or locally on clients. Share this post Link to post Share on other sites
iV - Ghost 50 Posted June 14, 2018 I wanna create a wreck on a random position and you have to recover the blackbox by using a addAction. The script is local to the server but I use remoteExec for the addAction. Part of the code... // ADD ADDACTION [_object, [_text, _addAction, nil, 2, true, true, "", "true", 3.5, false]] remoteExec ["addAction", -2, true]; Share this post Link to post Share on other sites
HazJ 1288 Posted June 14, 2018 You are testing not as the server, right? Also, why remoteExec? You could just add actions locally in client init somewhere. Please show more so I can help narrow the issue down. What do you have set for these: _object _addAction Without looking the Wiki... Condition, radius and unconscious? Right? Remove the radius and set condition as "" too. "true", 3.5, false 1 Share this post Link to post Share on other sites
iV - Ghost 50 Posted June 14, 2018 This is the function: /* * * Filename: fn_objectCreate.sqf * Author: [iV] Ghost * Description: Creates a object with a addaction and a marker on given position and radius. * * Example: ["M_AreaBB", [17172, 12396], 500, "Land_Wreck_Heli_Attack_01_F", "NONE", localize "STR_iV_TakeBlackbox", "scripts\misc\TakeBlackbox.sqf"] call iV_fnc_objectCreate; * */ // RUN ON DEDICATED SERVER OR PLAYER HOST if (!isServer) exitWith {}; // VARIABLES params ["_markerName", "_pos", "_radius", "_type", "_special", "_text", "_addAction"]; private _spawnPos = _pos; private _debug = true; // CREATE MARKER [_markerName, _pos, [_radius, _radius], "colorOPFOR"] call iV_fnc_markerArea; // CREATE OBJECT private _object = createVehicle [_type, _spawnPos, [], _radius, _special]; _object setDir (random 360); // ADD ADDACTION [_object, [_text, _addAction, nil, 2, true, true, "", "true", 3.5, false]] remoteExec ["addAction", -2, true]; // CREATE DEBUG MARKER if (_debug) then { private _randomNumber = floor random 100000; private _debugMarker = "M_Debug_Mine_" + (str _randomNumber); [_debugMarker, getPos _object, "mil_triangle", "colorOPFOR"] call iV_fnc_markerIcon; }; 1 Share this post Link to post Share on other sites
iV - Ghost 50 Posted June 15, 2018 This works underwater in MP. THX a lot! // ADD ADDACTION [_object, [_text, _addAction, nil, 2, true, true, "", ""]] remoteExec ["addAction", -2, true]; 1 Share this post Link to post Share on other sites