Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
Model Engine 4 Model Engine 4
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 113
    • Issues 113
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Create a new issue
  • Issue Boards
Collapse sidebar
  • MythicCraft
  • Model Engine 4Model Engine 4
  • Wiki
    • Modeling
  • Scriptable Keyframes

Scriptable Keyframes · Changes

Page history
Create Modeling/Scriptable Keyframes authored Sep 16, 2023 by Lxlp's avatar Lxlp
Hide whitespace changes
Inline Side-by-side
Showing with 46 additions and 0 deletions
+46 -0
  • Modeling/Scriptable-Keyframes.md Modeling/Scriptable-Keyframes.md +46 -0
  • No files found.
Modeling/Scriptable-Keyframes.md 0 → 100644
View page @ 632ff4e0
Using the script keyframe, you can now call MM skills or MEG commands at the exact animation frame. You can add new script keyframes by opening the effects timeline within Blockbench.
![image](https://user-images.githubusercontent.com/41558177/177030314-8db9a942-238d-4dd8-a228-1e354943e2ce.png)
Afterward, add a new keyframe on the Instructions timeline. Instead of the normal XYZ input, you will see an input called Script.
![image](https://user-images.githubusercontent.com/41558177/177030338-d663af59-8249-4026-ba9b-7b48ef0f96c1.png)
## MM Skills
You can call any custom-defined MM skills by using the prefix `mm:` and the skill name. For example:
```yml
Primary_5:
Skills:
- message{m="Get punched";audience=world} @self
- explode @ModelPart{m=dr_axis;p=attack_point}
```
![image](https://user-images.githubusercontent.com/41558177/177030827-c7bc59c0-ff89-4545-8a60-3e5df1578d8a.png)
You can even use [Skill Parameters](https://git.lumine.io/mythiccraft/MythicMobs/-/wikis/skills/skillparametersystem) within keyframes.
```yml
Primary_5:
Skills:
- message{m=<skill.dialogue>;audience=world} @self
- explode @ModelPart{m=dr_axis;p=attack_point}
```
![image](https://user-images.githubusercontent.com/41558177/177030890-dee52b88-8ce5-49a2-ad7a-7713305c653c.png)
## MEG Commands
MEG Commands are, by design, structurally very similar to MM mechanics. Currently, we have 7 commands which have the same attributes as their MM mechanic counterpart. However, **all commands will only target the model you are editing.**
* changeparent = [ChangeParent](/Mechanics:-Model#changeparent)
* partvis = [PartVisibility](https://github.com/Ticxo/Model-Engine-Wiki/wiki/Mechanics#partvisibility)
* tint = [Tint](/Mechanics:-Model#tint)
* enchant = [Enchant](/Mechanics:-Model#enchant)
* tag = [SetModelTag](/Mechanics:-Model#setmodeltag)
* changepart = [ChangePart](/Mechanics:-Model#changepart)
* remap = [RemapModel](/Mechanics:-Model#remapmodel)
To use a MEG command, you just enter it like using them as a normal mechanic.
![image](https://user-images.githubusercontent.com/41558177/177031244-1abfce42-da71-4978-a88f-8e429de8fe64.png)
## Multiline scripts
You can write multiple lines of scripts into a single keyframe, and you can also mix and match different script types.
![image](https://user-images.githubusercontent.com/41558177/177031293-34a39164-7ddf-4490-af9e-aae6008e86a7.png)
This keyframe would run the MM Skill that plays the dialogue and effect first, then the MEG command to enchant the arm bone.
## Using Animation Variables
Finally, you can make use of the Variable Placeholder system provided by Blockbench itself. This system is also extremely similar to MM's variable system, and it works on both MM skills and MEG commands.
![image](https://user-images.githubusercontent.com/41558177/177031442-0f2ca7a4-973f-4e47-b34d-f82ee150398d.png)
## [Video Demo](https://youtu.be/JqVQ4ARJoIQ)
\ No newline at end of file
Clone repository
Home
FAQ / Common Issues
Commands & Permissions
Configuration
Modeling
  • Creating a Model
  • Animating a Model
  • Bone Behaviors
  • Importing a Model
  • Scriptable Keyframes
MythicMobs
  • Mechanics: Model
  • Mechanics: VFX
  • Conditions
  • Targeters
API
Technical
  • Terminology
  • Animation Systems