Files
OneCAD/crates/ui-egui/tests/scenarios/s24_motion_study.json
T

50 lines
1.8 KiB
JSON

[
{"note": "Target: a motion study keys a revolute joint and plays it (FusionMotionStudyCommand, motion.play by solvecraft-params; dialog by solvecraft-dialogs). Starts like s07; adjust the study steps when the dialog lands."},
{"start": "FusionCreateNewComponentCommand"},
{"key": "Enter"},
{"start": "SketchCreate"},
{"click": {"plane": "XY"}},
{"start": "ShapeRectangleTwoPoint"},
{"click": {"sketch": [0, 0]}},
{"click": {"sketch": [20, 20]}},
{"key": "Escape"},
{"start": "SketchStop"},
{"call": "ui.view", "params": {"view": "iso"}},
{"start": "Extrude"},
{"text": "10"},
{"key": "Enter"},
{"call": "ui.menu", "params": {"x": 100, "y": 170, "target": {"type": "component", "id": 0}}},
{"call": "ui.menuPick", "params": {"item": "Activate"}},
{"start": "FusionCreateNewComponentCommand"},
{"key": "Enter"},
{"start": "SketchCreate"},
{"click": {"plane": "XZ"}},
{"start": "ShapeRectangleTwoPoint"},
{"click": {"sketch": [30, 0]}},
{"click": {"sketch": [50, 10]}},
{"key": "Escape"},
{"start": "SketchStop"},
{"call": "ui.view", "params": {"view": "iso"}},
{"start": "Extrude"},
{"click": {"world": [40, 0, 5]}},
{"text": "20"},
{"key": "Enter"},
{"start": "JointAssembleCmdNew"},
{"click": {"world": [10, 10, 10]}},
{"click": {"world": [40, -20, 5]}},
{"widget": "Rigid"},
{"widget": "Revolute"},
{"widget": "OK"},
{"start": "FusionMotionStudyCommand"},
{"widget": "Add Key"},
{"widget": "0 deg", "near": "Value"},
{"key": "A", "cmd": true},
{"text": "90"},
{"key": "Enter"},
{"widget": "OK"},
{"expect": {"dialog": null, "errors": 0}},
{"call": "engine.execute", "params": {"command": "motion.play", "params": {"study": 1, "step": 100}}},
{"expect": {"query": {"command": "joint.list", "path": ["joints", 0, "values", 0, "value"], "value": 90}}},
{"shot": "s24_motion_end"}
]