Commit Graph
2779 Commits
Author SHA1 Message Date
altrisi 15b120f729 Encapsulate COUNTERS field in HopperCounter 2023-04-22 20:45:29 +02:00
altrisi f1205a4251 Make hoppers use the getter for HopperCounter in their mixin
And very minor cleanup in it
2023-04-22 20:41:12 +02:00
gnembon d68c252180 23w16a 2023-04-20 22:13:32 +02:00
gnembon 51fae27708 single argument print(foo) in player scoped apps will always target the player instance for chat message output. 2023-04-20 20:46:33 +02:00
gnembon c9b93e598a added two argument while loop because duh? 2023-04-20 14:26:40 +02:00
altrisi 384bd37159 Remove unnecessary getPlayerOrException in TickCommand 2023-04-13 20:27:20 +02:00
altrisi 51f213fa15 Cleanup counter command (#1695)
- Import `Commands.literal`
- Use more readable syntax for Brigadier command
- Use `DyeColor` directly instead of toString -> fromString everywhere
  - Also updates `WoolTool` to use the new `HopperCounter` getter that supports it
- Split `resetCounter` in two, one for single and one for all

Also: HopperCounter now uses `.overworld()` and its `//OW` comments are removed
2023-04-08 20:14:26 +02:00
altrisi 8cd60db5e4 Random cleanups to users of Level.OVERWORLD and reduce minecraft_server usage (#1697)
- Use `overworld()` instead of `getLevel(Level.OVERWORLD)` when convenient
- Remove now unnecessary `// OW` comments, from when it had no mappings
- Make spawn chunk size and light batches not depend on global server instance
- Merge all spawn chunk size logic into SpawnChunks instead of methods in the validator
- Remove unneeded `withWorld(OVERWORLD)` with just-created server `CommandSource`s
- Use enhanced for in light batch application
2023-04-08 20:01:30 +02:00
altrisi 17c2d601d2 Remove global server reference from Player_antiCheatDisabledMixin 2023-04-08 19:48:52 +02:00
altrisi 6b9e7aff3e Use List.of in EquipmentInventory
`Arrays.asList` isn't immutable, and `List.of` can be optimized slightly better, is more readable and also removes an import
2023-04-08 16:14:47 +02:00
altrisi a3762584f3 Use for loop for hopper counter info in HUDController 2023-04-08 16:12:38 +02:00
gnembon 1751f103f9 23w14a 2023-04-05 20:12:21 +02:00
gnembon 9a5c2d5fc3 deprecation of material(...), fix map_colour(...) 2023-04-05 20:09:52 +02:00
altrisi fdb0936df7 Remove deprecated log4j dependent methods in c.s.SettingsManager
And another one that is normally a bug to use, and a field that is
broken.

Enables `runtimeOnlyLog4j` in loom
2023-04-04 15:57:59 +02:00
altrisi cda7f791b7 Prioritize new Rule annotation when parsing if both are present 2023-04-03 21:58:16 +02:00
altrisi 50c22b6fe2 Log exceptions in notifyPlayersCommandsChanged
I want to remove this try-catch if possible, but don't know why it's
triggered
2023-04-03 21:47:30 +02:00
altrisi 3ae913c3e6 Use enhanced switch in CommandHelper 2023-04-03 21:42:44 +02:00
altrisi d85c23125f Add explicit deprecation SuppressWarnings for Gradle 2023-04-03 19:40:33 +02:00
altrisi 56e25a780c Missed call in 5fcfc7a 2023-04-03 19:19:31 +02:00
altrisi 83e88856ab Rename fungus growth enum given the rule is no longer about a fix 2023-04-03 19:15:08 +02:00
altrisi 431b0e68de Cleanup to the /player command (#1690)
* 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`
2023-04-03 18:41:09 +02:00
altrisi 5fcfc7aa8d Tiny drive-by cleanup of action pack's onUpdate 2023-04-02 21:54:44 +02:00
altrisi 73260a220c Use EnumMap in the action pack 2023-04-02 21:23:42 +02:00
altrisi 2d0a8e11da Keep the other improvements from #1689 2023-04-02 13:26:46 +02:00
altrisi b055b05263 Revert "Fix /player look and turn commands reversing yaw and pitch (#1689)"
This reverts commit 591153458c.
2023-04-02 12:51:22 +02:00
altrisi 591153458c Fix /player look and turn commands reversing yaw and pitch (#1689)
* Fix `/player` `look` and `turn` commands reversing yaw and pitch

* Translate a comment to mojmap and update it a bit
2023-04-01 12:34:54 +02:00
James McCulloch e7c02ea21a shadow-single-player-owner-fix: (#1687)
* shadow-single-player-owner-fix:
* Disallow shadowing a single player server owner. Fixes #1442

* shadow-single-player-owner-fix:
* Remove some redundant calls
2023-04-01 12:22:04 +02:00
gnembon 4171f9b784 23w13a 2023-03-29 18:44:12 +02:00
gnembon f1586b3809 23w12a 2023-03-22 18:27:44 +01:00
altrisi 1ad927da9d Up priority in MinecraftServer_tickspeedMixin 2023-03-19 19:36:37 +01:00
Ghoulboy cde3ffced2 Fixing /player botname stop with relation to *fake* player movement (#1683) 2023-03-19 18:56:12 +01:00
altrisi f98c2409be Simplify enum options creation
Slightly optimizes it
2023-03-16 17:36:44 +01:00
replaceitem 8aae23c983 Fixed AnnotationParser not detecting USE_METHOD_NAME (#1677) 2023-03-15 14:46:31 +01:00
James McCulloch 8307794f19 Fix fake players not being able to respawn for exiting the end (#1664)
* Allow fake players to respawn (to return from the end)
* Fixes #1645 (Fake players get stuck in the end exit portal)

* fix up some imports
2023-03-14 17:07:27 +01:00
James McCulloch 8c09946bef Fix fake players not teleporting to unloaded chunks (#1665)
* fake-players-teleporting-fix:
* Fix fake players not being moved on the chunkmap when teleporting
* Fixes #1190 (Player bots cannot be teleported to unloaded chunks)

* fake-players-teleporting-fix:
* add missing access widener

* Revert "fake-players-teleporting-fix:"

This reverts commit 617702fca14035913103140d2e04fa33065bf628.

* fake-players-teleporting-fix:
* access awaitingTeleport in a nicer way

* fake-players-teleporting-fix: * access awaitingTeleport in a nicer way
2023-03-14 17:02:41 +01:00
altrisi 0869cbb81c Move rule change event into a rule observer and outside the Java api
* 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
2023-03-08 21:31:34 +01:00
altrisi 06bdbdaed2 Add arithmetic shift, use logic shift in current right shift (#1670)
* Add arithmetic shift, use logic shift in current

* State that the MSBs will be cleared to zero in logic right shift
2023-03-08 21:26:27 +01:00
Ghoulboy c2ef75df6d Removed if clauses
It was functionally equivalent to the solution proposed in #1072
2023-03-08 21:25:19 +01:00
altrisi cc24f79d47 Allow scarpet function name to be different to annotated method name 2023-03-08 20:53:35 +01:00
altrisi 4801534229 Sync fillLimit rule with the equivalent gamerule 2023-03-08 20:52:44 +01:00
altrisi 13882146fc Simplify app store rule cleaning 2023-03-08 16:41:43 +01:00
altrisi 883d887e11 Make OutputConverter.convert return Value
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
2023-03-08 14:07:50 +01:00
altrisi 93bec37dac Simplify and optimize bit roll operations
Suggested in #1666, ran many testing to check it gives the same results
2023-03-08 13:24:37 +01:00
gnembon 3f19cce649 fixed chest stickyness 2023-03-02 22:24:29 +01:00
gnembon 4c8e477f4b 1.19.4-pre1 2023-02-22 20:22:02 +01:00
gnembon 4d842ae382 not needed 2023-02-22 11:24:41 +01:00
gnembon 146573803c scarpet corountines idea 2023-02-22 02:33:03 +01:00
silnarm 23ed35a398 fake-players-falling-fix:
* Fix fake players not accumulating fallDistance or ever 'hitting the ground'
 * Fixes #1586 (Fake player does not take fall damage)
 * Should Fix #1478 (fake players cannot use critical hits)
 * Should Fix Unreported/Unconfirmed (fake players can not engage Elytras)
2023-02-22 01:33:07 +01:00
gnembon a295f81fa9 23w07a 2023-02-15 20:10:24 +01:00
gnembon 86a123d2f1 store rate limit prevention 2023-02-15 12:57:53 +01:00