Jump to content
  • 0

problem linking plot poles to PlayerUID


ekroemer

Question

Hi there,

 

as on our server we cannot access/remove plot poles at all, after every player death the poles linked to the player's old characterID have to be deleted by the admin.

 

To overcome this problem we have tried to link the pole to the playerUID instead, so, even if it cannot be removed, the player can continue building on his plot.

 

For this one of our admins has taken the standard player_build.sqf (shown below) and modified it in the lines 75, 80 and 281, replacing characterID with playerUID.

 

This seemed to work: the database shows the correct playerUID and a player can continue building after being respawned.

 

But the problem is, that after a server restart the player cannot build on the plot, anymore, even if he did not die.

 

I don't know any sqf, myself. Looking at the code I only noticed 2 things:

  • The code uses PlayerUID where I had expected playerUID but maybe sqf is case insensitive.
  • In another forum I saw a player_build.sqf that had the additional lines I have added near 288, a call to server_publishObj

Neither would explain that the expected PlayerUID can be seen in the DB....

 

Any ideas why the link player-pole is broken after a restart?

 

Edit: the codebox doesn't seem to work :-(, I'll paste the relevant lines, only, hoping I did not miss the really relevant ones.

 

Another edit: sorry, the editor here seems to consistently swallow some lines :-(

 

Basically what the admin did was to change lines containing characterID resulting in

 

(75) _ownerID = _nearestPole getVariable["PlayerUID","0"];

(80) if(dayz_PlayerUID == _ownerID) then

(281) _tmpbuilt setVariable ["PlayerUID",dayz_PlayerUID,true];

(285) dayzPublishObj = [dayz_PlayerUID,_tmpbuilt,[_dir,_location],_classname];

 

 and what I miss is a statement

if (isServer) then dayzPublishObj call server_publishObj;
 

after the line

 

(287) publicVariableServer "dayzPublishObj";



 

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

in the 1.0.1.6 beta plot poles are no longer needed so its irrelevant...

 

Correction:

 

from the changelog to come

CHANGED] Removed plot pole requirement to build. Plot pole is still used to prevent others from building and to increase item deconstruction times.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
  • Discord

×
×
  • Create New...