2015-08-15 16:39:43 +00:00
|
|
|
/*
|
|
|
|
* Author: Glowbal
|
|
|
|
* Adds an object to curator upon spawn
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* Object <OBJECT>
|
|
|
|
*
|
|
|
|
* Return Value:
|
|
|
|
* None
|
|
|
|
*
|
|
|
|
* Public: No
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include "script_component.hpp"
|
|
|
|
|
|
|
|
params ["_object"];
|
|
|
|
|
2016-05-08 11:47:35 +00:00
|
|
|
if !(EGVAR(common,settingsInitFinished)) exitWith {
|
|
|
|
TRACE_1("pushing to runAtSettingsInitialized", _this);
|
|
|
|
EGVAR(common,runAtSettingsInitialized) pushBack [FUNC(addObjectToCurator), _this];
|
|
|
|
};
|
|
|
|
|
2015-11-30 16:27:09 +00:00
|
|
|
if (!(_object getVariable [QGVAR(addObject), GVAR(autoAddObjects)])) exitWith {};
|
2015-08-15 16:39:43 +00:00
|
|
|
|
2016-03-30 15:26:33 +00:00
|
|
|
[{
|
|
|
|
TRACE_1("Delayed addCuratorEditableObjects",_this);
|
|
|
|
{
|
|
|
|
_x addCuratorEditableObjects [[_this], true];
|
|
|
|
} forEach allCurators;
|
|
|
|
}, _object] call EFUNC(common,execNextFrame);
|