EntityOwner

Moved

Total Downloads: 7,293 - First Release: Jul 23, 2015 - Last Update: Dec 8, 2017

5/5, 25 likes
  1. While this update does indeed seem a bit rushed (which is a very touchy thing because if this plugin doesn't work it means having to wipe the map for some servers) I think your argument about OnUnload is not a good one.
    You should never unload EntityOwner (or any building-tracking-plugin of that matter) manually because during the time the plugin is unloaded, no data will be stored, which might break compatability with other plugins.
     
  2. I'm aware of this.
     
  3. Also, to confirm your claims:
    • FindEntityData still returns false for cupboards and /saveowners still reports "No changes" when building a cupboard
    • /authclean still exists, but doesn't appear to work anymore.
     
  4. Anyone else getting this?


    (11:25:02) | 968725523

    (11:25:03) | 1425970515

    (11:25:11) | 1590173093

    (11:25:11) | 1669257593

    (11:25:12) | 2268399418

    (11:25:13) | 1669257593

    (11:25:22) | 1669257593
     
  5. Calytic

    Calytic Community Admin Community Mod

    merged
     
  6. Calytic

    Calytic Community Admin Community Mod

    Calytic updated EntityOwner with a new update entry:

    2.0.1


    [DOUBLEPOST=1454625210][/DOUBLEPOST]
    Fixed.
    [DOUBLEPOST=1454627075][/DOUBLEPOST]
    Thanks for the question. This answer will be relatively long but the short of it is the performance update required it. Uncommenting this code is risky, you will lose entire ownership profiles if the plugin reloads before the previous instance is done saving (which becomes more likely the more popular your server is). If this were not the case, I would have left OnUnload in, and it may even be entirely reasonable to comment it out only on a low pop server.

    I did not understand this issue previously and wrote a slower, 100% reliable saving method that works in conjunction with the OnUnload behavior as you know it. The performance implications of a fix in addition to the need for a forced wipe (due to pillar exploit) provided a unique opportunity to revert to the previous, faster saving method. The only barrier to the previous method is that the reliability is less than 100% when used in conjunction with the OnUnload behavior. By removing the OnUnload behavior, we have the performance gain and maintain 100% reliability.

    So it's one or the other: Keep the OnUnload behavior with slower data handling or remove OnUnload and have faster data handling. I chose performance over flexibility here, and the specific flexibility in question only really effects developers (a very small minority). In contrast, suboptimal performance of this plugin effects basically everyone using it.

    The size of the folder will not affect performance of this plugin. The number of profiles currently loaded into memory will. If you are concerned about the impact of a large EntityOwner footprint on a high-pop server, EntityOwner does account for that. You have 2 options.
    1. Unloading EntityOwner safely without losing pending changes
      owners.save
      unload EntityOwner

    2. Pruning the master player list, therein reducing the memory footprint to bare minimum
      owners.expire
      reload EntityOwner
    I appreciate the feedback, please do not hesitate to contact me if you have any other questions regarding this issue.
     
    Last edited: Feb 4, 2016
  7. nice thank you Calytic :)

    edit: TY Calytic. Running smooth as butter @ 240 players
     
    Last edited by a moderator: Feb 5, 2016
  8. Got A Question, is it better to use Entity Owners plugin or Building owners? I dont want to load hard our server - its like virtual server or something >50 slots
     
  9. Depends on what you need.
    EntityOwner has a larger footprint than BuildingOwners but actually tracks everything (like signs, chests, or whatever) instead of just buildings.
    If you do not need the features provided by EntityOwner which aren't provided by BuildingOwners, then always err on the side of simplicity.
    While I think that Catalytic is doing an amazing job, EntityOwner is still a HUGE plugin.
    EntityOwner has roughly 2.5k lines of code while BuildingOwners only has 200.
    EntityOwner is a lot more complex than BuildingOwners, and because of that, will inherently suffer more from bugs.
    So, to sum it up: EntityOwner has a larger footprint and is a lot more complex than BuildingOwners, if you do not need the features provided by EntityOwner, you should use BuildingOwners.
     

  10. Thanks for providing such good info, will stick to BuildingOwners, i mean it would be great to track all, but i think server would lag huge... But anyway thanks man!
     
  11. I only said EntityOwner leaves a larger footprint.
    That doesn't essentially mean that it performs worse or makes the server lag more.
    You'd have to actually test it to see which causes more lag.
     
  12. some of my players still have that building blocked thing. how do i fix it if i cant /authclean?
     
  13. Calytic

    Calytic Community Admin Community Mod

    This plugin no longer causes that issue. In what situation are players receiving a stuck building block?
     
  14. Well i cant say for sure that he had building blocked everywhere. But he said he has.
    He was going to /sethome at his base, but wasnt able cause building blocked.
    Sometimes it helps running away from the area and run back.
    If this happens again i will give you more information.
    Thanks for reply and a helpful plugin!
     
  15. Calytic

    Calytic Community Admin Community Mod

    Sounds right, that is a known issue with teleportation.
     
  16. The issue of /removing a cupboard without auth'ing it is back. I saw in the update notes that was intentional. Is there a specific reason why the ownerdata is associated with it again? Have countless cases of people getting stuck with building block as a result.
     
  17. Hey, I tried the old method of getting Entity Owner to work with the Remove tool but its not working anymore.. any ideas?
     
  18. Calytic

    Calytic Community Admin Community Mod

    Calytic updated EntityOwner with a new update entry:

    2.0.2


    [DOUBLEPOST=1454747032][/DOUBLEPOST]For the record, the EntityOwner/Remover Tool combination is no longer causing the stuck building block bug in most cases.

    This is happening because of network latency and having /remove enabled WHILE PLACING A TOOL CUPBOARD. The tool cupboard does not have enough time to initialize before being removed by Remover Tool. The workaround is to delay cupboard ownership by a fraction of a second after placement. This means that players will have to click twice to remove cupboards while placing them.

    This bug will still occur on servers with cupboard warriors and m-Teleportation.
    [DOUBLEPOST=1454749193][/DOUBLEPOST]On performance, without proper profiling tools it is impossible to compare the performance of EntityOwner and Building Owners. It is therefore impossible to objectively state which performs better in the aggregate.

    However, I can say several things with complete certainty when comparing the two.
    1. EntityOwner uses a completely different method for loading and saving player ownership profiles
    2. EntityOwner requires basically the same amount of processing when starting the server and loading all ownership profiles.
    3. EntityOwner requires less processing when randomly accessing ownership profiles in memory (checking who owns something is faster)
    4. EntityOwner stores profiles without loading them. Building Owners must load all profiles all the time (substantially increasing potential memory footprint and requiring a larger index thus slowing down random access of ownership profiles).
    Ultimately, as of this posting, is more friendly to highly populated servers with large data sets (naturally) and servers that use any plugins that depend on EntityOwner.
     
    Last edited: Feb 6, 2016
  19. So, I finally made decision to move from BuildingOwners to this plugin. Testing this plugin on fresh-wiped test server. Made small building with cupboard and deployables in it. Testing commands:
    "/prod2 block" gives this:
    Code:
    [2/8/2016 1:49:44 AM] [Oxide] 1:49 AM [Debug]   at Oxide.Plugins.EntityOwner.massProd[BuildingBlock] (.BasePlayer player) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.EntityOwner.cmdProd2 (.BasePlayer player, System.String command, System.String[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.EntityOwner.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.CSharpPlugin.InvokeMethod (System.Reflection.MethodInfo method, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.Plugin.CallHook (System.String hookname, System.Object[] args) [0x00000] in <filename unknown>:0
    [2/8/2016 1:49:45 AM] [Oxide] 1:49 AM [Info] [Logger] Rizzok :: /prod2 block
    and "/prod2 storage" gives that:
    Code:
    [2/8/2016 1:52:36 AM] [Oxide] 1:52 AM [Debug]   at Oxide.Plugins.EntityOwner.massProd[StorageContainer] (.BasePlayer player) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.EntityOwner.cmdProd2 (.BasePlayer player, System.String command, System.String[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.EntityOwner.DirectCallHook (System.String name, System.Object& ret, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Plugins.CSharpPlugin.InvokeMethod (System.Reflection.MethodInfo method, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.CSPlugin.OnCallHook (System.String name, System.Object[] args) [0x00000] in <filename unknown>:0
      at Oxide.Core.Plugins.Plugin.CallHook (System.String hookname, System.Object[] args) [0x00000] in <filename unknown>:0
    [2/8/2016 1:52:37 AM] [Oxide] 1:52 AM [Info] [Logger] Rizzok :: /prod2 storage
    owners_list.json:
    Code:
    [
      76561197971543022
    ]
    entityowner_76561197971543022.json:
    Code:
    {
      "playerID": 76561197971543022,
      "Constructions": [
        "x1446.132y46.2609z343.9522",
        "x1444.6y46.2609z346.5311",
        "x1448.711y46.2609z345.4849",
        "x1447.179y46.2609z348.0638",
        "x1443.833y46.2509z347.8206",
        "x1446.412y46.2509z349.3533",
        "x1448.468y46.2509z348.8302",
        "x1450.001y46.2509z346.2513",
        "x1449.478y46.2509z344.1955",
        "x1446.899y46.2509z342.6628",
        "x1444.843y46.2509z343.1859",
        "x1443.31y46.2509z345.7648"
      ],
      "Deployables": [
        "x1450.001y46.2509z346.2513",
        "x0y0z0",
        "x1446.575y46.35091z346.1248",
        "x1447.502y46.35091z349.3764",
        "x1445.729y46.35091z343.131",
        "x1447.65y46.35091z347.0501",
        "x1444.009y46.35091z346.8012"
      ]
    }
     
  20. Calytic

    Calytic Community Admin Community Mod

    Calytic updated EntityOwner with a new update entry:

    2.0.3