Files
DayZ-Epoch/dayz_server/compile/server_publishObject.sqf
vbawol 73594cc02c 0.98
+ Added Armored SUV to spawn tables
+ Lowered gear counts on armed suv to 400,20,10
+ Removed boats from takistan DVS table
+ Moved metals trader options to a "trade metals" menu on each trader.
+ Changed old metals trader to new Hero only trader, will have certain
clothes at first. and lower priced items.
+ Add crafting in progress lock to prevent duping.
+ changed wording of vault to safe
+ added Hero traders that only deal with 5000+ humanity
+ Updated to larger 10oz copper, silver, gold equipment icons.
+ Server Side changed allowed buildables to array
2013-02-23 08:45:41 -06:00

36 lines
1.2 KiB
Plaintext

private ["_class","_uid","_charID","_object","_worldspace","_key"];
//[dayz_characterID,_tent,[_dir,_location],"TentStorage"]
_charID = _this select 0;
_object = _this select 1;
_worldspace = _this select 2;
_class = _this select 3;
if (!(_object isKindOf "Building")) exitWith {
deleteVehicle _object;
};
_allowed = [_object, "Server"] call check_publishobject;
if (!_allowed) exitWith { };
//diag_log ("PUBLISH: Attempt " + str(_object));
//get UID
_uid = _worldspace call dayz_objectUID2;
//Send request
_key = format["CHILD:308:%1:%2:%3:%4:%5:%6:%7:%8:%9:",dayZ_instance, _class, 0 , _charID, _worldspace, [], [], 0,_uid];
//diag_log ("HIVE: WRITE: "+ str(_key));
_key call server_hiveWrite;
_object setVariable ["ObjectUID", _uid,true];
_allowedObjects = ["TentStorage", "VaultStorageLocked", "Hedgehog_DZ", "Sandbag1_DZ","TrapBear","Fort_RazorWire","WoodGate_DZ","Land_HBarrier1_DZ"];
if ((typeOf _object) in _allowedObjects) then {
_object addMPEventHandler ["MPKilled",{_this call vehicle_handleServerKilled;}];
};
dayz_serverObjectMonitor set [count dayz_serverObjectMonitor,_object];
//diag_log ("PUBLISH: Created " + (_class) + " with ID " + _uid);