Jump to content

Gwandoya

Member
  • Posts

    21
  • Joined

  • Last visited

  • Days Won

    1

Reputation Activity

  1. Like
    Gwandoya got a reaction from KnIniAlexveni in BattleEye v1.212 client DLL update makes client side lag   
    Does anyone experienced the latest BattlEye v1.212 client update makes massive client side lag spikes?
    Pings and FPS-es are good, but the screen freezes for a 0.2 second in every 1-2 seconds.
    It happened today after players updated their BE client DLLs from 1.208 to 1.212.
  2. Like
    Gwandoya got a reaction from Rythron in [RELEASE] Vehicle Key Changer - For making Masterkey - V 1.4 (Updated 06/15/2014)   
    Hi!
     
    In first line thanks for the author for this great idea and code!
     
    To solve the problem with disappearing and replaced vehicles, open VehicleKeyChanger_init.sqf and place the following code after function ON_fnc_vkc_reset in line 56:
    dayz_objectUID_vkc = { private["_position","_dir","_key","_object"]; _object = _this; _position = getPosATL _object; _dir = direction _object; _key = [_dir,_position] call dayz_objectUID2_vkc; _key }; dayz_objectUID2_vkc = { private["_position","_dir","_key"]; _dir = _this select 0; _key = ""; _position = _this select 1; { _x = _x * 10; if ( _x < 0 ) then { _x = _x * -10 }; _key = _key + str(round(_x)); } forEach _position; _key = _key + str(round(_dir)); _key }; I suggest to reset some variables as well, place the following code after waitUntil {!isNil "dayz_animalCheck"}; in line 83:
    s_player_copyToKey=-1; lastKeyChangeCursorTarget = [objNull,objNull,objNull,objNull,objNull]; I also changed the self action menu text in that case when you claim a vehicle without a key, text "Change Vehicle Key" changed to "Claim Vehicle" in line 118.
     
    And I got an odd 'general error' in some cases (probably when I had no key in my inventory but all other requirements were fullfilled)

    so, I changed
    if (_carKey != "0") then { to
    } else { Now open VehicleKeyChanger.sqf and add the following code to line 129:
    /* Giving unique UID for claimed vehicles */ if (_targetVehicleUID=="0") then { _targetVehicleUID = _targetVehicle call dayz_objectUID_vkc; _targetVehicle setVariable ["ObjectUID",_targetVehicleUID,true]; // It does probably nothing and it's not needed :) }; With these modfifications you can Claim a server spawned vehicle which has only ObjectID (MySQL primary, autoincremented ID) but ObjectUID=0.

    On our server you can claim mission vehicles as well, because for mission vehicles we generate ObjectID="0" and ObjectUID=_vehicle call dayz_objectUID; (Server side call.)

    dayz_objectUID and dayz_objectUID2 are standard ObjectUID generator functions from server_functions.sqf, and we had to place them to client side (_vkc added to names).

    To fix objects stored in your database with ObjectUID=0 just run this MySQL command on object_data table:
    UPDATE object_data SET ObjectUID=ROUND(RAND(1)*1000000000000000) WHERE ObjectUID=0
     
    [ Modifications made for Vehicle Key Changer - For making Masterkey - V 1.3 (Updated 02/20/2014) ]
  3. Like
    Gwandoya got a reaction from koolaidman04 in [RELEASE] Vehicle Key Changer - For making Masterkey - V 1.4 (Updated 06/15/2014)   
    Here's another update which allows you to claim vehicles which were not in database at server start but spawned by a mission script.
     
    Open your server_updateObject.sqf included in Vehicle Key Changer release and add after _object setVariable ["ObjectID", _vehicleID, true]; in line 244:
    /* Save the ObjectUID to the vehicles variable and make it public */ _object setVariable ["ObjectUID", _vehicleUID, true]; Add code after _object setVariable ["reargundeployed",0,true]; before the closing bracket to line 267:
    _object call fnc_veh_ResetEH; This is important to add the event handlers to the mission vehicles, otherways Epoch won't update the position, gear and damage of your vehicle, and after server restart it will spawn at that place where you claimed the vehicle.
     
    And one small note:
    mission vehicles will not be saved correctly if your mission script sets ObjectID="1" (and ObjectUID="1"). The next claimed vehicle will always overwrite the previous one because both have ObjectID 1 in database.
    To solve this, you might need to modify your AI mission script: (replace "_vehicle" with the appropriate variable name.)
    _uid = _vehicle call dayz_objectUID; _vehicle setVariable ["ObjectID", "0", true]; _vehicle setVariable ["ObjectUID", _uid, true]; (It doesn't matter if ObjectID is zero, HiveWrite will add a new record to object_data table.)
     
    And of course, object has to be in PVDZE_serverObjectMonitor :)
    PVDZE_serverObjectMonitor set [count PVDZE_serverObjectMonitor, _vehicle];
  4. Like
    Gwandoya got a reaction from koolaidman04 in [RELEASE] Vehicle Key Changer - For making Masterkey - V 1.4 (Updated 06/15/2014)   
    Hi!
     
    In first line thanks for the author for this great idea and code!
     
    To solve the problem with disappearing and replaced vehicles, open VehicleKeyChanger_init.sqf and place the following code after function ON_fnc_vkc_reset in line 56:
    dayz_objectUID_vkc = { private["_position","_dir","_key","_object"]; _object = _this; _position = getPosATL _object; _dir = direction _object; _key = [_dir,_position] call dayz_objectUID2_vkc; _key }; dayz_objectUID2_vkc = { private["_position","_dir","_key"]; _dir = _this select 0; _key = ""; _position = _this select 1; { _x = _x * 10; if ( _x < 0 ) then { _x = _x * -10 }; _key = _key + str(round(_x)); } forEach _position; _key = _key + str(round(_dir)); _key }; I suggest to reset some variables as well, place the following code after waitUntil {!isNil "dayz_animalCheck"}; in line 83:
    s_player_copyToKey=-1; lastKeyChangeCursorTarget = [objNull,objNull,objNull,objNull,objNull]; I also changed the self action menu text in that case when you claim a vehicle without a key, text "Change Vehicle Key" changed to "Claim Vehicle" in line 118.
     
    And I got an odd 'general error' in some cases (probably when I had no key in my inventory but all other requirements were fullfilled)

    so, I changed
    if (_carKey != "0") then { to
    } else { Now open VehicleKeyChanger.sqf and add the following code to line 129:
    /* Giving unique UID for claimed vehicles */ if (_targetVehicleUID=="0") then { _targetVehicleUID = _targetVehicle call dayz_objectUID_vkc; _targetVehicle setVariable ["ObjectUID",_targetVehicleUID,true]; // It does probably nothing and it's not needed :) }; With these modfifications you can Claim a server spawned vehicle which has only ObjectID (MySQL primary, autoincremented ID) but ObjectUID=0.

    On our server you can claim mission vehicles as well, because for mission vehicles we generate ObjectID="0" and ObjectUID=_vehicle call dayz_objectUID; (Server side call.)

    dayz_objectUID and dayz_objectUID2 are standard ObjectUID generator functions from server_functions.sqf, and we had to place them to client side (_vkc added to names).

    To fix objects stored in your database with ObjectUID=0 just run this MySQL command on object_data table:
    UPDATE object_data SET ObjectUID=ROUND(RAND(1)*1000000000000000) WHERE ObjectUID=0
     
    [ Modifications made for Vehicle Key Changer - For making Masterkey - V 1.3 (Updated 02/20/2014) ]
  5. Like
    Gwandoya got a reaction from koolaidman04 in [RELEASE] Vehicle Key Changer - For making Masterkey - V 1.4 (Updated 06/15/2014)   
    I followed the and did the changes I posted.
    I wanted to upload my files, but somehow I can't do it here :huh:
     
    In the post you quite mixed codes up.
     
    server_updateObject.sqf



    VehicleKeyChanger.sqf



    VehicleKeyChanger_init.sqf



  6. Like
    Gwandoya got a reaction from Radec59437 in [RELEASE] Vehicle Key Changer - For making Masterkey - V 1.4 (Updated 06/15/2014)   
    Hi!
     
    In first line thanks for the author for this great idea and code!
     
    To solve the problem with disappearing and replaced vehicles, open VehicleKeyChanger_init.sqf and place the following code after function ON_fnc_vkc_reset in line 56:
    dayz_objectUID_vkc = { private["_position","_dir","_key","_object"]; _object = _this; _position = getPosATL _object; _dir = direction _object; _key = [_dir,_position] call dayz_objectUID2_vkc; _key }; dayz_objectUID2_vkc = { private["_position","_dir","_key"]; _dir = _this select 0; _key = ""; _position = _this select 1; { _x = _x * 10; if ( _x < 0 ) then { _x = _x * -10 }; _key = _key + str(round(_x)); } forEach _position; _key = _key + str(round(_dir)); _key }; I suggest to reset some variables as well, place the following code after waitUntil {!isNil "dayz_animalCheck"}; in line 83:
    s_player_copyToKey=-1; lastKeyChangeCursorTarget = [objNull,objNull,objNull,objNull,objNull]; I also changed the self action menu text in that case when you claim a vehicle without a key, text "Change Vehicle Key" changed to "Claim Vehicle" in line 118.
     
    And I got an odd 'general error' in some cases (probably when I had no key in my inventory but all other requirements were fullfilled)

    so, I changed
    if (_carKey != "0") then { to
    } else { Now open VehicleKeyChanger.sqf and add the following code to line 129:
    /* Giving unique UID for claimed vehicles */ if (_targetVehicleUID=="0") then { _targetVehicleUID = _targetVehicle call dayz_objectUID_vkc; _targetVehicle setVariable ["ObjectUID",_targetVehicleUID,true]; // It does probably nothing and it's not needed :) }; With these modfifications you can Claim a server spawned vehicle which has only ObjectID (MySQL primary, autoincremented ID) but ObjectUID=0.

    On our server you can claim mission vehicles as well, because for mission vehicles we generate ObjectID="0" and ObjectUID=_vehicle call dayz_objectUID; (Server side call.)

    dayz_objectUID and dayz_objectUID2 are standard ObjectUID generator functions from server_functions.sqf, and we had to place them to client side (_vkc added to names).

    To fix objects stored in your database with ObjectUID=0 just run this MySQL command on object_data table:
    UPDATE object_data SET ObjectUID=ROUND(RAND(1)*1000000000000000) WHERE ObjectUID=0
     
    [ Modifications made for Vehicle Key Changer - For making Masterkey - V 1.3 (Updated 02/20/2014) ]
×
×
  • Create New...