class
Rosegold::Entity
- Rosegold::Entity
- Reference
- Object
Defined in:
rosegold/world/entity.crConstant Summary
-
METADATA_12111 =
Array(Metadata).from_json(Rosegold.read_game_asset("1.21.11/entities.json")) -
METADATA_1218 =
Array(Metadata).from_json(Rosegold.read_game_asset("1.21.8/entities.json")) -
METADATA_261 =
Array(Metadata).from_json(Rosegold.read_game_asset("26.1/entities.json")) -
METADATA_BY_PROTOCOL =
{772_u32 => METADATA_1218, 774_u32 => METADATA_12111, 775_u32 => METADATA_261} -
NON_PICKABLE_ENTITIES =
Set {"item", "experience_orb", "area_effect_cloud", "marker", "block_display", "item_display", "text_display", "lightning_bolt", "evoker_fangs", "ominous_item_spawner", "eye_of_ender", "arrow", "spectral_arrow", "trident", "fireball", "small_fireball", "dragon_fireball", "wither_skull", "snowball", "egg", "ender_pearl", "experience_bottle", "splash_potion", "lingering_potion", "llama_spit", "wind_charge", "breeze_wind_charge", "firework_rocket", "fishing_bobber"} -
Matches vanilla MC's Entity.isPickable() = false. Default is pickable; only these are excluded.
Constructors
Class Method Summary
Instance Method Summary
- #bounding_box
- #effects : Array(EntityEffect)
- #effects=(effects : Array(EntityEffect))
- #entity_id : UInt32
- #entity_id=(entity_id : UInt32)
- #entity_type : UInt32
- #entity_type=(entity_type : UInt32)
- #head_yaw : Float32
- #head_yaw=(head_yaw : Float32)
- #living=(living : Bool)
- #living? : Bool
- #metadata
- #on_ground=(on_ground : Bool)
- #on_ground? : Bool
- #passenger_ids : Array(UInt32)
- #passenger_ids=(passenger_ids : Array(UInt32))
-
#pickable?
Mirrors vanilla MC's Entity.isPickable().
- #pitch : Float32
- #pitch=(pitch : Float32)
- #position : Vec3d
- #position=(position : Vec3d)
- #update_passengers(client)
- #uuid : UUID
- #uuid=(uuid : UUID)
- #velocity : Vec3d
- #velocity=(velocity : Vec3d)
- #yaw : Float32
- #yaw=(yaw : Float32)
Constructor Detail
def self.new(entity_id : UInt32, uuid : UUID, entity_type : UInt32, position : Rosegold::Vec3d, pitch : Float32, yaw : Float32, head_yaw : Float32, velocity : Rosegold::Vec3d, on_ground : Bool = true, living : Bool = false)
#