No description
  • JavaScript 100%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Flaig ea68c35815 Release 0.2.1: stop cancelled animations and resolve current selections
Stop both animation channels on cancellation or takeover, preserve unrelated animations, and restore interrupted rotation. Stored selection keywords follow the current selection on replay, and instance stop retains the played token. Remove unused localization entries.
2026-10-18 15:53:36 +02:00
lang Release 0.2.1: stop cancelled animations and resolve current selections 2026-10-18 15:53:36 +02:00
scripts Release 0.2.1: stop cancelled animations and resolve current selections 2026-10-18 15:53:36 +02:00
.gitignore Initial release 0.1.0 2026-10-02 16:38:11 +02:00
LICENSE Initial release 0.1.0 2026-10-02 16:38:11 +02:00
module.json Release 0.2.1: stop cancelled animations and resolve current selections 2026-10-18 15:53:36 +02:00
README.md Release 0.2.0: stored chains replay after a redraw, consistent saves on scene change, v14 only 2026-10-03 23:13:36 +02:00

TokenMove

A chainable macro API for eased token animations in Foundry VTT: attack lunges, recoils, dodges and shakes that return to where they started, relational movement between two tokens, and saved moves with wall collision and grid snapping. Every animation plays on all connected clients.

await TokenMove.between(source, target)
  .on("source").lunge()                                   // lunge toward the target, marks "impact"
  .on("target").at("impact").offset({ direction: "backward", tokens: 0.3, ease: "easeOutBounce" })
  .play();

Documentation: the wiki has the full API reference, concepts and copy-paste examples.

Features

  • Temporary animations (offset, restore, face): purely visual, never saved, automatically undone at the end.
  • Saved movement (moveTo, moveBy): animated with any easing, then written to the token once.
  • Relational directions with between(): "forward" means toward the other token.
  • Timelines per token with mark() / at() to line reactions up with impacts.
  • Wall collision and grid snapping, calculated once and identical on every client.
  • 35+ easings, custom easings, and reusable presets (lunge, shake, or your own).
  • Multiplayer: players can start animations too; the GM saves positions for tokens a player doesn't own (configurable).

Settings

Setting Scope Default Effect
Let players move tokens they don't own World On A player's moveTo/moveBy on a token they can't update is saved by the active GM. Off: only their own tokens move; others snap back with a warning.
Define source/target globals World On Provides source (first controlled token) and target (first targeted token) to every macro. TokenMove.source / TokenMove.target always work. Needs a reload.

Requirements

  • Foundry VTT v14
  • socketlib
  • Sequencer (optional, for picking destinations with a crosshair)

Installation

In Foundry's Add-on Modules tab, choose Install Module and paste this manifest URL:

https://someto.de/flaig/tokenmove/releases/download/latest/module.json

This is a personal project and stays at 0.x: expect breaking changes between versions.

AI disclosure

This module was created by AI with the help of human ideas.

License

MIT