# 🎥Custom Animation

* Open your `config.yml` file, add below contents in it.

```yaml
animations:
  chest: # Animation ID
    chest_1: # Animation File Name
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70025
    chest_2:
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70026
    chest_3:
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70027
    chest_4:
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70028
    chest_5:
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70029
    chest_6:
      rotation: 0.0
      y_translation: 0.0
      z_translation: 28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70030
    chest_7:
      rotation: 0.0
      y_translation: -18.0
      z_translation: -28.0
      x_scale: 1.9
      y_scale: 1.9
      material: WHITE_DYE
      cmd: 70031
```

* `chest` is animation ID, and `chest_1, chest_2 etc.` are animation file name. You need put animation texture at `texture/animation` folder.
* `material` and `cmd` is optional, if not set, plugin will auto generate them.
* A custom animation must have 7 ticks, the first tick is same as front card, the last tick is same as back card, other 5 ticks are animations, if you set more or less then 7 ticks, animation maybe have some small problems (not test).
* Send `/fc reload` command in your server.
* Copy new resource pack to your client.
* Open `ui/<uiName>.yml`, find your card configs, remove `edge`, `front` and `back` option in it, and add `animate` option with the animation id. (like `chest` in this example).

## Showcase

<figure><img src="/files/aukivuZPQYXKeWepwgmL" alt=""><figcaption></figcaption></figure>

```yaml
card_2:
  animate: chest # <--- Changed line, removed front and back option, add animate option
  amount: 4
  name: "&bCommon Card"
  lore:
    - "&7You need cost: %price% "
  prices:
    1:
      free: true
      apply: [1,2]
    2:
      economy-plugin: Vault
      apply: [1,2,3,4,5]
      cost: [50,500,1000,1500,2000]
  rewards:
    1: # Removed edge option
      material: IRON_INGOT
      amount: 5~10
      rate: 10
    2: # Removed edge option
      material: DIAMOND
      amount: 1~2
      rate: 5
    3: # Removed edge option
      material: GOLD_INGOT
      amount: 1~5
      rate: 6
    4: # Removed edge option
      material: sword
      amount: 1
      rate: 1
    5: # Removed edge option
      material: gold_nugget
      amount: 1
      dispaly: "&6Coins"
      lore:
        - "    ×1000"
      rate: 10
      give-item: false
      actions:
        1:
          type: console_command
          command: "eco give %player% 1000"

```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://flipcard.superiormc.cn/features/custom-animation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
