From 6ffc7871c090ab126353c918adcd5c4ef33dc261 Mon Sep 17 00:00:00 2001 From: Tobias Klauser Date: Fri, 25 Jan 2013 13:02:19 +0100 Subject: LocomotorPrimitives: Check availability of control data before running --- LocomotorPrimitives.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'LocomotorPrimitives.cpp') diff --git a/LocomotorPrimitives.cpp b/LocomotorPrimitives.cpp index 6b6f5f5..cfb484e 100644 --- a/LocomotorPrimitives.cpp +++ b/LocomotorPrimitives.cpp @@ -24,6 +24,10 @@ static void constructModel(OpenSim::Model &model, OpenSim::Storage actData) // Define controller for the model LocomotorPrimitivesController *control = new LocomotorPrimitivesController(actData, 0.01); control->setActuators(model.updActuators()); + if (control->checkControls() != 0) { + std::cerr << "Control data for some muscles in the model is missing. ENTER to continue, ^-C to quit." << std::endl; + std::cin.get(); + } model.addController(control); // Set default activation and fiber length on all muscles of the model -- cgit v1.2.3-54-g00ecf