Skip to content

一些类型修改 #54

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 11 commits into
base: develop
Choose a base branch
from
Open

一些类型修改 #54

wants to merge 11 commits into from

Conversation

xiaoqch
Copy link

@xiaoqch xiaoqch commented Jul 13, 2025

null改为undefined,参考 ScriptX 各种值类型

注意: 对于JS有nullundefined两种类型,在ScriptX中统一收归为script::Null类型。同时ScriptX的script::Null在传递给JS的时候统一为undefined

引擎未定义枚举改为const enum,这样在编译时会被内联为枚举值

@superx101
Copy link
Contributor

typescript项目编译失败:

platforms/javascript/src/EventAPI/EntityEvents.d.ts(3,14): error TS2567: Enum declarations can only merge with namespace or other enum declarations.

platforms/javascript/src/GameAPI/Basic/types.d.ts(7,20): error TS2567: Enum declarations can only merge with namespace or other enum declarations.

@xiaoqch
Copy link
Author

xiaoqch commented Jul 13, 2025

typescript项目编译失败:

platforms/javascript/src/EventAPI/EntityEvents.d.ts(3,14): error TS2567: Enum declarations can only merge with namespace or other enum declarations.

platforms/javascript/src/GameAPI/Basic/types.d.ts(7,20): error TS2567: Enum declarations can only merge with namespace or other enum declarations.

有个多余的定义,修了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants