Koja Scripts

Animation Creator

Pose a ped over time in its own window and export the animation as a ready-to-play FiveM resource or a plain .ycd.

Animation Creator

The Animation Creator lets you pose a ped, move through time and pose it again, and export the result as an animation your FiveM server can play. You can start from nothing, from a template, or from a clip the game already has.

To play the game's own moves on your garments instead, see Animations.

Opening it

Open the app menu (click Koja Cloth Tool at the top left) and choose Animations…. The creator opens in its own window, sized to fit the screen it opens on.

The first time it opens, a short guided tour shows how to pose the ped, move the playhead, play and export. Press ? in the header to see it again.

No base body yet?

To pose a ped, the app needs the game's base body. If it is not on this PC yet, a card over the viewport walks you through it: Find my GTA V folder, then Read the base ped now. Reading the game files takes a few minutes. The app keeps the result on this PC, and the ped appears when it is done. Settings has the same option.

Starting

StartWhat you get
New animation — man / New animation — womanStart empty, standing at rest.
Edit a game animationOpen a .ycd clip the game already plays.
Open a saved animationA .kctanim you saved earlier.
Start from a templateA pose or a whole clip from the library.
RecoveredSessions that were never saved. The app kept a copy, so open one to carry on where it stopped.

The window

The header holds:

  • the File menu: new, open, import a .ycd, save, save as, and add or remove a second person;
  • the Show controls menu: Body, Hands, Face, Everything or Nothing;
  • the Advanced switch;
  • ? for the guided tour.

One short line of help sits over the ped, and the timeline runs along the bottom.

Simple and Advanced

New in 2.0.11, the creator opens in a Simple layout. Turn on Advanced in the header to show every control: the controller layers, Rotate and Move, frame numbers, FPS, easing and the skeleton's own bone names. The app remembers which layout you use on this PC.

Posing

In Simple, drag a ring to turn a joint, or drag a cube to pull a hand or foot.

The rotation gizmo

Click a joint to select it. The gizmo shows three rings, Tilt, Turn and Roll, plus:

  • an outer ring that faces the camera. Drag it to Spin the joint the way you see it on screen;
  • Free turn: drag inside the rings to turn the joint freely.

A live angle shows at the joint while you drag. Press Esc during a drag to cancel it. While you turn a joint, its own control and the knee targets of unselected legs step out of the way.

The pose panel

The side panel describes the selected joint in plain words:

  • Hold this pose here keys the joint's pose at the playhead (K).
  • Reset to rest puts the joint back in its rest pose.
  • Tilt, Turn and Roll are counted from the ped's rest pose. The trackball and sliders are under Fine-tune.
  • Copy pose, Paste and Mirror copy a pose, paste it at the playhead, or mirror it left to right.

Advanced tools

With Advanced on:

  • Rotate (R) turns the grabbed bone, and Move (G) pulls the end of an arm or leg, with the elbow or knee following.
  • The rig is split into Controller layers (torso, head and neck, arms, hands, legs, face and IK handles). Click a layer chip to show or hide it, and Alt-click to show only that one.
  • All bones (advanced) lists the bones the rig does not shape. You can key them, but they are not drawn on the body.

The timeline

Pose the ped, move the playhead, then pose again. Every change becomes a key on the timeline.

  • The timeline counts in seconds. Length sets how long the animation is. In Advanced, Frames and FPS are there as well.
  • Loop plays it round, and Play / Pause play it.
  • Smooth new keys (ease in and out), Smooth every key in the clip and Constant speed on every key change how keys blend. In Advanced, each key can be Linear, Ease in, Ease out or Ease in-out.
  • Right-click a key to delete it, copy the pose to another frame, or Remove every key on this bone.

Shortcuts

KeyAction
KHold the selected joint's pose at the playhead
DeleteRemove the selected joint's key at the playhead
Home / EndJump to the start / the end
R / GRotate / Move (Advanced)
EscCancel a drag on the gizmo

Templates

The library has Gestures, Two people, Showing off clothes, and your own under Saved by you.

  • Use this pose puts a template's pose on the current frame.
  • Start from this replaces the animation with the template.

To save your own, choose This pose or Whole clip under Add to the library as and type a name. The creator tells you when it still needs a name. Templates that ship with the app cannot be deleted.

Props

Props are shown while you pose, so you can build a pose around a bottle, a phone or a rifle.

  • Anything in the game searches your GTA V files, in groups such as Bags & boxes, Drinks, Flowers & plants, Food, Money, Phones & tech, Smoking, Tools and Weapons. The search has its own section.
  • The ped's own — hats, glasses, watches, and From this project for the project's prop items.
  • Add your own model… adds a .ydd.

Pick where it is worn, using plain slot names such as Right hand and Head, then place it with X, Y, Z, Pitch, Yaw and Roll.

Two people

Choose Add a second person in the File menu to make a two-person scene. A scene bar appears with Person 1 and Person 2, and Distance, Side and Facing set where the second person stands. The bar only shows while there are two people.

Two people play together only through the exported resource's scene code. The .ycd alone plays each person on their own.

Exporting

New in 2.0.11, Export .ycd opens the Export animation dialog.

  1. Name it

    Type the Name of the animation. It names the resource folder and the in-game command.
  2. Choose what to write

    • A FiveM resource (recommended): a folder with the .ycd, fxmanifest.lua and client.lua. Add it to your server and type the command in game to play it.
    • Just the .ycd: only the clip file, for a resource you already have. You get the Lua lines to play it.
    The app remembers your choice.
  3. Check the notes

    Real problems are listed one per line under Worth fixing. Notes about props and two-person scenes are shown apart from them, under Good to know.
  4. Export

    Press Export… and choose where it goes. A resource is written into a folder of its own, named after the animation, inside the folder you pick, for example resources\[local].

When it is done, the dialog shows the Dictionary and Clips names, with Copy buttons and Open folder:

  • For a resource, copy the folder into your server's resources, add the server.cfg line it shows, then type the command in game. /name plays the animation once and /name loop keeps it playing, where name is your animation's name. client.lua names its command at the top.
  • For a .ycd, put it in a resource's stream folder and play it with the Lua the dialog shows.

The clip is baked at 30 fps.

Importing a game clip that animates fingers, the face or cloth keeps those tracks, even though the rig does not show them, so a round trip does not throw them away. If you open an animation posed on a different ped than the one loaded, the creator says so and still opens it.