Files
DayZ-Epoch/Server Files/Battleye/scripts.txt
oiad 854c41cf8c switchModel, jerry_fill, packTent changes/fixes (#1836)
* switchModel, jerry_fill, water_fill, drinkWater, packTent changes/fixes

player_packTent: Add private array since there was none. Make it match
player_packVault so a player can't pack the tent with others near (to
stop duping)

water_fill:
Fixed the massive lag issue with the check for ponds etc, Originally was
being done searching for all which is quite intensive, now only
searching for waterholeproxy which matches all the water holes on
chernarus I could try.
Fixed a few localizations. Thanks @schwanzkopfhegel

player_drinkWater: Same as above. Also removed a lot of unused private
variables.

jerry_fill:
Made the minimum fill level of fuel tanks 10% of
dayz_randomMaxFuelAmount so the tank will always have fuel
Fixed issue with ItemFuelBarrel only using 40 litres from a tank.
Thanks @schwanzkopfhegel
Display how much fuel was needed if the tank is empty
Fix issue if the tank was empty that dayz_actionInProgress was not reset

player_switchModel:
Fixed issue of coins dissapearing on gear change
Fixed old commented out code that was broken so now you will go back
into the camera view you were in before you changed clothes

* Revert drinkWater/water_fill changes

My previous commit can only be used on chernarus since it's the only map
that has the waterholeproxy we rely on.

* crafting localization fix

* Update german translations

* Rework

* Missed private variable

* Rework again

* Update german string
2016-12-29 19:47:04 -05:00

54 lines
13 KiB
Plaintext

//new2
5 allDead !"} count allDead;\nif (!_found) then {deleteMarkerLocal \"MyBody\";};"
5 allGroups !"publicVariableServer \"PVDZ_Server_UpdateGroup\";\n};\n} count allGroups;"
5 allMissionObjects !"allMissionObjects \"RoadFlare\"" !"allMissionObjects \"ChemLight\"" !"[_x,2,0,false,false] spawn BIS_Effects_Burn;\n};\n} count allMissionObjects \"SpawnableWreck\";" !"if (isNull _grp) then { _grp = group ((allmissionobjects 'FunctionsManager') select 0); };"
5 allowDammage
5 allUnits !"} count allUnits;\nlbSort _playerList;" !"if (getPlayerUID _x == _this) exitWith {\n_player = _x;\n};\n} count allUnits;" !"owner _x publicVariableClient \"PVDZ_groupInvite\";\n};\n} count allUnits;"
5 attachTo !"riation),((random (_variation * 2)) - _variation)];\n_bolt attachTo [_hitObject,_val,_hitMemoryPt];\n_dir = ([_hitObject,_unit]" !"select 3;\nplayer playActionNow \"PutDown\";\nuiSleep 2;\n_flare attachTo [player,[0,0,0],\"granat2\"];\n[_flare, -90, -10] call object" !"tchmove \"ainjpfalmstpsnonwrfldnon_carried_still\";\n_dragee attachto [_unit,[-0.2, 0.2, 0]];\n\n\nwhile {r_carry_sqf} do\n{\n_anim_n" !"0, 0.1], 0, 0, 10];\n_source setDropInterval 0.02;\n_point attachTo [_unit,_modelPos,_wound];\n};\n\nuiSleep 5;\n\nwhile {((_unit getV" !"_objGhost attachTo [_object, [0, 0, 0.7]];\n};\n\n_boundingBox = boundingBox" !" attachto [_v,[0,0,0],\"destructionEffect" !"rag = [_dragee];\npublicVariable \"PVDZ_drg_RaDrag\";\n\n_dragee attachto [_unit,[0.1, 1.01, 0]];\nuiSleep 0.02;\n\n\n\n\n_dragee setDir 180;" !"_objectHelper attachTo [player,_offset];" !"_object attachTo [player,_offset];\n\n_position = getPosATL _object;" !="_vehicle attachTo [_liftHeli,[0,0,-7]];" !="_obj attachTo [_axis];" !"_objectSnapGizmo attachTo [_object,[_x select 0,_x select 1,_x select 2]];" !="_vehicle attachTo [_towTruck,[1.3,-2,2.3]];" !"localize \"STR_EPOCH_ACTIONS_ATTACHTOHELI\"," !="_l1 attachTo [_lh,[0,0,0],\"light\"];"
5 buttonSetAction
5 callExtension
5 closeDisplay !"'closeDisplay'" !"closeDisplay 0" !"closeDisplay 2" !"if (!isNil \"closeDisplay\") then {"
5 createAgent !="_agent = createAgent [_type, _position, [], _radius, \"CAN_COLLIDE\"];" !="_agent = if (_type == \"Pastor\") then {createAgent [_type, _Pos, [], 0, \"NONE\"]} else {createAgent [_type, _Pos, [], 0, \"FORM\"]};" !="_dog = createAgent [_type, _Pos, [], 0, \"NONE\"];"
5 createDialog !="_region = createDialog \"RscDisplaySpawnSelecter\";" !="_gender = createDialog 'RscDisplayGenderSelect';" !="_dialog = createDialog \"bloodTest\";" !="createDialog 'RscDisplayCraftingMenu';" !="createDialog \"DAYZ_PADLOCK\";" !="createDialog \"horde_journal_front_cover\";" !="createDialog 'horde_journal_front_cover';" !="createDialog 'horde_journal_pages_headshots';" !="createDialog 'horde_journal_pages_murders';" !="createDialog 'horde_journal_pages_journal_humanity';" !="createDialog 'horde_journal_pages_zombies';" !="createDialog 'horde_journal_pages_bandits';" !="createDialog 'horde_journal_pages_humanity_art';" !"Z_ResetContainer = true;\ncreateDialog \"AdvancedTrading\";" !"createDialog \"DoorManagement\";\ncall DoorNearbyHumans;" !="createDialog \"ComboLockUI\";" !"createdialog \"PlotManagement\";\ncall PlotNearbyHumans;" !"_trader_data = (_this select 3);\n\n_dialog = createdialog \"TraderDialog\";" !="_ok = createdialog \"SafeKeyPad\";" !="_ok = createdialog \"KeypadUI\";" !"EpochDeathBoardLoad = {\ncreatedialog \"EpochDeathBoardDialog\";" !="if(DZE_doorManagement) then {createdialog \"DoorAccess\";} else {createdialog \"ComboLockUI\";};" !"\ndisableSerialization;\ncreateDialog \"DZ_GroupDialog\";"
5 createDisplay
5 createMarker !"\"createMarkerLocal\",\n\"setMarkerPosLocal\"," !="rcreateMarkerLocal = 'createMarkerLocal'" !"rcreateMarkerLocalcode" !"\"createMarkerLocal\", \"createSimpleTask\"," !"if (isnil 'BIS_GITA_fnc_createMarkers' || false) then {" !"_marker = createMarkerLocal [format[\"groupMember" !="_marker = createMarkerLocal [\"MyBody\",_pos];"
5 createUnit !="_newUnit = _group createUnit [_class,respawn_west_original,[],0,\"NONE\"];" !="BIS_MPF_logic = BIS_MPF_dummygroup createUnit [\"Logic\", [1000,10,0], [], 0, \"NONE\"];"
5 createVehicleLocal !="_object = (_x select 1) createVehicleLocal [0,0,0];" !="_Crater= \"CraterLong\" createvehiclelocal [_pos select 0, _pos select 1, 0];" !="_plant = _x createVehicleLocal (getMarkerPos \"center\");" !="_point = \"Logic\" createVehicleLocal getPosATL _unit;" !="_obj = _class createVehicleLocal _new;" !="_obj = _class createVehicleLocal (getMarkerpos \"respawn_west\");" !" = \"#lightpoint\" createVehicleLocal " !" = \"#particlesource\" createVehicleLocal " !="_object = _ghost createVehicleLocal getMarkerpos \"respawn_west\";" !="_cursorTarget = _upgrade createVehicleLocal getMarkerpos \"respawn_west\";" !="_sign = \"Sign_arrow_down_large_EP1\" createVehicleLocal [0,0,0];" !="_obj = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !="_obj = _model createVehicleLocal [0,0,0];" !="_objectSnapGizmo = \"Sign_sphere10cm_EP1\" createVehicleLocal [0,0,0];" !"_object = _type createVehicleLocal [0,0,0];"
5 ctrlAddEventHandler
5 ctrlRemoveAllEventHandlers
5 ctrlSetPosition !="_control ctrlSetPosition [_posX, _posY];" !"if (_h != -1) then {_pos set [3,_h]};\n_control ctrlsetposition _pos;" !="_control ctrlSetPosition [0, (_y + _deltaY)];" !="_disp_ctrl ctrlSetPosition [_posX, _posY];" !="_control ctrlSetPosition _grpPos;" !="_group ctrlSetPosition _pos;" !="_control ctrlSetPosition [_controlPos select 0, _controlPos select 1, _controlPos select 2, 0.03921 * _lines];" !="((uiNamespace getVariable 'DAYZ_GUI_waiting') displayCtrl 1400) ctrlSetPosition _sandLevel;" !="_delayControl ctrlSetPosition [0, _pos];" !="_icon ctrlSetPosition [(_screen select 0),(_screen select 1),.99,.65];"
5 deleteMarker !"} count allDead;\nif (!_found) then {deleteMarkerLocal \"MyBody\";};"
5 displayAddEventHandler !"bis_fnc_halo_keydown_eh = (finddisplay 46) displayaddeventhandler [\"keydown\",\"_this call bis_fnc_halo_keydown;\"];"
5 displayRemoveAllEventHandlers
5 displaySetEventHandler
5 enableEnvironment
5 groupIcon !="uiNamespace setVariable ['DZ_GroupIcons',_this select 0];" !="80000 cutRsc [\"DZ_GroupIcons\",\"PLAIN\"];" !="_display = uiNamespace getVariable \"DZ_GroupIcons\";" !"if (!isNull (uiNamespace getVariable \"DZ_GroupIcons\")) then {" !"dayz_groupIcons = compile preprocessFileLineNumbers " !="if (!isNil \"dayz_groupIcons\") then {call dayz_groupIcons;};"
5 hideObject !"\"setMarkerPosLocal\",\n\"hideObject\"\n];" !="rhideObject = 'hideObject'" !"rhideObjectcode" !"\"hideObject\", \"hint\","
5 lbCurSel !="_selectedMissionIndex = lbCurSel _lbMissionsControl;" !="_selectedUserIndex = lbCurSel _lbUsersControl;" !="profileNamespace setVariable ['streamerMode',(lbCurSel (_this select 0))];" !="_index = lbCurSel _lbcontrol;" !="_selected = lbCurSel _list;" !="_friendName = _userList lbText (lbCurSel _userList);" !")] call Z_" !"(lbCurSel 7421) call Z_fillCategoryList" !"] call Door" !"] call Plot" !")] spawn TraderDialog" !="[(lbCurSel 21000), ((ctrlParent (_this select 0)) displayCtrl 21001)] spawn EpochDeathBoardClick;" !"((ctrlParent (_this select 0)) closeDisplay 2);" !="_uid = _playerList lbData (lbCurSel _playerList);" !"_myGroup lbData (lbCurSel _myGroup);"
5 lbSet !="_lbUsersControl lbSetColor [_x, [1,0,0,1]];" !="_lbUsersControl lbSetValue [_x, _rating];" !="_control lbSetColor [_x, _color];" !"_weaponsLBSetFocus" !="(_this select 0) displayCtrl 140 lbSetCurSel (profileNamespace getVariable ['streamerMode',0]);" !="(_display displayCtrl 105) lbSetColor [_i, [0.06, 0.05, 0.03, 1]];" !"[7421," !"lbSetPicture [7422, _index" !"lbSetPicture [7402, _index" !"lbSetPicture [7401, _index" !="_userList lbSetData [(lbSize _userList) -1,_friendUID];" !" [TraderDialogItemList, _index, " !"_myGroup lbSetData [_index,getPlayerUID _x];"
5 onMapSingleClick
5 playableUnits !"for [{_y=0},{_y < count(playableUnits)},{_y=_y+1}] do {" !"typeName player == \"OBJECT\")}) AND {((player in playableUnits) AND {(alive player)" !"(1 max count playableUnits)) min (dayz_maxAnimals - _count))) to 1 step -1 do {" !"AND {((alive _x) AND {((vehicle _x) distance _obj < 150)})}} count playableUnits)}) then {" !="_local = { _unit distance _x < _dis; } count playableUnits <= 1;" !"if (!_isOk) exitWith {false};\nuiSleep 0.001;\n} forEach playableUnits;" !"ManagementMustBeClose) then { player nearEntities [\"CAManBase\", 10] } else { playableUnits };"
5 selectPlayer !"dayz_originalPlayer enableSimulation true;\naddSwitchableUnit dayz_originalPlayer;\nsetPlayable dayz_originalPlayer;\nselectPlayer dayz_originalPlayer;" !"addSwitchableUnit _newUnit;\nsetPlayable _newUnit;\nselectPlayer _newUnit;"
5 serverCommand !="_character = if (serverCommandAvailable \"#kick\") then { call sched_tg_follow } else { player };" !"serverCommand (\"#kick \" + _selectedName);"
5 setDamage !"([4654,9595,0] nearestObject 145259) setDamage 1;\n([4654,9595,0] nearestObject 145260) setDamage 1;" !"if (_entity isKindOf \"Animal\") then {\n_entity setDamage 1;" !"_tree setDamage 1;\ndayz_choppedTrees set [count dayz_choppedTrees,_tree];" !="if ((alive player) && (r_fracture_legs or {player isKindOf 'PZombie_VB'})) then { player SetDamage 1;};" !"if (deathHandled) exitWith {};\ndeathHandled = true;\nplayer setDamage 1;" !"\n_obj setDamage (damage _obj) + _damage;\n" !"if(\"\" == typeOf _tree) then {\n_tree setDamage 1;\n};" !"if (_ent isKindOf \"Animal\" || _ent isKindOf \"zZombie_base\") then {\n_ent setDamage 1;"
5 setDammage
5 SetEventHandler !="_menu ctrlSetEventHandler [\"ButtonClick\",_compile];" !="inGameUISetEventHandler [\"PrevAction\",\"false\"];" !="inGameUISetEventHandler [\"NextAction\",\"false\"];" !="inGameUISetEventHandler [\"Action\",\"false\"];"
5 setMarkerAlpha
5 setMarkerBrush
5 setMarkerColor !",if (_vehicle == _x) then {name _x} else {_vehicle call dayz_getCrew}];\n_marker setMarkerColorLocal \"ColorGreen\";"
5 setMarkerDir
5 setMarkerPos !"\"setMarkerPosLocal\",\n\"hideObject\"\n];" !="rsetMarkerPosLocal = 'setMarkerPosLocal'" !"rsetMarkerPosLocalcode" !"\"setMarkerPosLocal\", \"setObjectTexture\","
5 setMarkerShape
5 setMarkerSize
5 setMarkerText !",if (_vehicle == _x) then {name _x} else {_vehicle call dayz_getCrew}];\n_marker setMarkerColorLocal \"ColorGreen\";"
5 setMarkerType !",if (_vehicle == _x) then {name _x} else {_vehicle call dayz_getCrew}];\n_marker setMarkerColorLocal \"ColorGreen\";"
5 setPosASL !="_unit setPosAsl [(_position select 0), (_position select 1), (LHA_height+1)];" !="_objectHelper setPosASL _position;" !="_tmpbuilt setPosASL _location;" !="_b0x1337 setPosASL (getPosASL player);" !"_obj setPosASL [_center select 0, " !"_obj setPosASL [_a, " !"_objectSnapGizmo setPosASL " !"_para setposasl [\n" !"_thingy setPosASL (ATLToASL _pos);" !"if (surfaceIsWater _location) then {_object setPosASL (getPosASL player);"
5 setTerrainGrid !"if (dayz_REsec == 1) then {call compile preprocessFileLineNumbers \""
5 setUnitRecoilCoefficient
5 setVehicle !="_this setVehicleInit \"this setVectorUp [0,0,1];\";" !"if(_status) then {\n_vehicle setVehicleLock \"LOCKED\";\n} else {\n_vehicle setVehicleLock \"UNLOCKED\";\n};"
5 setViewDistance
5 showCommandingMenu !"\"showCommandingMenu\", \n\"globalChat\", " !="rshowCommandingMenu = 'showCommandingMenu'" !"rshowCommandingMenucode" !"\"showCommandingMenu\", \"sideChat\","
5 sideLogic !"{ \nBIS_MPF_ServerInitDone = true;\ncreatecenter sidelogic;\nBIS_MPF_dummygroup = createGroup sideLogic;" !"{ \nBIS_MPF_ServerInitDone = true;\ncreatecenter sidelogic;\n\n\nBIS_MPF_dummygroup = createGroup sideLogic;"
5 switchCamera !"\"switchCamera\", \n\n\n\"fadeMusic\"," !="rswitchCamera = 'switchCamera'" !"rswitchCameracode" !"\"switchCamera\", \"taskHint\"," !="player switchCamera (Dayz_constructionContext select 2);" !="player switchCamera _currentCamera;"
5 toString !="_skinToModel = toString (_finalArray);" !="{_textArrayTemp = _textArrayTemp + [tostring [_x]]} foreach _line;" !="_cmpt = toString _cmpt;" !="_objName = toLower(toString(_objName));" !"if (toString _hayArr != _needle) then {" !="_type = toString _typeA;" !="_anim4 = toString _anim4;" !"{(count _stance>17)}) then {toString [_stance select 17]}" !="lbAdd [7102, if (typeName _name == \"ARRAY\") then {toString _name} else {_name}];" !="lbAdd [7002, if (typeName _name == \"ARRAY\") then {toString _name} else {_name}];" !"if (isnil 'BIS_fnc_timeToString' || false) then {"
5 worldTo !"ect 1;\n_inside = false;\n_offset = 1; \n\n_relPos = _building worldToModel _point;\n_boundingBox = boundingBox _building;\n\n_min = _" !"\n\n_new = getPosATL _obj;\n\nif (_isPlayer) then {\n_x = _pos worldToModel _new;\n_dir = _dir + (if ((_x select 1)==0) then { 0 } else" !"_pondPos = (_x worldToModel _playerPos) select 2;\n" !"ts [_new, [], 100];\n{\nif (((typeOf(_x) == \"\")\nAND {((((_x worldToModel _new) select 2) < 0))\nAND {([_x, _new] call _checkPerimete" !"t = _this select 1;\n_inside = false;\n\n_relPos = _building worldToModel _point;\n_boundingBox = boundingBox _building;\n\n_min = _bou" !"fascl,getDir _x,\"\",1];if(_fash==_forEachIndex)then{_fapos2D=worldtoscreen _fapos;if(count _fapos2D>=2)then{_fasp ctrlsetposition" !"_pondPos = (_x worldToModel _playerPos) select 2;\nif (_pondPos < 0) then {\n_canFill" !"_w2m = _x worldToModel (getPosATL player);\n_bb = (boundingbox _x) select 1;" !"_bn == 1) then { \n_bb = boundingBox _o;\n_h = _offset + ((_o worldToModel (getPosATL _o)) select 2);\n_p = [ (_bb select 0) select" !"if (_distance > 1 && _distance < 2500) then {\n_pos set [2,(_pos select 2) + 1.5];\n_screen = worldToScreen _pos;\n_text = composeText [image"