Skip to content

Instantly share code, notes, and snippets.

View Spyeedy's full-sized avatar

Spyeedy

View GitHub Profile
@Spyeedy
Spyeedy / EntityRegistration.java
Last active May 22, 2025 09:44
Dismounting from entity sometimes "push-teleports" the entity away visually. But their actual location (on server) is the same location, this can be verified by re-entering the world to find the entity at the same spot that you dismounted from.
// This is developed in Architectury, hence the class name is different as that is my own implementation of the registry holder for common access on both fabric and forge.
public static final RegistrySupplier<EntityType<?>, EntityType<RidingEntity>> RIDING_ENTITY = register("riding_entity", EntityType.Builder.<RidingEntity>of(RidingEntity::new, MobCategory.MISC).sized(0.5F, 1.0F).passengerAttachments(0.5f).clientTrackingRange(64));