Overview of MegModeledEntityTag
MegModeledEntityTag is used to identify and manage modeled entities. A modeled entity can have zero or multiple models associated with it.
- Prefix:
megmodeledentity@ - Identity Format:
megmodeledentity@<entity>
website·Indexed 31 days ago
https://0tickpulse.github.io/megizen-docsDocumentation for Megizen, an addon plugin for Denizen that provides interoperability with the ModelEngine API. It allows users to control, animate, and manage models via commands like megmodel, megmount, and megstate, as well as specialized tags and events for modeled entities.
MegModeledEntityTag is used to identify and manage modeled entities. A modeled entity can have zero or multiple models associated with it.
megmodeledentity@megmodeledentity@<entity>meg adds <model> event is fired when a model is about to be added to a MegModeledEntityTag. This event is cancellable, meaning you can prevent the model from being added using the - determine 'cancelled' command or filter the event using the cancelled:<true/false> or ignorecancelled:true switches.# Example of cancelling the event
- determine 'cancelled'
meg removes <model> event is triggered, the following context tags are available to retrieve information about the removal and interaction:# Available Context Tags:
<context.action> # ElementTag: The interaction cause (ATTACK, INTERACT, or INTERACT_ON)
<context.active_model> # MegActiveModelTag: The model being removed
<context.click_position> # LocationTag: World-less vector relative to model center (if applicable)
<context.item> # ItemTag: The item used to interact with the model
<context.is_secondary> # ElementTag(Boolean): True if the player was crouching during interactionmeg removes <model> event is fired when a model is about to be removed from a MegModeledEntityTag. This event is cancellable, meaning you can prevent the model from being removed using the - determine 'cancelled' command. When using this event, you can utilize the cancelled:<true/false> or 'ignorecancelled:true' event switches, and check the <context.cancelled> tag.meg removes model: # Example event trigger
- determine 'cancelled'
meg adds <model> event fires, the following context tags are available to retrieve information about the operation:<context.active_model> # Returns the MegActiveModelTag of the model that is about to be added.
<context.modeled_entity> # Returns the MegModeledEntityTag of the entity that the model is about to be added to.MegActiveModelTag represents an active model on an entity. It is identified using the prefix megactivemodel@ followed by the entity and model blueprint in the format: megactivemodel@<entity>,<model_blueprint>.A MegBoneTag represents a specific bone on a model. To identify or reference a bone, use the prefix megbonetag@ followed by the entity, model blueprint, and bone ID in the following format:
megbonetag@<entity>,<model_blueprint>,<bone_id>
meg <entity> mounts <'model'> event fires, the following context tags are available to retrieve information about the mount action:| Context | Description |
|---|---|
<context.model> | Returns the MegActiveModelTag of the model that the entity is mounting. |
<context.entity> | Returns the EntityTag of the entity that is mounting the model. |
<context.is_driver> | Returns a Boolean (ElementTag) indicating whether the entity is mounting the model as a driver. |
meg <entity> dismounts <model> event fires, the following context tags are available to retrieve information about the dismount action:| Context | Description |
|---|---|
<context.model> | Returns the MegActiveModelTag of the model that the entity is dismounting. |
<context.entity> | Returns the EntityTag of the entity that is dismounting the model. |
<context.was_driver> | Returns a Boolean (ElementTag) indicating whether the dismounting entity was the driver. |
MegBoneTag.children # Returns MapTag(MegBoneTag): A map of children bones (key: bone id, value: bone)
MegBoneTag.damage_tint # Returns ColorTag: The damage tint of the bone
MegBoneTag.default_tint # Returns ColorTag: The default tint of the bone
MegBoneTag.global_position # Returns LocationTag: The position of the bone as a vector
MegBoneTag.glow_color # Returns ColorTag: The glow color of the bone
MegBoneTag.id # Returns ElementTag: The ID of the bone
MegBoneTag.item # Returns ItemTag: The underlying item the bone uses
MegBoneTag.is_glowing # Returns ElementTag(Boolean): Whether the bone is glowing
MegBoneTag.location # Returns LocationTag: The location of the bone
MegBoneTag.scale # Returns LocationTag: The scale of the bone as a vector
MegBoneTag.skin_texture # Returns ElementTag: The skin texture in format `UUID|Texture|Name` (null if none)MegBoneTag.item should only be used if you have specific knowledge of the underlying item requirements.MegBoneTag.damage_tint # Input: ColorTag - Sets the damage tint
MegBoneTag.default_tint # Input: ColorTag - Sets the default tint
MegBoneTag.glow_color # Input: ColorTag - Sets the glow color
MegBoneTag.item # Input: ItemTag - Sets the underlying item
MegBoneTag.is_glowing # Input: ElementTag(Boolean) - Sets whether the bone is glowing
MegBoneTag.scale # Input: ElementTag(Number) - Sets the scale of the bone
MegBoneTag.skin_texture # Input: ElementTag - Sets the skin texture (Format: `UUID|Texture|Name`)