Administration
Profile overlays
Change a few keys of an author's profile from the server side, without touching the author's file, and undo it with one command.
An overlay lets an administrator retune a profile on one server (calmer cadence, a lower zone mode, a smaller zone) without editing the author's file. ThePredict never writes the author's profile: the profile a mob uses becomes the author's profile plus the overlay, and removing the overlay brings the author's version back.
Each overlay belongs to exactly one profile. Nothing is ever applied on its own: autoconfig.autoApply only accepts "off".
The proposal file
A proposal is a plain text file you write under plugins/ThePredict/autoconfig/, one key=value per line. Lines starting with # are comments.
# Calmer guardian on the survival server
profile=thepredict_guardian
base=<fingerprint of the author's profile>
Timing.Cadence=standard
Zone.Mode=guard
Zone.Radius=32| Line | Meaning |
|---|---|
profile=<id> | The profile ID the overlay belongs to. Without it, the file name without its extension is used. |
base=<fingerprint> | Fingerprint of the author's profile the proposal was written for. Required by apply. |
pin=<key> | Leaves that key out: the author's value is kept. |
<key>=<value> | A profile key and its new value. |
To get the fingerprint, leave base= out and run apply once: the refusal OVERLAY_STALE prints the fingerprint of the profile as it is now (... (base <fingerprint>)). Copy it into the file and apply again.
Keys an overlay can set
| Key | Notes |
|---|---|
Timing.Cadence | reactive or standard. |
Timing.TickLayer | casts, reactions or full. Above decision.tickLayer.mode it is lowered to the global mode, like a profile's, with a warning. |
Timing.Reactions | all, survival or none. |
Timing.ReactiveInterval | 4 to 20 ticks. |
Zone.Mode | Can only lower zone.mode, and cannot be off. |
Zone.Radius | 8 to 64 blocks. |
Group.Mode | Can only lower group.mode, and cannot be off. |
Patterns.Mode | Can only lower patterns.mode. |
Decision.Pruning, Decision.MaxOptions, Decision.CandidateScoring, Decision.Diversity | Accepted, but these profile keys have no effect in fights yet (see the Profile reference). |
Other keys are ignored. Mode values are read without case, so Zone.Mode=OFF is refused like off.
Commands
All of them need the permission thepredict.autoconfig. The <path> must contain plugins/ThePredict/autoconfig/ and no ..; anything else answers Autoconfig writes only under plugins/ThePredict/autoconfig/.
| Command | What it does |
|---|---|
/thepredict autoconfig or autoconfig status | Answers autoApply=off. |
/thepredict autoconfig import <path> | Copies the proposal into autoconfig/inbox/. It changes nothing in fights. |
/thepredict autoconfig apply <path> | Checks the proposal and writes autoconfig/active/<file name>: first profile= and base=, then the keys that are not pinned. Then it reloads the profile catalog, and live mobs switch to the new profile as after /mm reload. |
/thepredict autoconfig show <path> | Shows the active copy of that proposal, or none. |
/thepredict autoconfig revert <path> | Deletes the active copy and reloads the catalog: the author's profile rules again. |
The file commands answer queued and report the result when the storage thread finishes. Without the storage writer they answer Autoconfig <action> needs the storage writer.
/thepredict autoconfig apply plugins/ThePredict/autoconfig/thepredict_guardian.txt
/thepredict autoconfig show plugins/ThePredict/autoconfig/thepredict_guardian.txt
/thepredict autoconfig revert plugins/ThePredict/autoconfig/thepredict_guardian.txtTo change the overlay of a profile, revert the old one first, then apply the new proposal.
When apply refuses
apply checks everything a reload would check and writes nothing when it refuses:
| Refusal | Cause |
|---|---|
OVERLAY_RAISES_GLOBAL | A key raises a global mode (Zone.Mode, Group.Mode or Patterns.Mode above zone.mode, group.mode or patterns.mode), or sets Zone.Mode or Group.Mode to off. |
OVERLAY_INVALID | A mode is not a mode, base= is missing, a line has no =, or a key cannot be applied to the profile (for example Zone.Radius=100; the reason is given). |
OVERLAY_UNREADABLE | The file is larger than 64 KiB. |
OVERLAY_UNMATCHED | No profile read now has that ID. |
OVERLAY_STALE | base= is not the fingerprint of the profile read now; the message gives the current one. |
On every reload
At startup, on every /mm reload and after each apply or revert, ThePredict reads up to 256 files of at most 64 KiB from autoconfig/active/ and applies each one to its own profile. A key from the overlay wins over the same key of the author's profile. When a file cannot be applied, the author's profile is used and the console warns, naming the file:
| Warning | Cause |
|---|---|
OVERLAY_UNMATCHED | No profile with that ID. |
OVERLAY_DUPLICATE | An earlier file already holds the overlay of that profile. |
OVERLAY_STALE | The author changed the profile after the overlay was built. |
OVERLAY_INVALID | A key does not apply. |
OVERLAY_UNREADABLE | The file is unreadable or larger than 64 KiB. |
An overlay whose Timing.TickLayer is above decision.tickLayer.mode still applies, lowered to the global mode, and the console warns, for example autoconfig/active/thepredict_guardian.txt: thepredict_guardian: Timing.TickLayer is above the global reactions; using reactions.
When the author edits the profile, its fingerprint changes, the overlay goes stale and the author's version rules again until you write a new proposal.
Note No automatic search yet
The autoconfig.* keys size an offline search for good overlays. That search does not run on the server in this release: proposals are written by hand.