Skip to content
maskostudioDocs

All pages

  • Overview/docs/use-cases
  • Mobile app/docs/use-cases#mobile
  • Website/docs/use-cases#website
  • Desktop/docs/use-cases#desktop
  • AI agents/docs/use-cases#agents
  • Videos/docs/use-cases#videos
  • Brand/docs/use-cases#brand
  • Start here/docs/tutorials#start-here
  • All tutorials/docs/tutorials
  • Create your first mascot/docs/tutorials/first-mascot
  • Make your mascot move/docs/tutorials/first-animation
  • Make your mascot talk/docs/tutorials/make-it-talk
  • Put your mascot on your website/docs/tutorials/mascot-on-your-website
  • Show a mascot while your AI thinks/docs/tutorials/ai-loading-mascot
  • Give your AI agent a face/docs/tutorials/ai-agent-face
  • Animate the mascot you already have/docs/tutorials/animate-your-mascot
  • Quickstart: your first animation/docs/quickstart
  • API keys and workspaces/docs/authentication
  • How mascots work/docs/how-mascots-work
  • Credits and costs/docs/credits
  • From text/docs/create/from-text
  • From an image/docs/create/from-image
  • From a website/docs/create/from-website
  • From a brand book/docs/create/from-brand-book
  • Reference images/docs/manage/references
  • What you can generate/docs/generation
  • Pose-to-animation walkthrough/docs/generate/workflow
  • Images and poses/docs/generate/images
  • Animations/docs/generate/animations
  • Talking animations/docs/generate/talking
  • Logos, scenes and stickers/docs/generate/design-assets
  • Cursor follower/docs/generate/cursor-follower
  • Batch generation/docs/generate/batch
  • Canvases and releases/docs/canvas
  • Build a canvas/docs/canvas/build
  • Canvas templates/docs/canvas/templates
  • Generate canvas assets/docs/canvas/generate-all
  • Export a canvas/docs/canvas/export
  • Smooth mascot playback/docs/integrations/playback
  • Hosting and file formats/docs/generate/cdn
  • File sizes/docs/generate/file-sizes
  • Image and video exports/docs/manage/media-exports
  • Terminal quickstart/docs/terminal
  • Desktop commands/docs/terminal/commands
  • CLI browser login/docs/authentication/cli
  • Swift SDK/docs/sdk/swift
  • TypeScript and Electron SDK/docs/sdk/typescript
  • Jobs and polling/docs/manage/jobs
  • Webhooks/docs/manage/webhooks
  • Manage mascots and assets/docs/manage/collections
  • Connect an AI agent/docs/ai-agents
  • Masko in ChatGPT/docs/ai-tools/chatgpt
  • Masko for Cursor/docs/ai-tools/cursor
  • Masko for Muse/docs/ai-tools/muse
  • Masko skill for coding agents/docs/ai-tools/skills
  • All endpoints/docs/reference
  • Requests and responses/docs/reference/conventions
  • Errors and recovery/docs/reference/errors
  • Changelog/docs/reference/changelog
  • Migrate to mascots and canvases/docs/manage/studio-migration
Get an API key
Documentation

Make a focus timer
where the mascot falls if you leave.

Mugi hangs from a sunflower seed while your user focuses. Leave the app and Mugi slips to one paw. Come back in time and it grabs on again. Stay away ten seconds and it falls. Press START below, then switch tabs.

Hang In
9:41
25:00
Focus lostMugi fell after 00:00
TASKLaunch post ▾

Hang Innow

Mugi is slipping! Come back within 10 seconds.

Press START. Mugi hangs on while you focus.

action::away
false
action::fall
false
Playing
hang loop

Or switch to another browser tab during a session. Mugi notices, and this tab’s title calls you back.

What Masko made

One loop for each pose and one animation for each move. Hover a clip to play it.

  • Hangloop
  • Sliphang → slip, when away
  • Slippingloop
  • Grab on againslip → hang, back in time, free
  • Fallslip → fallen, after 10 s away
  • Fallenloop

How it works

  1. 1

    Make the character and its poses

    Create Mugi from a prompt or a picture, then make each pose as an image of the same character: hanging, slipping and fallen.

    Create a mascot
  2. 2

    Connect the poses in a state graph

    Each pose is a node with its own loop. away moves Mugi from hang to slip and back, and fall drops it to the floor. The move back up is the slip played backwards, so it is free.

    Build a canvas
  3. 3

    Let Masko animate it, then set the inputs

    Generate all makes every loop and every move. Your app sets away when the user leaves and fall after ten seconds away, and plays the matching move.

    Export a canvas

The moves on Mugi’s canvas

{
  "inputs": ["action::away", "action::fall"],
  "edges": [
    { "id": "hang-to-slip",
      "conditions": [{ "input": "action::away", "op": "==", "value": true }] },
    { "id": "slip-to-hang", "reverse": true, "reverseOfEdgeId": "hang-to-slip",
      "conditions": [{ "input": "action::away", "op": "==", "value": false }] },
    { "id": "slip-to-fallen",
      "conditions": [{ "input": "action::fall", "op": "==", "value": true }] }
  ]
}

Leaving the app, on the web

// setInput is your player: it plays the move whose condition now matches.
let timer;
document.addEventListener('visibilitychange', () => {
  setInput('action::away', document.hidden);
  clearTimeout(timer);
  if (document.hidden) {
    timer = setTimeout(() => setInput('action::fall', true), 10_000);
  }
});

Watch the whole story

The same app as a 27-second video: one session, one slip, one fall.

Questions

How does the app know the user left?

On the web, the page visibility event fires when the tab is hidden, as in the demo above. On iOS, watch scenePhase leave active; on Android, use onPause and onResume. Set away when the app leaves the screen and clear it when it comes back.

Is the seed part of the animation?

No. The app draws the string and the seed, and moves the seed to Mugi’s paws in every frame, so Mugi can let go of it when it falls.

How much did Mugi cost?

62 credits: 8 to explore the look, 4 for the poses including one redo, and 50 for five animations. The grab back on is the slip played backwards, which is free.

Where does the idea come from?

From SwingCat, a focus timer by @o_shinworks where a cat falls if you leave the app. Mugi is our take on it, made with Masko.

Where can it play?

Anywhere a transparent video plays. The export gives WebM for Chrome and Firefox and HEVC for Safari and iOS, and the playback guide covers Android.