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
2133675ac7
renamed sample_density with 'sample_noise'. sample noise values directly from the local router if possible.
2023-01-30 18:02:08 +01:00
gnembon
659f0106e3
renamed compute_density_function with 'sample_density' and tweaked its use
2023-01-28 19:51:13 +01:00
gnembon
ea88c09c42
cached access to worldgen noise functions
2023-01-28 19:20:44 +01:00
Crec0
f2c658bf03
Add compute_density_function to replace removed `sample_noise ( #1591 )
2023-01-25 17:08:36 +01:00
gnembon
a95622e749
22w04a
2023-01-24 21:52:01 +01:00
altrisi
889e3b6999
Replace usages of j.u.Stack with fastutil's
...
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
2023-01-24 13:46:53 +01:00
altrisi
fb7b1f79a5
Fix unchecked removal of commands by app name
2023-01-23 22:19:07 +01:00
altrisi
1eb25ba1b5
Improve unexpected java exception in scarpet error slightly
2023-01-20 18:53:26 +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
3050a82b96
Replace one missed usage
...
It was also using the copy-constructor, so this way it should also be more efficient
2023-01-19 01:47:33 +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
altrisi
dd1dc3756a
Remove a no longer necessary mixin
...
And tiny cleanup to another one
2023-01-19 00:30:23 +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
altrisi
0e8b53c8d3
Add CarpetContext.s back temporarily as Deprecated for compatibility
2023-01-18 13:47:22 +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
Ghoulboy
43bb84437f
Add event for commands and make __on_player_message not trigger for them ( #1525 )
...
* Restoring old behaviour of __on_player_message
Fixes #1511
* Changed to PLAYER_COMMAND
* Updated docs
* Updated event_test.sc
* Updated editor keywords
* Fixed issue
2022-12-26 15:30:50 +01:00
gnembon
8c1c189caa
1.19.3-pre3
2022-11-29 21:31:07 +01:00
gnembon
1edd06605b
1.19.3-pre2
2022-11-24 06:10:18 +01:00
gnembon
cda6994cae
45a great reg split
2022-11-10 20:51:10 +01:00
altrisi
1466006638
Don't compute tree size and depth with debugging disabled ( #1588 )
2022-11-09 09:59:00 +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
2b5e51b4df
Fixed NPE when events are triggered within events ( #1574 )
2022-10-16 17:33:54 +02:00
altrisi
ab9f7992b7
Use Java's Math constants for Scarpet math constants
2022-10-16 14:33:38 +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
altrisi
8e38619f61
Don't hold Context variables for the lifetime of scheduled calls
...
Fixes #1568
2022-10-15 12:34:55 +02:00
altrisi
1fa2e515e5
Make CarpetContext's new constructor take a CarpetScriptHost
...
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
2022-10-12 12:45:13 +02:00
altrisi
0c8e1d1653
Fix in (~) operator producing broken values
2022-10-10 20:36:44 +02:00
Sensei
059fda49a4
Make client net handling run on main thread
2022-10-10 20:30:25 +02:00
altrisi
a50a0d7328
Fix wrong line numbers by not trimming the start of expressions
...
We still trim the end because else `Tokenizer` crashes...
But trimming the end doesn't matter because there's it doesn't affect anything.
2022-10-09 13:13:37 +02:00
altrisi
3f5eac7472
Simplify ExpressionException.errorMaker
...
Why was this a lambda?
2022-10-08 14:57:32 +02:00
altrisi
db031b175b
Optimize ListValue::new(Collection) slightly for best-case scenarios ( #1565 )
2022-10-08 14:31:21 +02:00
altrisi
4f9bd3ab78
Simplify and standarize some conversions with ValueConversions
2022-10-02 18:49:49 +02:00
altrisi
be1cb6888a
Remove redundant null checks in string concat
2022-10-02 18:11:15 +02:00
altrisi
3247b83272
Simplify and slightly optimize EntityClassDescriptor
...
Could probably also be a record, though I'll look into that at another time
2022-10-02 15:29:34 +02:00
altrisi
b1c29efa2b
Expose origin-less constructors and methods ( #1556 )
2022-10-02 13:57:29 +02:00
altrisi
f63c6acb05
Fully remove scarpet commands when apps are unloaded ( #1452 )
...
Using new Loader 0.14+ features
2022-10-02 13:32:27 +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
fce4918c87
Fix handling files with uppercase letters in case-sensitive systems
2022-08-28 21:01:48 +02:00
gnembon
bb12e3ddd1
code cleanup for getItemsStackFromValue and npp keywords
2022-08-28 20:01:40 +02:00
ch-yx
d418b7d090
move getItemStackFromValue to ValueConversions
2022-08-28 18:59:11 +02:00