Fix MuJoCo WASM loader imports
build / setup (compute matrix) (push) Has been cancelled
build / ${{ matrix.label }} (push) Has been cancelled
build / macos-15-arm64-studio (push) Has been cancelled
build / ubuntu-24.04-clang-18-studio (push) Has been cancelled
build / ubuntu-24.04-gcc-14-studio (push) Has been cancelled
build / windows-2025-ninja-studio (push) Has been cancelled
build / ubuntu-24.04-clang-18-wasm (push) Has been cancelled
build / ubuntu-24.04-clang-18-mjx (push) Has been cancelled
build / setup (compute matrix) (push) Has been cancelled
build / ${{ matrix.label }} (push) Has been cancelled
build / macos-15-arm64-studio (push) Has been cancelled
build / ubuntu-24.04-clang-18-studio (push) Has been cancelled
build / ubuntu-24.04-gcc-14-studio (push) Has been cancelled
build / windows-2025-ninja-studio (push) Has been cancelled
build / ubuntu-24.04-clang-18-wasm (push) Has been cancelled
build / ubuntu-24.04-clang-18-mjx (push) Has been cancelled
This commit is contained in:
@@ -16,8 +16,6 @@ import * as THREE from "three"
|
|||||||
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js"
|
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js"
|
||||||
import loadMujoco from "../dist/mujoco.js"
|
import loadMujoco from "../dist/mujoco.js"
|
||||||
|
|
||||||
declare function loadMujoco(): Promise<MainModule>;
|
|
||||||
|
|
||||||
let mujoco: any;
|
let mujoco: any;
|
||||||
|
|
||||||
const modelXml = `
|
const modelXml = `
|
||||||
@@ -483,7 +481,7 @@ async function main() {
|
|||||||
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('Initialization error: ', error);
|
console.error('Initialization error: ', error);
|
||||||
app.dispose();
|
app?.dispose();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
main();
|
main();
|
||||||
|
|||||||
@@ -15,8 +15,6 @@
|
|||||||
import { MainModule, MjData, MjModel } from "../../dist/mujoco"
|
import { MainModule, MjData, MjModel } from "../../dist/mujoco"
|
||||||
import loadMujoco from "../../dist/mujoco.js"
|
import loadMujoco from "../../dist/mujoco.js"
|
||||||
|
|
||||||
declare function loadMujoco(): Promise<MainModule>;
|
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
const mujoco: MainModule = await loadMujoco();
|
const mujoco: MainModule = await loadMujoco();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user