Skip to content

NPCSensorStatsCommand

Package: com.hypixel.hytale.server.npc.commands

public class NPCSensorStatsCommand extends AbstractPlayerCommand

Implements /npc sensorstats. Computes and logs sensor detection range statistics for every spawnable NPC role. For each role, temporarily builds the role object and extracts RoleStats to determine sorted/unsorted/avoidance detection ranges and priority buckets for both player and entity detection.

Results are formatted as a table logged to the NPC plugin logger, with rows labeled PLY (player detection) and ENT (entity detection), showing:

  • S= — sorted detection ranges
  • U= — unsorted detection ranges
  • A= — avoidance ranges
  • B= — priority bucket assignments

A temporary NPC is spawned and immediately removed to provide the build context.

public NPCSensorStatsCommand()

Registers as sub-command "sensorstats" with translation key "server.commands.npc.sensorstats.desc".

Hydex is an independent community resource. Hytale is a trademark of Hypixel Studios. Hydex is not affiliated with or endorsed by Hypixel Studios.