Commit Graph
267 Commits
Author SHA1 Message Date
gnembon d68c252180 23w16a 2023-04-20 22:13:32 +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
gnembon 1751f103f9 23w14a 2023-04-05 20:12:21 +02:00
gnembon 4171f9b784 23w13a 2023-03-29 18:44:12 +02:00
gnembon 4c8e477f4b 1.19.4-pre1 2023-02-22 20:22:02 +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
gnembon 2ff1f4fb71 refactored nonscarpet references yeet 2023-02-11 01:33:23 +01:00
gnembon 41e33503fb 23w06a 2023-02-08 21:44:15 +01:00
gnembon 277872b33c warning cleanup 2023-02-08 21:13:15 +01:00
gnembon 75d94b0570 cleanup of scarpet dependencies 2023-02-08 21:13:14 +01:00
gnembon fd93785fec added nonnull assertions 2023-02-05 12:56:06 +01:00
gnembon 8f61271606 semi-auto cleanup 2023-02-04 13:26:21 +01:00
gnembon 85f7c64847 fixed use of client side classes in shape dispatcher 2023-01-31 21:54:34 +01:00
vlad2305m d49be89e23 Do not load clientside-only classes in serverside ShapeDispatcher code (#1642)
fixed use of client side classes in shape dispatcher
2023-01-31 21:39:37 +01:00
gnembon a95622e749 22w04a 2023-01-24 21:52:01 +01:00
altrisi 583a372ba4 Migrate Context usage from recently merged PR 2023-01-20 18:09:15 +01:00
Ghoulboy 811b330446 Adding system_info('world_min_spawning_light') (#1475) 2023-01-20 14:01:37 +01:00
altrisi 914e129f6e Merge particle caches (#1528)
* Merge particle caches

* Reset this cache on world reload
2023-01-20 13:56:16 +01:00
altrisi 17249c3c77 Refactor code to use ListValue.wrap(Stream)
Simplifies code (improving readability) and unifies `Stream<Value>` to `ListValue` handling
2023-01-19 01:40:29 +01:00
gnembon c7d506675e 23w03a 2023-01-18 22:11:19 +01:00
altrisi 2b95a878ad Remove now fixed flatWorldStructureSpawning rule and cleanup some unused mixins 2023-01-18 14:41:46 +01:00
gnembon bd5dfdbf9f refactor limit access to built-in registries 2023-01-18 04:07:55 +01:00
gnembon 8dd08d5cb1 refactor access to context data 2023-01-16 19:01:10 +01:00
altrisi 7efa9df3ee Simplify chunk refreshing and fix a bug in it
where block-specific distance is used instead of chunk distance
2022-12-28 16:32:01 +01:00
gnembon cda6994cae 45a great reg split 2022-11-10 20:51:10 +01:00
gnembon 4be362e58b 1.4.87 for 22w44a 2022-11-02 22:30:46 +01:00
gnembon e0b6aae07b 22w43a 2022-10-26 23:26:27 +02:00
gnembon 9f776167e3 22w42a 2022-10-20 14:33:36 +02:00
replaceitem 24b9c386ec [Scarpet] Added ability to cancel events (#1497)
* Added ability to cancel events

* Made more events cancellable

* Added event_priority to __config

* Check for string values for performance

* Made player_finishes_using_item cancellable

* Made player_chooses_recipe cancellable

* Made player_swaps_hands cancellable

* Made player_message cancellable

* Added __on_player_placing_block (#1498)

* Added event to docs, keywords, event_test

* Added docs for event cancellation
2022-10-15 13:30:53 +02:00
gnembon c6b1f53b44 shapes 'facing' now defaults to player and player is correctly rendered facing player face, not camera plane. 2022-10-15 12:49:18 +02:00
Sensei 059fda49a4 Make client net handling run on main thread 2022-10-10 20:30:25 +02:00
gnembon 36aff8f9d3 cleanup and tilt-lean fixes for new shapes 2022-09-12 02:08:43 +02:00
ch-yx 179f5a6006 adding a shape that can display a item or a block (#1365)
added 'polygon', 'item' and 'block' to scarpet rendered shapes
2022-09-12 00:38:52 +02:00
altrisi 2a4d678aa7 Remove the last few File usages
Barring one, given I've heard in hot code `Files.exists()` is slower than toFile().exists() if in the default `FileSystem`
2022-08-28 18:34:39 +02:00
altrisi c6941b840f Map from id in system_info('server_mods') 2022-08-19 07:32:46 +02:00
altrisi 97c4cc9c7d Simplify threading and networking in download suggester (#1512)
* Simplify threading in download suggester
This also makes it more robust against race conditions

* Simplify network requests around app store
2022-07-25 21:59:50 +02:00
altrisi c08d857821 Don't refresh local app store repo on world change
Relates to #1508.
2022-07-23 23:56:13 +02:00
gnembon 6d3c4fa508 1.19.1-rc2 2022-07-22 18:25:43 +02:00
gnembon 544857d323 1.19.1-pre4 2022-07-14 00:57:49 +02:00
altrisi 0a972d6c56 Settings rework and encapsulation (#1330)
* 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
2022-06-27 13:12:15 +02:00
altrisi a60bc386cb Refactor Module into a single record type and fix system globals (#1383) 2022-05-17 20:11:49 +02:00
gnembon 217567c037 22w18a 2022-05-04 21:34:22 +02:00
gnembon 746c8548e9 22w16b with massive Component changes 2022-04-21 00:26:39 +02:00
gnembon 812d361af2 22w14a 2022-04-06 22:16:05 +02:00
gnembon 79f994f2da enable_hidden_dimensions is ded :( 2022-03-30 07:52:44 +02:00
gnembon 842370f68d Merge branch 'master' into future
# Conflicts:
#	src/main/java/carpet/script/api/Auxiliary.java
2022-03-30 07:49:07 +02:00
gnembon c33c53c8c2 enable_hidden_dimensions is ded :( 2022-03-30 07:44:37 +02:00
gnembon 193cf3777f fixes for 22w11a 2022-03-17 23:57:42 +01:00
gnembon 302a7b4817 fixes for 22w11a 2022-03-17 20:21:55 +01:00