-
Notifications
You must be signed in to change notification settings - Fork 21
How it Works
Blockbench .geo
files are read by WSEE, and the data is parsed. .geo
files describe how bones are nested, where cubes are relative to bones, and where textures are applied on cubes.
Once the Blockbench
file is read, this data can be used to construct a Resource Pack
. This is done by turning each bone in to its own item texture, creating a mapping of Bone Name -> Item ID
, and reposition the bone within the new item so that it is centered. Centering the item is important for reasons that will be discussed below.
This system creates a display entity entity for each bone using the bone's texture. In the image above you can see this in action. Note - This image is outdated, this library now uses display entities instead of armor stands.
Whenever an animation is run or an entity is moved, each entity calculates the position it should be at and the rotation of the head. When done properly, this can make a multipart entity appear as if it is one single entity.
Invisible interaction entities are used as hitboxes. Attacks are forwarded to their master entity.