Update behavior3 lib

This commit is contained in:
codetypess committed 2026-04-08 23:06:39 +08:00
1 parent 1c1bb56bb6
commit 9d0261fcd7
4 files changed
+6 -4

No files matched your search

+3 -1
View File
@@ -1,6 +1,8 @@
# vscode 插件 # vscode 插件
[Behavior3 Editor](https://marketplace.visualstudio.com/items?itemName=codetypes.vscode-behavior3) [Behavior3 Editor](https://marketplace.visualstudio.com/items?itemName=codetypess.vscode-behavior3)
![](readme/vscode.png)
# 行为树编辑器 # 行为树编辑器
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 532 KiB

+2 -2
View File
@@ -1,5 +1,5 @@
import { Node, NodeDef } from "../behavior3/src/behavior3"; import { Node, NodeDef } from "../behavior3/src/behavior3";
import { Context, DeepReadonly } from "../behavior3/src/behavior3/context"; import { Context } from "../behavior3/src/behavior3/context";
export const zhNodeDef = () => { export const zhNodeDef = () => {
const context = new (class extends Context { const context = new (class extends Context {
@@ -7,7 +7,7 @@ export const zhNodeDef = () => {
throw new Error("Method not implemented."); throw new Error("Method not implemented.");
} }
})(); })();
const defs: DeepReadonly<NodeDef>[] = []; const defs: NodeDef[] = [];
for (const k in context.nodeDefs) { for (const k in context.nodeDefs) {
const descriptor = context.nodeDefs[k]; const descriptor = context.nodeDefs[k];
defs.push(descriptor); defs.push(descriptor);