mirror of
https://github.com/unanmed/HumanBreak.git
synced 2025-01-19 12:49:25 +08:00
fix: 工具栏编辑器报错
This commit is contained in:
parent
ad2cb0b757
commit
f4757d7cc3
2
idea.md
2
idea.md
@ -70,7 +70,7 @@ dam4.png ---- 存档 59
|
||||
[] 小地图显示框,可以选择是否显示剩余怪物数量等
|
||||
[x] 怪物死亡特效
|
||||
[] 区域名称显示特效,3D 粒子特效
|
||||
[] 单独的工具栏,可以自定义按键
|
||||
[x] 单独的工具栏,可以自定义按键
|
||||
[] 完全 ts 化
|
||||
[] 平行光(待定)
|
||||
[] 视角控制系统
|
||||
|
@ -321,24 +321,3 @@ CustomToolbar.register(
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
hook.once('reset', () => {
|
||||
const toolbar = new CustomToolbar('test');
|
||||
toolbar
|
||||
.add<'hotkey'>({
|
||||
id: 'test1',
|
||||
type: 'hotkey',
|
||||
assist: 0,
|
||||
key: KeyCode.KeyX
|
||||
})
|
||||
.add<'assistKey'>({
|
||||
id: 'test2',
|
||||
type: 'assistKey',
|
||||
assist: KeyCode.Ctrl
|
||||
})
|
||||
.add<'item'>({
|
||||
id: 'test3',
|
||||
type: 'item',
|
||||
item: 'book'
|
||||
});
|
||||
});
|
||||
|
@ -114,10 +114,7 @@ function KeyToolEdtior(props: CustomToolbarProps<'hotkey'>) {
|
||||
};
|
||||
|
||||
const getKeyShow = (key: KeyCode, assist: number) => {
|
||||
return (
|
||||
unwarpAssist(assist) +
|
||||
(key === KeyCode.Unknown ? '' : KeyCodeUtils.toString(key))
|
||||
);
|
||||
return unwarpAssist(assist) + KeyCodeUtils.toString(key);
|
||||
};
|
||||
|
||||
return (
|
||||
|
@ -45,7 +45,7 @@
|
||||
:type="isMobile ? 'horizontal' : 'vertical'"
|
||||
></a-divider>
|
||||
<div id="tool-info">
|
||||
<div id="tool-detail">
|
||||
<div id="tool-detail" v-if="!!bar">
|
||||
<Scroll class="tool-item-list-scroll">
|
||||
<div class="tool-item-list">
|
||||
<div
|
||||
@ -152,7 +152,7 @@
|
||||
</Scroll>
|
||||
</div>
|
||||
<a-divider dashed></a-divider>
|
||||
<div id="tool-preview">
|
||||
<div id="tool-preview" v-if="!!bar">
|
||||
<div id="tool-preview-container">
|
||||
<div class="tool-preview-item" v-for="item of bar.items">
|
||||
<component
|
||||
|
Loading…
Reference in New Issue
Block a user