Commit graph

565 commits

Author SHA1 Message Date
Deximus-Maximus
5f10696617
Add @Nullable and friends (#1007)
* Boost to Loom 0.5
Add null related annotations

* Rearrange nullable to be overline

* Fix anno sorting for picky

* Add imports

* Address feedback

* Fix import
2020-09-27 12:10:02 +01:00
i509VCB
ca18475868
Add fix for handling removal of old structures. (#1100)
* Add fix for handling removal of old structures.

This fix is required or else worlds where a mod is removed WILL NOT SAVE.

* Only mark for saving if the chunk has a null key

* Add label for issue being fixed

* Actually fix the redirect lol

* Licenses...

* Use ThreadLocal boolean instead of nullable unit

* Checkstyle is picky

* remove unnecessary `containsKey`
2020-09-27 12:09:34 +01:00
shartte
bbdb433e98
Clarify an aspect about the block renderer registry (#1035)
* Clarify an aspect about the block renderer registry.

* Update fabric-renderer-registries-v1/src/main/java/net/fabricmc/fabric/api/client/rendereregistry/v1/BlockEntityRendererRegistry.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

Co-authored-by: liach <7806504+liach@users.noreply.github.com>
2020-09-27 12:09:20 +01:00
Vincent Lee
616c01224d
Add hook for custom damage logic (#964)
* Add hook for custom damage logic

* Address comments

* Change to use new FabricItemSettings

* Make CustomDamageHandler a functional interface
2020-09-27 12:09:07 +01:00
modmuss50
c1aa8ed8d7 Version Bump 2020-09-18 18:48:09 +01:00
modmuss50
95c147c6a1 Fix crash in prod 2020-09-18 18:30:17 +01:00
shartte
c29459abaf
Ported 1.16.1 biomes-api-v1 to 1.16.2 (#1053)
* Ported 1.16.1 biomes-api-v1 to 1.16.2.
Public API changes:
- Removed flagging biomes as suitable for player spawns since that is now handled in the Biome Builder.
- Changed API over to RegistryKey's, not because it's necessary, but because it is more ergonomic since Vanilla Biomes in BuiltInBiomes are now all exposed as keys, rather than instances.

* Changed to CheaterCode's mixin for modifying the nether biomes, saving us one accessor.

* Move Bonanza

* Finished moving and updating of the module, added experimental markers.

* Adjusted experimental notes.

* Finished rename from biomes-v1 to biome-api-v1

* Reverted memory settings in preparation for loom-0.5
2020-09-18 18:11:51 +01:00
shartte
7490af87a1
Make BuiltInRegistries safe for Worldgen Registration during Mod Initialization (#1052)
* Adds a synchronisation for entries in BuiltInRegistries to the built-in DynamicRegistryManager, to a void class-loading DynamicRegistryManager during Mod initialization from messing up the Worldgen registrations of subsequently loaded mods.

* Changed to use updated Yarn mappings.
2020-09-18 18:10:47 +01:00
i509VCB
670bc71753 Fix bug with creating custom villager types and TradeOffer utilities. 2020-09-18 18:09:23 +01:00
modmuss50
b17f382b19
Custom advancement criterion registry (#1091)
* Custom advancement criterion registry

Fixes #20

Signed-off-by: liach <liach@users.noreply.github.com>

* Update fabric-object-builder-api-v1/src/main/java/net/fabricmc/fabric/api/object/builder/v1/advancement/FabricCriterionRegistry.java

* Update fabric-object-builder-api-v1/src/main/java/net/fabricmc/fabric/api/object/builder/v1/advancement/FabricCriterionRegistry.java

* Rename fabric criterion registry -> criterion registry

Signed-off-by: liach <liach@users.noreply.github.com>

* Remove unnecessary build.gradle parts

Will add manually when I run tests

Signed-off-by: liach <liach@users.noreply.github.com>

* Fine I give up

Hope my github editing skill suffices

* Code style

Co-authored-by: liach <liach@users.noreply.github.com>
Co-authored-by: liach <7806504+liach@users.noreply.github.com>
2020-09-18 17:44:59 +01:00
modmuss50
74685c149c
Update loom to 0.5 (#1060)
You may need to run `--refresh-dependencies` if you have odd issues. Please ask if you need help.
2020-09-10 17:36:46 +01:00
modmuss50
1c9f449974 1.16.3 2020-09-10 16:41:12 +01:00
Player
d86a720d2c
Checkstyle: Detect package names ending with ss as singular 2020-09-09 03:14:01 +00:00
modmuss50
facf3bbf67 Fix license... 2020-09-03 23:53:33 +01:00
modmuss50
fcdfdfa1c7 Fix server crash, closes #1058 2020-09-03 23:44:31 +01:00
modmuss50
fb0d9b0e7d Update mappings 2020-09-03 20:39:05 +01:00
modmuss50
432ea188f9 Bump version 2020-09-03 20:00:01 +01:00
grondag
8bcfced859
Fix for #987 (#1046)
* Fix #987, simplify geometry tracking, clean up scoping

* Bump indigo version

* Expose improved fromVanilla method

* Strip deprecations in non-API components

* bump renderer api version

* Clear tag for converted quads

Otherwise possible for tags added by transforms to pollute subsequent quads

* Borrow from Canvas - don't set nominal face twice, prevent header state leakage
2020-09-03 19:50:26 +01:00
LambdAurora
8072a3a990
Resource loader changes and built-in mod resource/data packs API (#1011)
* WIP built-in resource packs API.

* Add built-in resource pack register API and fix old injection methods.

* Fix code style.

* Fix code style.

* Add documentation.

* Drop useless else.

* Fix resource packs and data packs isolation issues, and more.

* Move ResourcePackManagerAccessor to its own accessor mixin.

* Make the built-in mod pack test mod work on server too because data pack part.

* Add new argument to built-in pack method and make mod data packs always active.

* Add documentation.

* Complete documentation in GameOptions mixin.

* Remove register built-in pack overload as Player requested.
2020-09-03 19:49:40 +01:00
i509VCB
0ba3dd89ec
Add item renderer with model transformation mode, deprecate old one. (#973)
* Add item renderer with model transformation mode, deprecate old one.

This PR simply adds a new interface which supplies the additional `Mode` parameter.
All old renderers are delegated to an implementation of the new renderer, thereby making this PR still backwards compatable with all existing renderers.

(cherry picked from commit 7c9162e99f48c6e3989eec9a46afaa935d65ce30)

* Update fabric-rendering-v1/src/main/java/net/fabricmc/fabric/api/client/rendering/v1/BuiltinItemRendererWithMode.java

Co-authored-by: shartte <shartte@users.noreply.github.com>

* Rename new interfact to `DynamicItemRenderer`, make it an inner class of the registry class.

* Update fabric-rendering-v1/src/main/java/net/fabricmc/fabric/impl/client/rendering/BuiltinItemRendererRegistryImpl.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update BuiltinItemRendererRegistryImpl.java

* Update BuiltinItemRendererRegistryImpl.java

* Imports

* Use ItemConvertible for new render method

* Rename new interfact to `DynamicItemRenderer`, make it an inner class of the registry class.

fabric-rendering-v1/src/main/java/net/fabricmc/fabric/api/client/rendering/v1/BuiltinItemRendererRegistry.java

* Move inner class out, fix formatting issue in loot-tables with linux oses

* why was this multilined

* license header lol

* Apply suggestions from code review

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Make renderer a nested class again

* putIfAbsent

Co-authored-by: shartte <shartte@users.noreply.github.com>
Co-authored-by: liach <7806504+liach@users.noreply.github.com>
2020-09-03 19:47:50 +01:00
Hugman
15028e6f6c
Tweaks to EntityTypeBuilder [1.16] (#836)
* Better consistency with vanilla mobs

* Added a new method for just tracking distance

* Renamed param names

* Update FabricEntityTypeBuilder.java

* Updated v0 for backwards compatibility

* Updated descriptions and parameter names of FabricEntityTypeBuilder

* Added compat with new builders

* Style fix

* Fix style again

* Added backwards compat
2020-09-03 19:46:36 +01:00
modmuss50
a607839c1a 0.19.0 2020-08-21 17:37:32 +01:00
Joseph Burton
516ece7c6e
Structures API (#917)
* Initial structures API implementation

* Improve generics + add a superflatFeature helper method

* Initialize StructuresConfig class early to prevent its assertion failing

* Add a testmod

* Documentation and null assertions

* Apply review suggestions

* Update fabric-structure-api-v1/src/main/java/net/fabricmc/fabric/api/structure/v1/FabricStructureBuilder.java

Co-authored-by: shartte <shartte@users.noreply.github.com>

* Apply review suggestions

* Update to 1.16.2

Co-authored-by: shartte <shartte@users.noreply.github.com>
2020-08-21 17:22:57 +01:00
Geometrically
e2e6cdad60
Block break event (#980)
* Block break event

* License headers + after event

* Before and after events, testmod

* Fix checkstyle

* Version bump, fix client method call

* Move to one event class

* Expand event parameters + javadoc

* Add cancelation event and move javadocs

* Move JavaDoc + Make success have same function as pass

* Fix success bug

* Fix documentation again, change approach

* Fix checkstyle

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/BlockBreakEvents.java

Co-authored-by: liach <7806504+liach@users.noreply.github.com>

* Fix checkstyle

* Rename stuff

* fixes

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/PlayerBlockBreakEvents.java

Co-authored-by: i509VCB <i509vcb@gmail.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/PlayerBlockBreakEvents.java

Co-authored-by: i509VCB <i509vcb@gmail.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/impl/event/interaction/InteractionEventsRouter.java

Co-authored-by: i509VCB <i509vcb@gmail.com>

* Update fabric-events-interaction-v0/src/main/java/net/fabricmc/fabric/api/event/player/PlayerBlockBreakEvents.java

Co-authored-by: i509VCB <i509vcb@gmail.com>

* Rename Canceled Event Method Name

Co-authored-by: liach <7806504+liach@users.noreply.github.com>
Co-authored-by: i509VCB <i509vcb@gmail.com>
2020-08-21 17:22:11 +01:00
Juuxel
29679fd6fa
Add FabricItemSettings and an API for custom item equipment slots (#956)
* Add FabricItemSettings and an API for custom item equipment slots

Closes #952.

* Bump module version

* Rename duck method to have fabric_ prefix and add Unique to mixin field

* Switch to FabricItemInternals + ExtraData like in FabricBlockSettings
2020-08-21 17:21:09 +01:00
shartte
ccce563e15
Fix dynamic tools not using their mining speed on modded blocks with mining level 0. (#1030) 2020-08-21 17:20:03 +01:00
modmuss50
e81ec80bf4 Version bump 2020-08-13 18:17:47 +01:00
i509VCB
de1d6c86d0
Add ability to define default attributes and spawn restirctions within the entity type builder. (#828)
* Add ability to define default attributes within the entity type builder.

* Update fabric-object-builder-api-v1/src/main/java/net/fabricmc/fabric/api/object/builder/v1/entity/FabricDefaultAttributeRegistry.java

Co-authored-by: Pyrofab <redstoneinfire@gmail.com>

* Add ability to specify spawn restriction. Add a Living and Mob builder to handle attributes and spawn restrictions seperately from default builder.

* Let's not cast like a maniac

* Add misc overloads for living builder

* Add a few null checks

* Allow factory to be defined in builder

* Make spawn group a builder parameter

Co-authored-by: Pyrofab <redstoneinfire@gmail.com>
2020-08-13 18:15:01 +01:00
Juuxel
fc24ff24ef
Add ItemConvertible overload for BuiltinItemRendererRegistry (#955)
Closes #953.
2020-08-13 18:14:01 +01:00
modmuss50
54fedaeb9b update curse version 2020-08-11 17:45:12 +01:00
modmuss50
e5d3217f0d Mappings update 2020-08-11 17:42:40 +01:00
modmuss50
7d3b96dd8a 1.16.2 2020-08-11 17:27:22 +01:00
modmuss50
ac8e8c5914 Bump version 2020-08-08 13:19:35 +01:00
i509VCB
648c8fd11f
Fix crashes by actually targetting the correct class in mixin (#1003)
This was renamed in yarn almost a month ago, so who knows how many times it's crashed
2020-08-08 13:18:49 +01:00
modmuss50
ad64ee68e8 Bump version 2020-08-07 19:52:25 +01:00
i509VCB
e2862de602
Add callback to allow registration of feature renderers. (#873)
* Add callback to allow registration of feature renderers.

* Laymans terms for those who don't map yarn for a living.

* Be a little less generic

* Dispatch events in a better spot, play with generics again, move to renderer-registries.

Also move this to render registries

* Handle players as well

* Tweak generics

* Hide acceptor impl

* Add actual testmod, fix where player events are fired, Simplify to returning a list.

* the old style worked fine

* registerRenderers

* Rename the event interface

* Javadoc fixes
2020-08-07 19:49:39 +01:00
Florens Pauwels
02fb8fda0e
Add Netherite mining level to vanilla blocks ToolHandler (#978)
* Add Netherite mining level to vanilla blocks ToolHandler

* Version bump, fix icon
2020-08-07 19:47:18 +01:00
Shnupbups
23a4a963ba
Fix FabricBlockSettings not copying the toolRequired boolean (#984) 2020-08-07 19:47:09 +01:00
modmuss50
f8ee145623 1.16.2-rc1 2020-08-07 17:20:50 +01:00
modmuss50
627dccba1d pre3, no changes, so no release. 2020-08-06 18:28:24 +01:00
i509VCB
944242f10a
licenser... (#995) 2020-08-05 20:33:21 +01:00
modmuss50
f653ee41b0 checkstyle... 2020-08-05 20:02:36 +01:00
modmuss50
91555cd1f0 1.16.2-pre2 - no biomes for now 2020-08-05 20:00:37 +01:00
modmuss50
d54afe8768 Bump version 2020-07-29 23:54:25 +01:00
modmuss50
80f083f580 Revert "Update to loom 0.5"
This reverts commit 9be3744a
2020-07-29 23:54:09 +01:00
modmuss50
847665c2f2 Fix crash when remapping registries. Closes #967 2020-07-29 20:16:13 +01:00
modmuss50
74cc3b2021 Version Bump 2020-07-29 20:07:00 +01:00
i509VCB
5098e03e12
Add world unload event (And functional interface annotations to events) (#895)
* Add world unload event

* Add functional interface annotations to all events
2020-07-29 19:54:16 +01:00
modmuss50
9be3744a3b Update to loom 0.5
For now this will only be for 1.16.2
2020-07-29 19:52:57 +01:00
modmuss50
bf0e62bd42 1.16.2-pre1 2020-07-29 16:52:10 +01:00