feat: pick up item

This commit is contained in:
xtex 2023-07-03 10:00:00 +08:00
parent f451a4b868
commit b1f44ff2db
Signed by: xtex
GPG Key ID: B918086ED8045B91

View File

@ -64,6 +64,10 @@ class ProjectedPersonEntity(entityType: EntityType<out PathfinderMob>, level: Le
}
init {
setCanPickUpLoot(true)
}
override fun finalizeSpawn(
serverLevelAccessor: ServerLevelAccessor,
difficultyInstance: DifficultyInstance,
@ -139,6 +143,7 @@ class ProjectedPersonEntity(entityType: EntityType<out PathfinderMob>, level: Le
super.readAdditionalSaveData(tag)
shapeTag = tag.getCompound(KEY_ENTITY_SHAPE)
readInventoryFromTag(tag)
setCanPickUpLoot(true)
}
override fun shouldShowName() = true