Improve data attachment port ()

* Bump yarn

* Apply yarn update

* Fix porting of Data Attachment block entity support

* Fix FrameBlockEntity testmod
This commit is contained in:
apple502j 2024-04-03 23:39:47 +09:00 committed by GitHub
parent 3844af0a25
commit 97f703da44
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 24 additions and 76 deletions
fabric-object-builder-api-v1/src/main/java/net/fabricmc/fabric
api/object/builder/v1/block
mixin/object/builder

View file

@ -84,7 +84,7 @@ public class FabricBlockSettings extends AbstractBlock.Settings {
// more proper way, this copies all the fields, not just the shallow ones.
// Fields are added by field definition order.
this.jumpVelocityMultiplier(otherAccessor.getJumpVelocityMultiplier());
this.drops(otherAccessor.getLootTableId());
this.drops(otherAccessor.getLootTableKey());
this.allowsSpawning(otherAccessor.getAllowsSpawningPredicate());
this.solidBlock(otherAccessor.getSolidBlockPredicate());
this.suffocates(otherAccessor.getSuffocationPredicate());
@ -409,7 +409,7 @@ public class FabricBlockSettings extends AbstractBlock.Settings {
@Deprecated
public FabricBlockSettings drops(RegistryKey<LootTable> dropTableId) {
((AbstractBlockSettingsAccessor) this).setLootTableId(dropTableId);
((AbstractBlockSettingsAccessor) this).setLootTableKey(dropTableId);
return this;
}

View file

@ -101,7 +101,7 @@ public interface AbstractBlockSettingsAccessor {
Optional<AbstractBlock.Offsetter> getOffsetter();
@Accessor
RegistryKey<LootTable> getLootTableId();
RegistryKey<LootTable> getLootTableKey();
@Accessor
boolean getBlockBreakParticles();
@ -150,7 +150,7 @@ public interface AbstractBlockSettingsAccessor {
void setIsAir(boolean isAir);
@Accessor
void setLootTableId(RegistryKey<LootTable> lootTableId);
void setLootTableKey(RegistryKey<LootTable> lootTableKey);
@Accessor
void setToolRequired(boolean toolRequired);