PluginBugs / Issues-ItemsAdder

Repository used to keep track of issues of my plugin ItemsAdder
https://itemsadder.devs.beer
52 stars 21 forks source link

/iaplayerstat read is possible, but /iaplayerstat write is not possible. #2321

Closed repiece closed 1 year ago

repiece commented 1 year ago

Terms

Discord tag (optional)

No response

What happened?

hud config

info:
  namespace: hud
huds:
  wrold_hud:
    enabled: true
    show:
      auto: true
    type: FRAMES
    x_position_pixels: 220
    value:
      player_stat_name: example_stat
      start: 0
      min: 0
      max: 2
    images:
      frames:
      -  hud:blood_moon
      -  hud:power_up
      -  hud:health_up

The float, int values do not change when writing from example_stat.

Steps to reproduce the issue

  1. /iaplayerstat read [playerName] [exampleStatName] float Verify that the existing value is 0.
  2. /iaplayerstat write [playerName] [exampleStatName] float 1
  3. /iaplayerstat read [playerName] [exampleStatName] float Check if the value has changed

I think it works fine to change the value using the trigger, but I don't think I can change it using the command, itemsadder api.

Server version

This server is running CraftBukkit version 3638-Spigot-d90018e-7dcb59b (MC: 1.19.3) (Implementing API version 1.19.3-R0.1-SNAPSHOT)

ItemsAdder Version

ItemsAdder version 3.3.1

ProtocolLib Version

ProtocolLib version 5.0.0-SNAPSHOT-b612

LoneLibs Version

LoneLibs version 1.0.23

FULL server log

Starting server Error, this build is outdated Please download a new build as per instructions from https://www.spigotmc.org/go/outdated-spigot Server will start in 20 seconds Loading libraries, please wait... [10:35:33] [ServerMain/WARN]: Invalid registry value type detected for PerfOS counters. Should be REG_DWORD. Ignoring: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\PerfOS\Performance\Disable Performance Counters. [10:35:35] [ServerMain/INFO]: Building unoptimized datafixer [10:35:36] [ServerMain/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD' [10:35:38] [ServerMain/INFO]: Loaded 7 recipes [10:35:33] [ServerMain/WARN]: Invalid registry value type detected for PerfOS counters. Should be REG_DWORD. Ignoring: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\PerfOS\Performance\Disable Performance Counters. [10:35:35] [ServerMain/INFO]: Building unoptimized datafixer [10:35:36] [ServerMain/INFO]: Environment: authHost='https://authserver.mojang.com', accountsHost='https://api.mojang.com', sessionHost='https://sessionserver.mojang.com', servicesHost='https://api.minecraftservices.com', name='PROD' [10:35:38] [ServerMain/INFO]: Loaded 7 recipes [10:35:39] [Server thread/INFO]: Starting minecraft server version 1.19.3 [10:35:39] [Server thread/INFO]: Loading properties

[10:35:40] [Server thread/INFO]: This server is running CraftBukkit version 3638-Spigot-d90018e-7dcb59b (MC: 1.19.3) (Implementing API version 1.19.3-R0.1-SNAPSHOT) [10:35:40] [Server thread/INFO]: Debug logging is disabled [10:35:40] [Server thread/INFO]: Server Ping Player Sample Count: 12 [10:35:40] [Server thread/INFO]: Using 4 threads for Netty based IO [10:35:40] [Server thread/INFO]: Default game type: SURVIVAL [10:35:40] [Server thread/INFO]: Generating keypair [10:35:40] [Server thread/INFO]: Starting Minecraft server on *:25565 [10:35:40] [Server thread/INFO]: Using default channel type [10:35:40] [Server thread/INFO]: [LoneLibs] Loading LoneLibs v1.0.23 [10:35:40] [Server thread/INFO]: [ProtocolLib] Loading ProtocolLib v5.0.0-SNAPSHOT-b612 [10:35:41] [Server thread/INFO]: [ItemsAdder] Loading ItemsAdder v3.3.1 [10:35:41] [Server thread/INFO]: [LoneLibs] Enabling LoneLibs v1.0.23 [10:35:41] [Server thread/INFO]: [ProtocolLib] Enabling ProtocolLib v5.0.0-SNAPSHOT-b612 [10:35:41] [Server thread/INFO]: Preparing level "world" [10:35:41] [Server thread/INFO]: -------- World Settings For [world] -------- [10:35:41] [Server thread/INFO]: Item Despawn Rate: 6000 [10:35:41] [Server thread/INFO]: Item Merge Radius: 2.5 [10:35:41] [Server thread/INFO]: Simulation Distance: 10 [10:35:41] [Server thread/INFO]: View Distance: 10 [10:35:41] [Server thread/INFO]: Nerfing mobs spawned from spawners: false [10:35:41] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true [10:35:41] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200 [10:35:41] [Server thread/INFO]: Zombie Aggressive Towards Villager: true [10:35:41] [Server thread/INFO]: Experience Merge Radius: 3.0 [10:35:41] [Server thread/INFO]: Mob Spawn Range: 6 [10:35:41] [Server thread/INFO]: Cactus Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Cane Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Melon Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Mushroom Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Pumpkin Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Sapling Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Beetroot Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Carrot Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Potato Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Wheat Growth Modifier: 100% [10:35:41] [Server thread/INFO]: NetherWart Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Vine Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Cocoa Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Bamboo Growth Modifier: 100% [10:35:41] [Server thread/INFO]: SweetBerry Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Kelp Growth Modifier: 100% [10:35:41] [Server thread/INFO]: TwistingVines Growth Modifier: 100% [10:35:41] [Server thread/INFO]: WeepingVines Growth Modifier: 100% [10:35:41] [Server thread/INFO]: CaveVines Growth Modifier: 100% [10:35:41] [Server thread/INFO]: Entity Activation Range: An 12 / Mo 24 / Ra 24 / Mi 8 / Tiv true / Isa false [10:35:41] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false [10:35:41] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64 [10:35:41] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645 [10:35:41] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms [10:35:41] [Server thread/INFO]: Max TNT Explosions: 100 [10:35:42] [Server thread/INFO]: -------- World Settings For [world_nether] -------- [10:35:42] [Server thread/INFO]: Item Despawn Rate: 6000 [10:35:42] [Server thread/INFO]: Item Merge Radius: 2.5 [10:35:42] [Server thread/INFO]: Simulation Distance: 10 [10:35:42] [Server thread/INFO]: View Distance: 10 [10:35:42] [Server thread/INFO]: Nerfing mobs spawned from spawners: false [10:35:42] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true [10:35:42] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200 [10:35:42] [Server thread/INFO]: Zombie Aggressive Towards Villager: true [10:35:42] [Server thread/INFO]: Experience Merge Radius: 3.0 [10:35:42] [Server thread/INFO]: Mob Spawn Range: 6 [10:35:42] [Server thread/INFO]: Cactus Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Cane Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Melon Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Mushroom Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Pumpkin Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Sapling Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Beetroot Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Carrot Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Potato Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Wheat Growth Modifier: 100% [10:35:42] [Server thread/INFO]: NetherWart Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Vine Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Cocoa Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Bamboo Growth Modifier: 100% [10:35:42] [Server thread/INFO]: SweetBerry Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Kelp Growth Modifier: 100% [10:35:42] [Server thread/INFO]: TwistingVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: WeepingVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: CaveVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Entity Activation Range: An 12 / Mo 24 / Ra 24 / Mi 8 / Tiv true / Isa false [10:35:42] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false [10:35:42] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64 [10:35:42] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645 [10:35:42] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms [10:35:42] [Server thread/INFO]: Max TNT Explosions: 100 [10:35:42] [Server thread/INFO]: -------- World Settings For [world_the_end] -------- [10:35:42] [Server thread/INFO]: Item Despawn Rate: 6000 [10:35:42] [Server thread/INFO]: Item Merge Radius: 2.5 [10:35:42] [Server thread/INFO]: Simulation Distance: 10 [10:35:42] [Server thread/INFO]: View Distance: 10 [10:35:42] [Server thread/INFO]: Nerfing mobs spawned from spawners: false [10:35:42] [Server thread/INFO]: Allow Zombie Pigmen to spawn from portal blocks: true [10:35:42] [Server thread/INFO]: Arrow Despawn Rate: 1200 Trident Respawn Rate:1200 [10:35:42] [Server thread/INFO]: Zombie Aggressive Towards Villager: true [10:35:42] [Server thread/INFO]: Experience Merge Radius: 3.0 [10:35:42] [Server thread/INFO]: Mob Spawn Range: 6 [10:35:42] [Server thread/INFO]: Cactus Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Cane Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Melon Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Mushroom Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Pumpkin Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Sapling Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Beetroot Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Carrot Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Potato Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Wheat Growth Modifier: 100% [10:35:42] [Server thread/INFO]: NetherWart Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Vine Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Cocoa Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Bamboo Growth Modifier: 100% [10:35:42] [Server thread/INFO]: SweetBerry Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Kelp Growth Modifier: 100% [10:35:42] [Server thread/INFO]: TwistingVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: WeepingVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: CaveVines Growth Modifier: 100% [10:35:42] [Server thread/INFO]: Entity Activation Range: An 12 / Mo 24 / Ra 24 / Mi 8 / Tiv true / Isa false [10:35:42] [Server thread/INFO]: Hopper Transfer: 8 Hopper Check: 1 Hopper Amount: 1 Hopper Can Load Chunks: false [10:35:42] [Server thread/INFO]: Entity Tracking Range: Pl 48 / An 48 / Mo 48 / Mi 32 / Other 64 [10:35:42] [Server thread/INFO]: Custom Map Seeds: Village: 10387312 Desert: 14357617 Igloo: 14357618 Jungle: 14357619 Swamp: 14357620 Monument: 10387313 Ocean: 14357621 Shipwreck: 165745295 End City: 10387313 Slime: 987234911 Nether: 30084232 Mansion: 10387319 Fossil: 14357921 Portal: 34222645 [10:35:42] [Server thread/INFO]: Tile Max Tick Time: 50ms Entity max Tick Time: 50ms [10:35:42] [Server thread/INFO]: Max TNT Explosions: 100 [10:35:42] [Server thread/INFO]: Preparing start region for dimension minecraft:overworld [10:35:45] [Worker-Main-14/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-14/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-1/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-4/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-14/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-19/INFO]: Preparing spawn area: 0% [10:35:45] [Worker-Main-17/INFO]: Preparing spawn area: 0% [10:35:46] [Worker-Main-18/INFO]: Preparing spawn area: 9% [10:35:46] [Worker-Main-11/INFO]: Preparing spawn area: 89% [10:35:46] [Server thread/INFO]: Time elapsed: 4052 ms [10:35:46] [Server thread/INFO]: Preparing start region for dimension minecraft:the_nether [10:35:48] [Worker-Main-18/INFO]: Preparing spawn area: 0% [10:35:48] [Worker-Main-7/INFO]: Preparing spawn area: 0% [10:35:48] [Worker-Main-1/INFO]: Preparing spawn area: 0% [10:35:48] [Worker-Main-13/INFO]: Preparing spawn area: 0% [10:35:48] [Worker-Main-1/INFO]: Preparing spawn area: 0% [10:35:49] [Worker-Main-14/INFO]: Preparing spawn area: 0% [10:35:49] [Worker-Main-5/INFO]: Preparing spawn area: 69% [10:35:49] [Server thread/INFO]: Time elapsed: 3117 ms [10:35:49] [Server thread/INFO]: Preparing start region for dimension minecraft:the_end [10:35:52] [Worker-Main-13/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-23/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-13/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-19/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-14/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-11/INFO]: Preparing spawn area: 0% [10:35:52] [Worker-Main-1/INFO]: Preparing spawn area: 0% [10:35:53] [Worker-Main-5/INFO]: Preparing spawn area: 44% [10:35:53] [Server thread/INFO]: Time elapsed: 3747 ms [10:35:53] [Server thread/INFO]: [ItemsAdder] Enabling ItemsAdder v3.3.1 [10:35:53] [Server thread/INFO]: [NBTAPI] Found Spigot: v1_19_R2! Trying to find NMS support [10:35:53] [Server thread/INFO]: [NBTAPI] NMS support 'MC1_19_R2' loaded! [10:35:53] [Server thread/INFO]: [NBTAPI] Found Gson: class com.google.gson.Gson

ItemsAdder 3.3.1 | | | |\/| /` /\ | \ | \ | |) LoneLibs 1.0.23 | | | | | ./ /--\ |/ |__/ |___ | \ CraftBukkit 3638-Spigot-d90018e-7dcb59b (MC: 1.19.3)

[10:35:53] [Server thread/INFO]: [ItemsAdder] LightAPI not installed, please install it to see blocks emitting light: https://a.devs.beer/lightapi-new [10:35:54] [Server thread/INFO]: [ItemsAdder] [Host] Starting self-host webserver on port: 8163 [10:35:54] [Server thread/INFO]: Server permissions file permissions.yml is empty, ignoring it

[10:35:54] [Server thread/INFO]: [ItemsAdder] [Pack] Extracting internal contents from .jar [10:35:54] [Server thread/INFO]: [ItemsAdder] [Pack] DONE extracting internal contents from .jar [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] [License] Spigot product licensed to: MindControl (1728770) [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Loaded 14 items [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 0/188 REAL block IDs [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 0/750 REAL_NOTE block IDs [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 0/63 REAL_TRANSPARENT block IDs [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 0/127 REAL_WIRE block IDs [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 0/14 FIRE block IDs [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] Used 10/6608 font_images [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] [Init] Loaded 1 categories [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] [Init] Loaded successfully. [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] [Pack] Checking resourcepack url... [10:35:54] [Craft Scheduler Thread - 1/INFO]: [ItemsAdder] [Pack] Resourcepack URL (self-host): http://220.79.149.182:8163/generated.zip [10:37:32] [User Authenticator #1/INFO]: UUID of player J_sed38 is 65e5cf85-6507-472a-b334-749b27ae7c3d [10:37:33] [Server thread/INFO]: J_sed38 joined the game [10:37:33] [Server thread/INFO]: J_sed38[/220.79.149.182:55738] logged in with entity id 87 at ([world]-31.79087724917599, 68.0, 207.95813406733723) [10:37:57] [Server thread/INFO]: J_sed38 issued server command: /iaplayerstat write J_sed38 example_stat int 1 [10:38:00] [Server thread/INFO]: J_sed38 issued server command: /iaplayerstat write J_sed38 example_stat int 2 [10:38:21] [Server thread/INFO]: J_sed38 issued server command: /iaplayerstat read J_sed38 example_stat int [10:42:37] [Server thread/INFO]: J_sed38 issued server command: /iaplayerstat read J_sed38 example_stat int

LoneDev6 commented 1 year ago

Did you add the permissions? ia.admin.iaplayerstat.write ia.admin.iaplayerstat.read

Millionary commented 1 year ago

i've noticed that we cannot change iaplayerstat to OP players, i tried without OP and /iaplayerstat works fine

LoneDev6 commented 1 year ago

You have to negate the bypass permission to OP players, it should be the issue. ia.user.hud.bypass.triggers.* ia.user.hud.bypass.commands.* ia.user.hud.bypass.api.*