fix
This commit is contained in:
parent
74c97d077b
commit
d80316180b
@ -52,24 +52,6 @@ onMounted(async () => {
|
|||||||
await readScene();
|
await readScene();
|
||||||
await editor.value?.initRobots();
|
await editor.value?.initRobots();
|
||||||
await monitorScene();
|
await monitorScene();
|
||||||
|
|
||||||
// const id = 'mock-robot-1';
|
|
||||||
// let x = 800;
|
|
||||||
// let y = 500;
|
|
||||||
// const active = true;
|
|
||||||
// const angle = -90;
|
|
||||||
// const path = <[number, number][]>[
|
|
||||||
// [600, 500],
|
|
||||||
// [100, 400],
|
|
||||||
// ];
|
|
||||||
// editor.value?.refreshRobot(id, { x, y, active, angle, path });
|
|
||||||
// const test = () =>
|
|
||||||
// requestAnimationFrame(() => {
|
|
||||||
// x -= 0.1;
|
|
||||||
// editor.value?.refreshRobot(id, { x, y });
|
|
||||||
// test();
|
|
||||||
// });
|
|
||||||
// test();
|
|
||||||
});
|
});
|
||||||
onUnmounted(() => {
|
onUnmounted(() => {
|
||||||
client.value?.close();
|
client.value?.close();
|
||||||
|
@ -404,7 +404,7 @@ export class EditorService extends Meta2d {
|
|||||||
): Required<Pick<MapPen, 'image' | 'iconWidth' | 'iconHeight' | 'iconTop'>> {
|
): Required<Pick<MapPen, 'image' | 'iconWidth' | 'iconHeight' | 'iconTop'>> {
|
||||||
const theme = this.data().theme;
|
const theme = this.data().theme;
|
||||||
const image =
|
const image =
|
||||||
import.meta.env.BASE_URL + active ? `/robot/${type}-active-${theme}.png` : `/robot/${type}-${theme}.png`;
|
import.meta.env.BASE_URL + (active ? `/robot/${type}-active-${theme}.png` : `/robot/${type}-${theme}.png`);
|
||||||
return { image, iconWidth: 34, iconHeight: 54, iconTop: -5 };
|
return { image, iconWidth: 34, iconHeight: 54, iconTop: -5 };
|
||||||
}
|
}
|
||||||
//#endregion
|
//#endregion
|
||||||
|
Loading…
x
Reference in New Issue
Block a user