Skip to Content

Chokehold

An attacker grabs and chokes a victim, who breaks the hold, shoves him off and slaps back.

Loading the take.

Each person is a chain of typed actions from @automovie/motions. This is what an agent writes for the scene; Composing motion explains the parts.

import type { IAutoMovieMotionHumanBody, IAutoMovieMotionHumanPerformance } from "@automovie/interface";
import { HumanChain, HumanEmblem, HumanPerformance, HumanStageFight } from "@automovie/motions";

// xia: body m2, at (0, 0) m, facing 0°, trained
const xia = HumanChain.subject("xia")
  .registered("poke", {
      target: { kind: "person", subject: "yan", region: "chestLeft" },
      count: 1,
    }, "ch-poke")
  .registered("grab", {
      target: { kind: "person", subject: "yan", region: "upperArmRight" },
    }, "ch-grab")
  .registered("choke", {
      target: { kind: "person", subject: "yan", region: "neckLeft" },
      other: { kind: "person", subject: "yan", region: "neckRight" },
    }, "choke")
  .act("stand", { seconds: 1.4 })
  .registered("pushed", {
      from: { kind: "person", subject: "yan", region: "palmRight" },
    }, "ch-off")
  .registered("shakeFist", {})
  .registered("leanBack", {
      from: { kind: "person", subject: "yan", region: "palmRight" },
    }, "ch-lean");

// yan: body m1, at (0, 0.5) m, facing 180°, trained
const yan = HumanChain.subject("yan")
  .registered("pushed", {
      from: { kind: "person", subject: "xia", region: "indexTipRight" },
    })
  .sync({ of: "ch-poke" })
  .registered("grabbed", {
      from: { kind: "person", subject: "xia", region: "palmRight" },
    })
  .sync({ of: "ch-grab" })
  .registered("halt", {})
  .registered("struggle", {
      target: { kind: "person", subject: "xia", region: "forearmLeft" },
      other: { kind: "person", subject: "xia", region: "forearmRight" },
    })
  .sync({ of: "choke", event: "strokeStart" })
  .registered("shove", {
      target: { kind: "person", subject: "xia", region: "chestLeft" },
      side: "right",
    })
  .sync({ of: "ch-off", event: "start", align: "stroke" })
  .registered("stageSlap", {
      target: { kind: "person", subject: "xia", region: "cheekLeft" },
    })
  .sync({ of: "ch-lean", event: "stroke", align: "stroke" });

const scene = xia.with(yan);

// The lexicon's laws this scene's rows perform, registered with the performance.
const laws = [HumanStageFight.poke, HumanStageFight.grab, HumanStageFight.choke, HumanStageFight.pushed, HumanEmblem.shakeFist, HumanStageFight.leanBack, HumanStageFight.grabbed, HumanEmblem.halt, HumanStageFight.struggle, HumanStageFight.shove, HumanStageFight.stageSlap];

// Each body id's motion body, prepared from the site's measures.
declare const bodies: Record<string, IAutoMovieMotionHumanBody>;

const input: IAutoMovieMotionHumanPerformance.IInput = {
  seed: "chokehold",
  performers: [
    { subject: "xia", body: bodies["m2"]!, at: { x: 0, y: 0, z: 0 }, yaw: 0, proficiency: { level: "trained" } },
    { subject: "yan", body: bodies["m1"]!, at: { x: 0, y: 0, z: 0.5 }, yaw: 180, proficiency: { level: "trained" } },
  ],
  composition: scene.node,
  laws,
};
const performance = new HumanPerformance(input);