Arm wrestle
A challenger and a champion size each other up, sit and arm-wrestle; the champion wins.
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, HumanObject, HumanPerformance, HumanSocial, HumanStance, armWrestle } from "@automovie/motions";
import * as archetypes from "@automovie/archetypes";
const table = archetypes.createTable({ kind: "dining" });
const tableAt = { at: { x: 0, y: 0, z: 0 }, yaw: 0 };
const chairT = archetypes.createSeat({ kind: "dining" });
const chairTAt = { at: { x: 0, y: 0, z: -0.6 }, yaw: 0 };
const chairU = archetypes.createSeat({ kind: "dining" });
const chairUAt = { at: { x: 0, y: 0, z: 0.6 }, yaw: 180 };
// tad: body m1, at (0, -0.45) m, facing 0°, trained
const tad = HumanChain.subject("tad")
.act("gesture", { kind: "rubHands" })
.registered("shakeFist", {})
.act("gesture", { kind: "squareShoulders" })
.act("sit", { seat: HumanObject.seat(chairT, chairTAt), seconds: 1 });
// uri: body m2, at (0, 0.45) m, facing 180°, trained
const uri = HumanChain.subject("uri")
.registered("armsCrossed", { seconds: 1.5 })
.act("gesture", { kind: "chinLift" })
.act("gesture", { kind: "beckon" })
.act("sit", { seat: HumanObject.seat(chairU, chairUAt), seconds: 1 });
const scene = tad.with(uri).next(
HumanChain.mutual(
HumanSocial.armWrestle,
{ one: HumanChain.subject("tad"), other: HumanChain.subject("uri") },
{
table: { x: 0, y: 0.736, z: 0 },
winner: "other",
pin: 30,
},
),
);
// The lexicon's laws this scene's rows perform, registered with the performance.
const laws = [HumanEmblem.shakeFist, HumanStance.armsCrossed, armWrestle];
const props = [
HumanObject.prop("table", table, tableAt),
HumanObject.prop("chairT", chairT, chairTAt),
HumanObject.prop("chairU", chairU, chairUAt),
];
// Each body id's motion body, prepared from the site's measures.
declare const bodies: Record<string, IAutoMovieMotionHumanBody>;
const input: IAutoMovieMotionHumanPerformance.IInput = {
seed: "arm-wrestle",
performers: [
{ subject: "tad", body: bodies["m1"]!, at: { x: 0, y: 0, z: -0.45 }, yaw: 0, proficiency: { level: "trained" } },
{ subject: "uri", body: bodies["m2"]!, at: { x: 0, y: 0, z: 0.45 }, yaw: 180, proficiency: { level: "trained" } },
],
composition: scene.node,
props,
laws,
};
const performance = new HumanPerformance(input);Each person's actions on the film clock, with their named instants, as the engine placed them.
The timeline appears when the take is drawn.
The same composition in 4 takes on the player's clock. Each changes one choice and keeps the rest; the other takes are computed in this page, which takes a few seconds.