* Small cleanup to `/player` command
There should be no changes to users
* Use extracted `source` variable
* Inline another single-use small function
* Inline another trivial helper
* Import inner classes of the ActionPack
* Rename `literalargumentbuilder` variable
* Compact unnecessary three lines into one
* Inline `source.getServer` and pass `Vec3` to `createFake`
This gets outside of "just" the command, but it's fine
* Unpick name length constant
* Pass `Vec3` directly to `BlockPos.containing`
* Move rule change event into a rule observer, without exposing it
* Fix comment
* Fix formatting changes added by my IDE
Still trying to configure it to force correctly the new style
Also remove some finals
This is a breaking change, but there's only one use of the function on all github
The refactor also makes `register` take a function to `Value`, no one uses the one to `LazyValue` anyway. `registerToValue` is now deprecated
- Fully remove late registration handling
- That removes the reference to the command dispatcher
- Fix displaced comment
- Simplify "don't mixin to register" checking
Java's is synchronized everywhere, reducing performance given we don't need it to be. It's recommended to use `Deque` as a replacement, but given we have fastutil's, we use those
Closes#1640
When warping and frozen the game will now run at 20 (frozen) TPS instead of as fast as possible around a loop
Frozen ticks will no longer count towards tick warping
TPS logger will now display `TPS: 0.0` when the game is frozen
- Prevents boxes with different nbt from stacking. Fixes#1596
- Makes stacks partially be able merge to max size when sum would be greater than it (by keeping both entities around, but lowering its count)
Pending for the future: Checking why client doesn't render stack size changes
Many users assume it is, and all callers pass it anyway. At some point `host` access could be made a function so CC could override it and return `CarpetScriptHost` without requiring casts
* Improve error message when command already exists
* Add app's name to the message
* Add app name to any command load failure and fix commands from new system masking existing ones
* Fix duplicated app name in an error
* Update to recent snapshot changes
* Settings rework and encapsulation
* Settings overhaul 3
Move everything in the new system to a new API package
Require rules using the new system to specify descriptions in their translation files
Implement temporary system on top of current translations to allow that to work properly
* Fix getRules fallback
* Final touches to settings refactor
* Mention that set shouldn't throw and remove comment
* Change translation keys to unify with translation PR
* Deprecate printAllRulesToLog to allow using any PrintStream
* Remove restriction of CarpetRules being Comparable
And fix overreaction in a deprecation message
* Bring back user input to rule observers
* Make Validator deprecation warning not spam on use
* Remove unneeded abstract methods in CarpetRule already inherited from CarpetRule
They literally do nothing, don't even force them to be implemented, and may be confusing as to why they're there or as if they are needed to be implemented
* Fix legacy SettingsManager field not being assigned correctly
* Finish fixing conflicts from future merge
* Actually fix remaining conflicts from future merge (missing imports)
* Import the newer rule in SettingsManager
* Refactor Validators
* Don't spam deprecation warnings on custom managers
* Get out the var
* Fix missing warning in old rule observers
* Update src/main/java/carpet/api/settings/Rule.java
* Remove `@ApiStatus.Experimental` annotations
* Fix incorrect `@deprecated` javadoc tags
By removing them given the class is deprecated anyway and else there's too much noise
* Add missing static import
* Remove TypedField and use a regular field
I liked that class tbh, but it's true that it wasn't really needed
* Move `field` assignment out of for removal
* Fix not following contract of `type()` returning boxed value
Previously handled by TypedField
* Fix few incorrect translation keys
* Remove resaving of comments when saving config files
Comments ignoring is still a thing when reading, so `locked` configs for example will keep comments
* Condense rule load messages in one
* Only print loaded settings message when at least one setting was changed
* Fix legacy validator detector
* Tweak and add more context to response to invalid values
* Fix strict validator not actually erroring on invalid input