Skip to content

Commit d0b2d8f

Browse files
authored
Merge pull request #3078 from JdeRobot/prepare-custom-universes
Prepare custom universes
2 parents 8822e73 + 3ca0c71 commit d0b2d8f

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

react_frontend/src/components/visualizers/WorldSelector.js

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,19 @@ export default function WorldSelector(props) {
4545
window.RoboticsReactComponents.MessageSystem.Loading.showLoading(
4646
"Launching Universe"
4747
);
48-
await window.RoboticsExerciseComponents.commsManager.launchWorld({
49-
world: config.world,
50-
robot: config.robot,
51-
});
48+
49+
if (config.zip) {
50+
await window.RoboticsExerciseComponents.commsManager.launchWorld({
51+
world: config.world,
52+
robot: config.robot,
53+
zip: config.zip
54+
});
55+
} else {
56+
await window.RoboticsExerciseComponents.commsManager.launchWorld({
57+
world: config.world,
58+
robot: config.robot,
59+
});
60+
}
5261
await window.RoboticsExerciseComponents.commsManager.prepareVisualization(
5362
{type: config.visualization, file: config.visualization_config_path}
5463
);

0 commit comments

Comments
 (0)