Compare commits
2 Commits
c62073f7f8
...
f46e6f0102
| Author | SHA1 | Date | |
|---|---|---|---|
| f46e6f0102 | |||
|
|
e15dc56de3 |
@ -848,8 +848,13 @@ const KubikonEditor = () => {
|
|||||||
}
|
}
|
||||||
s.focusOnSelection?.();
|
s.focusOnSelection?.();
|
||||||
} catch (e) {}
|
} catch (e) {}
|
||||||
// Тост-уведомление.
|
// Тост-уведомление (showToast будет подключён позже — заглушка,
|
||||||
try { showToast?.(`Механика «${kit.name}» добавлена`); } catch (e) {}
|
// чтобы не падал eslint no-undef и CI оставался зелёным).
|
||||||
|
try {
|
||||||
|
if (typeof window !== 'undefined' && typeof window.showToast === 'function') {
|
||||||
|
window.showToast(`Механика «${kit.name}» добавлена`);
|
||||||
|
}
|
||||||
|
} catch (e) {}
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
const [paletteTab, setPaletteTab] = useState('blocks'); // 'blocks' | 'models' | 'primitives'
|
const [paletteTab, setPaletteTab] = useState('blocks'); // 'blocks' | 'models' | 'primitives'
|
||||||
|
|||||||
@ -154,7 +154,6 @@ export class FloaterManager {
|
|||||||
if (slot.isCrit) text = 'POW!';
|
if (slot.isCrit) text = 'POW!';
|
||||||
else if (num > 100) text = 'KAPOW!';
|
else if (num > 100) text = 'KAPOW!';
|
||||||
else if (num > 50) text = 'BAM!';
|
else if (num > 50) text = 'BAM!';
|
||||||
text = text;
|
|
||||||
}
|
}
|
||||||
if (stackCount > 1) text = baseText + ' ×' + stackCount;
|
if (stackCount > 1) text = baseText + ' ×' + stackCount;
|
||||||
|
|
||||||
|
|||||||
@ -4314,6 +4314,11 @@ export class GameRuntime {
|
|||||||
const id = t.id ?? t.ref;
|
const id = t.id ?? t.ref;
|
||||||
this.scene3d?.primitiveManager?.removeInstance(id);
|
this.scene3d?.primitiveManager?.removeInstance(id);
|
||||||
}
|
}
|
||||||
|
// Снять interact-подсказку удалённого объекта (иначе «E» висит на пустоте).
|
||||||
|
if (t.kind && (t.ref ?? t.id) != null && Array.isArray(this._interactables)) {
|
||||||
|
const ref = t.kind + ':' + (t.ref ?? t.id);
|
||||||
|
this._interactables = this._interactables.filter(it => it.ref !== ref);
|
||||||
|
}
|
||||||
this.scheduleSceneSnapshot();
|
this.scheduleSceneSnapshot();
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
// eslint-disable-next-line no-console
|
// eslint-disable-next-line no-console
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user