Compare commits

...

1056 Commits

Author SHA1 Message Date
yhh 8662449dcf feat(ci): 改进 SignPath 代码签名集成
- 添加 SignPath 配置检查步骤
- 使用 test-signing 策略进行测试
- 即使签名跳过也能继续版本更新 PR
2025-12-16 13:09:39 +08:00
yhh 1834bc2068 fix(tests): 更新测试以使用 GlobalComponentRegistry 实例
修复多个测试文件以适配 ComponentRegistry 从静态类变为实例类的变更:
- ComponentStorage.test.ts: 使用 GlobalComponentRegistry.reset()
- EntitySerializer.test.ts: 使用 GlobalComponentRegistry 实例
- IncrementalSerialization.test.ts: 使用 GlobalComponentRegistry 实例
- SceneSerializer.test.ts: 使用 GlobalComponentRegistry 实例
- ComponentRegistry.extended.test.ts: 使用 GlobalComponentRegistry,同时注册到 scene.componentRegistry
- SystemTypes.test.ts: 在 Scene 创建前注册组件
- QuerySystem.test.ts: mockScene 添加 componentRegistry
2025-12-16 12:38:14 +08:00
yhh c23c6c21db fix(asset-system): 移除未使用的 TextureLoader 导入 2025-12-16 12:06:09 +08:00
yhh b494283e9c refactor(asset-system-editor): 资产元数据改进
- AssetMetaFile 优化
- 导出调整
2025-12-16 11:55:39 +08:00
yhh 9b334f36e1 refactor(platform): 平台适配层优化
- BrowserRuntime 改进
- 新增 RuntimeSceneManager 服务
- 导出优化
2025-12-16 11:55:06 +08:00
yhh 7f8d2eb142 refactor(particle): 粒子系统改进
- 适配新的组件注册接口
- ParticleSystem 优化
- 添加单元测试
2025-12-16 11:52:21 +08:00
yhh 9d3eeb1980 feat(tauri): 添加文件修改时间查询命令
- 新增 get_file_mtime 命令
- 支持检测文件外部修改
2025-12-16 11:51:58 +08:00
yhh 0bcb675c3b feat(i18n): 更新国际化翻译
- 添加新功能相关翻译
- 更新中文、英文、西班牙文
2025-12-16 11:29:14 +08:00
yhh 574b4d08a3 refactor(editor-app): 编辑器服务和组件优化
- EngineService 改进引擎集成
- EditorEngineSync 同步优化
- AssetFileInspector 改进
- VectorFieldEditors 优化
- InstantiatePrefabCommand 改进
2025-12-16 11:28:50 +08:00
yhh d64e463a71 feat(editor-app): 添加渲染调试面板
- 新增 RenderDebugService 和调试面板 UI
- App/ContentBrowser 添加调试日志
- TitleBar/Viewport 优化
- DialogManager 改进
2025-12-16 11:28:34 +08:00
yhh 792fd05c85 feat(editor-app): 添加外部文件修改检测
- 新增 ExternalModificationDialog 组件
- TauriFileAPI 支持 getFileMtime
- 场景文件被外部修改时提示用户
2025-12-16 11:28:08 +08:00
yhh 7814b97ace feat(ui): 添加场景切换和文本闪烁组件
新增组件:
- SceneLoadTriggerComponent: 场景切换触发器
- TextBlinkComponent: 文本闪烁效果

新增系统:
- SceneLoadTriggerSystem: 处理场景切换逻辑
- TextBlinkSystem: 处理文本闪烁动画

其他改进:
- UIRuntimeModule 适配新组件注册接口
- UI 渲染系统优化
2025-12-16 11:25:49 +08:00
yhh 75be905f14 feat(engine): 改进 Rust 纹理管理器
- 支持任意 ID 的纹理加载(非递增)
- 添加纹理状态追踪 API
- 优化纹理缓存清理机制
- 更新 TypeScript 绑定
2025-12-16 11:25:28 +08:00
yhh 01293590e8 feat(editor-core): 改进编辑器核心服务
- EntityStoreService 添加调试日志
- AssetRegistryService 优化资产注册
- PluginManager 改进插件管理
- IFileAPI 添加 getFileMtime 接口
2025-12-16 11:23:50 +08:00
yhh b236b729b4 fix(editor-app): 在编译完成后调用 signalReady()
确保用户脚本编译完成后发出就绪信号:
- 编译成功后调用 userCodeService.signalReady()
- 编译失败也要发出信号,避免阻塞场景加载
2025-12-16 11:21:57 +08:00
yhh 0170dc6e9c feat(editor-core): 添加 UserCodeService 就绪信号机制
- 新增 waitForReady()/signalReady() API
- 支持等待用户脚本编译完成
- 解决场景加载时组件未注册的时序问题
2025-12-16 11:17:19 +08:00
yhh 7834328ae0 fix(physics-rapier2d): 修复物理插件组件注册
- PhysicsEditorPlugin 添加 runtimeModule 引用
- 适配 IComponentRegistry 接口
- 修复物理组件在场景加载时未注册的问题
2025-12-16 11:12:50 +08:00
yhh 39fa797299 refactor(modules): 适配新的组件注册接口
更新各模块 RuntimeModule 使用 IComponentRegistry 接口:
- audio, behavior-tree, camera
- sprite, tilemap, world-streaming
2025-12-16 11:12:17 +08:00
yhh 03229ffb59 refactor(engine-core): 改进插件服务注册机制
- 更新 IComponentRegistry 类型引用
- 优化 PluginServiceRegistry 服务管理
2025-12-16 11:11:48 +08:00
yhh 844a770335 refactor(core): 提取 IComponentRegistry 接口
将组件注册表抽象为接口,支持场景级组件注册:
- 新增 IComponentRegistry 接口定义
- Scene 持有独立的 componentRegistry 实例
- 支持从 GlobalComponentRegistry 克隆
- 各系统支持传入自定义注册表
2025-12-16 11:11:29 +08:00
yhh c8dc9869a3 fix(runtime-core): 修复 PluginManager 组件注册类型错误
将 ComponentRegistry 类改为 GlobalComponentRegistry 实例:
- registerComponents() 期望 IComponentRegistry 接口实例
- GlobalComponentRegistry 是 ComponentRegistry 的全局实例
2025-12-16 11:08:09 +08:00
yhh 38755c9014 fix(editor-core): 修复场景切换时的资源泄漏
在 openScene() 加载新场景前先卸载旧场景资源:
- 调用 sceneResourceManager.unloadSceneResources() 释放旧资源
- 使用引用计数机制,仅卸载不再被引用的资源
- 路径稳定 ID 缓存不受影响,保持 ID 稳定性
2025-12-16 11:07:48 +08:00
yhh 5d5537e4c7 fix(runtime-core): 移除 Play/Stop 循环中的 clearTextureMappings 调用
使用路径稳定 ID 后,不再需要在快照保存/恢复时清除纹理缓存:
- saveSceneSnapshot() 移除 clearTextureMappings() 调用
- restoreSceneSnapshot() 移除 clearTextureMappings() 调用
- 组件保存的 textureId 在 Play/Stop 后仍然有效
2025-12-16 11:07:15 +08:00
yhh 9da9f5f068 feat(asset-system): 实现路径稳定 ID 生成器
使用 FNV-1a hash 算法为纹理生成稳定的运行时 ID:
- 新增 _pathIdCache 静态缓存,跨 Play/Stop 循环保持稳定
- 新增 getStableIdForPath() 方法,相同路径永远返回相同 ID
- 修改 loadTextureForComponent/loadTextureByGuid 使用稳定 ID
- clearTextureMappings() 不再清除 _pathIdCache

这解决了 Play/Stop 后纹理 ID 失效的根本问题。
2025-12-16 11:06:59 +08:00
yhh d834ca5e77 ci(editor): add SignPath OSS code signing for Windows builds
- Upload Windows artifacts (exe/msi) for SignPath signing
- Configure SignPath action with organization secrets
- Fix artifact name to 'windows-unsigned'
- Add bilingual comments for required secrets
2025-12-15 10:20:15 +08:00
yhh 85e95ec18c docs: add English entity documentation with EntityHandle 2025-12-15 10:00:44 +08:00
yhh ff9bc00729 docs: 改进 EntityHandle 文档,添加实际使用场景示例 2025-12-15 09:59:12 +08:00
yhh 7451a78e60 docs: 补充 EntityHandle 实体句柄文档 2025-12-15 09:38:45 +08:00
yhh 23ee2393c6 chore(release): 准备发布 v2.4.0,改进 CI 发布流程
- 更新 @esengine/ecs-framework 版本号到 2.4.0
- 更新中英文 changelog
- CI: 支持标签触发自动发布(v* 或 package-v* 格式)
- CI: 保留手动触发选项
- CI: 标签模式下自动创建 GitHub Release
2025-12-15 09:33:51 +08:00
YHH cd6ef222d1 feat(ecs): 核心系统改进 - 句柄、调度、变更检测与查询编译 (#304)
新增功能:
- EntityHandle: 轻量级实体句柄 (28位索引 + 20位代数)
- SystemScheduler: 声明式系统调度,支持 @Stage/@Before/@After/@InSet 装饰器
- EpochManager: 帧级变更检测
- CompiledQuery: 预编译类型安全查询

API 改进:
- EntitySystem 添加 getBefore()/getAfter()/getSets() getter 方法
- Entity 添加 markDirty() 辅助方法
- IScene 添加 epochManager 属性
- CommandBuffer.pendingCount 修正为返回实际操作数

文档更新:
- 更新系统调度和查询相关文档
2025-12-15 09:17:00 +08:00
yhh b5158b6ac6 chore: 移除第三方引擎引用,改进 README 专业度 2025-12-13 20:56:22 +08:00
YHH beaa1d09de feat: 预制体系统与架构改进 (#303)
* feat(prefab): 实现预制体系统和编辑器 UX 改进

## 预制体系统
- 新增 PrefabSerializer: 预制体序列化/反序列化
- 新增 PrefabInstanceComponent: 追踪预制体实例来源和修改
- 新增 PrefabService: 预制体核心服务
- 新增 PrefabLoader: 预制体资产加载器
- 新增预制体命令: Create/Instantiate/Apply/Revert/BreakLink

## 预制体编辑模式
- 支持双击 .prefab 文件进入编辑模式
- 预制体编辑模式工具栏 (保存/退出)
- 预制体实例指示器和操作菜单

## 编辑器 UX 改进
- SceneHierarchy 快捷键: F2 重命名, Ctrl+D 复制, ↑↓ 导航
- 支持双击实体名称内联编辑
- 删除实体时显示子节点数量警告
- 右键菜单添加重命名/复制选项及快捷键提示
- 布局持久化和重置功能

## Bug 修复
- 修复 editor-runtime 组件类重复导致的 TransformComponent 不识别问题
- 修复 .prefab-name 样式覆盖导致预制体工具栏文字不可见
- 修复 Inspector 资源字段高度不正确问题

* feat(editor): 改进编辑器 UX 交互体验

- ContentBrowser: 加载动画 spinner、搜索高亮、改进空状态设计
- SceneHierarchy: 选中项自动滚动到视图、搜索清除按钮
- PropertyInspector: 输入框本地状态管理、Enter/Escape 键处理
- EntityInspector: 组件折叠状态持久化、属性搜索清除按钮
- Viewport: 变换操作实时数值显示
- 国际化: 添加相关文本 (en/zh)

* fix(build): 修复 Web 构建资产加载和编辑器 UX 改进

构建系统修复:
- 修复 asset-catalog.json 字段名不匹配 (entries vs assets)
- 修复 BrowserFileSystemService 支持两种目录格式
- 修复 bundle 策略检测逻辑 (空对象判断)
- 修复 module.json 中 assetExtensions 声明和类型推断

行为树修复:
- 修复 BehaviorTreeExecutionSystem 使用 loadAsset 替代 loadAssetByPath
- 修复 BehaviorTreeAssetType 常量与 module.json 类型名一致 (behavior-tree)

编辑器 UX 改进:
- 构建完成对话框添加"打开文件夹"按钮
- 构建完成对话框样式优化 (圆形图标背景、按钮布局)
- SceneHierarchy 响应式布局 (窄窗口自动隐藏 Type 列)
- SceneHierarchy 隐藏滚动条

错误追踪:
- 添加全局错误处理器写入日志文件 (%TEMP%/esengine-editor-crash.log)
- 添加 append_to_log Tauri 命令

* feat(render): 修复 UI 渲染和点击特效系统

## UI 渲染修复
- 修复 GUID 验证 bug,使用统一的 isValidGUID() 函数
- 修复 UI 渲染顺序随机问题,Rust 端使用 IndexMap 替代 HashMap
- Web 运行时添加 assetPathResolver 支持 GUID 解析
- UIInteractableComponent.blockEvents 默认值改为 false

## 点击特效系统
- 新增 ClickFxComponent 和 ClickFxSystem
- 支持在点击位置播放粒子效果
- 支持多种触发模式和粒子轮换

## Camera 系统重构
- CameraSystem 从 ecs-engine-bindgen 移至 camera 包
- 新增 CameraManager 统一管理相机

## 编辑器改进
- 改进属性面板 UI 交互
- 粒子编辑器面板优化
- Transform 命令系统

* feat(render): 实现 Sorting Layer 系统和 Overlay 渲染层

- 新增 SortingLayerManager 管理排序层级 (Background, Default, Foreground, UI, Overlay)
- 实现 ISortable 接口,统一 Sprite、UI、Particle 的排序属性
- 修复粒子 Overlay 层被 UI 遮挡问题:添加独立的 Overlay Pass 在 UI 之后渲染
- 更新粒子资产格式:从 sortingOrder 改为 sortingLayer + orderInLayer
- 更新粒子编辑器面板支持新的排序属性
- 优化 UI 渲染系统使用新的排序层级

* feat(ci): 集成 SignPath 代码签名服务

- 添加 SignPath 自动签名工作流(Windows)
- 配置 release-editor.yml 支持代码签名
- 将构建改为草稿模式,等待签名完成后发布
- 添加证书文件到 .gitignore 防止泄露

* fix(asset): 修复 Web 构建资产路径解析和全局单例移除

## 资产路径修复
- 修复 Tauri 本地服务器 `/asset?path=...` 路径解析,正确与 root 目录连接
- BrowserPathResolver 支持两种模式:
  - 'proxy': 使用 /asset?path=... 格式(编辑器 Run in Browser)
  - 'direct': 使用直接路径 /assets/path.png(独立 Web 构建)
- BrowserRuntime 使用 'direct' 模式,无需 Tauri 代理

## 架构改进 - 移除全局单例
- 移除 globalAssetManager 导出,改用 AssetManagerToken 依赖注入
- 移除 globalPathResolver 导出,改用 PathResolutionService
- 移除 globalPathResolutionService 导出
- ParticleUpdateSystem/ClickFxSystem 通过 setAssetManager() 注入依赖
- EngineService 使用 new AssetManager() 替代全局实例

## 新增服务
- PathResolutionService: 统一路径解析接口
- RuntimeModeService: 运行时模式查询服务
- SerializationContext: EntityRef 序列化上下文

## 其他改进
- 完善 ServiceToken 注释说明本地定义的意图
- 导出 BrowserPathResolveMode 类型

* fix(build): 添加 world-streaming composite 设置修复类型检查

* fix(build): 移除 world-streaming 引用避免 composite 冲突

* fix(build): 将 const enum 改为 enum 兼容 isolatedModules

* fix(build): 添加缺失的 IAssetManager 导入
2025-12-13 19:44:08 +08:00
YHH a716d8006c fix(build): 修复 Web 构建组件注册和用户脚本打包问题 (#302)
* refactor(build): 重构 Web 构建管线,支持配置驱动的 Import Maps

- 重构 WebBuildPipeline 支持 split-bundles 和 single-bundle 两种构建模式
- 使用 module.json 的 isCore 字段识别核心模块,消除硬编码列表
- 动态生成 Import Map,从模块清单的 name 字段获取包名映射
- 动态扫描 module.json 文件,不再依赖固定模块列表
- 添加 HTTP 服务器启动脚本 (start-server.bat/sh) 支持 ESM 模块
- 更新 BuildSettingsPanel UI 支持新的构建模式选项
- 添加多语言支持 (zh/en/es)

* fix(build): 修复 Web 构建组件注册和用户脚本打包问题

主要修复:
- 修复组件反序列化时找不到类型的问题
- @ECSComponent 装饰器现在自动注册到 ComponentRegistry
- 添加未使用装饰器的组件警告
- 构建管线自动扫描用户脚本(无需入口文件)

架构改进:
- 解决 Decorators ↔ ComponentRegistry 循环依赖
- 新建 ComponentTypeUtils.ts 作为底层无依赖模块
- 移除冗余的防御性 register 调用
- 统一 ComponentType 定义位置

* refactor(build): 统一 WASM 配置架构,移除硬编码

- 新增 wasmConfig 统一配置替代 wasmPaths/wasmBindings
- wasmConfig.files 支持多候选源路径和明确目标路径
- wasmConfig.runtimePath 指定运行时加载路径
- 重构 _copyWasmFiles 使用统一配置
- HTML 生成使用配置中的 runtimePath
- 移除 physics-rapier2d 的冗余 WASM 配置(由 rapier2d 负责)
- IBuildFileSystem 新增 deleteFile 方法

* feat(build): 单文件构建模式完善和场景配置驱动

## 主要改动

### 单文件构建(single-file mode)
- 修复 WASM 初始化问题,支持 initSync 同步初始化
- 配置驱动的 WASM 识别,通过 wasmConfig.isEngineCore 标识核心引擎模块
- 从 wasmConfig.files 动态获取 JS 绑定路径,消除硬编码

### 场景配置
- 构建验证:必须选择至少一个场景才能构建
- 自动扫描:项目加载时扫描 scenes 目录
- 抽取 _filterScenesByWhitelist 公共方法统一过滤逻辑

### 构建面板优化
- availableScenes prop 传递场景列表
- 场景复选框可点击切换启用状态
- 移除动态 import,使用 prop 传入数据

* chore(build): 补充构建相关的辅助改动

- 添加 BuildFileSystemService 的 listFilesByExtension 优化
- 更新 module.json 添加 externalDependencies 配置
- BrowserRuntime 支持 wasmModule 参数传递
- GameRuntime 添加 loadSceneFromData 方法
- Rust 构建命令更新
- 国际化文案更新

* feat(build): 持久化构建设置到项目配置

## 设计架构

### ProjectService 扩展
- 新增 BuildSettingsConfig 接口定义构建配置字段
- ProjectConfig 添加 buildSettings 字段
- 新增 getBuildSettings / updateBuildSettings 方法

### BuildSettingsPanel
- 组件挂载时从 projectService 加载已保存配置
- 设置变化时自动保存(500ms 防抖)
- 场景选择状态与项目配置同步

### 配置保存位置
保存在项目的 ecs-editor.config.json 中:
- scenes: 选中的场景列表
- buildMode: 构建模式
- companyName/productName/version: 产品信息
- developmentBuild/sourceMap: 构建选项

* fix(editor): Ctrl+S 仅在主编辑区域触发保存场景

- 模态窗口打开时跳过(构建设置、设置、关于等)
- 焦点在 input/textarea/contenteditable 时跳过

* fix(tests): 修复 ECS 测试中 Component 注册问题

- 为所有测试 Component 类添加 @ECSComponent 装饰器
- 移除 beforeEach 中的 ComponentRegistry.reset() 调用
- 将内联 Component 类移到文件顶层以支持装饰器
- 更新测试预期值匹配新的组件类型名称
- 添加缺失的 HierarchyComponent 导入

所有 1388 个测试现已通过。
2025-12-10 18:23:29 +08:00
YHH 1b0d38edce feat(i18n): 统一国际化系统架构,支持插件独立翻译 (#301)
* feat(i18n): 统一国际化系统架构,支持插件独立翻译

## 主要改动

### 核心架构
- 增强 LocaleService,支持插件命名空间翻译扩展
- 新增 editor-runtime/i18n 模块,提供 createPluginLocale/createPluginTranslator
- 新增 editor-core/tokens.ts,定义 LocaleServiceToken 等服务令牌
- 改进 PluginAPI 类型安全,使用 ServiceToken<T> 替代 any

### 编辑器本地化
- 扩展 en.ts/zh.ts 翻译文件,覆盖所有 UI 组件
- 新增 es.ts 西班牙语支持
- 重构 40+ 组件使用 useLocale() hook

### 插件本地化系统
- behavior-tree-editor: 新增 locales/ 和 useBTLocale hook
- material-editor: 新增 locales/ 和 useMaterialLocale hook
- particle-editor: 新增 locales/ 和 useParticleLocale hook
- tilemap-editor: 新增 locales/ 和 useTilemapLocale hook
- ui-editor: 新增 locales/ 和 useUILocale hook

### 类型安全改进
- 修复 Debug 工具使用公共接口替代 as any
- 修复 ChunkStreamingSystem 添加 forEachChunk 公共方法
- 修复 blueprint-editor 移除不必要的向后兼容代码

* fix(behavior-tree-editor): 使用 ServiceToken 模式修复服务解析

- 创建 BehaviorTreeServiceToken 遵循"谁定义接口,谁导出Token"原则
- 使用 ServiceToken.id (symbol) 注册服务到 ServiceContainer
- 更新 PluginSDKRegistry.resolveService 支持 ServiceToken 检测
- BehaviorTreeEditorPanel 现在使用类型安全的 PluginAPI.resolve

* fix(behavior-tree-editor): 使用 ServiceContainer.resolve 获取类注册的服务

* fix: 修复多个包的依赖和类型问题

- core: EntityDataCollector.getEntityDetails 使用 HierarchySystem 获取父实体
- ui-editor: 添加 @esengine/editor-runtime 依赖
- tilemap-editor: 添加 @esengine/editor-runtime 依赖
- particle-editor: 添加 @esengine/editor-runtime 依赖
2025-12-09 18:04:03 +08:00
YHH 995fa2d514 refactor(arch): 改进 ServiceToken 设计,统一服务获取模式 (#300)
* refactor(arch): 移除全局变量,使用 ServiceToken 模式

- 创建 PluginServiceRegistry 类,提供类型安全的服务注册/获取
- 添加 ProfilerServiceToken 和 CollisionLayerConfigToken
- 重构所有 __PROFILER_SERVICE__ 全局变量访问为 getProfilerService()
- 重构 __PHYSICS_RAPIER2D__ 全局变量访问为 CollisionLayerConfigToken
- 在 Core 类添加 pluginServices 静态属性
- 添加 getService.ts 辅助模块简化服务获取

这是 ServiceToken 模式重构的第一阶段,移除了最常用的两个全局变量。
后续可继续应用到其他模块(Camera/Audio 等)。

* refactor(arch): 改进 ServiceToken 设计,移除重复常量

- tokens.ts: 从 engine-core 导入 createServiceToken(符合规范)
- tokens.ts: Token 使用接口 IProfilerService 而非具体类
- 移除 AssetPickerDialog 和 ContentBrowser 中重复的 MANAGED_ASSET_DIRECTORIES
- 统一从 editor-core 导入 MANAGED_ASSET_DIRECTORIES

* fix(type): 修复 IProfilerService 接口与实现类型不匹配

- 将 ProfilerData 等数据类型移到 tokens.ts 以避免循环依赖
- ProfilerService 显式实现 IProfilerService 接口
- 更新使用方使用 IProfilerService 接口类型而非具体类

* refactor(type): 移除类型重导出,改进类型安全

- 删除 ProfilerService.ts 中的类型重导出,消费方直接从 tokens.ts 导入
- PanelDescriptor 接口添加 titleZh 属性,移除 App.tsx 中的 as any
- 改进 useDynamicIcon.ts 的类型安全,使用正确的 Record 类型

* refactor(arch): 为模块添加 ServiceToken 支持

- Material System: 创建 tokens.ts,定义 IMaterialManager 接口和 MaterialManagerToken
- Audio: 创建预留 tokens.ts 文件,为未来 AudioManager 服务扩展做准备
- Camera: 创建预留 tokens.ts 文件,为未来 CameraManager 服务扩展做准备

遵循"谁定义接口,谁导出 Token"原则,统一服务访问模式
2025-12-09 11:07:44 +08:00
yhh c71a47f2b0 docs: 更新文档链接到 esengine.cn 2025-12-09 09:09:45 +08:00
YHH 6c99b811ec refactor(editor): 统一配置管理、完善插件卸载和热更新同步 (#298)
主要变更:

1. 统一配置管理 (EditorConfig)
   - 新增 EditorConfig 集中管理路径、文件名、全局变量等配置
   - 添加 SDK 模块配置系统 (ISDKModuleConfig)
   - 重构 PluginSDKRegistry 使用配置而非硬编码

2. 完善插件卸载机制
   - 扩展 PluginRegisteredResources 追踪运行时资源
   - 实现完整的 deactivatePluginRuntime 清理流程
   - ComponentRegistry 添加 unregister/getRegisteredComponents 方法

3. 热更新同步机制
   - 新增 HotReloadCoordinator 协调热更新过程
   - 热更新期间暂停 ECS 循环避免竞态条件
   - 支持超时保护和失败恢复
2025-12-09 09:06:29 +08:00
yhh 40a38b8b88 docs: 更新品牌形象和项目文档
- 新增 ES logo (docs/public/logo.svg)
- README 添加居中 logo、徽章和导航链接
- 更新 LICENSE 版权为 ESEngine Contributors
- SECURITY.md 添加英文版本,更新联系方式
- 移除不稳定的性能测试
2025-12-08 21:47:47 +08:00
yhh ad96edfad0 fix: 恢复 @esengine/ecs-framework 包名
上一个提交错误地将 npm 包名也改了,这里恢复正确的包名。
只更新 GitHub 仓库 URL,不改变 npm 包名。
2025-12-08 21:26:35 +08:00
yhh 240b165970 chore: 更新仓库 URL (ecs-framework → esengine)
仓库已从 esengine/ecs-framework 重命名为 esengine/esengine
更新所有引用旧 URL 的文件
2025-12-08 21:23:37 +08:00
YHH c3b7250f85 refactor(plugin): 重构插件系统架构,统一类型导入路径 (#296)
* refactor(plugin): 重构插件系统架构,统一类型导入路径

## 主要更改

### 新增 @esengine/plugin-types 包
- 提供打破循环依赖的最小类型定义
- 包含 ServiceToken, createServiceToken, PluginServiceRegistry, IEditorModuleBase

### engine-core 类型统一
- IPlugin<T> 泛型参数改为 T = unknown
- 所有运行时类型(IRuntimeModule, ModuleManifest, SystemContext)在此定义
- 新增 PluginServiceRegistry.ts 导出服务令牌相关类型

### editor-core 类型优化
- 重命名 IPluginLoader.ts 为 EditorModule.ts
- 新增 IEditorPlugin = IPlugin<IEditorModuleLoader> 类型别名
- 移除弃用别名 IPluginLoader, IRuntimeModuleLoader

### 编辑器插件更新
- 所有 9 个编辑器插件使用 IEditorPlugin 类型
- 统一从 editor-core 导入编辑器类型

### 服务令牌规范
- 各模块在 tokens.ts 中定义自己的服务接口和令牌
- 遵循"谁定义接口,谁导出 Token"原则

## 导入规范

| 场景 | 导入来源 |
|------|---------|
| 运行时模块 | @esengine/engine-core |
| 编辑器插件 | @esengine/editor-core |
| 服务令牌 | @esengine/engine-core |

* refactor(plugin): 完善服务令牌规范,统一运行时模块

## 更改内容

### 运行时模块优化
- particle: 使用 PluginServiceRegistry 获取依赖服务
- physics-rapier2d: 通过服务令牌注册/获取物理查询接口
- tilemap: 使用服务令牌获取物理系统依赖
- sprite: 导出服务令牌
- ui: 导出服务令牌
- behavior-tree: 使用服务令牌系统

### 资产系统增强
- IAssetManager 接口扩展
- 加载器使用服务令牌获取依赖

### 运行时核心
- GameRuntime 使用 PluginServiceRegistry
- 导出服务令牌相关类型

### 编辑器服务
- EngineService 适配新的服务令牌系统
- AssetRegistryService 优化

* fix: 修复 editor-app 和 behavior-tree-editor 中的类型引用

- editor-app/PluginLoader.ts: 使用 IPlugin 替代 IPluginLoader
- behavior-tree-editor: 使用 IEditorPlugin 替代 IPluginLoader

* fix(ui): 添加缺失的 ecs-engine-bindgen 依赖

UIRuntimeModule 使用 EngineBridgeToken,需要声明对 ecs-engine-bindgen 的依赖

* fix(type): 解决 ServiceToken 跨包类型兼容性问题

- 在 engine-core 中直接定义 ServiceToken 和 PluginServiceRegistry
  而不是从 plugin-types 重新导出,确保 tsup 生成的类型声明
  以 engine-core 作为类型来源
- 移除 RuntimeResolver.ts 中的硬编码模块 ID 检查,
  改用 module.json 中的 name 配置
- 修复 pnpm-lock.yaml 中的依赖记录

* refactor(arch): 改进架构设计,移除硬编码

- 统一类型导出:editor-core 从 engine-core 导入 IEditorModuleBase
- RuntimeResolver: 将硬编码路径改为配置常量和搜索路径列表
- 添加跨平台安装路径支持(Windows/macOS/Linux)
- 使用 ENGINE_WASM_CONFIG 配置引擎 WASM 文件信息
- IBundlePackOptions 添加 preloadBundles 配置项

* fix(particle): 添加缺失的 ecs-engine-bindgen 依赖

ParticleRuntimeModule 导入了 @esengine/ecs-engine-bindgen 的 tokens,
但 package.json 中未声明该依赖,导致 CI 构建失败。

* fix(physics-rapier2d): 移除不存在的 PhysicsSystemContext 导出

PhysicsRuntimeModule 中不存在该类型,导致 type-check 失败
2025-12-08 21:10:57 +08:00
yhh 2476379af1 docs: 更新 worker-generator 版本号为 v1.0.2 2025-12-08 18:34:49 +08:00
yhh e0d659fe46 fix(worker-generator): 映射文件不再放入 workers 目录避免微信编译错误 2025-12-08 18:33:23 +08:00
yhh 9ff03c04f3 docs: 更新 worker-generator 版本号为 v1.0.1 2025-12-08 17:17:26 +08:00
yhh 7b45fbeab3 fix(worker-generator): 将 typescript 移至 dependencies 以修复运行时依赖问题 2025-12-08 17:12:30 +08:00
yhh a733a53d3e chore(release): 准备发布 v2.3.2 和 worker-generator v1.0.0
- 更新 @esengine/ecs-framework 版本号到 2.3.2
- 更新中英文 changelog
2025-12-08 17:04:01 +08:00
YHH dfd0dfc7f9 feat(worker): 添加微信小游戏 Worker 支持和 Worker Generator CLI (#297)
* feat(worker): 添加微信小游戏 Worker 支持和 Worker Generator CLI

- 新增 @esengine/worker-generator 包,用于从 WorkerEntitySystem 生成 Worker 文件
- WorkerEntitySystem 添加 workerScriptPath 配置项,支持预编译 Worker 脚本
- CLI 工具支持 --wechat 模式,自动转换 ES6+ 为 ES5 语法
- 修复微信小游戏 Worker 消息格式差异(res 直接是数据,无需 .data)
- 更新中英文文档,添加微信小游戏支持章节

* docs: 更新 changelog,添加 v2.3.1 说明并标注 v2.3.0 为废弃

* fix: 修复 CI 检查问题

- 移除 cli.ts 中未使用的 toKebabCase 函数
- 修复 generator.ts 中正则表达式的 ReDoS 风险(使用 [ \t] 替代 \s*)
- 更新 changelog 版本号(2.3.1 -> 2.3.2)

* docs: 移除未发布版本的 changelog 条目

* fix(worker-generator): 使用 TypeScript 编译器替代手写正则进行 ES5 转换

- 修复 CodeQL 检测的 ReDoS 安全问题
- 使用 ts.transpileModule 进行安全可靠的代码转换
- 移除所有可能导致回溯的正则表达式
2025-12-08 17:02:11 +08:00
YHH 52bbccd53c feat(particle): 添加粒子与 Rapier2D 物理碰撞集成 (#295)
* feat(particle): 添加粒子与 Rapier2D 物理碰撞集成

- 新增 Physics2DCollisionModule 模块,支持粒子与场景碰撞体交互
- 支持圆形重叠检测和射线检测两种模式
- 支持 Kill/Bounce/Stop 三种碰撞行为
- 修复 module.update() 参数顺序 bug
- 物理模块自动通过 context 注入,用户只需添加模块即可

* chore: update pnpm-lock.yaml for particle physics dependency

Update lockfile to include @esengine/physics-rapier2d as optional peer dependency.
2025-12-08 09:38:37 +08:00
YHH d92c2a7b66 feat(asset): 增强资产管理系统和编辑器 UI (#291)
* fix(editor): 修复粒子实体创建和优化检视器

- 添加 effects 分类到右键菜单,修复粒子实体无法创建的问题
- 添加粒子效果的本地化标签
- 简化粒子组件检视器,优先显示资产文件选择
- 高级属性只在未选择资产时显示,且默认折叠
- 添加可折叠的属性分组提升用户体验

* fix(particle): 修复粒子系统在浏览器预览中的资产加载和渲染

- 添加粒子 Gizmo 支持,显示发射形状并响应 Transform 缩放/旋转
- 修复资产热重载:添加 reloadAsset() 方法和 assets:refresh 事件监听
- 修复 VectorFieldEditors 数值输入精度(step 改为 0.01)
- 修复浏览器预览中粒子资产加载失败的问题:
  - 将相对路径转换为绝对路径以正确复制资产文件
  - 使用原始 GUID 而非生成的 GUID 构建 asset catalog
  - 初始化全局 assetManager 单例的 catalog 和 loader
  - 在 GameRuntime 的 systemContext 中添加 engineIntegration
- 公开 AssetManager.initializeFromCatalog 方法供运行时使用

* feat(asset): 增强资产管理系统和编辑器 UI

主要改动:
- 添加 loaderType 字段支持显式指定加载器类型覆盖
- 添加 .particle 扩展名和类型映射
- 新增 MANAGED_ASSET_DIRECTORIES 常量和相关工具方法
- EngineService 使用全局 assetManager 并同步 AssetRegistry 数据
- 修复插件启用逻辑,defaultEnabled=true 的新插件不被旧配置禁用
- ContentBrowser 添加 GUID 管理目录指示和非托管目录警告
- AssetPickerDialog 和 AssetFileInspector UI 增强
2025-12-07 20:26:03 +08:00
YHH 568b327425 fix(particle): 修复粒子系统在浏览器预览中的资产加载和渲染 (#290)
* fix(editor): 修复粒子实体创建和优化检视器

- 添加 effects 分类到右键菜单,修复粒子实体无法创建的问题
- 添加粒子效果的本地化标签
- 简化粒子组件检视器,优先显示资产文件选择
- 高级属性只在未选择资产时显示,且默认折叠
- 添加可折叠的属性分组提升用户体验

* fix(particle): 修复粒子系统在浏览器预览中的资产加载和渲染

- 添加粒子 Gizmo 支持,显示发射形状并响应 Transform 缩放/旋转
- 修复资产热重载:添加 reloadAsset() 方法和 assets:refresh 事件监听
- 修复 VectorFieldEditors 数值输入精度(step 改为 0.01)
- 修复浏览器预览中粒子资产加载失败的问题:
  - 将相对路径转换为绝对路径以正确复制资产文件
  - 使用原始 GUID 而非生成的 GUID 构建 asset catalog
  - 初始化全局 assetManager 单例的 catalog 和 loader
  - 在 GameRuntime 的 systemContext 中添加 engineIntegration
- 公开 AssetManager.initializeFromCatalog 方法供运行时使用
2025-12-07 01:00:35 +08:00
YHH 1fb702169e feat(asset-system): 完善资源加载和场景资源管理 (#289)
- 添加 AudioLoader 支持音频资源加载 (mp3/wav/ogg/m4a/flac/aac)
- EngineIntegration 添加音频资源加载/卸载支持
- EngineIntegration 添加数据(JSON)资源加载/卸载支持
- SceneResourceManager 实现完整的引用计数机制
- SceneResourceManager 实现场景资源卸载,仅卸载无引用的资源
- 添加资源统计和引用计数查询接口
2025-12-06 14:47:35 +08:00
YHH 3617f40309 feat(asset): 统一资产引用使用 GUID 替代路径 (#287)
* feat(world-streaming): 添加世界流式加载系统

实现基于区块的世界流式加载系统,支持开放世界游戏:

运行时包 (@esengine/world-streaming):
- ChunkComponent: 区块实体组件,包含坐标、边界、状态
- StreamingAnchorComponent: 流式锚点组件(玩家/摄像机)
- ChunkLoaderComponent: 流式加载配置组件
- ChunkStreamingSystem: 区块加载/卸载调度系统
- ChunkCullingSystem: 区块可见性剔除系统
- ChunkManager: 区块生命周期管理服务
- SpatialHashGrid: 空间哈希网格
- ChunkSerializer: 区块序列化

编辑器包 (@esengine/world-streaming-editor):
- ChunkVisualizer: 区块可视化覆盖层
- ChunkLoaderInspectorProvider: 区块加载器检视器
- StreamingAnchorInspectorProvider: 流式锚点检视器
- WorldStreamingPlugin: 完整插件导出

* feat(asset): 统一资产引用使用 GUID 替代路径

将所有组件的资产引用字段从路径改为 GUID:
- SpriteComponent: texture -> textureGuid, material -> materialGuid
- SpriteAnimatorComponent: AnimationFrame.texture -> textureGuid
- UIRenderComponent: texture -> textureGuid
- UIButtonComponent: normalTexture -> normalTextureGuid 等
- AudioSourceComponent: clip -> clipGuid
- ParticleSystemComponent: 已使用 textureGuid

修复 AssetRegistryService 注册问题和路径规范化,
添加渲染系统的 GUID 解析支持。

* fix(sprite-editor): 更新 material 为 materialGuid

* fix(editor-app): 更新 AnimationFrame.texture 为 textureGuid
2025-12-06 14:08:48 +08:00
YHH 0c03b13d74 feat(world-streaming): 添加世界流式加载系统 (#288)
实现基于区块的世界流式加载系统,支持开放世界游戏:

运行时包 (@esengine/world-streaming):
- ChunkComponent: 区块实体组件,包含坐标、边界、状态
- StreamingAnchorComponent: 流式锚点组件(玩家/摄像机)
- ChunkLoaderComponent: 流式加载配置组件
- ChunkStreamingSystem: 区块加载/卸载调度系统
- ChunkCullingSystem: 区块可见性剔除系统
- ChunkManager: 区块生命周期管理服务
- SpatialHashGrid: 空间哈希网格
- ChunkSerializer: 区块序列化

编辑器包 (@esengine/world-streaming-editor):
- ChunkVisualizer: 区块可视化覆盖层
- ChunkLoaderInspectorProvider: 区块加载器检视器
- StreamingAnchorInspectorProvider: 流式锚点检视器
- WorldStreamingPlugin: 完整插件导出
2025-12-06 13:56:01 +08:00
YHH 3cbfa1e4cb fix(editor): 修复右键菜单和粒子编辑器问题 (#286)
- 修复右键菜单被状态栏遮挡的问题
- 修复右键菜单边界检测,考虑标题栏和状态栏高度
- 调整右键菜单结构:新建文件夹 → 资源类型 → 工具操作
- 修复 Particle 插件默认未启用的问题(defaultEnabled 的新插件不被旧配置禁用)
- 修复 SizeOverLifetime 模块在预览中无效果的问题
- 移除 MaterialEditorModule 中的重复模板注册
2025-12-06 11:56:25 +08:00
yhh 397f79caa5 docs: 更新 v2.3.0 版本文档和 changelog
- 添加 v2.3.0 changelog(中英文)
- 更新文档版本号从 v2.2.22+ 到 v2.3.0+
- 更新 package.json 版本至 2.3.0
- vitepress 配置添加 ignoreDeadLinks
2025-12-06 10:44:08 +08:00
yhh 972c1d5357 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-12-06 10:15:13 +08:00
YHH 32d35ef2ee feat(particle): 添加完整粒子系统和粒子编辑器 (#284)
* feat(editor-core): 添加用户系统自动注册功能

- IUserCodeService 新增 registerSystems/unregisterSystems/getRegisteredSystems 方法
- UserCodeService 实现系统检测、实例化和场景注册逻辑
- ServiceRegistry 在预览开始时注册用户系统,停止时移除
- 热更新时自动重新加载用户系统
- 更新 System 脚本模板添加 @ECSSystem 装饰器

* feat(editor-core): 添加编辑器脚本支持(Inspector/Gizmo)

- registerEditorExtensions 实际注册用户 Inspector 和 Gizmo
- 添加 unregisterEditorExtensions 方法
- ServiceRegistry 在项目加载时编译并加载编辑器脚本
- 项目关闭时自动清理编辑器扩展
- 添加 Inspector 和 Gizmo 脚本创建模板

* feat(particle): 添加粒子系统和粒子编辑器

新增两个包:
- @esengine/particle: 粒子系统核心库
- @esengine/particle-editor: 粒子编辑器 UI

粒子系统功能:
- ECS 组件架构,支持播放/暂停/重置控制
- 7种发射形状:点、圆、环、矩形、边缘、线、锥形
- 5个动画模块:颜色渐变、缩放曲线、速度控制、旋转、噪声
- 纹理动画模块支持精灵表动画
- 3种混合模式:Normal、Additive、Multiply
- 11个内置预设:火焰、烟雾、爆炸、雨、雪等
- 对象池优化,支持粒子复用

编辑器功能:
- 实时 Canvas 预览,支持全屏和鼠标跟随
- 点击触发爆发效果(用于测试爆炸类特效)
- 渐变编辑器:可视化颜色关键帧编辑
- 曲线编辑器:支持缩放曲线和缓动函数
- 预设浏览器:快速应用内置预设
- 模块开关:独立启用/禁用各个模块
- Vector2 样式输入(重力 X/Y)

* feat(particle): 完善粒子系统核心功能

1. Burst 定时爆发系统
   - BurstConfig 接口支持时间、数量、循环次数、间隔
   - 运行时自动处理定时爆发
   - 支持无限循环爆发

2. 速度曲线模块 (VelocityOverLifetimeModule)
   - 6种曲线类型:Constant、Linear、EaseIn、EaseOut、EaseInOut、Custom
   - 自定义关键帧曲线支持
   - 附加速度 X/Y
   - 轨道速度和径向速度

3. 碰撞边界模块 (CollisionModule)
   - 矩形和圆形边界类型
   - 3种碰撞行为:Kill、Bounce、Wrap
   - 反弹系数和最小速度阈值
   - 反弹时生命损失

* feat(particle): 添加力场模块、碰撞模块和世界/本地空间支持

- 新增 ForceFieldModule 支持风力、吸引点、漩涡、湍流四种力场类型
- 新增 SimulationSpace 枚举支持世界空间和本地空间切换
- ParticleSystemComponent 集成力场模块和空间模式
- 粒子编辑器添加 Collision 和 ForceField 模块的 UI 编辑支持
- 新增 Vortex、Leaves、Bouncing 三个预设展示新功能
- 编辑器预览实现完整的碰撞和力场效果

* fix(particle): 移除未使用的 transform 循环变量
2025-12-05 23:03:31 +08:00
yhh 57e165779e Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-12-05 22:59:24 +08:00
YHH 690d7859c8 feat(core): 添加持久化实体支持跨场景迁移 (#285)
实现实体生命周期策略,允许标记实体为持久化,在场景切换时自动迁移到新场景。

主要变更:
- 新增 EEntityLifecyclePolicy 枚举(SceneLocal/Persistent)
- Entity 添加 setPersistent()、setSceneLocal()、isPersistent API
- Scene 添加 findPersistentEntities()、extractPersistentEntities()、receiveMigratedEntities()
- SceneManager.setScene() 自动处理持久化实体迁移
- 添加完整的中英文文档和 21 个测试用例
2025-12-05 22:54:41 +08:00
yhh 8f9a7d8581 feat(core): 添加持久化实体支持跨场景迁移
实现实体生命周期策略,允许标记实体为持久化,在场景切换时自动迁移到新场景。

主要变更:
- 新增 EEntityLifecyclePolicy 枚举(SceneLocal/Persistent)
- Entity 添加 setPersistent()、setSceneLocal()、isPersistent API
- Scene 添加 findPersistentEntities()、extractPersistentEntities()、receiveMigratedEntities()
- SceneManager.setScene() 自动处理持久化实体迁移
- 添加完整的中英文文档和 21 个测试用例
2025-12-05 22:46:53 +08:00
YHH 3d5fcc1a55 feat(editor-core): 添加用户系统自动注册功能 (#283)
* feat(editor-core): 添加用户系统自动注册功能

- IUserCodeService 新增 registerSystems/unregisterSystems/getRegisteredSystems 方法
- UserCodeService 实现系统检测、实例化和场景注册逻辑
- ServiceRegistry 在预览开始时注册用户系统,停止时移除
- 热更新时自动重新加载用户系统
- 更新 System 脚本模板添加 @ECSSystem 装饰器

* feat(editor-core): 添加编辑器脚本支持(Inspector/Gizmo)

- registerEditorExtensions 实际注册用户 Inspector 和 Gizmo
- 添加 unregisterEditorExtensions 方法
- ServiceRegistry 在项目加载时编译并加载编辑器脚本
- 项目关闭时自动清理编辑器扩展
- 添加 Inspector 和 Gizmo 脚本创建模板
2025-12-05 18:28:11 +08:00
YHH 823e0c1d94 feat(engine-core): 添加统一输入系统 (#282)
* perf(core): 优化 EntitySystem 迭代性能,添加 CommandBuffer 延迟命令

ReactiveQuery 快照优化:
- 添加快照机制,避免每帧拷贝数组
- 只在实体列表变化时创建新快照
- 静态场景下多个系统共享同一快照

CommandBuffer 延迟命令系统:
- 支持延迟添加/移除组件、销毁实体、设置实体激活状态
- 每个系统拥有独立的 commands 属性
- 命令在帧末统一执行,避免迭代过程中修改实体列表

Scene 更新:
- 在 lateUpdate 后自动刷新所有系统的命令缓冲区

文档:
- 更新系统文档,添加 CommandBuffer 使用说明

* fix(ci): upgrade first-interaction action to v1.3.0

Fix Docker build failure in welcome workflow.

* fix(ci): upgrade pnpm/action-setup to v4 and fix unused import

- Upgrade pnpm/action-setup@v2 to v4 in all workflow files
- Remove unused CommandType import in CommandBuffer.test.ts

* fix(ci): remove duplicate pnpm version specification

* feat(engine-core): 添加统一输入系统

添加完整的输入系统,支持平台抽象:

- IPlatformInputSubsystem: 扩展接口支持键盘/鼠标/滚轮事件
- WebInputSubsystem: 浏览器实现,支持事件绑定/解绑
- InputManager: 全局输入状态管理器(键盘、鼠标、触摸)
- InputSystem: ECS 系统,连接平台事件到 InputManager
- GameRuntime 集成: 自动创建 InputSystem 并绑定平台子系统

使用方式:
```typescript
import { Input, MouseButton } from '@esengine/engine-core';

if (Input.isKeyDown('KeyW')) { /* 移动 */ }
if (Input.isKeyJustPressed('Space')) { /* 跳跃 */ }
if (Input.isMouseButtonDown(MouseButton.Left)) { /* 射击 */ }
```

* fix(runtime-core): 添加缺失的 platform-common 依赖

* fix(runtime-core): 移除 platform-web 依赖避免循环依赖

* fix(runtime-core): 使用工厂函数注入 InputSubsystem 避免循环依赖

- BrowserPlatformAdapter 通过 inputSubsystemFactory 配置接收输入子系统
- 在 IPlatformInputSubsystem 接口添加可选的 dispose 方法
- 移除对 @esengine/platform-web 的直接依赖
2025-12-05 18:15:50 +08:00
YHH 13a149c3a2 perf(core): 优化 EntitySystem 迭代性能,添加 CommandBuffer 延迟命令 (#281)
* perf(core): 优化 EntitySystem 迭代性能,添加 CommandBuffer 延迟命令

ReactiveQuery 快照优化:
- 添加快照机制,避免每帧拷贝数组
- 只在实体列表变化时创建新快照
- 静态场景下多个系统共享同一快照

CommandBuffer 延迟命令系统:
- 支持延迟添加/移除组件、销毁实体、设置实体激活状态
- 每个系统拥有独立的 commands 属性
- 命令在帧末统一执行,避免迭代过程中修改实体列表

Scene 更新:
- 在 lateUpdate 后自动刷新所有系统的命令缓冲区

文档:
- 更新系统文档,添加 CommandBuffer 使用说明

* fix(ci): upgrade first-interaction action to v1.3.0

Fix Docker build failure in welcome workflow.

* fix(ci): upgrade pnpm/action-setup to v4 and fix unused import

- Upgrade pnpm/action-setup@v2 to v4 in all workflow files
- Remove unused CommandType import in CommandBuffer.test.ts

* fix(ci): remove duplicate pnpm version specification
2025-12-05 17:24:33 +08:00
github-actions[bot] dd130eacb0 chore(editor): bump version to 1.0.14 (#280)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-12-05 16:45:52 +08:00
YHH d0238add2d fix: 当 esbuild 未打包时创建占位文件避免 Tauri 构建失败 (#276) 2025-12-05 16:24:26 +08:00
yhh fe96d72ac6 docs: 补充 v2.2.21 changelog 中遗漏的迭代安全修复 (#272) 2025-12-05 16:17:18 +08:00
yhh b2b8df9340 chore(core): release v2.2.21
- 优化 HierarchySystem 性能 (#279)
- 更新 changelog
2025-12-05 16:10:24 +08:00
YHH 2d56eaf11a perf(core): 优化 HierarchySystem 避免每帧遍历所有实体 (#279)
使用脏实体集合代替每帧遍历所有实体,静态场景下 process() 从 O(n) 优化为 O(1)。

性能提升:
- 1000 实体静态场景: 81.79μs -> 0.07μs (快 1168 倍)
- 10000 实体静态场景: 939.43μs -> 0.56μs (快 1677 倍)
- 服务端模拟 (100房间 x 100实体): 2.7ms -> 1.4ms 每 tick

改动:
- 新增 dirtyEntities Set 追踪需要更新缓存的实体
- process() 只遍历脏实体
- markCacheDirty() 将实体加入脏集合
- onAdded() 在实体注册时将脏实体加入集合
- onRemoved() 将实体从脏集合移除
2025-12-05 16:07:53 +08:00
YHH 2cb9c471f9 fix(docs): 修正 v2.2.16 组件生命周期描述 (#278) 2025-12-05 16:01:07 +08:00
YHH e8fc7f497b docs: 添加 core 库更新日志 (v2.2.16 - v2.2.20) (#277) 2025-12-05 15:10:14 +08:00
YHH 6702f0bfad feat(editor): 完善用户代码热更新和环境检测 (#275)
* fix: 更新 bundle-runtime 脚本使用正确的 platform-web 输出文件

原脚本引用的 runtime.browser.js 不存在,改为使用 index.mjs

* feat(editor): 完善用户代码热更新和环境检测

## 热更新改进
- 添加 hotReloadInstances() 方法,通过更新原型链实现真正的热更新
- 组件实例保留数据,仅更新方法
- ComponentRegistry 支持热更新时替换同名组件类

## 环境检测
- 启动时检测 esbuild 可用性
- 在启动页面底部显示环境状态指示器
- 添加 check_environment Rust 命令和前端 API

## esbuild 打包
- 将 esbuild 二进制文件打包到应用中
- 用户无需全局安装 esbuild
- 支持 Windows/macOS/Linux 平台

## 文件监视优化
- 添加 300ms 防抖,避免重复编译
- 修复路径分隔符混合问题

## 资源打包修复
- 修复 Tauri 资源配置,保留 engine 目录结构
- 添加 src-tauri/bin/ 和 src-tauri/engine/ 到 gitignore

* fix: 将热更新模式改为可选,修复测试失败

- ComponentRegistry 添加 hotReloadEnabled 标志,默认禁用
- 只有启用热更新模式时才会替换同名组件类
- 编辑器环境自动启用热更新模式
- reset() 方法中重置热更新标志

* test: 添加热更新模式的测试用例
2025-12-05 14:24:09 +08:00
YHH d7454e3ca4 feat(engine): 添加编辑器模式标志控制编辑器UI显示 (#274)
* feat(engine): 添加编辑器模式标志控制编辑器UI显示

- 在 Rust 引擎中添加 isEditor 标志,控制网格、gizmos、坐标轴指示器的显示
- 运行时模式下自动隐藏所有编辑器专用 UI
- 编辑器预览和浏览器运行时通过 setEditorMode(false) 禁用编辑器 UI
- 添加 Scene.isEditorMode 延迟组件生命周期回调,直到 begin() 调用
- 修复用户组件注册到 Core ComponentRegistry 以支持序列化
- 修复 Run in Browser 时用户组件加载问题

* fix: 复制引擎模块的类型定义文件到 dist/engine

* fix: 修复用户项目 tsconfig paths 类型定义路径

- 从 module.json 读取实际包名而不是使用目录名
- 修复 .d.ts 文件复制逻辑,支持 .mjs 扩展名
2025-12-04 22:43:26 +08:00
YHH 0d9bab910e feat(editor): 实现用户脚本编译加载和自动重编译 (#273) 2025-12-04 19:32:51 +08:00
YHH 3d16bbdc64 fix: 修复 process/lateProcess 迭代时组件变化导致跳过实体的问题 (#272)
- 在 update() 和 lateUpdate() 中创建实体数组副本,防止迭代过程中数组被修改
- lateUpdate() 现在重新查询实体以获取 update 阶段添加的新实体
- 添加 lawn-mower-demo 场景测试用例验证修复
- 更新中英文文档说明 onAdded/onRemoved 同步调用时机和 process/lateProcess 安全性
2025-12-04 15:11:01 +08:00
YHH b4e7ba2abd fix: 修复项目切换时运行时和系统重复初始化问题 (#267)
* feat(editor): 添加 GitHub Discussions 社区论坛功能

* chore: 更新 pnpm-lock.yaml

* chore: 删除测试图片

* refactor: 改用 Imgur 图床上传图片

* fix: 修复项目切换时运行时和系统重复初始化问题

* fix: 修复多个编辑器问题

* feat: 添加脚本编辑器配置和类型定义支持

* feat: 实现资产 .meta 文件自动生成功能
2025-12-04 14:04:39 +08:00
github-actions[bot] 374b26f7c6 chore(core): release v2.2.20 (#271)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-12-04 13:01:47 +08:00
YHH dbebb4f4fb fix: 修复系统 onAdded 回调受注册顺序影响的问题 (#270) 2025-12-04 12:56:19 +08:00
github-actions[bot] eec89b626c chore(core): release v2.2.19 (#268)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-12-04 11:36:12 +08:00
yhh 763d23e960 fix: 改用 Imgur 图床并删除测试图片 2025-12-04 09:57:33 +08:00
YHH 3b56ed17fe feat(editor): 添加 GitHub Discussions 社区论坛功能 (#266)
* feat(editor): 添加 GitHub Discussions 社区论坛功能

* chore: 更新 pnpm-lock.yaml
2025-12-04 09:51:04 +08:00
YHH 4b8d22ac32 Upload forum image: 1764812524764-ic2nic.png 2025-12-04 09:42:06 +08:00
YHH 9cd873da14 Merge pull request #260 from esengine/fix/docs-dead-links
fix(docs): 修复英文文档dead links问题
2025-12-03 23:02:48 +08:00
yhh c1799bf7b3 fix(docs): 修复英文文档dead links问题 2025-12-03 23:01:31 +08:00
YHH 85be826b62 Merge pull request #259 from esengine/feat/docs-i18n-clean
feat(docs): 添加中英文国际化支持
2025-12-03 22:51:54 +08:00
yhh dd1ae97de7 feat(docs): 添加中英文国际化支持 2025-12-03 22:48:22 +08:00
YHH 63f006ab62 feat: 添加跨平台运行时、资产系统和UI适配功能 (#256)
* feat(platform-common): 添加WASM加载器和环境检测API

* feat(rapier2d): 新增Rapier2D WASM绑定包

* feat(physics-rapier2d): 添加跨平台WASM加载器

* feat(asset-system): 添加运行时资产目录和bundle格式

* feat(asset-system-editor): 新增编辑器资产管理包

* feat(editor-core): 添加构建系统和模块管理

* feat(editor-app): 重构浏览器预览使用import maps

* feat(platform-web): 添加BrowserRuntime和资产读取

* feat(engine): 添加材质系统和着色器管理

* feat(material): 新增材质系统和着色器编辑器

* feat(tilemap): 增强tilemap编辑器和动画系统

* feat(modules): 添加module.json配置

* feat(core): 添加module.json和类型定义更新

* chore: 更新依赖和构建配置

* refactor(plugins): 更新插件模板使用ModuleManifest

* chore: 添加第三方依赖库

* chore: 移除BehaviourTree-ai和ecs-astar子模块

* docs: 更新README和文档主题样式

* fix: 修复Rust文档测试和添加rapier2d WASM绑定

* fix(tilemap-editor): 修复画布高DPI屏幕分辨率适配问题

* feat(ui): 添加UI屏幕适配系统(CanvasScaler/SafeArea)

* fix(ecs-engine-bindgen): 添加缺失的ecs-framework-math依赖

* fix: 添加缺失的包依赖修复CI构建

* fix: 修复CodeQL检测到的代码问题

* fix: 修复构建错误和缺失依赖

* fix: 修复类型检查错误

* fix(material-system): 修复tsconfig配置支持TypeScript项目引用

* fix(editor-core): 修复Rollup构建配置添加tauri external

* fix: 修复CodeQL检测到的代码问题

* fix: 修复CodeQL检测到的代码问题
2025-12-03 22:15:22 +08:00
YHH caf7622aa0 Merge pull request #257 from esengine/feat/system-stable-sorting
feat(ecs): 添加系统稳定排序支持
2025-12-03 21:01:52 +08:00
yhh d746cf3bb8 feat(ecs): 添加系统稳定排序支持 2025-12-03 20:54:34 +08:00
github-actions[bot] 88af781d78 chore(editor): bump version to 1.0.13 (#255)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-12-02 00:07:52 +08:00
yhh 15d5d37e50 fix(docs): 修复 hierarchy.md 中的死链接
将不存在的 ./transform.md 链接替换为 ./component.md
2025-12-01 23:36:20 +08:00
imgbot[bot] b9aaf894d7 [ImgBot] Optimize images (#252)
*Total -- 1,159.60kb -> 862.13kb (25.65%)

/screenshots/main_screetshot.png -- 175.29kb -> 84.97kb (51.52%)
/screenshots/settings.png -- 44.17kb -> 25.59kb (42.06%)
/screenshots/plugin_manager.png -- 60.70kb -> 37.42kb (38.35%)
/screenshots/about.png -- 32.89kb -> 23.61kb (28.21%)
/screenshots/performance_profiler.png -- 564.36kb -> 420.67kb (25.46%)
/packages/editor-app/src-tauri/icons/128x128.png -- 4.76kb -> 4.40kb (7.55%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-512@2x.png -- 58.30kb -> 54.30kb (6.86%)
/packages/editor-app/src-tauri/icons/Square107x107Logo.png -- 3.96kb -> 3.73kb (5.75%)
/packages/editor-app/src-tauri/icons/Square142x142Logo.png -- 5.44kb -> 5.13kb (5.69%)
/packages/editor-app/src-tauri/icons/android/mipmap-xhdpi/ic_launcher.png -- 3.16kb -> 2.98kb (5.69%)
/packages/editor-app/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_round.png -- 3.16kb -> 2.98kb (5.69%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-40x40@2x-1.png -- 2.61kb -> 2.47kb (5.35%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-40x40@2x.png -- 2.61kb -> 2.47kb (5.35%)
/packages/editor-app/src-tauri/icons/android/mipmap-mdpi/ic_launcher_foreground.png -- 4.06kb -> 3.87kb (4.73%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher.png -- 7.68kb -> 7.34kb (4.41%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_round.png -- 7.68kb -> 7.34kb (4.41%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-40x40@3x.png -- 4.58kb -> 4.38kb (4.33%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-60x60@2x.png -- 4.58kb -> 4.38kb (4.33%)
/packages/editor-app/src-tauri/icons/64x64.png -- 2.11kb -> 2.02kb (4.21%)
/packages/editor-app/src-tauri/icons/Square310x310Logo.png -- 13.92kb -> 13.36kb (4.04%)
/packages/editor-app/src-tauri/icons/Square89x89Logo.png -- 2.99kb -> 2.87kb (3.95%)
/packages/editor-app/src-tauri/icons/Square284x284Logo.png -- 12.53kb -> 12.04kb (3.89%)
/packages/editor-app/src-tauri/icons/Square150x150Logo.png -- 5.84kb -> 5.62kb (3.83%)
/packages/editor-app/src-tauri/icons/icon.png -- 25.58kb -> 24.61kb (3.81%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-83.5x83.5@2x.png -- 6.73kb -> 6.47kb (3.75%)
/packages/editor-app/src-tauri/icons/android/mipmap-hdpi/ic_launcher_foreground.png -- 6.27kb -> 6.03kb (3.72%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_foreground.png -- 14.68kb -> 14.15kb (3.59%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-76x76@2x.png -- 6.06kb -> 5.85kb (3.51%)
/packages/editor-app/src-tauri/icons/128x128@2x.png -- 10.88kb -> 10.53kb (3.21%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher.png -- 5.66kb -> 5.48kb (3.21%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxhdpi/ic_launcher_round.png -- 5.66kb -> 5.48kb (3.21%)
/packages/editor-app/src-tauri/icons/android/mipmap-xhdpi/ic_launcher_foreground.png -- 9.02kb -> 8.78kb (2.74%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-60x60@3x.png -- 7.22kb -> 7.02kb (2.65%)
/packages/editor-app/src-tauri/icons/android/mipmap-xxxhdpi/ic_launcher_foreground.png -- 20.92kb -> 20.40kb (2.49%)
/packages/editor-app/src-tauri/icons/Square71x71Logo.png -- 2.38kb -> 2.33kb (1.81%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-76x76@1x.png -- 2.52kb -> 2.47kb (1.79%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-20x20@3x.png -- 2.01kb -> 1.98kb (1.46%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-29x29@3x.png -- 2.84kb -> 2.81kb (1.1%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-29x29@2x-1.png -- 1.91kb -> 1.89kb (0.82%)
/packages/editor-app/src-tauri/icons/ios/AppIcon-29x29@2x.png -- 1.91kb -> 1.89kb (0.82%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
Co-authored-by: ImgBotApp <ImgBotHelp@gmail.com>
Co-authored-by: YHH <359807859@qq.com>
2025-12-01 23:34:47 +08:00
YHH 460cdb5af4 Feature/docs improvement (#254)
* refactor: 编辑器/运行时架构拆分与构建系统升级

* feat(core): 层级系统重构与UI变换矩阵修复

* refactor: 移除 ecs-components 聚合包并修复跨包组件查找问题

* fix(physics): 修复跨包组件类引用问题

* feat: 统一运行时架构与浏览器运行支持

* feat(asset): 实现浏览器运行时资产加载系统

* fix: 修复文档、CodeQL安全问题和CI类型检查错误

* fix: 修复文档、CodeQL安全问题和CI类型检查错误

* fix: 修复文档、CodeQL安全问题、CI类型检查和测试错误

* test: 补齐核心模块测试用例,修复CI构建配置

* fix: 修复测试用例中的类型错误和断言问题

* fix: 修复 turbo build:npm 任务的依赖顺序问题

* fix: 修复 CI 构建错误并优化构建性能

* feat(docs): 重构文档站主题样式

* chore(ci): 升级所有 workflow 的 pnpm 版本从 v8 到 v10
2025-12-01 23:33:04 +08:00
github-actions[bot] 290bd9858e chore(core): release v2.2.18 (#253)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-12-01 22:34:05 +08:00
YHH b42a7b4e43 Feature/editor optimization (#251)
* refactor: 编辑器/运行时架构拆分与构建系统升级

* feat(core): 层级系统重构与UI变换矩阵修复

* refactor: 移除 ecs-components 聚合包并修复跨包组件查找问题

* fix(physics): 修复跨包组件类引用问题

* feat: 统一运行时架构与浏览器运行支持

* feat(asset): 实现浏览器运行时资产加载系统

* fix: 修复文档、CodeQL安全问题和CI类型检查错误

* fix: 修复文档、CodeQL安全问题和CI类型检查错误

* fix: 修复文档、CodeQL安全问题、CI类型检查和测试错误

* test: 补齐核心模块测试用例,修复CI构建配置

* fix: 修复测试用例中的类型错误和断言问题

* fix: 修复 turbo build:npm 任务的依赖顺序问题

* fix: 修复 CI 构建错误并优化构建性能
2025-12-01 22:28:51 +08:00
github-actions[bot] 189714c727 chore(editor): bump version to 1.0.12 (#250)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-30 01:07:19 +08:00
YHH 987051acd4 Feature/advanced profiler (#249)
* feat(profiler): 实现高级性能分析器

* test(core): 添加 ProfilerSDK 和 AdvancedProfilerCollector 测试覆盖

* test(core): 添加 ProfilerSDK 和 AdvancedProfilerCollector 测试覆盖

* test(core): 添加 ProfilerSDK 和 AdvancedProfilerCollector 测试覆盖
2025-11-30 00:53:01 +08:00
YHH 374e08a79e feat(profiler): 实现高级性能分析器 (#248)
* feat(profiler): 实现高级性能分析器

* test(core): 添加 ProfilerSDK 和 AdvancedProfilerCollector 测试覆盖

* test(core): 添加 ProfilerSDK 和 AdvancedProfilerCollector 测试覆盖
2025-11-30 00:22:47 +08:00
YHH 359886c72f Feature/physics and tilemap enhancement (#247)
* feat(behavior-tree,tilemap): 修复编辑器连线缩放问题并增强插件系统

* feat(node-editor,blueprint): 新增通用节点编辑器和蓝图可视化脚本系统

* feat(editor,tilemap): 优化编辑器UI样式和Tilemap编辑器功能

* fix: 修复CodeQL安全警告和CI类型检查错误

* fix: 修复CodeQL安全警告和CI类型检查错误

* fix: 修复CodeQL安全警告和CI类型检查错误
2025-11-29 23:00:48 +08:00
yhh f03b73b58e docs: 完善装饰器和 Matcher API 文档 2025-11-28 11:03:34 +08:00
github-actions[bot] 18d20df4da chore(core): release v2.2.17 (#246)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-28 11:03:11 +08:00
github-actions[bot] c5642a8605 chore(editor): bump version to 1.0.11 (#245)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-28 11:01:04 +08:00
YHH 673f5e5855 feat(physics): 集成 Rapier2D 物理引擎并修复预览重置问题 (#244)
* feat(physics): 集成 Rapier2D 物理引擎并修复预览重置问题

* fix: 修复 CI 流程并清理代码
2025-11-28 10:32:28 +08:00
YHH cabb625a17 Feature/UI input system fix (#243)
* feat(ui): 实现编辑器预览模式下的 UI 输入系统

* feat(platform-web): 为浏览器运行时添加 UI 输入系统绑定
2025-11-27 22:31:05 +08:00
github-actions[bot] b8f05b79b0 chore(core): release v2.2.16 (#242)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-27 21:13:09 +08:00
github-actions[bot] b22faaac86 chore(editor): bump version to 1.0.10 (#241)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-27 21:05:40 +08:00
YHH 107439d70c Feature/runtime cdn and plugin loader (#240)
* feat(ui): 完善 UI 布局系统和编辑器可视化工具

* refactor: 移除 ModuleRegistry,统一使用 PluginManager 插件系统

* fix: 修复 CodeQL 警告并提升测试覆盖率

* refactor: 分离运行时入口点,解决 runtime bundle 包含 React 的问题

* fix(ci): 添加 editor-core 和 editor-runtime 到 CI 依赖构建步骤

* docs: 完善 ServiceContainer 文档,新增 Symbol.for 模式和 @InjectProperty 说明

* fix(ci): 修复 type-check 失败问题

* fix(ci): 修复类型检查失败问题

* fix(ci): 修复类型检查失败问题

* fix(ci): behavior-tree 构建添加 @tauri-apps 外部依赖

* fix(ci): behavior-tree 添加 @tauri-apps/plugin-fs 类型依赖

* fix(ci): platform-web 添加缺失的 behavior-tree 依赖

* fix(lint): 移除正则表达式中不必要的转义字符
2025-11-27 20:42:46 +08:00
github-actions[bot] 71869b1a58 chore(editor): bump version to 1.0.9 (#239)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-26 11:47:09 +08:00
yhh 9aed3134cf fix(ci): 修复 Windows 上 mkdir 命令报错 2025-11-26 11:28:14 +08:00
yhh 3ff57aff37 fix(ci): 修复 release-editor workflow 构建顺序 2025-11-26 11:22:43 +08:00
yhh 152c0541b8 fix(ci): 修复 release-editor workflow 构建顺序 2025-11-26 11:15:38 +08:00
YHH 7b14fa2da4 feat(editor): 添加 ECS UI 系统和编辑器更新优化 (#238) 2025-11-26 11:08:10 +08:00
YHH 3fb6f919f8 Feature/tilemap editor (#237)
* feat: 添加 Tilemap 编辑器插件和组件生命周期支持

* feat(editor-core): 添加声明式插件注册 API

* feat(editor-core): 改进tiledmap结构合并tileset进tiledmapeditor

* feat: 添加 editor-runtime SDK 和插件系统改进

* fix(ci): 修复SceneResourceManager里变量未使用问题
2025-11-25 22:23:19 +08:00
github-actions[bot] 551ca7805d chore(core): release v2.2.15 (#236)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-23 22:52:05 +08:00
yhh 8ab25fe293 fix(ci): 使用纯 bash+node 实现版本更新绕过 workspace 协议问题 2025-11-23 22:49:54 +08:00
yhh eea7ed9e58 fix(ci): 将 npm version 改为 pnpm version 修复 workspace 协议问题 2025-11-23 22:46:21 +08:00
yhh 0279cf6d27 fix(ci): 使用 pnpm publish 修复 workspace:* 协议不支持的问题 2025-11-23 22:42:23 +08:00
yhh 0dff1ad2ad fix(ci): 修复 npm 发布时 workspace:* 协议不支持的问题 2025-11-23 22:36:54 +08:00
yhh 95fbcca66f chore: 移除渲染系统调试日志 2025-11-23 22:26:46 +08:00
github-actions[bot] a61baa83a7 chore(editor): bump version to 1.0.8 (#235)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-23 22:21:20 +08:00
yhh afebeecd68 fix(ci): 修复 Tauri 构建缺少 runtime 文件的问题 2025-11-23 22:08:38 +08:00
yhh f4e9925319 fix(ci): 修复 Tauri 构建缺少 runtime 文件的问题 2025-11-23 21:57:10 +08:00
YHH 32460ac133 feat(editor): 优化编辑器UI和改进核心功能 (#234)
* feat(editor): 优化编辑器UI和改进核心功能

* feat(editor): 优化编辑器UI和改进核心功能
2025-11-23 21:45:10 +08:00
github-actions[bot] 4d95a7f044 chore(editor): bump version to 1.0.7 (#233)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-23 16:30:14 +08:00
yhh 57f919fbe0 fix(ci): 移除release-editor工作流中有问题的TypeScript缓存步骤 2025-11-23 16:12:42 +08:00
yhh 1cb9a0e58f fix(ci): 修复release-editor工作流hashFiles语法错误 2025-11-23 15:47:23 +08:00
yhh 1da43ee822 fix: 修复 release-editor workflow 构建问题 2025-11-23 15:26:17 +08:00
yhh f4c7563763 chore: 移除 network 相关包并修复 CI 问题 2025-11-23 15:13:51 +08:00
YHH a3f7cc38b1 Feature/render pipeline (#232)
* refactor(engine): 重构2D渲染管线坐标系统

* feat(engine): 完善2D渲染管线和编辑器视口功能

* feat(editor): 实现Viewport变换工具系统

* feat(editor): 优化Inspector渲染性能并修复Gizmo变换工具显示

* feat(editor): 实现Run on Device移动预览功能

* feat(editor): 添加组件属性控制和依赖关系系统

* feat(editor): 实现动画预览功能和优化SpriteAnimator编辑器

* feat(editor): 修复SpriteAnimator动画预览功能并迁移CI到pnpm

* feat(editor): 修复SpriteAnimator动画预览并迁移到pnpm

* feat(editor): 修复SpriteAnimator动画预览并迁移到pnpm

* feat(editor): 修复SpriteAnimator动画预览并迁移到pnpm

* feat(editor): 修复SpriteAnimator动画预览并迁移到pnpm

* feat(ci): 迁移项目到pnpm并修复CI构建问题

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 迁移CI工作流到pnpm并添加WASM构建支持

* chore: 移除 network 相关包

* chore: 移除 network 相关包
2025-11-23 14:49:37 +08:00
github-actions[bot] b15cbab313 chore(editor): bump version to 1.0.6 (#231)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-21 12:42:30 +08:00
yhh 504b9ffb66 fix(ci): 添加编辑器工作流缺失的引擎构建步骤 2025-11-21 11:53:33 +08:00
github-actions[bot] 6226e3ff06 chore(core): release v2.2.14 (#230)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-21 11:40:22 +08:00
YHH 2621d7f659 refactor(core): 移除@Inject参数装饰器,统一使用@InjectProperty (#229)
* refactor(core): 移除@Inject参数装饰器,统一使用@InjectProperty

* refactor(core): 移除@Inject参数装饰器,统一使用@InjectProperty
2025-11-21 11:37:55 +08:00
YHH a768b890fd feat: 集成Rust WASM渲染引擎与TypeScript ECS框架 (#228)
* feat: 集成Rust WASM渲染引擎与TypeScript ECS框架

* feat: 增强编辑器UI功能与跨平台支持

* fix: 修复CI测试和类型检查问题

* fix: 修复CI问题并提高测试覆盖率

* fix: 修复CI问题并提高测试覆盖率
2025-11-21 10:03:18 +08:00
yhh 8b9616837d style(editor-app): 移除log信息 2025-11-20 09:51:29 +08:00
yhh 0d2948e60c feat(tools): rust工具初始化工具 2025-11-19 16:27:11 +08:00
YHH ecfef727c8 feat: 实现可扩展的字段编辑器系统与专业资产选择器 (#227) 2025-11-19 14:54:03 +08:00
YHH caed5428d5 refactor(editor-app): 改进架构和类型安全 (#226)
* refactor(editor-app): 改进架构和类型安全

* refactor(editor-app): 开始拆分 Inspector.tsx - 创建基础架构

* refactor(editor-app): 完成 Inspector.tsx 拆分

* refactor(editor-app): 优化 Inspector 类型定义,消除所有 any 使用

* refactor(editor): 实现可扩展的属性渲染器系统

* Potential fix for code scanning alert no. 231: Unused variable, import, function or class

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* fix(ci): 防止 Codecov 服务故障阻塞 CI 流程

---------

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
2025-11-18 22:28:13 +08:00
YHH bce3a6e253 refactor(editor): 提取行为树编辑器为独立包并重构编辑器架构 (#216)
* refactor(editor): 提取行为树编辑器为独立包并重构编辑器架构

* feat(editor): 添加插件市场功能

* feat(editor): 重构插件市场以支持版本管理和ZIP打包

* feat(editor): 重构插件发布流程并修复React渲染警告

* fix(plugin): 修复插件发布和市场的路径不一致问题

* feat: 重构插件发布流程并添加插件删除功能

* fix(editor): 完善插件删除功能并修复多个关键问题

* fix(auth): 修复自动登录与手动登录的竞态条件问题

* feat(editor): 重构插件管理流程

* feat(editor): 支持 ZIP 文件直接发布插件

- 新增 PluginSourceParser 解析插件源
- 重构发布流程支持文件夹和 ZIP 两种方式
- 优化发布向导 UI

* feat(editor): 插件市场支持多版本安装

- 插件解压到项目 plugins 目录
- 新增 Tauri 后端安装/卸载命令
- 支持选择任意版本安装
- 修复打包逻辑,保留完整 dist 目录结构

* feat(editor): 个人中心支持多版本管理

- 合并同一插件的不同版本
- 添加版本历史展开/折叠功能
- 禁止有待审核 PR 时更新插件

* fix(editor): 修复 InspectorRegistry 服务注册

- InspectorRegistry 实现 IService 接口
- 注册到 Core.services 供插件使用

* feat(behavior-tree-editor): 完善插件注册和文件操作

- 添加文件创建模板和操作处理器
- 实现右键菜单创建行为树功能
- 修复文件读取权限问题(使用 Tauri 命令)
- 添加 BehaviorTreeEditorPanel 组件
- 修复 rollup 配置支持动态导入

* feat(plugin): 完善插件构建和发布流程

* fix(behavior-tree-editor): 完整恢复编辑器并修复 Toast 集成

* fix(behavior-tree-editor): 修复节点选中、连线跟随和文件加载问题并优化性能

* fix(behavior-tree-editor): 修复端口连接失败问题并优化连线样式

* refactor(behavior-tree-editor): 移除调试面板功能简化代码结构

* refactor(behavior-tree-editor): 清理冗余代码合并重复逻辑

* feat(behavior-tree-editor): 完善编辑器核心功能增强扩展性

* fix(lint): 修复ESLint错误确保CI通过

* refactor(behavior-tree-editor): 优化编辑器工具栏和编译器功能

* refactor(behavior-tree-editor): 清理技术债务,优化代码质量

* fix(editor-app): 修复字符串替换安全问题
2025-11-18 14:46:51 +08:00
YHH eac660b1a0 refactor(core): 统一参数命名 - worldId/sceneId 改为 worldName/sceneName (#225)
* refactor(core): 统一参数命名 - worldId/sceneId 改为 worldName/sceneName

* test(core): 更新测试用例以匹配新的错误消息

* refactor(core): 提高代码覆盖率 - 添加参数验证和测试
2025-11-15 00:20:17 +08:00
github-actions[bot] af49870084 chore(core): release v2.2.13 (#224)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-14 12:13:47 +08:00
YHH e2b316b3cc Fix/entity system dispose ondestroy (#223)
* fix(core): 修复 EntitySystem dispose 未调用 onDestroy 导致资源泄漏

* fix(core): 修复 Scene.end() 中 unload 调用时机导致用户无法清理资源
2025-11-14 12:10:59 +08:00
YHH 3a0544629d feat(core): 为 World 添加独立的服务容器 (#222)
* feat(core): 为 World 添加独立的服务容器

* test(core): 为 World 服务容器添加完整测试覆盖
2025-11-14 09:55:31 +08:00
LINGYE 609baace73 fix(logger): 移除自定义 factory 的缓存, 由使用方管理 (#221)
* fix(logger): 移除自定义 factory 的缓存, 由使用方管理

* test
2025-11-13 16:53:07 +08:00
LINGYE b12cfba353 refactor(core): 移除 _activeWorlds 并优化 WorldManager 清理机制 (#220)
* refactor(core): 将 WorldManager 清理机制从定时器改为帧驱动

* refactor(core): 移除 WorldManager _activeWorlds 优化,简化状态管理

* test(core): 补充 WorldManager 测试用例

* docs(core): 更新 WorldManager cleanupFrameInterval 配置说明
2025-11-09 17:35:07 +08:00
LINGYE 6242c6daf3 fix(core): 修复 PerformanceMonitor 未遵循 Core debug 参数的问题 (#219)
- Core 传递 debug 配置到 WorldManager
- WorldManager 传递 debug 配置到 World
- World 在 debug=true 时为 Scene 注册并启用 PerformanceMonitor
- new Scene 的情况默认未开启,但暴露了 `performanceMonitor` 由使用者处理
2025-11-09 11:32:04 +08:00
github-actions[bot] b5337de278 chore(core): release v2.2.12 (#218)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-11-07 12:12:44 +08:00
YHH 3512199ff4 fix(core): 移除fflate依赖,修复TextEncoder兼容性问题 (#217)
* fix(core): 移除fflate依赖,修复TextEncoder兼容性问题

* fix(core): 移除fflate依赖,修复TextEncoder兼容性问题
2025-11-07 12:10:52 +08:00
YHH e03b106652 refactor(editor): 优化布局管理和行为树文件处理 2025-11-04 23:53:26 +08:00
YHH f9afa22406 refactor(editor): 重构编辑器架构并增强行为树执行可视化 2025-11-04 18:29:28 +08:00
YHH adfc7e91b3 Refactor/clean architecture phase1 (#215)
* refactor(editor): 建立Clean Architecture领域模型层

* refactor(editor): 实现应用层架构 - 命令模式、用例和状态管理

* refactor(editor): 实现展示层核心Hooks

* refactor(editor): 实现基础设施层和展示层组件

* refactor(editor): 迁移画布和连接渲染到 Clean Architecture 组件

* feat(editor): 集成应用层架构和命令模式,实现撤销/重做功能

* refactor(editor): UI组件拆分

* refactor(editor): 提取快速创建菜单逻辑

* refactor(editor): 重构BehaviorTreeEditor,提取组件和Hook

* refactor(editor): 提取端口连接和键盘事件Hook

* refactor(editor): 提取拖放处理Hook

* refactor(editor): 提取画布交互Hook和工具函数

* refactor(editor): 完成核心重构

* fix(editor): 修复节点无法创建和连接

* refactor(behavior-tree,editor): 重构节点子节点约束系统,实现元数据驱动的架构
2025-11-03 21:22:16 +08:00
YHH 40cde9c050 fix(editor): 修复行为树删除连接时children数组未同步清理的bug (#214) 2025-11-03 09:57:18 +08:00
YHH ddc7a7750e Chore/lint fixes (#212)
* fix(eslint): 修复装饰器缩进配置

* fix(eslint): 修复装饰器缩进配置

* chore: 删除未使用的导入

* chore(lint): 移除未使用的导入和变量

* chore(lint): 修复editor-app中未使用的函数参数

* chore(lint): 修复未使用的赋值变量

* chore(eslint): 将所有错误级别改为警告以通过CI

* fix(codeql): 修复GitHub Advanced Security检测到的问题
2025-11-02 23:50:41 +08:00
YHH 50a01d9dd3 chore: 统一并强化ESLint配置规则 2025-11-02 12:45:47 +08:00
YHH 793aad0a5e chore: 移除旧版ESLint配置并更新子模块 2025-11-02 12:22:27 +08:00
YHH 9c1bf8dbed refactor(core): 移除全局EventBus,实现场景级事件隔离 (#211) 2025-11-01 18:19:23 +08:00
YHH 620f3eecc7 style(core): ESLint自动修复代码格式问题 (#210) 2025-11-01 17:41:50 +08:00
YHH 4355538d8d refactor(core): 重构Scene和Entity的代码质量,消除所有Lint警告 (#209) 2025-11-01 17:18:12 +08:00
YHH 3ad5dc9ca3 refactor(core): 改进事件系统类型安全并消除 ESLint 警告 (#208) 2025-11-01 16:12:18 +08:00
YHH 57c7e7be3f feat(core):统一 Core 库的命名规范和代码风格 (#207) 2025-11-01 10:23:46 +08:00
github-actions[bot] 6778ccace4 chore(editor): bump version to 1.0.5 (#201)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-31 17:42:41 +08:00
github-actions[bot] 1264232533 chore(behavior-tree): release v1.0.1 (#200)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-31 17:30:12 +08:00
YHH 61813e67b6 refactor(behavior-tree)!: 迁移到 Runtime 执行器架构 (#196)
* refactor(behavior-tree)!: 迁移到 Runtime 执行器架构

* fix(behavior-tree): 修复LogAction中的ReDoS安全漏洞

* feat(behavior-tree): 完善行为树核心功能并修复类型错误
2025-10-31 17:27:38 +08:00
YHH c58e3411fd feat(core): 启用 TypeScript 最严格的类型检查 (#199)
* feat(core):  启用 TypeScript 最严格的类型检查

* ci: 配置 Codecov 以适应类型安全改进

* fix(core): 修复 CodeQL 安全警告

* fix(core): eslint.config.mjs
2025-10-31 16:14:23 +08:00
LINGYE 011d795361 perf(core): 优化 Scene.systems getter 避免每帧重复排序 (#197) 2025-10-30 23:27:37 +08:00
YHH 3f40a04370 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-28 17:19:38 +08:00
YHH fc042bb7d9 feat(editor): 添加插件多语言支持 2025-10-28 17:19:28 +08:00
github-actions[bot] d051e52131 chore(core): release v2.2.11 (#195)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-28 14:12:56 +08:00
YHH fb4316aeb9 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-28 14:08:47 +08:00
YHH 683203919f refactor(core): 使用fflate替换msgpack以兼容小游戏环境 2025-10-28 14:08:34 +08:00
github-actions[bot] a0cddbcae6 chore(core): release v2.2.10 (#194)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-28 11:58:05 +08:00
YHH 4e81fc7eba fix(docs): 修复行为树文档中的死链接 2025-10-28 11:54:39 +08:00
YHH b410e2de47 fix(core): 移除TextEncoder依赖以兼容小游戏环境 2025-10-28 11:51:57 +08:00
YHH 9868c746e1 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-28 11:45:48 +08:00
YHH f0b4453a5f fix(behavior-tree): 修复插件节点执行问题并完善文档 2025-10-28 11:45:35 +08:00
github-actions[bot] 6b49471734 chore(editor-core): release v1.0.0 (#193)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-27 15:10:06 +08:00
YHH fe791e83a8 fix(ci): 添加--access public参数以支持发布公开scoped包 2025-10-27 15:08:00 +08:00
YHH edbc9eb27f ci(editor-core): 添加npm发布流程支持 2025-10-27 15:04:31 +08:00
github-actions[bot] 2f63034d9a chore(editor): bump version to 1.0.4 (#192)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
Co-authored-by: YHH <359807859@qq.com>
2025-10-27 10:25:27 +08:00
YHH dee0e0284a chore(behavior-tree): 移除CI测试脚本 2025-10-27 10:12:35 +08:00
YHH 890e591f2a fix(behavior-tree): 修复发布时缺少publishConfig导致的402错误 2025-10-27 10:07:00 +08:00
YHH cb6561e27b fix(ci): 修复首次发布时版本号未改变的错误 2025-10-27 10:03:14 +08:00
YHH 7ef70d7f9a Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-27 10:00:11 +08:00
YHH 86405c1dcd chore(ci): 禁用发布流程中的测试步骤 2025-10-27 10:00:02 +08:00
github-actions[bot] 60fa259285 chore(core): release v2.2.9 (#191)
Co-authored-by: esengine <18465053+esengine@users.noreply.github.com>
2025-10-27 09:56:54 +08:00
YHH 27f86eece2 chore(ci): 将semantic-release改为手动发布并支持patch/minor/major版本选择 2025-10-27 09:51:44 +08:00
YHH 4cee396ea9 chore(ci): 重构发布流程为手动触发方式并添加behavior-tree包发布支持 2025-10-27 09:47:59 +08:00
YHH d2ad295b48 chore: 移除Dependabot自动依赖更新配置 2025-10-27 09:36:03 +08:00
YHH 009f8af4e1 Feature/ecs behavior tree (#188)
* feat(behavior-tree): 完全 ECS 化的行为树系统

* feat(editor-app): 添加行为树可视化编辑器

* chore: 移除 Cocos Creator 扩展目录

* feat(editor-app): 行为树编辑器功能增强

* fix(editor-app): 修复 TypeScript 类型错误

* feat(editor-app): 使用 FlexLayout 重构面板系统并优化资产浏览器

* feat(editor-app): 改进编辑器UI样式并修复行为树执行顺序

* feat(behavior-tree,editor-app): 添加装饰器系统并优化编辑器性能

* feat(behavior-tree,editor-app): 添加属性绑定系统

* feat(editor-app,behavior-tree): 优化编辑器UI并改进行为树功能

* feat(editor-app,behavior-tree): 添加全局黑板系统并增强资产浏览器功能

* feat(behavior-tree,editor-app): 添加运行时资产导出系统

* feat(behavior-tree,editor-app): 添加SubTree系统和资产选择器

* feat(behavior-tree,editor-app): 优化系统架构并改进编辑器文件管理

* fix(behavior-tree,editor-app): 修复SubTree节点错误显示空节点警告

* fix(editor-app): 修复局部黑板类型定义文件扩展名错误
2025-10-27 09:29:11 +08:00
LINGYE 0cd99209c4 支持集成第三方日志库 (#190)
* 更新 ILogger 签名

改为纯可变参数兼容主流日志库

* 拆分日志类型与实现

* 新增 setLoggerFactory 方法

* tweak

* getLoggerName 返回类名,默认情况下子类无需重写

* 更新日志说明文档

* 增加测试

* 使用 getSystemInstanceTypeName,避免压缩导致获取类名不一致
2025-10-26 11:53:46 +08:00
YHH 3ea55303dc Merge pull request #187 from esengine/feature/complete-iscene-interface
feat(core): 完善 IScene 接口定义
2025-10-20 17:44:14 +08:00
YHH c458a5e036 chore(ci): 移除 pr-size-labeler workflow 2025-10-20 17:36:46 +08:00
YHH c511725d1f chore(ci): 移除 pr-agent 和 mergify 配置 2025-10-20 17:33:30 +08:00
YHH 3876d9b92b feat(core): 完善 IScene 接口定义 2025-10-20 17:24:56 +08:00
YHH f863c48ab0 feat(ci): 自动告知用户可使用 AI 助手 2025-10-19 10:13:03 +08:00
YHH 10096795a1 ci(deps): 优化 Dependabot 自动化流程减少维护负担 2025-10-19 10:03:35 +08:00
YHH 8b146c8d5f Merge pull request #161 from esengine/dependabot/npm_and_yarn/ws-8.18.3
chore(deps): bump ws from 8.18.2 to 8.18.3
2025-10-19 09:53:24 +08:00
YHH 1208c4ffeb Merge branch 'master' into dependabot/npm_and_yarn/ws-8.18.3 2025-10-19 09:48:30 +08:00
YHH ec5de97973 fix(ci): 换用 gpt-4o 模型解决 token 超限问题 2025-10-19 01:08:11 +08:00
YHH 0daa92cfb7 fix(ci): 优化 AI Issue Helper 避免 token 超限 2025-10-19 01:03:55 +08:00
YHH 130f466026 fix(ci): 修复 AI Issue Helper 的 MCP 配置和响应传递问题 2025-10-19 01:01:18 +08:00
YHH f93de87940 fix(ci): 修复 AI 响应包含代码时的 JavaScript 语法错误 2025-10-19 00:59:04 +08:00
YHH 367d97e9bb fix(ci): 修复 AI Issue Helper 的 prompt 文件读取问题 2025-10-19 00:55:47 +08:00
YHH 77701f214c fix(ci): AI Issue Helper 忽略机器人评论 2025-10-19 00:51:23 +08:00
YHH b5b64f8c41 feat(ci): 为 AI Issue Helper 添加代码检索功能 2025-10-19 00:43:40 +08:00
YHH ab04ad30f1 fix(ci): 修复 AI Issue Helper 的数据解析问题 2025-10-19 00:39:10 +08:00
YHH 330d9a6fdb fix(ci): 为 AI workflow 添加 models 权限 2025-10-19 00:33:12 +08:00
YHH e762343142 fix(ci): 修复 AI 工具 workflow 的 YAML 语法错误 2025-10-19 00:26:07 +08:00
YHH fce9e3d4d6 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-19 00:17:46 +08:00
YHH 0e5855ee4e ci: 添加 AI Issue 智能分析和批量处理工具 2025-10-19 00:16:05 +08:00
dependabot[bot] ba61737bc7 chore(deps): bump ws from 8.18.2 to 8.18.3
Bumps [ws](https://github.com/websockets/ws) from 8.18.2 to 8.18.3.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](https://github.com/websockets/ws/compare/8.18.2...8.18.3)

---
updated-dependencies:
- dependency-name: ws
  dependency-version: 8.18.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-18 16:16:01 +00:00
YHH bd7ea1f713 Merge pull request #173 from esengine/dependabot/npm_and_yarn/protobufjs-7.5.4
chore(deps): bump protobufjs from 7.5.3 to 7.5.4
2025-10-19 00:14:35 +08:00
YHH 1abd20edf5 Merge branch 'master' into dependabot/npm_and_yarn/protobufjs-7.5.4 2025-10-19 00:06:07 +08:00
YHH 496513c641 ci: 添加 AI 代码审查工具配置 2025-10-19 00:04:36 +08:00
YHH 848b637f45 docs: 增强 README可视化和统计展示 2025-10-18 23:45:34 +08:00
dependabot[bot] 39049601d4 chore(deps): bump protobufjs from 7.5.3 to 7.5.4
Bumps [protobufjs](https://github.com/protobufjs/protobuf.js) from 7.5.3 to 7.5.4.
- [Release notes](https://github.com/protobufjs/protobuf.js/releases)
- [Changelog](https://github.com/protobufjs/protobuf.js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/protobufjs/protobuf.js/compare/protobufjs-v7.5.3...protobufjs-v7.5.4)

---
updated-dependencies:
- dependency-name: protobufjs
  dependency-version: 7.5.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-18 15:30:56 +00:00
YHH e31cdd17d3 fix(ci): 修复 Mergify 配置语法错误 2025-10-18 23:13:14 +08:00
YHH 2a3f2d49b8 fix(ci): 放宽 commitlint scope 限制 2025-10-18 23:06:05 +08:00
YHH ca452889d7 chore(deps): 更新 package-lock.json 2025-10-18 22:44:55 +08:00
YHH 2df501ec07 ci: 添加自动化工具提升项目质量 2025-10-18 22:32:39 +08:00
YHH 6b1e6c6fdc fix(ci): 修复发布流程改为手动触发并包含 package-lock 2025-10-18 22:18:47 +08:00
YHH 570e970e1c chore: modernize project infrastructure 2025-10-18 22:06:27 +08:00
YHH f4e3505d52 规范项目标准,更改为MIT协议 2025-10-18 21:48:44 +08:00
YHH 9af2b9859a 新增deepwiki徽章 2025-10-18 21:16:17 +08:00
YHH d99d314621 Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-18 21:06:43 +08:00
YHH c5b8b18e33 显示自上个版本发布依赖的更新内容再pr里 2025-10-18 21:06:04 +08:00
YHH 7280265a64 core发布流程里的中文pr 2025-10-18 21:03:00 +08:00
YHH 35fa0ef884 Merge pull request #153 from esengine/release/core-v2.2.8
chore(core): Release v2.2.8
2025-10-18 21:00:39 +08:00
github-actions[bot] 9c778cb71b chore(core): bump version to 2.2.8 2025-10-18 12:59:36 +00:00
YHH 4a401744c1 更新core发布流程 2025-10-18 20:56:59 +08:00
YHH 5f6b2d4d40 更新core流程 2025-10-18 20:45:45 +08:00
YHH bf25218af2 新增发布core npm自动流程 2025-10-18 20:36:10 +08:00
YHH 1f7f9d9f84 修复端口没有跟随设置更改的问题 2025-10-18 20:21:43 +08:00
YHH 2be53a04e4 Merge pull request #152 from foxling/feature/world-manager-config
feat(core): 支持通过 Core.create() 配置 WorldManager 参数
2025-10-18 13:16:52 +08:00
LING YE 7f56ebc786 feat(core): 支持通过 Core.create() 配置 WorldManager 参数 2025-10-18 13:10:09 +08:00
YHH a801e4f50e Merge pull request #150 from esengine/issue-149-编辑器支持设置字体大小
支持字体设置大小
2025-10-17 23:47:42 +08:00
YHH a9f9ad9b94 支持字体设置大小 2025-10-17 23:47:04 +08:00
YHH 3cf1dab5b9 Merge pull request #148 from esengine/issue-147-Scene的构造函数不应该由用户传入性能分析器
performancemonitor由内部框架维护
2025-10-17 22:19:53 +08:00
YHH 63165bbbfc performancemonitor由内部框架维护 2025-10-17 22:13:32 +08:00
YHH 61caad2bef Merge pull request #146 from esengine/issue-132-场景序列化系统
更新图标及场景序列化系统
2025-10-17 18:17:56 +08:00
YHH b826bbc4c7 更新图标及场景序列化系统 2025-10-17 18:13:31 +08:00
YHH 2ce7dad8d8 Merge pull request #131 from esengine/release/editor-v1.0.3
chore(editor): Release v1.0.3
2025-10-16 23:53:37 +08:00
esengine dff400bf22 chore(editor): bump version to 1.0.3 2025-10-16 15:52:45 +00:00
YHH 27ce902344 配置createUpdaterArtifacts生成sig 2025-10-16 23:38:11 +08:00
YHH 33ee0a04c6 升级tauri-action 2025-10-16 23:20:55 +08:00
YHH d68f6922f8 Merge pull request #129 from esengine/release/editor-v1.0.1
chore(editor): Release v1.0.1
2025-10-16 23:09:26 +08:00
esengine f8539d7958 chore(editor): bump version to 1.0.1 2025-10-16 15:08:22 +00:00
YHH 14dc911e0a Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-10-16 22:55:09 +08:00
YHH deccb6bf84 修复editor再ci上版本冲突问题 2025-10-16 22:54:58 +08:00
YHH dacbfcae95 Merge pull request #127 from esengine/imgbot
[ImgBot] Optimize images
2025-10-16 22:49:51 +08:00
ImgBotApp 1b69ed17b7 [ImgBot] Optimize images
*Total -- 496.42kb -> 376.40kb (24.18%)

/screenshots/main_screetshot.png -- 179.18kb -> 121.90kb (31.97%)
/screenshots/performance_profiler.png -- 59.99kb -> 41.74kb (30.43%)
/screenshots/port_manager.png -- 22.70kb -> 16.86kb (25.72%)
/screenshots/about.png -- 38.75kb -> 29.00kb (25.17%)
/screenshots/plugin_manager.png -- 38.49kb -> 29.16kb (24.25%)
/packages/editor-app/src-tauri/icons/icon.svg -- 3.52kb -> 2.76kb (21.6%)
/screenshots/settings.png -- 53.78kb -> 44.90kb (16.51%)
/packages/editor-app/src-tauri/icons/icon.png -- 33.45kb -> 29.78kb (10.98%)
/packages/editor-app/src-tauri/icons/512x512.png -- 33.45kb -> 29.78kb (10.98%)
/packages/editor-app/src-tauri/icons/256x256.png -- 13.97kb -> 12.76kb (8.68%)
/packages/editor-app/src-tauri/icons/128x128@2x.png -- 13.97kb -> 12.76kb (8.68%)
/packages/editor-app/src-tauri/icons/128x128.png -- 5.17kb -> 5.03kb (2.89%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2025-10-16 14:45:32 +00:00
YHH 241acc9050 更新文档 2025-10-16 22:45:08 +08:00
YHH 8fa921930c Merge pull request #126 from esengine/issue-125-编辑器热更新
热更新配置
2025-10-16 22:31:26 +08:00
YHH 011e43811a 热更新配置 2025-10-16 22:26:50 +08:00
YHH 9f16debd75 新增rust编译缓存和ts构建缓存 2025-10-16 20:54:33 +08:00
YHH 92c56c439b 移除过时的工作流 2025-10-16 20:50:32 +08:00
YHH 7de6a5af0f v2.2.5 2025-10-16 20:37:16 +08:00
YHH 173a063781 Merge pull request #124 from esengine/issue-122-格式化的标准配置
所有源代码文件使用 LF (Unix 风格)
2025-10-16 20:29:21 +08:00
YHH e04ac7c909 所有源代码文件使用 LF (Unix 风格)
prettier格式化
eslint代码质量检查
2025-10-16 20:24:45 +08:00
YHH a6e49e1d47 修复publish-release中release_id错误问题 2025-10-16 20:07:56 +08:00
YHH f0046c7dc2 新增icons作为编辑器图标 2025-10-16 19:52:17 +08:00
YHH 2a17c47c25 修复ts警告 2025-10-16 18:20:31 +08:00
YHH 8d741bf1b9 Merge pull request #123 from esengine/issue-119-插件化编辑器
Issue 119 插件化编辑器
2025-10-16 17:50:35 +08:00
YHH c676006632 构建配置 2025-10-16 17:44:57 +08:00
YHH 5bcfd597b9 Merge remote-tracking branch 'remotes/origin/master' into issue-119-插件化编辑器 2025-10-16 17:37:24 +08:00
YHH 3cda3c2238 显示客户端链接的ip:port 2025-10-16 17:33:43 +08:00
YHH 43bdd7e43b 远程读取日志 2025-10-16 17:10:22 +08:00
YHH 1ec7892338 设置界面 2025-10-16 13:07:19 +08:00
YHH 6bcfd48a2f 清理调试日志 2025-10-16 12:21:18 +08:00
YHH 345ef70972 支持color类型 2025-10-16 12:00:17 +08:00
YHH c876edca0c 调试实体和组件属性 2025-10-16 11:55:41 +08:00
YHH fcf3def284 收集远端数据再profiler dockpanel上 2025-10-15 23:24:13 +08:00
YHH 6f1a2896dd 性能分析器及端口管理器 2025-10-15 22:30:49 +08:00
YHH 62381f4160 记录上一次操作的面板的size大小持久化 2025-10-15 20:26:40 +08:00
YHH 171805debf 禁用默认右键 2025-10-15 20:23:55 +08:00
YHH 619abcbfbc 插件管理器 2025-10-15 20:10:52 +08:00
YHH 03909924c2 app loading 2025-10-15 18:29:48 +08:00
YHH f4ea077114 菜单栏 2025-10-15 18:24:13 +08:00
YHH 956ccf9195 2D/3D视口 2025-10-15 18:08:55 +08:00
YHH e880925e3f 视口视图 2025-10-15 17:28:45 +08:00
YHH 0a860920ad 日志面板 2025-10-15 17:21:59 +08:00
YHH fb7a1b1282 可动态识别属性 2025-10-15 17:15:05 +08:00
YHH 59970ef7c3 Merge pull request #121 from foxling/fix/parent-child-deserialization-bug
fix: 修复场景反序列化时子实体丢失的问题
2025-10-15 15:55:26 +08:00
LING YE a7750c2894 fix: 修复场景反序列化时子实体丢失的问题
在场景反序列化过程中,子实体虽然保持了父子引用关系,
但未被添加到 Scene 的实体集合和查询系统中,导致查询时子实体"丢失"。
2025-10-15 15:48:54 +08:00
YHH b69b81f63a 支持树形资源管理器 2025-10-15 10:08:15 +08:00
YHH 00fc6dfd67 Dock系统,支持Tab和拖放 2025-10-15 09:58:45 +08:00
YHH 82451e9fd3 可拖动调整大小的面板 2025-10-15 09:43:48 +08:00
YHH d0fcc0e447 项目启动流程和资产浏览器功能 2025-10-15 09:34:44 +08:00
YHH 285279629e 优化加载脚本逻辑 2025-10-15 09:19:30 +08:00
YHH cbfe09b5e9 组件发现和动态加载系统 2025-10-15 00:40:27 +08:00
YHH b757c1d06c 项目打开功能 2025-10-15 00:23:19 +08:00
YHH 4550a6146a 组件属性编辑器 2025-10-15 00:15:12 +08:00
YHH 3224bb9696 国际化系统 2025-10-14 23:56:54 +08:00
YHH 3a5e73266e 组件注册与添加 2025-10-14 23:42:06 +08:00
YHH 1cf5641c4c 实体存储和管理服务 2025-10-14 23:31:09 +08:00
YHH 85dad41e60 Tauri 窗口,显示编辑器界面 2025-10-14 23:15:07 +08:00
YHH bd839cf431 Tauri 编辑器应用框架 2025-10-14 22:53:26 +08:00
YHH b20b2ae4ce 编辑器核心框架 2025-10-14 22:33:55 +08:00
YHH cac6aedf78 调试插件 DebugPlugin 2025-10-14 22:12:35 +08:00
YHH a572c80967 v2.2.4 2025-10-14 21:22:07 +08:00
YHH a09e8261db Merge pull request #118 from esengine/issue-117-统一组件注册系统,移除ComponentTypeManager重复实现
移除了功能重复的ComponentTypeManager
2025-10-14 18:24:17 +08:00
YHH 62e8ebe926 移除了功能重复的ComponentTypeManager 2025-10-14 18:19:08 +08:00
YHH 96e0a9126f Merge pull request #116 from esengine/issue-94-响应式查询(Reactive_Query_System)/_Event-driven_Query
使用ComponentRegistry来确保与Entity.componentMask使用相同的bitIndex
2025-10-14 17:56:26 +08:00
YHH 4afb195814 Merge remote-tracking branch 'origin/master' into issue-94-响应式查询(Reactive_Query_System)/_Event-driven_Query 2025-10-14 17:51:59 +08:00
YHH 7da5366bca 修复querysystem循环依赖的问题 2025-10-14 17:50:32 +08:00
YHH d979c38615 使用ComponentRegistry来确保与Entity.componentMask使用相同的bitIndex 2025-10-14 17:34:15 +08:00
YHH 7def06126b Merge pull request #115 from esengine/issue-114-reactive-query_文档
新增实体查询系统文档
2025-10-14 13:39:23 +08:00
YHH 9f600f88b0 新增实体查询系统文档 2025-10-14 13:33:12 +08:00
YHH e3c4d5f0c0 Merge pull request #105 from esengine/issue-94-响应式查询(Reactive_Query_System)/_Event-driven_Query
响应式查询
2025-10-14 12:29:54 +08:00
YHH b97f3a8431 移除了 EntitySystem.update() 中的冗余 invalidate() 调用 2025-10-14 12:08:08 +08:00
YHH 3b917a06af 修复响应式查询缓存失效和测试隔离问题 2025-10-14 11:48:04 +08:00
YHH 360106fb92 优化ReactiveQuery: 添加公共API、修复内存泄漏、提升通知性能 2025-10-13 23:55:43 +08:00
YHH 507ed5005f Merge remote-tracking branch 'origin/master' into issue-94-响应式查询(Reactive_Query_System)/_Event-driven_Query 2025-10-13 23:36:12 +08:00
YHH 8bea5d5e68 Merge remote-tracking branch 'origin/master' into issue-94-响应式查询(Reactive_Query_System)/_Event-driven_Query 2025-10-13 23:29:56 +08:00
YHH 99076adb72 Merge pull request #113 from esengine/issue-112-优化_DebugManager_使用_DI_避免依赖问题
使用DI避免依赖问题
2025-10-13 23:21:10 +08:00
YHH d1a6230b23 新增调试配置服务用于DI 2025-10-13 23:17:10 +08:00
YHH cfe3916934 使用DI避免依赖问题 2025-10-13 22:56:49 +08:00
YHH d798995876 Merge pull request #111 from esengine/issue-110-_Inject_装饰器在_Cocos_Creator_环境中不执行
扩展 InjectableMetadata 接口支持属性注入,实现 @InjectProperty 装饰器
2025-10-12 23:44:22 +08:00
YHH 43e6b7bf88 扩展 InjectableMetadata 接口支持属性注入,实现 @InjectProperty 装饰器 2025-10-12 23:39:32 +08:00
YHH 9253686de1 v2.2.3 2025-10-12 21:41:09 +08:00
YHH 7e7eae2d1a Merge pull request #109 from esengine/issue-108-world和scene进行了多次更新
Revert "Merge pull request #102 from esengine/issue-74-World与Scene关系不清晰"
2025-10-12 21:39:35 +08:00
YHH 1924d979d6 Revert "Merge pull request #102 from esengine/issue-74-World与Scene关系不清晰"
This reverts commit f2b9c5cc5a, reversing
changes made to 5f507532ed.
2025-10-12 21:38:53 +08:00
YHH ed84394301 更新序列化文档 2025-10-12 19:02:17 +08:00
YHH bb99cf5389 v2.2.2 2025-10-12 18:56:39 +08:00
YHH 2d0700f441 Merge pull request #107 from esengine/issue-106-类型定义声明返回_Buffer导致浏览器兼容问题
修复buffer再浏览器环境不兼容的问题
2025-10-12 18:53:53 +08:00
YHH e3ead8a695 修复buffer再浏览器环境不兼容的问题 2025-10-12 18:49:20 +08:00
YHH 942043f0b0 报告响应式查询的数量而不是传统缓存 2025-10-11 18:44:55 +08:00
YHH 23d81bca35 响应式查询 2025-10-11 18:31:20 +08:00
YHH 701f538e57 Merge pull request #104 from esengine/issue-103-WorldManager统一管理所有World实例_含默认World
Issue 103 world manager统一管理所有world实例 含默认world
2025-10-11 15:26:27 +08:00
YHH bb3017ffc2 Merge remote-tracking branch 'origin/master' into issue-103-WorldManager统一管理所有World实例_含默认World
# Conflicts:
#	packages/core/src/Core.ts
#	packages/core/src/ECS/SceneManager.ts
2025-10-11 15:21:43 +08:00
YHH f2b9c5cc5a Merge pull request #102 from esengine/issue-74-World与Scene关系不清晰
统一World与Scene架构,SceneManager内部使用DefaultWorld
2025-10-11 15:16:52 +08:00
YHH 532a52acfc 统一的World管理路径 2025-10-11 15:14:37 +08:00
YHH c19b5ae9a7 统一World与Scene架构,SceneManager内部使用DefaultWorld 2025-10-11 14:44:21 +08:00
YHH 5f507532ed 统一World与Scene架构,SceneManager内部使用DefaultWorld 2025-10-11 14:27:09 +08:00
YHH 6e48f22540 更新v2.2.1文档 2025-10-11 11:33:07 +08:00
YHH 66aa9f4f20 更新文档 2025-10-11 10:48:24 +08:00
YHH 62f895efe0 v2.2.1 2025-10-11 10:46:46 +08:00
YHH 4a060e1ce3 WorldManager 现在由 ServiceContainer 统一管理 2025-10-11 10:40:10 +08:00
YHH a0177c9163 从 tslib 导入辅助函数 2025-10-11 10:36:59 +08:00
YHH f45af34614 更新v2.2.0文档 2025-10-11 10:16:52 +08:00
YHH 14a8d755f0 PoolManager 现在由 ServiceContainer 统一管理 2025-10-11 09:38:16 +08:00
YHH b67ab80c75 Merge pull request #93 from esengine/issue-80-插件系统
插件系统
2025-10-11 09:32:12 +08:00
YHH ae71af856b 插件系统 2025-10-11 09:26:36 +08:00
YHH 279c1d9bc9 Merge pull request #92 from esengine/issue-82-组件引用完整性
组件引用完整性,升级到es2021使用weakref
2025-10-11 00:30:36 +08:00
YHH 9068a109b0 降级es2020,实现 WeakRef Polyfill 2025-10-11 00:25:10 +08:00
YHH 7850fc610c 组件引用完整性,升级到es2021使用weakref 2025-10-10 23:38:48 +08:00
YHH 536871d09b Merge pull request #88 from esengine/issue-76-依赖注入
依赖注入引入DI容器
2025-10-10 22:15:24 +08:00
YHH 1af2cf5f99 Scene 构造函数注入 PerformanceMonitor 2025-10-10 22:08:10 +08:00
YHH b13132b259 依赖注入引入DI容器 2025-10-10 21:52:43 +08:00
YHH a1a6970ea4 Merge pull request #87 from esengine/issue-73-Core类职责过重需要进行拆分
新增ServiceContainer服务容器, 所有服务统一实现 IService 接口
2025-10-10 18:17:55 +08:00
YHH 41bbe23404 新增ServiceContainer服务容器, 所有服务统一实现 IService 接口 2025-10-10 18:13:28 +08:00
YHH 1d2a3e283e Merge pull request #86 from esengine/issue-75-组件存储策略不统一
组件存储策略不统一
2025-10-10 16:38:06 +08:00
YHH 62d7521384 移除 Entity._localComponents/强制Entity必须属于Scene/简化组件操作逻辑 2025-10-10 16:31:43 +08:00
YHH bf14b59a28 空查询应该返回所有实体 2025-10-10 11:49:06 +08:00
YHH 0a0f64510f 更新测试用例 2025-10-10 10:58:52 +08:00
YHH 9445c735c3 对象池内存管理优化 2025-10-10 10:16:44 +08:00
YHH 7339e7ecec 新增scenemanager,重构core类减少多世界造成的性能压力 2025-10-09 23:33:11 +08:00
YHH 79f7c89e23 修复再不同环境下buffer兼容性问题 2025-10-09 17:44:15 +08:00
YHH e724e5a1ba 更新demo 2025-10-09 17:43:46 +08:00
YHH fdaa94a61d v2.1.52 2025-10-09 17:26:07 +08:00
YHH 6af0074c36 导航增加序列化章节 2025-10-09 17:18:14 +08:00
YHH 97a69fed09 增量序列化支持二进制 2025-10-09 17:14:18 +08:00
YHH 959879440d 更新序列化文档 2025-10-09 14:18:43 +08:00
YHH fd1bbb0e00 新增增量序列化 2025-10-09 12:30:04 +08:00
YHH 072e68cf43 修复序列化ci测试 2025-10-08 20:58:07 +08:00
YHH 610232e6b0 core库demo更新 2025-10-08 20:52:31 +08:00
YHH 69c46f32eb 支持二进制序列化 2025-10-08 20:42:55 +08:00
YHH 06b3f92007 场景自定义序列化支持 2025-10-08 18:34:15 +08:00
YHH c631290049 对query/entity进行安全类型扩展 2025-10-08 13:13:23 +08:00
YHH f41c1a3ca3 冗余测试合并 2025-10-08 12:04:13 +08:00
YHH bd6ba84087 Merge pull request #72 from 0MirageTank0/master
优化掩码数据结构,新增BitMaskHashMap类型,支持无限数量原型
2025-10-05 09:13:30 +08:00
MirageTank 1512409eb3 优化位掩码工具的输出格式
- 十六进制不再输出无意义的前导0符号
- 修正部分测试单元检测逻辑
2025-10-04 13:16:51 +08:00
MirageTank bcb5feeb1c 实现高性能 BitMaskHashMap 并优化ArchetypeSystem
- 引入 BitMaskHashMap 类,使用双层 MurmurHash3 哈希算法提升查找性能
- 替换 ArchetypeSystem 中原有的嵌套 Map 结构为 BitMaskHashMap,支持任意数量的原型
- 验证在十万级连续键值下无哈希冲突,确保生产环境可用性
2025-10-04 10:26:19 +08:00
MirageTank da8b7cf601 重构位掩码数据结构,修复部分方法未考虑扩展位的问题
- 所有操作均考虑扩展位、扩展长度不一致的使用场景,无感扩容掩码位
- 使用定长数组存储高低位,遍历友好,为高效哈希计算提供结构支持
- 补充相应单元测试,覆盖所有方法及分支
2025-10-03 16:55:07 +08:00
YHH 316527c459 更新实体文档(components为只读属性) 2025-10-01 00:15:19 +08:00
YHH da70818b22 v2.1.51 2025-10-01 00:11:14 +08:00
YHH 5ea3b72b2b 使用BitMask64Data.segments扩展ComponentRegistry 2025-09-30 23:58:52 +08:00
YHH 632864b361 单一数据源 + 懒加载缓存 2025-09-30 23:37:47 +08:00
YHH 952247def0 重构 Component基类违反ECS纯粹性问题 2025-09-30 22:26:44 +08:00
YHH 51debede52 移除废弃的文件 2025-09-30 20:44:08 +08:00
YHH ce7b731bcf Merge pull request #71 from esengine/fix/issue-70-component-mask-string
Fix/issue 70 component mask string
2025-09-30 18:19:11 +08:00
YHH 86e2dc8fdb 完全删除 ComponentIndexManager 2025-09-30 18:12:49 +08:00
YHH 78047134c2 完全移除 byComponentType 2025-09-30 18:03:03 +08:00
YHH 125a1686ab 完全删除 byComponentType 2025-09-30 17:54:22 +08:00
YHH d542ac48b8 重构byComponentType为lazy cache模式 2025-09-30 17:07:13 +08:00
YHH 1ac0227c90 移除bymask 2025-09-30 17:01:49 +08:00
YHH a5e70bcd99 修复QuerySystem组件掩码索引使用toString()返回[object Object]的问题 #70 2025-09-30 16:38:32 +08:00
YHH 38763de7f6 BitMask64Segment 独立类型 2025-09-30 15:56:28 +08:00
YHH db73b077c5 支持分层 BitMask 自动扩容,避免用户超过组件后报错问题 2025-09-30 15:38:50 +08:00
YHH 0969d09da1 优化ArchetypeSystem的AND指令 2025-09-30 15:08:33 +08:00
YHH a07108a431 修复soa测试用例 2025-09-30 13:43:12 +08:00
YHH 6693b56ab8 Merge pull request #69 from 0MirageTank0/master
优化ArchetypeSystem性能
2025-09-30 13:31:11 +08:00
MirageTank a7349bd360 补充TypeDecorators文件对ComponentType参数类型的修改 2025-09-30 12:53:23 +08:00
MirageTank e92c0040b5 重构原型系统以提升性能
- 将原型ID类型从字符串改为BitMask64Data,避免拼接字符串的性能损耗,降低内存占用.
- 原型ID生成不再依赖组件名称.
2025-09-30 11:57:31 +08:00
MirageTank f448fa48c4 重构组件类型管理器相关函数参数以使用ComponentType,而不是Component. 2025-09-30 11:42:01 +08:00
YHH aa33cad4fa 扩展typedarray存储系统,允许自动类型推断@AutoTyped 2025-09-30 11:00:05 +08:00
YHH d0cb7d5359 v2.1.50 2025-09-30 09:59:46 +08:00
YHH 90153b98fe 更新 2025-09-30 09:51:02 +08:00
YHH 8c4e8d523e 更新微信小游戏worker文档 2025-09-30 09:37:30 +08:00
YHH 90ad4b3ec4 抽象worker接口,避免污染项目 2025-09-29 18:15:47 +08:00
YHH 62bc6b547e 支持wx/browser的worker(由于wx限制默认不开启worker) 2025-09-29 13:21:08 +08:00
YHH be11060674 archetypesystem只负责原型管理,querysytem负责查询和缓存 2025-09-29 11:01:39 +08:00
YHH d62bf9f7f9 entitysytem的logger返回类型更改,需要重写实现getLoggerName 2025-09-29 09:53:13 +08:00
YHH 61fcd52c65 移除eventhandler装饰器 2025-09-29 09:35:02 +08:00
YHH 2947ddeb64 不限制ci的超时时间 2025-09-29 09:04:53 +08:00
YHH d9b752c180 修复workerentitysysten和entitysytem的logger重复问题 2025-09-29 00:01:59 +08:00
YHH b82891caee 装饰器事件自动清理 2025-09-28 23:58:43 +08:00
YHH 05f04ef37e 允许用户自定义核心数量 2025-09-28 23:35:25 +08:00
YHH 66dc9780b9 使用coi-serviceworker用于无法控制标头的情况 2025-09-28 21:11:17 +08:00
YHH d48b22c656 更新demo界面 2025-09-28 21:00:28 +08:00
YHH 727b1864eb 更新demo 2025-09-28 20:49:00 +08:00
YHH de3bfd7551 新增禁用sab功能 2025-09-28 20:41:23 +08:00
YHH dedb91379f worker系统不支持sab回退到普通worker 2025-09-28 20:22:06 +08:00
YHH 1dfcd008aa 新增worker-system文档及源码示例 2025-09-28 20:03:29 +08:00
YHH cf2dc91af6 更新worker-demo 2025-09-28 18:29:32 +08:00
YHH a66f80a766 新增WorkerEntitySystem系统 2025-09-28 17:36:36 +08:00
YHH f4e49c316e getWorldManager允许传入可选配置用于覆盖默认配置 2025-09-28 15:52:46 +08:00
YHH d1cd72bbb2 修复QuerySystem中addEntities没有更新componentIndexManager/archetypeSystem索引 2025-09-28 15:32:54 +08:00
YHH 6178851def 修复QuerySystem/ArchetypeSystem未响应实体增删Component的问题 2025-09-28 15:23:59 +08:00
YHH 945f772c30 只在有package改动的时候触发ci流程 2025-09-28 12:32:35 +08:00
YHH b546c9c712 vitepress修改为githubpage路径 2025-09-28 12:29:43 +08:00
YHH 413ce93b31 更新文档 2025-09-28 12:26:51 +08:00
YHH cffe32911d v2.1.49 2025-09-28 10:36:01 +08:00
YHH 4f651eb42e 优化querysystem系统(减少数组拷贝)
移除dirtytracksystem
2025-09-28 09:40:36 +08:00
YHH 6da1585b6b entitysystem实用帧缓存和长期缓存策略 2025-09-26 18:30:49 +08:00
YHH b988e81a1b 数学库新增Vector3 2025-09-26 17:45:52 +08:00
YHH 1a1c1087d2 标记组件不符合规范的废弃属性 2025-09-26 17:45:26 +08:00
YHH 1a1549230f 更新references库 2025-09-26 13:06:39 +08:00
YHH 64ea53eba1 系统添加缓存实体机制避免频繁开销 2025-09-26 10:50:31 +08:00
YHH 5e052a7e7d 默认不增强事件,避免事件性能开销 2025-09-26 10:28:00 +08:00
YHH cf9ea495d0 移除过时类并标记组件和实体的update为过时方法 2025-09-26 10:09:23 +08:00
YHH 9603c6423b 系统避免在同一帧内进行多次query操作 2025-09-26 09:45:22 +08:00
YHH 457eef585e Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-09-26 09:38:57 +08:00
YHH 1ade449c4d 控制实体update默认不更新 2025-09-26 09:38:51 +08:00
YHH aa9d73a810 Merge pull request #68 from snakenjq/master
场景移除时, 清理系统
2025-09-24 18:25:55 +08:00
SNDA\niujiaqun.nathan cc266a7ba9 修改错误方法调用 2025-09-24 18:18:48 +08:00
SNDA\niujiaqun.nathan d8ea324018 场景移除时, 清理系统 2025-09-24 18:14:22 +08:00
YHH 60566e8d78 v2.1.48 2025-09-24 16:05:22 +08:00
YHH 306d2994dc Merge pull request #67 from foxling/fix/global-log-level
修复 setGlobalLogLevel 不影响新创建 logger 的问题
2025-09-24 15:54:28 +08:00
YHH e6a8791fc3 系统中提供更安全的事件监听器方法(避免内存泄露) 2025-09-24 11:03:37 +08:00
YHH 6cbbc06998 规范jsdoc注释 2025-09-24 10:45:33 +08:00
YHH 0b4244fd8e 修复循环依赖问题 2025-09-24 10:20:36 +08:00
LING YE 367ddfbf8a 修复 setGlobalLogLevel 方法,使其可以在后续新建的 Logger 实例中生效 2025-09-22 15:28:29 +08:00
YHH 168e028098 更新支持es5环境 2025-09-04 16:26:29 +08:00
YHH 042ded37d2 新增自定义log颜色ci测试 2025-09-04 16:25:40 +08:00
YHH 4137eb2bce 网络层完善消息队列 2025-09-04 16:25:18 +08:00
YHH 20a3f03e12 支持用户自定义log颜色 2025-09-04 16:24:38 +08:00
YHH 7792710694 避免splice开销问题,改为SwapPop + typeId → denseIndex 2025-09-03 10:56:33 +08:00
YHH dbddbbdfb8 更新ci测试用例 2025-09-03 10:39:29 +08:00
YHH 4869f5741e bits多态改为POD+原地操作 2025-09-03 10:29:43 +08:00
YHH bda547dd2e 把掩码从BigInt-like多态都改成Mask64 2025-09-03 00:39:00 +08:00
YHH ef80b03a44 更改为固定64位掩码,没必要为任意精度付出性能代价 2025-09-03 00:12:59 +08:00
YHH 6e511ae949 改成 SparseSet+SwapRemove 的致密存储 2025-09-02 22:29:11 +08:00
YHH 94541d0abb 实体中的线性数组换为按组件类型ID直址的稀疏数组 2025-09-02 21:59:59 +08:00
YHH 586a0e5d14 降低ci测试覆盖率 2025-09-02 21:16:36 +08:00
YHH 814842dbaf 降低测试覆盖率导致的ci错误 2025-09-02 21:11:15 +08:00
YHH 70a993573f 修复ci报错 2025-09-02 18:04:55 +08:00
YHH 21659cbb13 交/并/差运算全部改用ID集合单次扫描 2025-09-02 17:17:07 +08:00
YHH a44251cc55 新增world概念(多world管理多scene概念)现在支持多个world多个scene同时更新 2025-08-20 17:48:31 +08:00
YHH 69616bbddc 实现ServerRpc和ClientRpc装饰器 2025-08-20 10:32:56 +08:00
YHH 0a1d7ac083 实现SyncVar装饰器和组件同步 2025-08-20 10:16:54 +08:00
YHH 364bc4cdab update demo 2025-08-20 09:17:43 +08:00
YHH 2504eb24e1 经测试转换为wasm没有明显的效率提升,因为js和rust的交互反而有所下降
等待以后有密集计算再考虑使用,先移除了
2025-08-20 09:15:06 +08:00
YHH bdbef0bd0d core核心rust实现 2025-08-18 20:46:47 +08:00
YHH e4e38ee4e6 更新api文档 2025-08-15 13:47:11 +08:00
YHH 021e892e33 ci流程需要core库先编译后再测试network-shared 2025-08-15 13:32:36 +08:00
YHH c27d5022fd 优化内部组件索引机制(更改为SparseSet索引)减少用户切换索引成本
修复内部系统初始化逻辑 - 不应该再onInitialize中初始内部entities,移动到initialize中
ci跳过cocos项目避免ci失败
soa开放更多安全类型接口
2025-08-15 12:58:55 +08:00
YHH 6730a5d625 传输层实现(客户端/服务端,链接管理和心跳机制,重连机制)
消息序列化(json序列化,消息压缩,消息ID和时间戳)
网络服务器核心(networkserver/基础room/链接状态同步)
网络客户端核心(networkclient/消息队列)
2025-08-14 23:59:00 +08:00
YHH 32092f992d 更新文档 2025-08-14 18:45:24 +08:00
YHH a5f0c8f6b5 更新文档 2025-08-14 18:44:04 +08:00
YHH 85cd93e51a 文档更新 2025-08-14 18:38:09 +08:00
YHH 0b7e623748 新增组件/系统装饰器避免混淆
更改Set兼容web/小游戏
2025-08-14 18:35:03 +08:00
YHH 62f250b43c 重构network库(mvp版本)搭建基础设施和核心接口
定义ITransport/ISerializer/INetworkMessage接口
NetworkIdentity组件
基础事件定义
2025-08-13 13:07:40 +08:00
YHH 25136349ff 修复动态require导致的跨平台错误
新增emitter的dispose方法用于清理事件
启用composite增量编译
2025-08-13 12:18:40 +08:00
YHH baeb047e27 支持可以任意参数 2025-08-12 11:47:18 +08:00
YHH 56dd18b983 废弃core.scene更改为setscene方法 2025-08-12 11:08:27 +08:00
YHH 86cb70a94f Merge branch 'master' of https://github.com/esengine/ecs-framework
# Conflicts:
#	packages/network-shared/package.json
2025-08-12 09:43:29 +08:00
YHH 9f76d37a82 更新network库及core库优化 2025-08-12 09:39:07 +08:00
YHH a026ed9428 降级ws版本 2025-08-11 12:33:42 +08:00
YHH c178e2fbcc 移除ci性能测试,github下不应该测试这些文件 2025-08-11 11:34:38 +08:00
YHH b88bb1dc87 修复ci中的大小写问题
update gitsubmodule
2025-08-11 11:11:56 +08:00
YHH 3069e28224 add submodule electric-world 2025-08-11 11:06:28 +08:00
YHH d69b3af99b 更新math版本 2025-08-11 10:39:14 +08:00
YHH 7398b7c6d0 修复math库tsconfig引用问题 2025-08-11 10:38:11 +08:00
YHH 5d57904d22 更新使用rollup打包
解决大小写冲突问题
2025-08-11 10:34:13 +08:00
YHH 7daf352a25 更新库rollup配置 2025-08-11 10:25:28 +08:00
YHH 6a49f6a534 npm包发布配置更改 2025-08-11 10:03:19 +08:00
YHH 5bce08683a update 2.1.30 2025-08-11 09:31:44 +08:00
YHH edc60fc3d8 添加发布core命令 2025-08-11 09:15:14 +08:00
YHH 1361fd8a90 导出soa装饰器 2025-08-11 09:01:01 +08:00
YHH d539bb3dd9 更新文档 2025-08-11 08:18:18 +08:00
YHH 3b9ae4f384 新增math库 2025-08-10 16:00:02 +08:00
YHH 2783448de5 重新整理网络架构,tsrpc/syncvar并行 2025-08-10 12:35:39 +08:00
YHH 6e21ff08d5 集成tsrpc代替protobuf 2025-08-09 18:56:19 +08:00
YHH e56278e4a6 移除路径映射,只让Jest处理路径解析 2025-08-08 15:57:56 +08:00
YHH fc9bf816dd 修复build失败问题 2025-08-08 15:47:48 +08:00
YHH 854fd7df3a 修复ci测试 2025-08-08 15:41:37 +08:00
YHH 87dd564a12 项目统一改用Logger控制管理
拆分pool类和FluentAPI
2025-08-08 11:16:00 +08:00
YHH 2d389308ea 新增syncvar高级特性,使用protobuf定义 2025-08-07 20:23:49 +08:00
YHH ea8523be35 使用Lerna 和 monorepo管理项目结构 2025-08-07 13:29:12 +08:00
YHH 4479f0fab0 避免throw导致的中止运行,增加fallback回退json的序列化 2025-08-07 10:16:36 +08:00
YHH 7a000318a6 整合组件类型至统一的componentregistry中 2025-08-07 09:43:34 +08:00
YHH 9a08ae74b6 移除json序列化只保留protobuf 2025-08-06 17:42:12 +08:00
YHH f3d2950df3 修复ci失败 2025-08-06 17:12:39 +08:00
YHH 8cfba4a166 新增protobuf依赖(为网络和序列化做准备)
更新readme
2025-08-06 17:04:02 +08:00
YHH 51e6bba2a7 2.1.29 2025-08-06 09:56:55 +08:00
YHH ccbfa78070 修复了QuerySystem在销毁实体时的内存泄漏问题
实现了完整的onAdded/onRemoved回调系统
修复了override修饰符和类型兼容性问题
2025-08-06 09:39:08 +08:00
YHH 69655f1936 测试用例更新 2025-07-31 15:37:40 +08:00
YHH 6ea366cfed 优化matcher内部实现改为querysystem
完善type类型
更新文档
2025-07-31 11:56:04 +08:00
YHH b7d17fb16d soa添加float32 2025-07-30 18:10:14 +08:00
YHH f3dc8c6344 BigIntFactory 缓存优化
- 为 zero() 和 one() 方法添加缓存,避免重复创建对象
ComponentIndexManager 优化
  - 添加了空实体检查,跳过不必要的索引操作
  - 实现了 Set 对象池,重用 Set 实例以减少内存分配
  - 优化了自动优化检查频率,从每次操作变为每100次操作检查一次
EntityManager 优化
  - 对空实体跳过不必要的组件索引、原型系统和脏标记操作
  - 批量创建时同样应用空实体优化
2025-07-30 17:10:58 +08:00
YHH 69ec545854 优化createEntity的性能/新增批量创建实体api 2025-07-30 16:05:16 +08:00
YHH 65386ff731 优化EntitySystem初始化逻辑/防止多次初始化
增加matcher和entitysystem的测试
2025-07-30 15:42:19 +08:00
YHH 01fa33e122 新增soastorage存储器 2025-07-30 14:14:04 +08:00
YHH 0411aa9aef 2.1.28 2025-07-30 11:14:26 +08:00
YHH 4a5c890121 对bigint进行兼容处理(不支持的环境回退到兼容模式) 2025-07-30 11:11:46 +08:00
YHH 4c11fdc176 2.1.27 2025-07-29 16:10:09 +08:00
YHH d99e7a45ea 新增更多覆盖测试 2025-07-29 15:56:40 +08:00
YHH 52528ff1b7 修复querysystem的rebuildindex方法
修复位掩码不一致问题
修复未注册组件的处理
2025-07-29 10:58:31 +08:00
YHH 4a9317f3f4 querysystem进行ci测试隔离 2025-07-29 10:39:48 +08:00
YHH 9450dd5869 修复ci报错 2025-07-29 10:25:12 +08:00
YHH d5471e4828 修复ci报错问题 2025-07-29 09:29:29 +08:00
YHH 2f71785add 覆盖querysystem/eventbus/componentstorage测试 2025-07-29 09:08:31 +08:00
YHH 608f5030b2 对ecs目录进行更多的ci测试 2025-07-28 17:38:18 +08:00
YHH dd8f3714ed 修复不应该jest console导致的ci失败 2025-07-28 17:20:28 +08:00
YHH abec2b3648 querysystem内部框架维护(不需要用户手动调用事件派发)
新增test覆盖测试
2025-07-28 17:14:10 +08:00
YHH ea06a9f07d Merge pull request #58 from esengine/develop_simple_entity
移除过度复杂的组件缓存系统 #57
2025-07-18 21:21:01 +08:00
YHH 9f54759cc5 添加-获取-移除循环CI条件放宽 #57 2025-07-18 18:29:17 +08:00
YHH 55dd5f9ed0 单元测试条件放宽 CI环境性能较低 #57 2025-07-18 18:26:47 +08:00
YHH 05455421fb 移除过度复杂的组件缓存系统 #57 2025-07-18 18:08:57 +08:00
YHH af61067f08 修复ci导致的问题 2025-07-18 15:15:37 +08:00
YHH 19cda88248 移除子模块CI 2025-07-18 15:11:20 +08:00
YHH 0edb2738a1 优化IdentifierPool - 世代式ID池管理器 2025-07-18 14:59:00 +08:00
YHH e1bc364525 新增实用ai编辑器 2025-07-13 22:53:30 +08:00
YHH 2925ee380d 新增mvvm示例 2025-07-08 20:23:19 +08:00
YHH 731edf5872 Merge branch 'master' of https://github.com/esengine/ecs-framework
# Conflicts:
#	.gitmodules
#	extensions/cocos/cocos-ecs/package-lock.json
#	extensions/cocos/cocos-ecs/package.json
2025-07-08 08:57:11 +08:00
YHH 7b85039b17 更新mvvm示例 2025-07-08 08:55:55 +08:00
YHH 2bc45fa574 新增子模块cocos-mvvm 2025-07-07 23:41:53 +08:00
YHH d2b4455205 2.1.26 2025-07-07 11:49:57 +08:00
YHH bce4a26197 构建cjs/mjs 2025-07-07 11:49:36 +08:00
YHH 1da5040d60 打包支持nodejs模块 2025-07-07 11:06:08 +08:00
YHH afd33e053b 更新子模块及导入demo 2025-07-07 11:02:11 +08:00
YHH 171d03c006 新增snapshot快照功能 2025-07-07 09:45:36 +08:00
YHH 34d5237aaa Merge branch 'master' of https://github.com/esengine/ecs-framework
# Conflicts:
#	package-lock.json
#	package.json
2025-07-03 09:02:37 +08:00
YHH 037c3d6a05 2.1.25 2025-07-02 23:49:28 +08:00
YHH 5596ba634e 2.1.24 2025-07-02 23:49:02 +08:00
YHH a5f69065f4 update 2025-07-02 23:48:51 +08:00
YHH 969ef249ea Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-07-02 23:47:41 +08:00
YHH a37183851f 修复queryall缓存信息错误问题 2025-07-02 23:47:30 +08:00
YHH 4cf3e1a769 2.1.24 2025-07-02 11:25:00 +08:00
YHH 354e5a2761 update submodule 2025-07-02 11:23:50 +08:00
YHH c9fd8cc2a7 优化组件递归调用导致的性能问题/新增实体所在的场景显示 2025-07-02 09:42:49 +08:00
YHH bb19f752a1 优化性能结构/延迟加载
新增测试代码用于测试性能
2025-07-02 00:13:29 +08:00
YHH 6bd9c1055c 2.1.23 2025-07-01 11:48:41 +08:00
YHH dff77097c6 git commit 2025-07-01 11:48:26 +08:00
YHH b4dc1c5661 修复type大小写问题 2025-06-30 20:43:11 +08:00
YHH 992338d924 更新性能分析器及更改部分注释 2025-06-30 20:33:45 +08:00
YHH f88a402b0c 新增程序化地形子模块 2025-06-27 16:51:19 +08:00
YHH 5938d36149 版本更新 2025-06-26 18:00:02 +08:00
YHH 78577db3f9 更新示例教程 2025-06-25 23:17:55 +08:00
YHH 0b4a6b77e2 采矿行为树示例 2025-06-25 17:50:40 +08:00
YHH 01084a8897 更新rts示例代码(矿工自动采矿) 2025-06-24 23:51:59 +08:00
YHH 0f18a1979e rts-demo 2025-06-24 19:34:37 +08:00
YHH 68a615bc7b 移除测试代码 2025-06-23 23:48:19 +08:00
YHH add1068c1a Merge branch 'master' of https://github.com/esengine/ecs-framework 2025-06-23 16:08:40 +08:00
YHH 7a40df9965 修复过时文档问题 2025-06-23 16:08:31 +08:00
YHH 3e6a1aa59a 更新example 2025-06-22 21:21:46 +08:00
YHH d3fe79cf39 example update 2025-06-20 18:21:50 +08:00
YHH 48fa547c8f 更改为submodule 2025-06-19 21:04:38 +08:00
YHH 80e2f7df71 remove cocos-extensions 2025-06-19 21:00:42 +08:00
YHH 0107f1f58a remove admin-dashboard 2025-06-19 20:49:09 +08:00
YHH d29c9a96f4 新增热更新后台管理系统 2025-06-19 18:32:32 +08:00
YHH 37d75c3281 2.1.22 2025-06-19 15:43:48 +08:00
YHH 666ded7b89 初始化只在系统真正开始工作时执行 2025-06-19 15:43:22 +08:00
YHH 73a882f75e 2.1.21 2025-06-19 15:01:20 +08:00
YHH 310f5f2349 支持先加入实体后加入系统以让matcher进行实体匹配/优化行为树节点效果及逻辑 2025-06-19 15:00:14 +08:00
YHH 8c86d6b696 更新文档及优化行为树编辑器 2025-06-19 10:38:31 +08:00
YHH 82cd163adc 清理冗余代码及频繁日志输出 2025-06-18 23:37:47 +08:00
YHH 802ee25621 新增Blackboard 2025-06-18 23:31:53 +08:00
YHH f48ebb65ba 修复插件生成代码报错问题 2025-06-18 20:22:17 +08:00
YHH aaa2a8ed2c 新增装饰节点选中功能 2025-06-18 18:31:29 +08:00
YHH 5a06f5420b 条件装饰节点和条件装饰器结合 2025-06-18 18:21:55 +08:00
YHH 343f5a44f2 新增根节点 2025-06-18 15:53:48 +08:00
YHH 92125aee3a 删除连线操作 2025-06-18 15:43:17 +08:00
YHH 96f651b7ca 新增cocos右键打开和保存行为树功能 2025-06-18 15:20:07 +08:00
YHH 06ea01e928 拖拽逻辑更新 2025-06-17 23:59:30 +08:00
YHH 577f1e429a 新增行为树编辑器 2025-06-17 18:28:57 +08:00
YHH 7808f64fe5 更新生成代码工具 2025-06-17 10:46:47 +08:00
YHH e6789e49e4 2.1.20 2025-06-17 07:35:46 +08:00
YHH 797619aece 更新池利用率 2025-06-17 07:35:23 +08:00
YHH 1b5363611d 新增cocos-debug-profiler 2025-06-17 00:32:16 +08:00
YHH 103f773286 添加Cocos Creator ECS编辑器插件:完整的框架管理和模板生成功能 2025-06-16 18:32:44 +08:00
YHH d9ef0b587e 2.1.19 2025-06-16 09:36:59 +08:00
YHH d5b98256f0 优化bits性能及移除组件上限 2025-06-16 09:36:36 +08:00
YHH efcceaa898 2.1.18 2025-06-12 09:47:44 +08:00
YHH e4aad11965 update readme 2025-06-12 09:47:25 +08:00
YHH 47207fad52 2.1.17 2025-06-12 09:44:05 +08:00
YHH 202bf82896 更新场景切换状态 2025-06-12 09:43:57 +08:00
YHH 0e3274a743 移除coreevents事件派发机制 2025-06-12 09:42:35 +08:00
YHH b06174926d 更新快速入门指南 2025-06-10 13:22:28 +08:00
YHH abb23a3c02 2.1.16 2025-06-10 13:12:22 +08:00
YHH 0c8f232282 文档及教程更新 2025-06-10 13:12:14 +08:00
YHH ef023d27bf 2.1.15 2025-06-10 09:50:05 +08:00
YHH 7a591825eb 先移除wasm后续再通过其他方式接入 2025-06-10 09:49:55 +08:00
YHH e71c49d596 移除额外的打包流程 2025-06-09 18:27:20 +08:00
YHH e6ce8995ba 2.1.14 2025-06-09 18:01:34 +08:00
YHH f6250b6d5b 规范为cococs wasm 2025-06-09 18:00:50 +08:00
YHH 757eff2937 2.1.13 2025-06-09 15:55:26 +08:00
YHH 996a7f3ddf 重构WASM架构:移除npm包中的WASM文件,改为独立发布 - 移除自动WASM加载逻辑 - 添加手动initializeWasm API - 创建专门的WASM发布包构建脚本 - 更新Cocos Creator使用指南 2025-06-09 15:54:34 +08:00
YHH 94c050bacb 2.1.12 2025-06-09 15:47:10 +08:00
YHH 3f4aa59a29 完善Cocos Creator支持:添加手动WASM初始化API和使用指南 2025-06-09 15:46:14 +08:00
YHH bee7cf4278 2.1.11 2025-06-09 15:32:11 +08:00
YHH b9db6f0b40 2.1.10 2025-06-09 15:16:31 +08:00
YHH 8967cba3c7 修复WASM路径解析问题,支持Cocos Creator环境 - 改进多路径WASM加载策略 - 添加Core.disableWasm()方法 - 简化WASM初始化逻辑以避免环境兼容性问题 2025-06-09 15:15:41 +08:00
YHH d04ad2eea9 Update build-rollup.js 2025-06-09 14:53:15 +08:00
YHH f2d3880a06 重构项目结构:整理gitignore,移动source目录到根目录,统一依赖管理 2025-06-09 14:51:26 +08:00
YHH ec5f70ecfc fix: 修复npm包构建和发布问题 - 将esbuild target从es2017升级到es2020以支持BigInt - 修复浏览器环境下Node.js模块依赖问题 - 添加define配置处理require等Node.js全局变量 - 成功发布@esengine/ecs-framework@2.1.7到npm 2025-06-09 13:34:46 +08:00
YHH 40b3fe7165 docs: 更新项目文档 - 添加EntityManager、事件系统、性能优化使用示例和说明 2025-06-09 13:25:10 +08:00
YHH 4095f1e946 refactor: 规范化代码注释和更新核心模块 - 移除冗余JSDoc注释,统一代码风格 2025-06-09 13:24:54 +08:00
YHH e219fc47ba feat: 添加ECS核心功能模块 - EntityManager实体管理器、EventBus事件总线、性能优化系统 2025-06-09 13:24:24 +08:00
YHH 6e2e7a4af5 refactor: 拆分WasmCore大文件为模块化结构 - 将23KB的WasmCore.ts拆分为types/loader/fallback/core/instance五个模块 2025-06-09 13:23:46 +08:00
YHH 2e7f764d6c refactor: 细化ECS/Core目录结构 - 按功能拆分为Events/Query/Performance/Storage四个子模块 2025-06-09 13:23:29 +08:00
YHH ce64de5b3d 更改为es2020模块适应Cocos/laya引擎 2025-06-09 10:42:19 +08:00
YHH 35ca1dd7ea 将dist目录添加到.gitignore中 - dist目录是npm包构建的输出目录,不应该提交到版本控制 2025-06-09 10:39:37 +08:00
YHH 8d0ad6b871 新增wasm以优化实体update速度 2025-06-08 21:50:50 +08:00
YHH 0aa4791cf7 更新文档并预留wasm接口 2025-06-08 10:20:51 +08:00
YHH 082c2b46d0 移除数学库 2025-06-07 21:45:11 +08:00
YHH 50420f9052 增加性能测试 2025-06-07 21:28:31 +08:00
YHH 499cbf8a60 Delete node.js.yml 2025-06-07 20:34:55 +08:00
YHH 2e38284d6e 升级项目框架,移除大部分无用的物理和tween系统 2025-06-07 20:32:43 +08:00
YHH 00cc3a11c6 修复安全漏洞 2025-06-07 12:37:16 +08:00
yhh 9909a7f7b0 补全注释 2023-03-14 17:33:05 +08:00
yhh 3363fca160 更改示例及新增注释 2023-03-14 14:03:41 +08:00
yhh 78e0b09c7a 文档更新 2023-03-14 11:22:09 +08:00
yhh caa3ffc8f5 1.新增es.TimeUtils
2.优化并给部分类添加注释
3.移除fasterDictionary
2023-03-13 23:32:24 +08:00
yhh 323fb6a5fe list注释优化 2023-03-13 22:17:11 +08:00
yhh 1adc5f1729 对ECS系统进行注释、移除JobSystem 2023-03-13 17:46:16 +08:00
yhh 78079252c9 修复rectangle中rayinterest方法返回错误信息 2023-03-13 15:23:02 +08:00
yhh 72fdabd099 mathHelper优化及注释。修复pointCircle错误实现 2023-03-13 14:51:38 +08:00
yhh 64bd6aa055 优化mathHelper代码 2023-03-13 12:31:59 +08:00
yhh 6329200b84 升级package包,更新readme 2023-03-13 12:10:17 +08:00
yhh 3f3fd16110 新增扇形collider 2023-02-24 19:16:20 +08:00
YHH 34f0c4ac2d 新增allTweensWithTargetEntity与clearAllCoroutines方法 2022-07-09 11:24:32 +08:00
YHH dde04d514e 新增场景过渡效果 2022-03-12 23:49:14 +08:00
YHH ffddadd798 新增Out类 2022-03-12 10:23:33 +08:00
YHH 5dca337b92 新增MathHelper.toInt 2022-03-12 09:13:06 +08:00
YHH 131df181e6 pool池优化性能 2022-03-07 22:52:51 +08:00
YHH e207952786 性能优化 2022-03-07 16:00:48 +08:00
YHH 3f7ef284fc transform.position更改不需要修改dirty 2022-03-06 18:40:42 +08:00
YHH 1a41533d15 修复mover.motion修正错误问题 2022-03-06 13:56:34 +08:00
YHH 85f7bbbf1a Merge branch 'master' of https://github.com/esengine/ecs-framework
# Conflicts:
#	source/bin/framework.min.js
2022-03-05 10:24:33 +08:00
YHH ccc603b59f 移除渲染模块,提供更纯净的ecs 2022-03-05 10:23:49 +08:00
YHH 8135f99616 防止小游戏函数丢失console.assert 2022-02-24 09:38:07 +08:00
YHH 713f4ae18b Merge branch 'master' of https://github.com/esengine/ecs-framework 2021-10-21 10:09:02 +08:00
YHH f3f5d0bbd1 修复重复多余的定义 2021-10-04 16:53:00 +08:00
YHH 4a9e11c480 更新注释 2021-09-14 18:24:57 +08:00
yhh cd94326aad 新增系统时序控制 2021-08-28 21:26:44 +08:00
yhh a4b971bba0 新增StringUtils.isNullOrEmpty方法 2021-08-26 13:58:09 +08:00
yhh 5d1609111c 补充泛型参数 2021-08-20 19:10:20 +08:00
yhh d54ccaf629 提供component的快捷操作 2021-08-20 19:05:40 +08:00
yhh 6adea240e2 修复componentlist中渲染组件add错误 2021-08-13 19:27:15 +08:00
yhh 3486d403d2 修复ITriggerListener失效问题 2021-08-09 19:08:27 +08:00
yhh f533186c8d listpool根据type划分池 2021-08-06 11:10:45 +08:00
yhh 0beadf8e5a 修复Time不传入dt获取deltaTime错误问题 2021-08-05 11:47:47 +08:00
yhh 8bc06f0476 Merge branch 'master' of https://github.com/esengine/ecs-framework
# Conflicts:
#	extensions/ecs-tween/lib/framework.d.ts
2021-08-04 12:54:18 +08:00
yhh 8fd8f74b27 update physics 2021-08-04 11:28:55 +08:00
yhh 9fc9b60de5 Merge branch 'master' of https://github.com/esengine/ecs-framework into master 2021-08-03 00:13:25 +08:00
yhh 2a026726db 修复tween中start报错 2021-08-03 00:09:43 +08:00
YHH f9a99f8b09 Update physics.md 2021-08-02 09:00:27 +08:00
yhh 95b8dc765d add collision readme 2021-07-27 14:03:57 +08:00
yhh 052d6e25e7 新增emitter与physics文档 2021-07-27 10:05:18 +08:00
yhh fd82486bbc Merge branch 'master' of https://github.com/esengine/ecs-framework into master 2021-07-24 13:48:35 +08:00
yhh ef07f7555f add time/coroutine 使用文档 2021-07-23 14:09:53 +08:00
yhh 67859b7be0 update readme 2021-07-22 10:48:35 +08:00
yhh 1e5ddadd00 Merge branch 'master' of https://github.com/esengine/ecs-framework into master 2021-07-16 07:09:54 +08:00
yhh 7bab76d765 fix 2021-07-16 07:03:14 +08:00
yhh 416f243bda 新增cloth与ragdoll 2021-07-04 23:53:38 +08:00
yhh 77ad112f67 新增tire。修改transform.Component为es.ComponentTransform 2021-07-04 21:03:30 +08:00
yhh dc3d639824 内置tween管理器 2021-07-03 12:27:21 +08:00
yhh 13a001c258 修复verlet报错 2021-07-02 20:59:44 +08:00
yhh 85bdd97d48 新增verlet物理引擎(实验性) 2021-07-02 18:25:30 +08:00
yhh 3d9c8699e7 框架优化 2021-07-02 10:11:09 +08:00
yhh ea482dab48 修复normalized 2021-06-29 18:40:34 +08:00
yhh 96a41eb2cc 移除collider的enable属性 2021-06-22 14:42:30 +08:00
yhh e5dfb20aa2 新增角色控制器 2021-06-22 14:41:21 +08:00
yhh fe308d35f2 完善Color 2021-06-22 13:50:31 +08:00
yhh 219b90fc5d 感谢NEZ库提供的思路 2021-06-11 16:20:01 +08:00
yhh 44e2ca07e5 修复无graphics报错问题 2021-05-28 17:00:33 +08:00
yhh 79d684caae overlapCircle添加检测圆重合 2021-05-28 16:16:58 +08:00
yhh 4db8734a34 添加检查圆重叠的盒子 2021-05-28 16:13:10 +08:00
yhh 8b7baf7f86 新增physics.debugDraw默认绘制 2021-05-28 15:45:45 +08:00
yhh 28145e876f 修复mover返回的collisionResult无数据问题 2021-05-28 15:05:15 +08:00
yhh 53625cf87b 修复mover碰撞失效问题 2021-05-28 14:19:53 +08:00
yhh 88f9779dd0 修复ArcadeRigidbody不触发OnEntityTransform事件 2021-05-28 08:41:38 +08:00
yhh 561a44b26b Merge branch 'master' of https://github.com/esengine/egret-framework 2021-05-27 18:37:17 +08:00
yhh 26068aaf6f 新增渲染接口 2021-05-27 18:32:38 +08:00
YHH fb0f9dc608 Update README.md 2021-05-25 12:10:23 +08:00
yhh 6c44d38c10 对像素进行取整保证在不同分辨率下保持清晰 2021-05-25 11:16:49 +08:00
yhh da3ab02a8d 优化vector2构造函数 2021-05-24 17:20:27 +08:00
yhh 9c7703eb2d 优化框架性能,Time支持传入引擎dt 2021-05-13 16:58:24 +08:00
yhh 84922794fb updateComponent更新 2021-05-12 14:53:29 +08:00
yhh 1dcce99d87 Merge branch 'master' of https://github.com/esengine/egret-framework 2021-05-12 13:09:02 +08:00
yhh fd62aa469a 优化实体更新效率 2021-05-12 13:08:47 +08:00
yhh 63d307b95a 新增identifierPool用于实体id复用 2021-05-11 17:23:04 +08:00
YHH 9f12971eda Update README.md 2021-05-08 10:56:48 +08:00
YHH 47edd4f583 Update README.md 2021-05-08 10:54:22 +08:00
yhh e94b7b23e4 update readme 2021-05-08 10:53:13 +08:00
yhh 5c77e6c56d publish 2021-05-07 16:25:01 +08:00
yhh 522cbe0e6e Merge branch 'master' of https://github.com/esengine/egret-framework
# Conflicts:
#	source/bin/framework.min.js
2021-05-07 16:24:25 +08:00
yhh f7061f360d 移除Bitset更改为Bits 2021-05-07 16:23:15 +08:00
yhh 16cdfa0426 完善mathhelper类与vector2 2021-05-03 08:17:48 +08:00
yhh 74bd0c161f 完善MathHelper/RectangleExt/Vector2Ext 2021-05-02 20:03:56 +08:00
YHH da595e1eb9 Update README.md 2021-04-30 20:55:34 +08:00
yhh 5277c0de7d Time.deltaTime更正
ArcadeRigidbody优化
2021-04-30 20:35:10 +08:00
yhh b3c85e00f9 完善mathHelper类 2021-04-30 15:10:11 +08:00
yhh 0748652a8d 修复getcomponents获取为空问题 2021-04-29 11:00:15 +08:00
yhh 9fa0442b20 shapeCollisions拆分 2021-04-28 14:43:48 +08:00
yhh bc6920f829 优化getComponent与getComponents性能 2021-04-26 15:23:16 +08:00
yhh d576a95548 fix wx 2021-04-23 21:27:34 +08:00
yhh 99eca546d2 remove config 2021-04-21 13:54:10 +08:00
yhh b5d0fc6d0d 优化component add/remove效率 2021-04-20 15:46:18 +08:00
yhh 17b36f01b0 优化实体列表add/remove效率。性能大幅度提高 2021-04-16 17:48:13 +08:00
yhh 5a6d1c72fe Merge branch 'master' of https://github.com/esengine/egret-framework 2021-04-14 17:21:14 +08:00
yhh 030fade7b6 修复bitset问题 2021-04-14 17:17:12 +08:00
YHH 60177d5a8e Update README.md 2021-04-14 10:56:59 +08:00
yhh a28fb72e36 新增 collidesWithAnyNonMotion 2021-04-14 10:51:18 +08:00
yhh 5e15543bab 新增collidesWithAny方法 2021-04-14 10:44:33 +08:00
yhh e1365ed343 新增系统debug使用时间 2021-04-07 15:24:37 +08:00
yhh abb5d10a54 新增getComponentInScene 2021-04-02 19:17:44 +08:00
yhh c58ca510cc 实体获取组件参数补全 2021-04-01 15:48:30 +08:00
yhh 781bad9573 1.新增类型识别
2.EntitySystem新增initialize生命周期,构造函数后执行
2021-03-31 16:59:21 +08:00
yhh 7e94f42b10 修复transform.setparent报错 2021-03-30 18:02:27 +08:00
yhh 0b8d752773 随机类移动至es命名空间 2021-03-29 17:45:36 +08:00
yhh e6096b644f getComponent不再需要指定类型 2021-03-29 17:28:58 +08:00
yhh 6b2c18ad75 更改命名空间linq为es 2021-03-29 15:28:18 +08:00
yhh 8b5bc444f1 场景搜索包含特定组件的实体列表 2021-03-26 17:36:50 +08:00
yhh d2915fe30c 新增 tryGetComponent 方法 2021-03-26 12:53:09 +08:00
yhh b9522ade5d 干掉timerruler 2021-03-26 12:49:00 +08:00
yhh f6513a0cf3 新增jobSystem 2021-02-01 14:23:13 +08:00
yhh d7ec4d087c 优化updateList,性能提高百倍! 2021-02-01 11:11:53 +08:00
yhh 25fca1ed56 新增workerutils 2021-01-29 16:19:00 +08:00
yhh b9822f2270 新增worker辅助类 2021-01-29 16:16:44 +08:00
yhh 11d03cef0c 新增bitVector用于优化bitSet 2021-01-28 11:57:29 +08:00
yhh 1c9276b4a1 新增DelayedIteratingSystem/IntervalSystem/IntervalIteratingSystem 2021-01-27 14:58:51 +08:00
yhh 4f7cfb087a 新增快速开始 README.md 2021-01-26 10:49:25 +08:00
yhh 93768fb4d9 更改注释 2021-01-21 10:18:23 +08:00
yhh f6b6a8aa1b 新增TimeRuler用于分析游戏平均帧率 2021-01-20 15:35:59 +08:00
yhh 1be5862dc4 Merge branch 'master' of https://github.com/esengine/egret-framework 2021-01-19 10:24:36 +08:00
yhh 3e182db019 新增Debug辅助Insist 2021-01-18 19:54:41 +08:00
yhh 8ac1eba378 移除component中的updateInterval 2021-01-18 13:50:48 +08:00
yhh eca9ba7b82 主版本(支持渲染版本移动分支至support_engine) 2021-01-13 13:09:04 +08:00
yhh 6699c32f73 update 2021-01-05 09:41:40 +08:00
yhh cadaeda3bf 初始化适配信息 2021-01-01 18:29:10 +08:00
yhh 62acd38492 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-12-31 16:38:22 +08:00
yhh 01c6c306b1 新增场景策略适配 2020-12-31 16:38:09 +08:00
YHH 1de1b6e05f Update README.md 2020-12-30 17:38:04 +08:00
yhh 6f1fc314b6 新增ecs-tween子模块 2020-12-30 16:38:52 +08:00
yhh d84ffcc2b7 移除Core,新增各接口用于sdk扩展 2020-12-30 16:28:07 +08:00
yhh f934890fac 新增hash 2020-12-28 16:59:16 +08:00
yhh ebc1ab649e 更新collider 2020-12-27 22:23:29 +08:00
yhh 0738e51852 新增Insist断言 2020-12-25 18:04:18 +08:00
yhh 90d84f9316 新增maxRectsBinPack 2020-12-24 11:12:24 +08:00
yhh fa10d5d4d5 新增Coroutine 2020-12-23 17:14:16 +08:00
yhh 8ed3eb24c3 新增Phyisics.overlapRectangle
新增TextureUtils.premultiplyAlpha
新增Entity快速访问Transform内联方法
2020-12-15 11:46:33 +08:00
yhh c60fe13d71 移除fastlist(经测试比Array并没有快) 2020-12-14 11:34:23 +08:00
yhh 59c8d456cb 新增子模块与文件迁移 2020-12-10 16:15:19 +08:00
yhh c0450f21b6 移除注释 2020-12-10 11:19:18 +08:00
yhh 0e7dc67d9d 移除参考依赖 2020-12-10 11:18:56 +08:00
yhh f38b5261d5 新增bezierSpline提供了一系列立方贝塞尔点,并提供了帮助方法来访问贝塞尔 2020-12-10 10:53:05 +08:00
yhh 8230d9cd9b Merge branch 'master' of https://github.com/esengine/egret-framework 2020-12-09 17:57:25 +08:00
yhh 24da0b79c2 修复RealtimeCollisions.intersectMovingCircleBox计算问题 2020-12-09 17:56:48 +08:00
YHH 1c6bb682ea Merge pull request #32 from esengine/imgbot
[ImgBot] Optimize images
2020-12-09 16:58:25 +08:00
YHH 9d2d96c52a Update FUNDING.yml 2020-12-09 11:15:03 +08:00
YHH e455785140 Update FUNDING.yml 2020-12-09 10:58:53 +08:00
YHH dabbe0b6e7 Update FUNDING.yml 2020-12-09 10:58:29 +08:00
ImgBotApp 4c123ed0ec [ImgBot] Optimize images
*Total -- 3,151.12kb -> 2,950.57kb (6.36%)

/sponsor/wechatpay.png -- 130.80kb -> 115.44kb (11.74%)
/sponsor/alipay.jpg -- 234.02kb -> 219.42kb (6.24%)
/screenshot/GIF.gif -- 2,786.30kb -> 2,615.71kb (6.12%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-12-09 02:56:09 +00:00
yhh 838795fd34 新增Matrix2D.toMatrix/Matrix类 2020-12-09 10:55:31 +08:00
YHH c398c714a3 Create FUNDING.yml 2020-12-09 10:38:14 +08:00
yhh 8c5e4537a6 新增visiblityComputer 表示从给定的一组遮挡物的原点可以看到哪些区域 2020-12-07 21:01:21 +08:00
yhh 06b2163aaa 优化spatialHash与修复ArcadeRigidbody报错 2020-12-07 14:58:47 +08:00
yhh cf492daa93 修复emitter 2020-12-07 12:16:36 +08:00
yhh bddae046a0 新增arcadeRigidbody组件, 可以用于简单的,街机风格的物理学 2020-12-07 11:48:42 +08:00
yhh 2a0d4ef4dd 移除color 2020-12-06 23:09:03 +08:00
yhh 8b3b645fbb 新增RealtimeCollisions.testCircleBox用于检测园与方框是否重叠并返回point交点 2020-12-04 16:48:33 +08:00
yhh c8096e3334 update gif 2020-12-04 14:55:17 +08:00
yhh 89d1d9c6c3 修复ArrayUtils.randomItem获取undefined 2020-12-04 14:47:11 +08:00
yhh c2cd3b9c44 修复intervalDistance计算错误问题 2020-12-04 14:42:29 +08:00
yhh 9654a4d8c9 修复foreach迭代无法返回问题 2020-12-04 11:57:54 +08:00
yhh 9d0c583399 EntityList.updateList效率提升10倍 2020-12-04 10:54:51 +08:00
yhh c59c822fbf update gif 2020-12-03 20:49:46 +08:00
yhh 2a257ec5b2 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-12-03 20:47:54 +08:00
yhh 8ce6b53cd5 优化碰撞算法 2020-12-03 20:43:59 +08:00
YHH 5ce44651bf Merge pull request #31 from esengine/imgbot
[ImgBot] Optimize images
2020-12-03 05:00:33 -06:00
yhh dac0ef1507 update readme 2020-12-03 18:08:54 +08:00
ImgBotApp 57c39e9091 [ImgBot] Optimize images
/screenshot/GIF.gif -- 2,994.05kb -> 2,556.37kb (14.62%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-12-03 10:05:56 +00:00
yhh 4f6d3cb10e update screenshot 2020-12-03 18:05:31 +08:00
yhh 4665d1d0ea 修复因Vector2.add/substract/divide/mutiply导致的计算错误 2020-12-03 17:58:25 +08:00
yhh 89cfd5388f Merge branch 'master' of https://github.com/esengine/egret-framework 2020-12-03 10:26:57 +08:00
yhh f41179965d 修复mover因为set遍历问题 2020-12-03 10:24:30 +08:00
yhh f8f83c52a1 新增gif游戏示例 2020-12-02 22:17:26 +08:00
YHH 83b88039e4 Update README.md 2020-12-02 22:02:32 +08:00
yhh 23a7d8af23 修复matrix2d的identity的获取方法。 2020-12-02 19:56:47 +08:00
yhh b2ebd5ee94 修复entityList获取实体失败问题 2020-12-02 15:42:55 +08:00
yhh f9284e9d8e 修复scenecomponent遍历更新报错 2020-12-01 20:02:45 +08:00
yhh 0d8878abef 移除Graphics相关 2020-11-30 18:23:03 +08:00
yhh 0137309d3a 取消Extension改为linq.List以避免forin污染 2020-11-30 13:50:18 +08:00
yhh 4c329881a1 完善sceneComponent中setEnabled。新增Core.Instance._frameCounter与Core.Instance._totalMemory 2020-11-30 12:57:53 +08:00
YHH 3b4a3fad5a Update README.md 2020-11-30 10:07:41 +08:00
yhh bac1ce5b7a 新增hashSet 2020-11-27 11:07:43 +08:00
yhh 6113fd9986 优化entitylist 2020-11-26 20:02:53 +08:00
yhh ae2cfdafdd 优化triggerListener与ArrayUtils 2020-11-26 17:26:49 +08:00
yhh de3f7bff60 生成dts带注释 2020-11-26 11:48:02 +08:00
yhh 97dfcb4c04 新增entitySystemsEnabled用于控制是否开启系统 2020-11-26 10:44:28 +08:00
yhh 1bb1b8704b 新增 _graphicsDeviceChangeTimer 用于凝聚GraphicsDeviceReset事件 2020-11-26 10:39:32 +08:00
YHH 918d998f4c Update README.md 2020-11-25 11:41:28 +08:00
yhh 24edbdd025 update readme 2020-11-25 11:39:58 +08:00
yhh 015a3b633a 新增time.totalTime 2020-11-25 11:37:24 +08:00
yhh 101d720f2a update readme 2020-11-25 11:12:32 +08:00
yhh 8b76eb3ccc update readme 2020-11-25 11:09:02 +08:00
yhh 1e8d2172bc 更新readme 2020-11-24 19:34:07 +08:00
yhh 8bc367ab48 修复bitset调整数组大小时错误/componentTypeManager获取修复 2020-11-24 18:21:26 +08:00
yhh 73b484d894 修复component关系管理器add问题 2020-11-24 15:27:49 +08:00
yhh 5c0ee92d85 判断接口更改、新增FrameUpdated核心事件 2020-11-24 12:15:20 +08:00
yhh e67f568069 取消wxgame依赖,去除debugRender与camera依赖 2020-11-23 18:10:45 +08:00
yhh 5845128479 移除astar库转为插件 2020-11-23 18:02:14 +08:00
yhh 6505f31ad5 移除物理引擎 2020-11-23 17:47:13 +08:00
yhh 30cc74c8eb update readme 2020-11-23 16:39:14 +08:00
yhh eb0787c198 移除gulp.pipe发布 2020-11-23 16:07:55 +08:00
yhh 0f17aff8fd 移除demo 2020-11-23 16:07:30 +08:00
yhh 14a73e4010 移除所有egret 依赖。移除renderablecomponent及所有依赖,移除camera。保持ecs基础框架 2020-11-23 16:05:06 +08:00
yhh 0fd6a24f5a 移除tiled依赖,改为可选 https://github.com/esengine/egret-framework-tiled 2020-11-20 16:30:09 +08:00
yhh 7eab688d9c 新增doc 2020-11-20 14:07:34 +08:00
yhh 562bacbe22 使用zIndex代替swapChildIndex 2020-11-18 14:56:08 +08:00
yhh 8b423310a6 Merge branch 'master' of https://github.com/esengine/egret-framework
# Conflicts:
#	demo/libs/framework/framework.min.js
2020-11-03 10:10:03 +08:00
yhh 7268ebab4a goap sample 2020-11-02 11:06:22 +08:00
yhh 8191359953 修复因fastlist component丢失问题 2020-10-30 20:08:26 +08:00
yhh c9fc9ffea5 新增agent用于帮助快速使用goap 2020-10-29 17:29:38 +08:00
yhh 1a78dada61 新增AI-GOAP目标导向计划与ASTAR寻路配合使用 2020-10-29 11:22:01 +08:00
yhh 85cc4b4ecc Merge branch 'master' of https://github.com/esengine/egret-framework 2020-10-27 18:09:00 +08:00
yhh fc6a8a0803 新增fastList、注释完善 2020-10-27 18:08:49 +08:00
YHH 3d8cdaf46c Update README.md 2020-10-19 13:17:31 +08:00
yhh 0e7b0bc45c 取消entitylist双缓冲区 使用分帧优化大数量实体时卡顿问题 2020-10-09 16:59:34 +08:00
yhh 74fcfd7778 优化updatelist增快addEntity速度 2020-10-09 15:39:06 +08:00
yhh c9c745c730 新增prototypespriteRenderer 2020-09-30 18:31:58 +08:00
yhh dd994cb16d timerRuler 新增调试渲染
timerRuler 提示为中文
2020-09-29 18:26:05 +08:00
yhh 861ef3db31 修复默认origin没有赋值正确问题 2020-09-16 20:16:51 +08:00
yhh f33bac012a update README 2020-09-16 18:17:42 +08:00
yhh 4294632909 update readme 2020-09-16 18:13:37 +08:00
yhh 449ca74e44 update readme 2020-09-16 17:44:11 +08:00
yhh 52980f0b55 新增scene.optimizeCost参数 用于优化cost过高情况 2020-09-16 14:48:15 +08:00
yhh 8e97dcda9c 动态合批 2020-09-15 09:39:26 +08:00
yhh 4ce810bdcd 修复demo 空格项目无法运行问题 2020-09-14 17:59:03 +08:00
yhh 24a463b85b 优化寻路速度 2020-09-14 17:54:17 +08:00
yhh 700d0194be 新增staticSpriteContainerRenderer 2020-09-14 13:32:20 +08:00
yhh 34a8d48df9 Coroutine 类型从IEnumerable为Iterator 2020-09-01 11:51:03 +08:00
YHH 8db028db1c 准备新增verlet物理引擎 2020-08-31 09:28:53 +08:00
yhh 358e899e8b 新增 CoroutineManager 协同程序 2020-08-28 19:12:21 +08:00
yhh 7a308f76b6 debugRender 新增camera参数来修正渲染位置 2020-08-28 18:04:50 +08:00
YHH a3c53116e1 修复碰撞器旋转后bounds计算错误 2020-08-28 09:13:53 +08:00
yhh d07912d610 新增虚拟输入类 VirtualInput 2020-08-27 18:48:20 +08:00
yhh e81f98ff17 修复Vector2.zero引起的引用混乱问题 2020-08-26 19:56:48 +08:00
yhh 1997b3f348 timeruler 绘制 2020-08-25 19:04:12 +08:00
yhh 0ab0728ddf update readme 2020-08-25 17:42:03 +08:00
yhh 46a8de39e3 新增windTransition例子 2020-08-25 17:28:22 +08:00
yhh 794e33a0a0 修复tiledmap tmxDirectory不正确问题 2020-08-25 16:19:56 +08:00
yhh 0bb09f6442 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-08-25 14:21:46 +08:00
yhh 27dea50026 新增Ref类型 2020-08-25 14:21:37 +08:00
YHH a39677062c Merge pull request #30 from esengine/imgbot
[ImgBot] Optimize images
2020-08-24 17:28:04 +08:00
YHH 27f9e78fe5 为boxCollider与spriteRenderer新增debugRender 2020-08-24 09:06:25 +08:00
ImgBotApp fc0a46d6a8 [ImgBot] Optimize images
*Total -- 30.71kb -> 8.13kb (73.53%)

/demo/resource/characters/1.png -- 4.86kb -> 1.18kb (75.76%)
/demo/resource/characters/5.png -- 5.14kb -> 1.28kb (75.09%)
/demo/resource/characters/6.png -- 4.88kb -> 1.25kb (74.41%)
/demo/resource/characters/2.png -- 5.17kb -> 1.41kb (72.79%)
/demo/resource/characters/4.png -- 5.34kb -> 1.51kb (71.74%)
/demo/resource/characters/3.png -- 5.32kb -> 1.51kb (71.69%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-08-23 14:10:25 +00:00
YHH 7345a17d24 新增ninja adventure例子 2020-08-23 22:09:22 +08:00
YHH 6c1cfec928 新增Physics.linecast/linecastAll方法 2020-08-22 12:21:40 +08:00
YHH 73f0f54ba7 Merge pull request #29 from esengine/imgbot
[ImgBot] Optimize images
2020-08-22 00:05:29 +08:00
ImgBotApp 24705d24f1 [ImgBot] Optimize images
*Total -- 162.77kb -> 109.27kb (32.87%)

/demo/resource/preload/orange.png -- 25.79kb -> 5.85kb (77.32%)
/demo/resource/preload/bg.png -- 7.88kb -> 2.81kb (64.37%)
/demo/resource/preload/moon.png -- 1.34kb -> 0.75kb (43.88%)
/demo/resource/preload/orangeNorm.png -- 60.69kb -> 45.92kb (24.32%)
/demo/resource/preload/bgNorm.png -- 28.49kb -> 22.06kb (22.59%)
/demo/resource/assets/buch-outdoor.png -- 16.16kb -> 12.65kb (21.74%)
/demo/resource/preload/moonNorm.png -- 22.42kb -> 19.24kb (14.21%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-08-21 11:22:17 +00:00
yhh 646d1806ec demo 更新 2020-08-21 19:21:40 +08:00
yhh 6d4d787530 修复tiled中objectgroup塞image解析失败问题 2020-08-18 17:39:11 +08:00
yhh 66ef4c6597 tmxDirectory 2020-08-17 19:40:44 +08:00
YHH f7ee2c8d1c tiled 防止中断合批 2020-08-15 22:29:45 +08:00
YHH b3961d8ea1 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-08-15 22:25:22 +08:00
YHH 1a2dd9ff2a tiled 文本位置居中 2020-08-15 22:24:08 +08:00
YHH 21e33495d8 Merge pull request #27 from esengine/develop_tiled
tiled 支持
2020-08-15 22:01:37 +08:00
YHH 23a45bfd2d Merge remote-tracking branch 'remotes/origin/master' into develop_tiled
# Conflicts:
#	demo/libs/framework/framework.min.js
#	source/bin/framework.min.js
2020-08-15 22:00:43 +08:00
YHH 593cc83012 #28 tiled objectgroup解析 2020-08-15 21:59:52 +08:00
YHH f0b2d5b9b8 #28 支持objectgroup的tile类型 2020-08-15 18:16:59 +08:00
YHH 5dc7a72310 #28 tiled orthogonal支持 2020-08-15 12:16:23 +08:00
yhh 89d05726ac #18 动态图集用于优化drawcall 2020-08-14 15:46:19 +08:00
yhh 15f6b06348 #28 修复解析properties 2020-08-14 11:44:20 +08:00
YHH a2a73562a0 #28 tileset 渲染 2020-08-14 08:54:27 +08:00
YHH 9111b69cee #28 parselayers方法修改 2020-08-13 22:23:02 +08:00
yhh 4290a10d5d #28 解析layers 2020-08-13 20:32:36 +08:00
yhh b0511db001 #28 tiled 数据解析与渲染 2020-08-13 17:39:24 +08:00
yhh 4012a9f6d1 新增场景截图 requestScreenshot 2020-08-12 19:57:06 +08:00
yhh e5805960e0 #28 新增tiledMapRenderer用于渲染tiledmap 2020-08-12 18:08:12 +08:00
yhh 167ef03df6 tiled 基本数据 2020-08-12 12:16:35 +08:00
yhh c89ed25d8a update readme 2020-08-11 14:20:39 +08:00
yhh 4baaa2629d Merge branch 'master' of https://github.com/esengine/egret-framework
# Conflicts:
#	README.md
2020-08-11 11:08:27 +08:00
yhh a3dbff63f0 新增相机震动、场景组件 2020-08-11 11:07:20 +08:00
YHH c6ef018d5e Update Reademe 2020-08-10 14:14:20 +08:00
YHH 14b70b307c camera.mapSize 支持左上顶点更改 2020-08-08 15:09:10 +08:00
YHH a39b98b5d9 #23 修复绘制层级问题 2020-08-08 14:43:43 +08:00
YHH 3492bbdf5e 修复scrollingSprite无法向左移动问题 2020-08-08 14:11:25 +08:00
YHH 7d0bcbcb32 demo fix 2020-08-08 10:18:56 +08:00
YHH c02a3aa071 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-08-08 10:12:43 +08:00
YHH a105bb11ca 修复origin导致显示位置错误问题 2020-08-08 10:12:08 +08:00
YHH 3fbbba7ac2 Merge pull request #25 from esengine/develop
#16 新增createEntityAsync方法
2020-08-08 09:51:24 +08:00
YHH 7cd38ea54e #16 新增createEntityAsync方法
修复entity.id为null
2020-08-08 09:50:40 +08:00
YHH 42852c5dba Merge pull request #24 from esengine/develop
#23 组件绘制层支持
2020-08-08 09:44:05 +08:00
YHH 6a3622a5ef #23 组件绘制层支持 2020-08-08 09:43:03 +08:00
YHH 03b568e28d Merge pull request #22 from esengine/develop
#21 新增gapXY用于平铺/滚动间距
2020-08-08 09:07:35 +08:00
YHH e7fb9e0d6b #21 完善 gapxy 2020-08-08 09:06:32 +08:00
yhh 463c64c628 #21 新增gapXY用于平铺/滚动间距 2020-08-07 15:34:42 +08:00
YHH 4025bc8554 Merge pull request #20 from esengine/develop
实现精灵平铺效果
2020-08-07 11:03:05 +08:00
yhh 1bf822725a #19 滚动精灵支持 2020-08-07 11:02:04 +08:00
YHH 359d7ae223 实现 scrollingSprite 2020-08-07 09:21:55 +08:00
YHH c611e31f7e Merge branch 'master' into develop
# Conflicts:
#	demo/libs/framework/framework.min.js
#	demo/src/game/MainScene.ts
#	source/bin/framework.min.js
2020-08-07 08:51:19 +08:00
YHH 834ad565e1 #19 实现精灵平铺效果 2020-08-07 08:50:26 +08:00
yhh ab3f38c6a8 修复lockUtils在wx上报错问题 2020-08-06 12:01:20 +08:00
yhh d0199e357b 修复vector2 y=0赋值错误问题 2020-08-06 10:55:02 +08:00
yhh 8e3bcc1257 射线检测完善 2020-08-03 14:45:57 +08:00
YHH a4fe9f5798 Merge pull request #15 from esengine/develop_ray
射线检测
2020-08-03 14:08:30 +08:00
yhh c692f0157e 新增射线检测 2020-08-03 14:06:47 +08:00
yhh bc6626865e ray2d 2020-07-31 19:33:04 +08:00
yhh 40fe7a57db 新增raycast射线 2020-07-31 17:17:44 +08:00
yhh 514572f291 reformat code 2020-07-28 16:25:20 +08:00
yhh 5994f0bee3 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-07-28 16:12:31 +08:00
yhh b3e1f2c446 边框支持旋转 2020-07-28 16:11:58 +08:00
YHH ed13186779 Merge pull request #13 from esengine/develop_collider
整理ecs框架
2020-07-28 11:08:46 +08:00
yhh d730851d97 修复circleToBox检测偏差问题 2020-07-27 18:16:19 +08:00
yhh 60921f703b #12 fix addObserver函数异常错误 2020-07-27 17:27:32 +08:00
yhh 506f8ddc0f 新增renderablecomponent显示
优化返回值
2020-07-27 16:10:36 +08:00
YHH 149a3e5833 修复tostring导致的循环maxinum call 2020-07-26 23:27:42 +08:00
yhh 2b13e5ee7d 初始化默认数值 2020-07-24 16:57:26 +08:00
yhh 6be43fc9ac 优化transform结构
新增实体列表排序
2020-07-24 15:29:07 +08:00
yhh d4c244daf5 修复运行时未初始化 2020-07-23 19:28:01 +08:00
yhh 79c5d6990c SceneManager更改为Core继承egret.DisplayContainer 2020-07-23 15:39:18 +08:00
yhh 347626a8ea 忽略ide缓存 2020-07-23 13:26:52 +08:00
yhh e61dd0c16b 优化matrix 2020-07-23 13:25:10 +08:00
yhh 1b52bc5fd1 全部移动至es模块 2020-07-23 11:00:46 +08:00
YHH 814234ca61 移动类至es模块 2020-07-23 09:10:27 +08:00
YHH 15c0844e29 移动部分类模块至es
优化框架
2020-07-22 23:30:31 +08:00
yhh 5b8f414a45 整理ecs框架 2020-07-22 20:07:14 +08:00
yhh 6b8569b0b5 collider更改 2020-07-20 16:38:49 +08:00
yhh 2a38858838 提供对SpriteAnimator中的一些字段的访问 2020-07-20 13:46:58 +08:00
yhh e76d5815f2 1. 修正了相机在变焦时不能保持在目标中心的问题
2. 增加检查,以确保碰撞器被触发时enabled也开启
2020-07-20 13:44:26 +08:00
yhh dccd4e21b6 base64辅助类 2020-07-17 15:40:28 +08:00
yhh c96e8b3a04 新增Time/String/Array/Keyboard/Random/Object/Texture辅助类 2020-07-17 14:34:42 +08:00
YHH e686ba64d7 Update README.md 2020-07-17 11:55:29 +08:00
yhh 14cb9cd257 贝塞尔曲线 2020-07-17 11:07:57 +08:00
yhh 13e7737cb9 防止删除一个空的函数发生未定义报错 2020-07-15 10:56:06 +08:00
yhh dd65c60921 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-07-15 10:53:38 +08:00
yhh 7dffb4d94a #12 fix Emitter类移除监听时是否有错 2020-07-15 10:53:30 +08:00
YHH 476204a296 Update README.md 2020-07-13 17:13:53 +08:00
yhh 983c8fbc99 iupdatable无法判断接口 去除改为component支持 2020-07-13 12:48:42 +08:00
YHH c30e591f6e Update README.md 2020-07-13 10:56:25 +08:00
YHH d9a1b5578c Update README.md 2020-07-13 10:56:06 +08:00
YHH f0e04b6981 emitter 支持 context 2020-07-12 23:41:10 +08:00
YHH 14598f08c7 sceneChanged事件 2020-07-12 23:30:48 +08:00
YHH 032b293085 新增analysis用于分析游戏缺陷 2020-07-12 14:51:20 +08:00
YHH d9bb76c105 Merge branch 'master' of https://github.com/esengine/egret-framework
# Conflicts:
#	demo/libs/framework/framework.d.ts
#	demo/libs/framework/framework.min.js
#	demo/src/game/MainScene.ts
#	source/bin/framework.d.ts
#	source/bin/framework.min.js
2020-07-12 09:46:07 +08:00
YHH 20392c8ab6 Set theme jekyll-theme-slate 2020-07-10 12:19:47 +08:00
yhh 583e03d025 Merge branch 'develop' 2020-07-10 11:25:11 +08:00
yhh f6c2d81a83 新增IUpdatable接口 用于减少update所带来的的性能损耗 2020-07-10 11:24:42 +08:00
YHH e703ff4e6c Merge pull request #11 from esengine/develop
Develop
2020-07-09 16:37:13 +08:00
yhh 877fc4c9bf astar 注释 2020-07-09 16:36:42 +08:00
yhh a80bb4b6f3 绘制帮助类 2020-07-09 16:16:04 +08:00
YHH 9b9d210109 Merge pull request #10 from esengine/develop
新增 circleCollider与 polygonCollider
2020-07-09 15:13:58 +08:00
yhh 817b703d4f 新增 circleCollider与 polygonCollider 2020-07-09 15:11:30 +08:00
YHH 88a25453e6 Merge pull request #9 from esengine/develop
对boxcollider碰撞支持
2020-07-09 14:16:52 +08:00
yhh 6e3eb1189a 修复boxcollider碰撞问题 2020-07-09 14:16:10 +08:00
YHH 1e3b2763e8 Merge branch 'develop' of https://github.com/esengine/egret-framework into develop 2020-07-08 22:00:39 +08:00
YHH a3dacd04f0 Merge branch 'master' into develop
# Conflicts:
#	demo/libs/framework/framework.min.js
#	demo/src/game/MainScene.ts
#	source/bin/framework.min.js
2020-07-08 21:56:07 +08:00
yhh aea50926a9 优化spriteRenderer渲染方法 2020-07-08 18:12:17 +08:00
yhh 299c1b8e7d 修复切换场景未移除问题 2020-07-08 15:15:15 +08:00
YHH 3f6ab79894 滚动精灵 2020-07-07 21:40:57 +08:00
yhh b14fee1685 box重载overlaps 2020-07-07 18:54:19 +08:00
yhh ace8fb685d box 重载 collidesWith 2020-07-07 12:18:51 +08:00
YHH 1870ee5e45 Merge pull request #8 from esengine/develop
Develop
2020-07-03 17:53:08 +08:00
yhh 8be65fa685 update reademe 2020-07-03 17:52:26 +08:00
yhh cf4e76b12d 新增tiledspriterenderer 2020-07-03 17:51:18 +08:00
YHH c156463f10 Merge pull request #7 from esengine/develop
新增动画 移除不相关的库
2020-07-03 16:48:34 +08:00
yhh e7796550c6 移除资源 2020-07-03 16:47:24 +08:00
yhh c3c9181400 新增动画 移除不相关的库 2020-07-03 16:45:52 +08:00
YHH 4f4d508685 Merge pull request #6 from esengine/develop
移除 transform
2020-07-01 16:56:45 +08:00
yhh f36a1cdb27 移除 transform 2020-07-01 16:55:10 +08:00
YHH 28941f2395 Merge pull request #4 from esengine/develop
新增被动系统与协调系统 完善matcher
2020-07-01 15:16:23 +08:00
YHH 7f02272304 Merge pull request #5 from esengine/restyled/develop
Restyle 新增被动系统与协调系统 完善matcher
2020-07-01 15:11:39 +08:00
Restyled.io 02d86e7b0a Restyled by prettier 2020-07-01 06:57:39 +00:00
Restyled.io 4c8b6add98 Restyled by clang-format 2020-07-01 06:57:33 +00:00
yhh 60d646c392 移除restylers 2020-07-01 14:57:09 +08:00
yhh 5e871bc501 新增被动系统与协调系统 完善matcher 2020-07-01 14:54:35 +08:00
yhh 549db2fcfe 新增restylers 2020-07-01 14:35:49 +08:00
yhh d9840d60ef 合并camera 2020-07-01 14:19:40 +08:00
yhh 124cf3f66c code quality 2020-06-30 23:44:52 +08:00
yhh cd78b8de59 Merge branch 'master' of https://github.com/esengine/egret-framework 2020-06-30 23:24:10 +08:00
yhh a3209de000 移除stale 2020-06-30 23:23:25 +08:00
YHH 2908be1705 Create SECURITY.md 2020-06-30 23:22:25 +08:00
YHH 009a01ebf4 Merge pull request #3 from esengine/imgbot
[ImgBot] Optimize images
2020-06-30 23:13:18 +08:00
yhh 3fdbf3bfef 新增stale 2020-06-30 23:10:48 +08:00
ImgBotApp c8ecf3cc69 [ImgBot] Optimize images
*Total -- 168.02kb -> 149.53kb (11.01%)

/demo/resource/assets/Panel/border.png -- 1.02kb -> 0.33kb (67.59%)
/demo/resource/assets/Slider/track.png -- 0.91kb -> 0.30kb (67.52%)
/demo/resource/assets/Panel/header.png -- 0.92kb -> 0.31kb (66.52%)
/demo/resource/assets/ItemRenderer/selected.png -- 0.92kb -> 0.31kb (66.52%)
/demo/resource/assets/ScrollBar/roundthumb.png -- 0.91kb -> 0.31kb (66.45%)
/demo/resource/assets/Slider/tracklight.png -- 0.91kb -> 0.31kb (66.45%)
/demo/resource/assets/CheckBox/checkbox_unselect.png -- 0.98kb -> 0.33kb (66.37%)
/demo/resource/assets/RadioButton/radiobutton_unselect.png -- 1.29kb -> 0.45kb (65.43%)
/demo/resource/assets/CheckBox/checkbox_select_disabled.png -- 1.22kb -> 0.43kb (64.91%)
/demo/resource/assets/ProgressBar/track_pb.png -- 0.95kb -> 0.34kb (64.02%)
/demo/resource/assets/ProgressBar/thumb_pb.png -- 0.95kb -> 0.35kb (63.01%)
/demo/resource/assets/ToggleSwitch/handle.png -- 1.13kb -> 0.43kb (61.49%)
/demo/resource/assets/RadioButton/radiobutton_select_up.png -- 1.42kb -> 0.56kb (60.95%)
/demo/resource/assets/Slider/thumb.png -- 1.23kb -> 0.49kb (60.1%)
/demo/resource/assets/ToggleSwitch/off.png -- 1.24kb -> 0.52kb (58.01%)
/demo/resource/assets/ToggleSwitch/on.png -- 1.25kb -> 0.52kb (57.96%)
/demo/resource/assets/CheckBox/checkbox_select_up.png -- 1.23kb -> 0.53kb (57.23%)
/demo/resource/assets/Button/button_up.png -- 1.00kb -> 0.43kb (57.02%)
/demo/resource/assets/CheckBox/checkbox_select_down.png -- 1.21kb -> 0.52kb (56.96%)
/demo/resource/assets/Button/button_down.png -- 1.02kb -> 0.45kb (56.45%)
/demo/resource/assets/RadioButton/radiobutton_select_down.png -- 1.65kb -> 0.79kb (51.81%)
/demo/resource/assets/RadioButton/radiobutton_select_disabled.png -- 1.65kb -> 0.79kb (51.81%)
/demo/resource/assets/egret_icon.png -- 6.62kb -> 4.20kb (36.61%)
/demo/resource/assets/bg.jpg -- 136.40kb -> 135.55kb (0.62%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-06-30 15:08:49 +00:00
yhh 088891c5ca 新增poolcomponent 对象池组件 2020-06-30 22:22:52 +08:00
yhh 099aa749e1 async scenetransition 2020-06-30 21:42:51 +08:00
yhh db7aac2b90 修复场景切换未在临界点切换问题 2020-06-30 14:32:29 +08:00
yhh 366bcf8efc mvc 2020-06-30 11:36:29 +08:00
yhh a4f1ae351f ecs适配egret 2020-06-29 15:41:02 +08:00
YHH a63d8598d8 shader 2020-06-28 08:38:22 +08:00
yhh d7385654ef gaussianblur 特效 2020-06-23 17:36:39 +08:00
yhh 7399b9f5ca 修复transition层级问题 2020-06-23 16:18:14 +08:00
YHH 795bfab1aa 新增postProcessor用于处理屏幕特效 2020-06-23 09:10:40 +08:00
yhh fb5906afe0 新增windtransition 2020-06-22 19:37:10 +08:00
YHH e38cd0f3ca Merge pull request #2 from esengine/develop_scenetransition
新增sceneTransition 用于场景过渡
2020-06-22 15:28:45 +08:00
yhh 481112cfc2 完善渐隐场景转换 2020-06-22 15:27:58 +08:00
YHH 3d9730d956 新增sceneTransition 用于场景过渡 2020-06-21 10:27:15 +08:00
YHH 60646edd6b 新增input类 用于管理触摸点信息 2020-06-19 22:43:56 +08:00
yhh 9bd5a99c81 修复isvisibleFromCamera剔除错误 新增setcolor方法 2020-06-19 19:28:14 +08:00
yhh d22c5775c2 新增Sprite用于控制纹理 2020-06-19 18:16:42 +08:00
YHH 981e149ca5 新增跟随相机 2020-06-19 09:16:49 +08:00
YHH b83b1a5b21 修复stage的宽高错误 2020-06-19 08:32:35 +08:00
YHH 09e6ace142 更新相机强制刷新矩阵 2020-06-19 00:38:37 +08:00
YHH e83bb087ea 相机渲染 2020-06-18 23:22:54 +08:00
yhh feaac83ee7 新增renderer渲染器 用于控制场景如何渲染 2020-06-18 16:35:51 +08:00
yhh 915056203d 新增全局管理器 2020-06-18 12:14:06 +08:00
yhh 231276e39b 新增renderable组件render方法 去除mathhelper.minof/maxof 2020-06-18 10:49:32 +08:00
yhh 9c293979a4 v1.0.1 2020-06-18 10:07:08 +08:00
YHH bc995e36c2 修复 triggerlistener 发生碰撞后不断触发问题(仅第一次碰撞触发) 2020-06-18 09:06:59 +08:00
YHH 18279d16cd 修复 collsionTriggerHelper 遍历问题 2020-06-18 00:03:01 +08:00
YHH 59b2f150f3 新增Long库 移除原有Long.ts 2020-06-17 23:19:25 +08:00
YHH e6d6c4199f fix long 2020-06-17 22:40:49 +08:00
yhh ccf8c4e107 新增 Long 类型 2020-06-17 20:40:56 +08:00
yhh 9e6e5eccc8 新增numberdictionary的散列键 2020-06-16 20:22:22 +08:00
yhh 447ea4efe4 修复box因缺少初始化报错问题 2020-06-16 16:35:17 +08:00
yhh 7f5b78f340 新增gulp build 2020-06-16 13:27:06 +08:00
YHH 4ac8bafa87 Merge pull request #1 from esengine/develop-test-ci
Create node.js.yml
2020-06-16 13:19:06 +08:00
yhh 25ce4c9cf9 remove test 2020-06-16 13:16:58 +08:00
yhh 2b81a0b06b Merge branch 'master' into develop-test-ci 2020-06-16 13:14:37 +08:00
yhh e68f6bd1be packages 2020-06-16 13:13:55 +08:00
YHH 06c1aeb97a Create node.js.yml 2020-06-16 12:46:40 +08:00
yhh ced176706b 修复physics register失效问题 2020-06-16 11:59:40 +08:00
yhh 8b21edc65f 新增mover移动器组件 用于处理itriggerListener接口碰撞信息 2020-06-16 11:22:37 +08:00
YHH 75301f7776 完善 colliderTriggerHelper 用于更新碰撞信息 2020-06-16 09:10:09 +08:00
YHH dba43b9773 完善shapeCollision 支持多边形 2020-06-16 00:04:28 +08:00
yhh 5186bc0187 修复polygon数组错误 修复emit空注册报错 2020-06-15 20:08:21 +08:00
yhh c3120d791f 新增事件发送接收器 2020-06-15 12:16:23 +08:00
yhh 16892eb7af 移除物理引擎 移动到新库 2020-06-15 10:42:06 +08:00
YHH 7f8f1cf0d0 优化collision 2020-06-15 08:46:38 +08:00
yhh 246e9a9511 新增shapecollision 用于计算多边形碰撞 2020-06-12 20:24:51 +08:00
YHH da5a1a0c79 优化Flags 2020-06-12 08:56:10 +08:00
YHH 6fa56dd572 新增flag 帮助处理位掩码 2020-06-12 08:47:13 +08:00
yhh ad68f0e1a0 新增shape形状 2020-06-11 20:36:36 +08:00
yhh 53ded30e0b 优化圆和矩形碰撞检测 2020-06-11 10:06:29 +08:00
YHH 2eec9a82f9 新增box复合体 修复vector2运算问题 2020-06-11 00:03:26 +08:00
yhh 74cbb4c9fd 新增verletworld 2020-06-10 20:29:16 +08:00
yhh fa4c3c5d0b 新增相机bounds与可渲染组件bounds 并添加可渲染组件的剔除方法 2020-06-10 17:41:53 +08:00
yhh f62f449d99 新增renderableComponent 用于控制可渲染组件的基类 不要在transform当中直接更改目标属性 2020-06-10 16:25:39 +08:00
yhh 94818d5784 新增webgl帮助类 用于自定义绘图 2020-06-10 13:38:04 +08:00
yhh 5f7c13c8cd 新增breadthfirst与dijkstra寻路算法 2020-06-10 12:23:19 +08:00
YHH 538677575d 新增polygonmesh 2020-06-10 08:57:17 +08:00
YHH 1816b16924 readme 更新 2020-06-09 23:14:47 +08:00
2033 changed files with 432088 additions and 146924 deletions
+62
View File
@@ -0,0 +1,62 @@
{
"projectName": "ecs-framework",
"projectOwner": "esengine",
"repoType": "github",
"repoHost": "https://github.com",
"files": ["README.md"],
"imageSize": 100,
"commit": true,
"commitConvention": "angular",
"contributors": [
{
"login": "yhh",
"name": "Frank Huang",
"avatar_url": "https://avatars.githubusercontent.com/u/145575?v=4",
"profile": "https://github.com/yhh",
"contributions": ["code"]
}
],
"contributorsPerLine": 7,
"contributorsSortAlphabetically": false,
"badgeTemplate": "[![All Contributors](https://img.shields.io/badge/all_contributors-<%= contributors.length %>-orange.svg?style=flat-square)](#contributors)",
"contributorTemplate": "<a href=\"<%= contributor.profile %>\"><img src=\"<%= contributor.avatar_url %>\" width=\"<%= options.imageSize %>px;\" alt=\"<%= contributor.name %>\"/><br /><sub><b><%= contributor.name %></b></sub></a>",
"types": {
"code": {
"symbol": "💻",
"description": "Code",
"link": "[<%= symbol %>](<%= url %> \"Code\")"
},
"doc": {
"symbol": "📖",
"description": "Documentation",
"link": "[<%= symbol %>](<%= url %> \"Documentation\")"
},
"test": {
"symbol": "⚠️",
"description": "Tests",
"link": "[<%= symbol %>](<%= url %> \"Tests\")"
},
"bug": {
"symbol": "🐛",
"description": "Bug reports",
"link": "[<%= symbol %>](<%= url %> \"Bug reports\")"
},
"example": {
"symbol": "💡",
"description": "Examples",
"link": "[<%= symbol %>](<%= url %> \"Examples\")"
},
"design": {
"symbol": "🎨",
"description": "Design",
"link": "[<%= symbol %>](<%= url %> \"Design\")"
},
"ideas": {
"symbol": "🤔",
"description": "Ideas & Planning",
"link": "[<%= symbol %>](<%= url %> \"Ideas & Planning\")"
}
},
"skipCi": true
}
+36
View File
@@ -0,0 +1,36 @@
# CodeRabbit 配置文件
# https://docs.coderabbit.ai/configuration
language: "zh-CN" # 使用中文评论
reviews:
# 审查级别
profile: "chill" # "chill" 或 "strict" 或 "assertive"
# 自动审查设置
auto_review:
enabled: true
drafts: false # 草稿 PR 不自动审查
base_branches:
- master
- main
# 审查内容
request_changes_workflow: false # 不阻止 PR 合并
high_level_summary: true # 生成高层次摘要
poem: false # 不生成诗歌(可以改为 true 增加趣味)
review_status: true # 显示审查状态
# 忽略的文件
path_filters:
- "!**/*.md" # 不审查 markdown
- "!**/package-lock.json" # 不审查 lock 文件
- "!**/dist/**" # 不审查构建输出
- "!**/*.min.js" # 不审查压缩文件
# 聊天设置
chat:
auto_reply: true # 自动回复问题
# 提交建议
suggestions:
enabled: true # 启用代码建议
+29
View File
@@ -0,0 +1,29 @@
{
"extends": ["@commitlint/config-conventional"],
"rules": {
"type-enum": [
2,
"always",
[
"feat",
"fix",
"docs",
"style",
"refactor",
"perf",
"test",
"build",
"ci",
"chore",
"revert"
]
],
"scope-enum": [
0
],
"scope-empty": [0],
"subject-empty": [2, "never"],
"subject-case": [0],
"header-max-length": [2, "always", 100]
}
}
+35
View File
@@ -0,0 +1,35 @@
# EditorConfig is awesome: https://EditorConfig.org
# top-most EditorConfig file
root = true
# 所有文件的默认设置
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true
# TypeScript/JavaScript 文件
[*.{ts,tsx,js,jsx,mjs,cjs}]
indent_style = space
indent_size = 4
# JSON 文件
[*.json]
indent_style = space
indent_size = 2
# YAML 文件
[*.{yml,yaml}]
indent_style = space
indent_size = 2
# Markdown 文件
[*.md]
trim_trailing_whitespace = false
indent_size = 2
# 包管理文件
[{package.json,package-lock.json,tsconfig.json}]
indent_size = 2
+4
View File
@@ -0,0 +1,4 @@
{
"toolchains": [],
"backend.maxHeapSizeMb": 896
}
+44
View File
@@ -0,0 +1,44 @@
# 自动检测文本文件并规范化换行符
* text=auto
# 源代码文件强制使用 LF
*.ts text eol=lf
*.tsx text eol=lf
*.js text eol=lf
*.jsx text eol=lf
*.mjs text eol=lf
*.cjs text eol=lf
*.json text eol=lf
*.md text eol=lf
*.yml text eol=lf
*.yaml text eol=lf
# 配置文件强制使用 LF
.gitignore text eol=lf
.gitattributes text eol=lf
.editorconfig text eol=lf
.prettierrc text eol=lf
.prettierignore text eol=lf
.eslintrc.json text eol=lf
tsconfig.json text eol=lf
# Shell 脚本强制使用 LF
*.sh text eol=lf
# Windows 批处理文件使用 CRLF
*.bat text eol=crlf
*.cmd text eol=crlf
*.ps1 text eol=crlf
# 二进制文件不转换
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.ico binary
*.svg binary
*.woff binary
*.woff2 binary
*.ttf binary
*.eot binary
*.otf binary
+12
View File
@@ -0,0 +1,12 @@
# These are supported funding model platforms
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: esengine # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: ['https://github.com/esengine/esengine/blob/master/sponsor/alipay.jpg', 'https://github.com/esengine/esengine/blob/master/sponsor/wechatpay.png'] # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
+130
View File
@@ -0,0 +1,130 @@
name: 🐛 Bug Report / 错误报告
description: Report a bug or issue / 报告一个错误或问题
title: "[Bug]: "
labels: ["bug"]
body:
- type: markdown
attributes:
value: |
感谢你提交 Bug 报告!请填写以下信息帮助我们更快定位问题。
Thanks for reporting a bug! Please fill in the information below to help us locate the issue faster.
- type: textarea
id: description
attributes:
label: 问题描述 / Bug Description
description: 清晰简洁地描述遇到的问题 / A clear and concise description of the bug
placeholder: 例如:当我创建超过1000个实体时,游戏卡顿严重...
validations:
required: true
- type: textarea
id: reproduction
attributes:
label: 复现步骤 / Steps to Reproduce
description: 如何复现这个问题?/ How can we reproduce this issue?
placeholder: |
1. 创建场景
2. 添加 1000 个实体
3. 运行游戏
4. 观察卡顿
value: |
1.
2.
3.
validations:
required: true
- type: textarea
id: expected
attributes:
label: 期望行为 / Expected Behavior
description: 你期望发生什么?/ What did you expect to happen?
placeholder: 游戏应该流畅运行,FPS 保持在 60...
validations:
required: true
- type: textarea
id: actual
attributes:
label: 实际行为 / Actual Behavior
description: 实际发生了什么?/ What actually happened?
placeholder: FPS 降到 20,游戏严重卡顿...
validations:
required: true
- type: input
id: version
attributes:
label: 版本 / Version
description: 使用的 @esengine/ecs-framework 版本 / Version of @esengine/ecs-framework
placeholder: 例如 / e.g., 2.2.8
validations:
required: true
- type: dropdown
id: platform
attributes:
label: 平台 / Platform
description: 在哪个平台遇到问题?/ Which platform did you encounter the issue?
multiple: true
options:
- Web / 浏览器
- Cocos Creator
- Laya Engine
- WeChat Mini Game / 微信小游戏
- Other / 其他
validations:
required: true
- type: textarea
id: environment
attributes:
label: 环境信息 / Environment
description: |
相关环境信息 / Relevant environment information
例如:操作系统、浏览器版本、Node.js 版本等
placeholder: |
- OS: Windows 11
- Browser: Chrome 120
- Node.js: 20.10.0
value: |
- OS:
- Browser:
- Node.js:
validations:
required: false
- type: textarea
id: code
attributes:
label: 代码示例 / Code Sample
description: 如果可能,提供最小可复现代码 / If possible, provide minimal reproducible code
render: typescript
placeholder: |
import { Core, Scene, Entity } from '@esengine/ecs-framework';
// 你的代码 / Your code here
validations:
required: false
- type: textarea
id: logs
attributes:
label: 错误日志 / Error Logs
description: 相关的错误日志或截图 / Relevant error logs or screenshots
render: shell
validations:
required: false
- type: checkboxes
id: checklist
attributes:
label: 检查清单 / Checklist
options:
- label: 我已经搜索过类似的 issue / I have searched for similar issues
required: true
- label: 我使用的是最新版本 / I am using the latest version
required: false
- label: 我愿意提交 PR 修复此问题 / I am willing to submit a PR to fix this issue
required: false
+17
View File
@@ -0,0 +1,17 @@
blank_issues_enabled: true
contact_links:
- name: 📚 文档 / Documentation
url: https://esengine.github.io/ecs-framework/
about: 查看完整文档和教程 / View full documentation and tutorials
- name: 🤖 AI 文档助手 / AI Documentation Assistant
url: https://deepwiki.com/esengine/esengine
about: 使用 AI 助手快速找到答案 / Use AI assistant to quickly find answers
- name: 💬 QQ 交流群 / QQ Group
url: https://jq.qq.com/?_wv=1027&k=29w1Nud6
about: 加入社区交流群 / Join the community group
- name: 🌟 GitHub Discussions
url: https://github.com/esengine/esengine/discussions
about: 参与社区讨论 / Join community discussions
@@ -0,0 +1,90 @@
name: ✨ Feature Request / 功能建议
description: Suggest a new feature or enhancement / 建议新功能或改进
title: "[Feature]: "
labels: ["enhancement"]
body:
- type: markdown
attributes:
value: |
感谢你的功能建议!请详细描述你的想法。
Thanks for your feature suggestion! Please describe your idea in detail.
- type: textarea
id: problem
attributes:
label: 问题描述 / Problem Description
description: 这个功能解决什么问题?/ What problem does this feature solve?
placeholder: 当我需要...的时候,现在很不方便,因为... / When I need to..., it's inconvenient because...
validations:
required: true
- type: textarea
id: solution
attributes:
label: 建议的解决方案 / Proposed Solution
description: 你希望如何实现这个功能?/ How would you like this feature to work?
placeholder: 可以添加一个新的 API,例如... / Could add a new API, for example...
validations:
required: true
- type: textarea
id: alternatives
attributes:
label: 其他方案 / Alternatives
description: 你考虑过哪些替代方案?/ What alternatives have you considered?
placeholder: 也可以通过...来实现,但是... / Could also achieve this by..., but...
validations:
required: false
- type: textarea
id: examples
attributes:
label: 使用示例 / Usage Example
description: 展示这个功能如何使用 / Show how this feature would be used
render: typescript
placeholder: |
// 理想的 API 设计 / Ideal API design
const pool = new ComponentPool(MyComponent, { size: 100 });
const component = pool.acquire();
validations:
required: false
- type: dropdown
id: scope
attributes:
label: 影响范围 / Scope
description: 这个功能主要影响哪个部分?/ Which part does this feature mainly affect?
options:
- Core / 核心框架
- Performance / 性能
- API Design / API 设计
- Developer Experience / 开发体验
- Documentation / 文档
- Editor / 编辑器
- Other / 其他
validations:
required: true
- type: dropdown
id: priority
attributes:
label: 优先级 / Priority
description: 你认为这个功能有多重要?/ How important do you think this feature is?
options:
- High / 高 - 非常需要这个功能
- Medium / 中 - 有会更好
- Low / 低 - 可有可无
validations:
required: true
- type: checkboxes
id: checklist
attributes:
label: 检查清单 / Checklist
options:
- label: 我已经搜索过类似的功能请求 / I have searched for similar feature requests
required: true
- label: 这个功能不会破坏现有 API / This feature won't break existing APIs
required: false
- label: 我愿意提交 PR 实现此功能 / I am willing to submit a PR to implement this feature
required: false
+64
View File
@@ -0,0 +1,64 @@
name: ❓ Question / 问题咨询
description: Ask a question about using the framework / 询问框架使用问题
title: "[Question]: "
labels: ["question"]
body:
- type: markdown
attributes:
value: |
💡 提示:如果是简单问题,可以先查看:
- [📚 文档](https://esengine.github.io/ecs-framework/)
- [📖 AI 文档助手](https://deepwiki.com/esengine/esengine)
- [💬 QQ 交流群](https://jq.qq.com/?_wv=1027&k=29w1Nud6)
💡 Tip: For simple questions, please check first:
- [📚 Documentation](https://esengine.github.io/ecs-framework/)
- [📖 AI Documentation](https://deepwiki.com/esengine/esengine)
- type: textarea
id: question
attributes:
label: 你的问题 / Your Question
description: 清晰描述你的问题 / Describe your question clearly
placeholder: 如何在 Cocos Creator 中使用 ECS Framework
validations:
required: true
- type: textarea
id: context
attributes:
label: 背景信息 / Context
description: 提供更多上下文帮助理解问题 / Provide more context to help understand
placeholder: |
我正在开发一个多人在线游戏...
我尝试过...但是...
validations:
required: false
- type: textarea
id: code
attributes:
label: 相关代码 / Related Code
description: 如果适用,提供相关代码片段 / If applicable, provide relevant code snippet
render: typescript
validations:
required: false
- type: input
id: version
attributes:
label: 版本 / Version
description: 使用的框架版本 / Framework version you're using
placeholder: 例如 / e.g., 2.2.8
validations:
required: false
- type: checkboxes
id: checklist
attributes:
label: 检查清单 / Checklist
options:
- label: 我已经查看过文档 / I have checked the documentation
required: true
- label: 我已经搜索过类似问题 / I have searched for similar questions
required: true
+8
View File
@@ -0,0 +1,8 @@
name: "CodeQL Config"
# Paths to exclude from analysis
paths-ignore:
- thirdparty
- "**/node_modules"
- "**/dist"
- "**/bin"
+32
View File
@@ -0,0 +1,32 @@
# 自动标签配置
# 根据 issue/PR 内容自动打标签
'bug':
- '/(bug|错误|崩溃|crash|error|exception|问题)/i'
'enhancement':
- '/(feature|功能|enhancement|improve|优化|建议)/i'
'documentation':
- '/(doc|文档|readme|guide|tutorial|教程)/i'
'question':
- '/(question|疑问|how to|如何|怎么)/i'
'performance':
- '/(performance|性能|slow|慢|lag|卡顿|optimize)/i'
'core':
- '/(@esengine\/ecs-framework|packages\/core|core package)/i'
'editor':
- '/(editor|编辑器|tauri)/i'
'network':
- '/(network|网络|multiplayer|多人)/i'
'help wanted':
- '/(help wanted|需要帮助|求助)/i'
'good first issue':
- '/(good first issue|新手友好|beginner)/i'
+95
View File
@@ -0,0 +1,95 @@
# GitHub Labels 配置
# 可以使用 https://github.com/Financial-Times/github-label-sync 来同步标签
# Size Labels (PR 大小)
- name: 'size/XS'
color: '00ff00'
description: '极小的改动 (< 10 行)'
- name: 'size/S'
color: '00ff00'
description: '小改动 (10-100 行)'
- name: 'size/M'
color: 'ffff00'
description: '中等改动 (100-500 行)'
- name: 'size/L'
color: 'ff9900'
description: '大改动 (500-1000 行)'
- name: 'size/XL'
color: 'ff0000'
description: '超大改动 (> 1000 行)'
# Type Labels
- name: 'bug'
color: 'd73a4a'
description: '错误或问题'
- name: 'enhancement'
color: 'a2eeef'
description: '新功能或改进'
- name: 'documentation'
color: '0075ca'
description: '文档相关'
- name: 'question'
color: 'd876e3'
description: '问题咨询'
- name: 'performance'
color: 'ff6b6b'
description: '性能相关'
# Scope Labels
- name: 'core'
color: '5319e7'
description: '核心包相关'
- name: 'editor'
color: '5319e7'
description: '编辑器相关'
- name: 'network'
color: '5319e7'
description: '网络相关'
# Status Labels
- name: 'stale'
color: 'ededed'
description: '长时间无活动'
- name: 'wip'
color: 'fbca04'
description: '进行中'
- name: 'help wanted'
color: '008672'
description: '需要帮助'
- name: 'good first issue'
color: '7057ff'
description: '适合新手'
- name: 'quick-review'
color: '00ff00'
description: '小改动,快速 Review'
- name: 'automerge'
color: 'bfdadc'
description: '自动合并'
- name: 'pinned'
color: 'c2e0c6'
description: '置顶,不会被标记为 stale'
- name: 'security'
color: 'ee0701'
description: '安全相关,高优先级'
# Dependencies
- name: 'dependencies'
color: '0366d6'
description: '依赖更新'
@@ -0,0 +1,73 @@
name: AI Batch Analyze Issues
on:
workflow_dispatch:
inputs:
mode:
description: '分析模式'
required: true
type: choice
options:
- 'recent' # 最近 10 个 issue
- 'open' # 所有打开的 issue
- 'all' # 所有 issue(慎用)
default: 'recent'
permissions:
issues: write
contents: read
jobs:
analyze:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Install GitHub CLI
run: |
gh --version || (curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | sudo dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null
sudo apt update
sudo apt install gh)
- name: Batch Analyze Issues
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
MODE="${{ github.event.inputs.mode }}"
# 获取 issue 列表
if [ "$MODE" = "recent" ]; then
echo "📊 分析最近 10 个 issue..."
ISSUES=$(gh issue list --limit 10 --json number --jq '.[].number')
elif [ "$MODE" = "open" ]; then
echo "📊 分析所有打开的 issue..."
ISSUES=$(gh issue list --state open --json number --jq '.[].number')
else
echo "📊 分析所有 issue(这可能需要很长时间)..."
ISSUES=$(gh issue list --state all --limit 100 --json number --jq '.[].number')
fi
# 为每个 issue 添加 AI 分析评论
for issue_num in $ISSUES; do
echo "🤖 分析 Issue #$issue_num..."
# 获取 issue 内容
ISSUE_BODY=$(gh issue view $issue_num --json body --jq '.body')
ISSUE_TITLE=$(gh issue view $issue_num --json title --jq '.title')
# 添加触发评论
gh issue comment $issue_num --body "@ai-helper 请帮我分析这个 issue" || true
# 避免 API 限制
sleep 2
done
echo "✅ 批量分析完成!"
echo "查看结果:https://github.com/${{ github.repository }}/issues"
+61
View File
@@ -0,0 +1,61 @@
name: AI Helper Tip
# 对所有新创建的 issue 自动回复 AI 助手使用说明(新老用户都适用)
on:
issues:
types: [opened]
permissions:
issues: write
jobs:
tip:
runs-on: ubuntu-latest
steps:
- name: Post AI Helper Usage Tip
uses: actions/github-script@v7
with:
script: |
const message = [
"## 🤖 AI 助手可用 | AI Helper Available",
"",
"**中文说明:**",
"",
"本项目配备了 AI 智能助手,可以帮助你快速获得解答!",
"",
"**使用方法:** 在评论中提及 `@ai-helper`,AI 会自动搜索项目代码并提供解决方案。",
"",
"**示例:**",
"```",
"@ai-helper 如何创建一个新的 System",
"@ai-helper 这个报错是什么原因?",
"```",
"",
"---",
"",
"**English:**",
"",
"This project has an AI assistant to help you get answers quickly!",
"",
"**How to use:** Mention `@ai-helper` in a comment, and AI will automatically search the codebase and provide solutions.",
"",
"**Examples:**",
"```",
"@ai-helper How do I create a new System?",
"@ai-helper What causes this error?",
"```",
"",
"---",
"",
"💡 *AI 助手基于代码库提供建议,复杂问题建议等待维护者回复*",
"💡 *AI suggestions are based on the codebase. For complex issues, please wait for maintainer responses*"
].join('\n');
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body: message
});
console.log('✅ AI helper tip posted successfully');
+85
View File
@@ -0,0 +1,85 @@
name: AI Issue Helper
on:
issue_comment:
types: [created]
permissions:
issues: write
contents: read
models: read
jobs:
ai-helper:
runs-on: ubuntu-latest
# 只在真实用户提到 @ai-helper 时触发,忽略机器人评论
if: |
contains(github.event.comment.body, '@ai-helper') &&
github.event.comment.user.type != 'Bot'
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Get Issue Details
id: issue
uses: actions/github-script@v7
with:
script: |
const issue = await github.rest.issues.get({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number
});
// 限制长度,避免超过 token 限制
const maxLength = 1000;
const truncate = (str, max) => {
if (!str) return '';
return str.length > max ? str.substring(0, max) + '...[内容过长已截断]' : str;
};
core.exportVariable('ISSUE_TITLE', truncate(issue.data.title || '', 200));
core.exportVariable('ISSUE_BODY', truncate(issue.data.body || '', maxLength));
core.exportVariable('COMMENT_BODY', truncate(context.payload.comment.body || '', 500));
core.exportVariable('ISSUE_NUMBER', context.issue.number);
- name: Create Prompt
id: prompt
run: |
cat > prompt.txt << 'PROMPT_EOF'
Issue #${{ env.ISSUE_NUMBER }}
标题: ${{ env.ISSUE_TITLE }}
内容: ${{ env.ISSUE_BODY }}
评论: ${{ env.COMMENT_BODY }}
请搜索项目代码并提供解决方案。
PROMPT_EOF
- name: AI Analysis
uses: actions/ai-inference@v1
id: ai
with:
model: 'gpt-4o'
enable-github-mcp: true
max-tokens: 1500
system-prompt: |
你是 ECS Framework (TypeScript ECS 框架) 的 AI 助手。
主要代码在 packages/core/src。
搜索相关代码后,用中文简洁回答问题,包含问题分析、解决方案和代码引用。
prompt-file: prompt.txt
- name: Post AI Response
env:
AI_RESPONSE: ${{ steps.ai.outputs.response }}
uses: actions/github-script@v7
with:
script: |
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body: process.env.AI_RESPONSE
});
+56
View File
@@ -0,0 +1,56 @@
name: AI Issue Moderator
on:
issues:
types: [opened]
issue_comment:
types: [created]
permissions:
issues: write
contents: read
models: read
jobs:
moderate:
runs-on: ubuntu-latest
steps:
- name: Check Content
uses: actions/ai-inference@v1
id: check
with:
model: 'gpt-4o-mini'
system-prompt: |
你是一个内容审查助手。
检查内容是否包含:
1. 垃圾信息或广告
2. 恶意或攻击性内容
3. 与项目完全无关的内容
只返回 "SPAM" 或 "OK",不要其他内容。
prompt: |
标题:${{ github.event.issue.title || github.event.comment.body }}
内容:
${{ github.event.issue.body || github.event.comment.body }}
- name: Mark as Spam
if: contains(steps.check.outputs.response, 'SPAM')
uses: actions/github-script@v7
with:
script: |
// 添加 spam 标签
github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
labels: ['spam']
});
// 添加评论
github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body: '🤖 这个内容被 AI 检测为可能的垃圾内容。如果这是误判,请联系维护者。\n\n🤖 This content was detected as potential spam by AI. If this is a false positive, please contact the maintainers.'
});
+160
View File
@@ -0,0 +1,160 @@
name: Batch Label Issues
on:
workflow_dispatch:
inputs:
mode:
description: '标签模式'
required: true
type: choice
options:
- 'recent' # 最近 20 个 issue
- 'open' # 所有打开的 issue
- 'unlabeled' # 只处理没有标签的 issue
- 'all' # 所有 issue(慎用)
default: 'recent'
skip_labeled:
description: '跳过已有标签的 issue'
required: false
type: boolean
default: true
permissions:
issues: write
contents: read
jobs:
batch-label:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Batch Label Issues
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
MODE="${{ github.event.inputs.mode }}"
SKIP_LABELED="${{ github.event.inputs.skip_labeled }}"
echo "📊 开始批量打标签..."
echo "模式: $MODE"
echo "跳过已标签: $SKIP_LABELED"
# 获取 issue 列表
if [ "$MODE" = "recent" ]; then
echo "📋 获取最近 20 个 issue..."
ISSUES=$(gh issue list --limit 20 --json number,labels,title,body --jq '.[] | {number, labels: [.labels[].name], title, body}')
elif [ "$MODE" = "open" ]; then
echo "📋 获取所有打开的 issue..."
ISSUES=$(gh issue list --state open --json number,labels,title,body --jq '.[] | {number, labels: [.labels[].name], title, body}')
elif [ "$MODE" = "unlabeled" ]; then
echo "📋 获取没有标签的 issue..."
ISSUES=$(gh issue list --state all --json number,labels,title,body --jq '.[] | select(.labels | length == 0) | {number, labels: [.labels[].name], title, body}')
else
echo "📋 获取所有 issue(限制 100 个)..."
ISSUES=$(gh issue list --state all --limit 100 --json number,labels,title,body --jq '.[] | {number, labels: [.labels[].name], title, body}')
fi
# 临时文件
echo "$ISSUES" > /tmp/issues.json
# 处理每个 issue
cat /tmp/issues.json | jq -c '.' | while read -r issue; do
ISSUE_NUM=$(echo "$issue" | jq -r '.number')
EXISTING_LABELS=$(echo "$issue" | jq -r '.labels | join(",")')
TITLE=$(echo "$issue" | jq -r '.title')
BODY=$(echo "$issue" | jq -r '.body')
echo ""
echo "🔍 处理 Issue #$ISSUE_NUM: $TITLE"
echo " 现有标签: $EXISTING_LABELS"
# 跳过已有标签的 issue
if [ "$SKIP_LABELED" = "true" ] && [ ! -z "$EXISTING_LABELS" ]; then
echo " ⏭️ 跳过(已有标签)"
continue
fi
# 分析内容并打标签
LABELS_TO_ADD=""
# 检测 bug
if echo "$TITLE $BODY" | grep -iE "(bug|错误|崩溃|crash|error|exception|问题|fix)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD bug"
echo " 🐛 检测到: bug"
fi
# 检测 feature request
if echo "$TITLE $BODY" | grep -iE "(feature|功能|enhancement|improve|优化|建议|新增|添加|add)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD enhancement"
echo " ✨ 检测到: enhancement"
fi
# 检测 question
if echo "$TITLE $BODY" | grep -iE "(question|疑问|how to|如何|怎么|为什么|why|咨询|\?|)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD question"
echo " ❓ 检测到: question"
fi
# 检测 documentation
if echo "$TITLE $BODY" | grep -iE "(doc|文档|readme|guide|tutorial|教程|说明)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD documentation"
echo " 📖 检测到: documentation"
fi
# 检测 performance
if echo "$TITLE $BODY" | grep -iE "(performance|性能|slow|慢|lag|卡顿|optimize|优化)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD performance"
echo " ⚡ 检测到: performance"
fi
# 检测 core
if echo "$TITLE $BODY" | grep -iE "(@esengine/ecs-framework|packages/core|core package|核心包)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD core"
echo " 🎯 检测到: core"
fi
# 检测 editor
if echo "$TITLE $BODY" | grep -iE "(editor|编辑器|tauri)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD editor"
echo " 🎨 检测到: editor"
fi
# 检测 network
if echo "$TITLE $BODY" | grep -iE "(network|网络|multiplayer|多人|同步)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD network"
echo " 🌐 检测到: network"
fi
# 检测 help wanted
if echo "$TITLE $BODY" | grep -iE "(help wanted|需要帮助|求助)" > /dev/null; then
LABELS_TO_ADD="$LABELS_TO_ADD help wanted"
echo " 🆘 检测到: help wanted"
fi
# 添加标签
if [ ! -z "$LABELS_TO_ADD" ]; then
echo " ✅ 添加标签: $LABELS_TO_ADD"
for label in $LABELS_TO_ADD; do
gh issue edit $ISSUE_NUM --add-label "$label" 2>&1 | grep -v "already exists" || true
done
echo " 💬 添加说明评论..."
gh issue comment $ISSUE_NUM --body $'🤖 自动标签系统检测到此 issue 并添加了相关标签。如有误判,请告知维护者。\n\n🤖 Auto-labeling system detected and labeled this issue. Please let maintainers know if this is incorrect.' || true
else
echo " ️ 未检测到明确类型"
fi
# 避免 API 限制
sleep 1
done
echo ""
echo "✅ 批量标签完成!"
echo "查看结果: https://github.com/${{ github.repository }}/issues"
+125
View File
@@ -0,0 +1,125 @@
name: CI
on:
push:
branches: [ master, main, develop ]
paths:
- 'packages/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'tsconfig.json'
- 'turbo.json'
- 'jest.config.*'
- '.github/workflows/ci.yml'
pull_request:
branches: [ master, main, develop ]
paths:
- 'packages/**'
- 'package.json'
- 'pnpm-lock.yaml'
- 'tsconfig.json'
- 'turbo.json'
- 'jest.config.*'
- '.github/workflows/ci.yml'
jobs:
ci:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-unknown-unknown
# 缓存 Rust 编译结果
- name: Cache Rust dependencies
uses: Swatinem/rust-cache@v2
with:
workspaces: packages/engine
cache-on-failure: true
# 缓存 wasm-pack
- name: Cache wasm-pack
uses: actions/cache@v4
with:
path: ~/.cargo/bin/wasm-pack
key: wasm-pack-${{ runner.os }}
- name: Install wasm-pack
run: |
if ! command -v wasm-pack &> /dev/null; then
cargo install wasm-pack
fi
- name: Install dependencies
run: pnpm install --no-frozen-lockfile
# 缓存 Turbo
- name: Cache Turbo
uses: actions/cache@v4
with:
path: .turbo
key: turbo-${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}-${{ github.sha }}
restore-keys: |
turbo-${{ runner.os }}-${{ hashFiles('**/pnpm-lock.yaml') }}-
turbo-${{ runner.os }}-
# 构建所有包
- name: Build all packages
run: pnpm run build
- name: Copy WASM files to ecs-engine-bindgen
run: |
mkdir -p packages/ecs-engine-bindgen/src/wasm
cp packages/engine/pkg/es_engine.js packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine.d.ts packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine_bg.wasm packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine_bg.wasm.d.ts packages/ecs-engine-bindgen/src/wasm/
# 类型检查
- name: Type check
run: pnpm run type-check
# Lint 检查
- name: Lint check
run: pnpm run lint
# 测试
- name: Run tests with coverage
run: pnpm run test:ci
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
continue-on-error: true
with:
file: ./coverage/lcov.info
flags: unittests
name: codecov-umbrella
fail_ci_if_error: false
# 构建 npm 包
- name: Build npm packages
run: pnpm run build:npm
# 上传构建产物
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: build-artifacts
path: |
packages/*/dist/
packages/*/bin/
retention-days: 7
+146
View File
@@ -0,0 +1,146 @@
name: Cleanup Old Dependabot PRs
# 手动触发的 workflow,用于清理堆积的 Dependabot PR
on:
workflow_dispatch:
inputs:
days_old:
description: '关闭多少天前创建的 PR(默认 7 天)'
required: false
default: '7'
dry_run:
description: '试运行模式(true=仅显示,不关闭)'
required: false
default: 'true'
type: choice
options:
- 'true'
- 'false'
jobs:
cleanup:
runs-on: ubuntu-latest
permissions:
pull-requests: write
issues: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: List and Close Old Dependabot PRs
uses: actions/github-script@v7
with:
script: |
const daysOld = parseInt('${{ github.event.inputs.days_old }}') || 7;
const dryRun = '${{ github.event.inputs.dry_run }}' === 'true';
const cutoffDate = new Date();
cutoffDate.setDate(cutoffDate.getDate() - daysOld);
console.log(`🔍 查找超过 ${daysOld} 天的 Dependabot PR...`);
console.log(`📅 截止日期: ${cutoffDate.toISOString()}`);
console.log(`🏃 模式: ${dryRun ? '试运行(不会实际关闭)' : '实际执行'}`);
console.log('---');
// 获取所有 Dependabot PR
const { data: pulls } = await github.rest.pulls.list({
owner: context.repo.owner,
repo: context.repo.repo,
state: 'open',
per_page: 100
});
const dependabotPRs = pulls.filter(pr =>
pr.user.login === 'dependabot[bot]' &&
new Date(pr.created_at) < cutoffDate
);
console.log(`📊 找到 ${dependabotPRs.length} 个符合条件的 Dependabot PR`);
console.log('');
if (dependabotPRs.length === 0) {
console.log('✅ 没有需要清理的 PR');
return;
}
// 按类型分组
const byType = {
dev: [],
prod: [],
actions: [],
other: []
};
for (const pr of dependabotPRs) {
const title = pr.title.toLowerCase();
const labels = pr.labels.map(l => l.name);
let type = 'other';
if (title.includes('dev-dependencies') || title.includes('development')) {
type = 'dev';
} else if (title.includes('production-dependencies')) {
type = 'prod';
} else if (labels.includes('github-actions')) {
type = 'actions';
}
byType[type].push(pr);
}
console.log('📋 PR 分类统计:');
console.log(` 🔧 开发依赖: ${byType.dev.length} 个`);
console.log(` 📦 生产依赖: ${byType.prod.length} 个`);
console.log(` ⚙️ GitHub Actions: ${byType.actions.length} 个`);
console.log(` ❓ 其他: ${byType.other.length} 个`);
console.log('');
// 处理每个 PR
for (const pr of dependabotPRs) {
const age = Math.floor((Date.now() - new Date(pr.created_at)) / (1000 * 60 * 60 * 24));
console.log(`${dryRun ? '🔍' : '🗑️ '} #${pr.number}: ${pr.title}`);
console.log(` 创建时间: ${pr.created_at} (${age} 天前)`);
console.log(` 链接: ${pr.html_url}`);
if (!dryRun) {
await github.rest.pulls.update({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: pr.number,
state: 'closed'
});
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: pr.number,
body: `🤖 **自动关闭旧的 Dependabot PR**
此 PR 已超过 ${daysOld} 天未合并,已被自动关闭以清理积压。
📌 **下一步:**
- Dependabot 已配置为月度运行,届时会创建新的分组更新
- 新的 Mergify 规则会智能处理不同类型的依赖更新
- 开发依赖和 GitHub Actions 会自动合并(即使 CI 失败)
- 生产依赖需要 CI 通过才会自动合并
如果需要立即应用此更新,请手动更新依赖。
---
*此操作由仓库维护者手动触发的清理工作流执行*`
});
console.log(' ✅ 已关闭并添加说明');
} else {
console.log(' ️ 试运行模式 - 未执行操作');
}
console.log('');
}
console.log('---');
if (dryRun) {
console.log(`✨ 试运行完成!共发现 ${dependabotPRs.length} 个待清理的 PR`);
console.log('💡 要实际执行清理,请将 dry_run 参数设为 false 重新运行');
} else {
console.log(`✅ 清理完成!已关闭 ${dependabotPRs.length} 个 Dependabot PR`);
}
+49
View File
@@ -0,0 +1,49 @@
name: Code Coverage
on:
push:
branches: [ master, main ]
pull_request:
branches: [ master, main ]
jobs:
coverage:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install dependencies
run: pnpm install
- name: Run tests with coverage
run: |
cd packages/core
pnpm run test:coverage
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
continue-on-error: true
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./packages/core/coverage/coverage-final.json
flags: core
name: core-coverage
fail_ci_if_error: false
verbose: true
- name: Upload coverage artifact
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: packages/core/coverage/
+42
View File
@@ -0,0 +1,42 @@
name: "CodeQL"
on:
push:
branches: [ "master", "main" ]
pull_request:
branches: [ "master", "main" ]
schedule:
- cron: '0 0 * * 1' # 每周一运行
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: [ 'javascript' ]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
queries: security-and-quality
config-file: ./.github/codeql/codeql-config.yml
- name: Autobuild
uses: github/codeql-action/autobuild@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"
+34
View File
@@ -0,0 +1,34 @@
name: Commit Lint
on:
pull_request:
types: [opened, synchronize, reopened]
permissions:
contents: read
pull-requests: read
jobs:
commitlint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install commitlint
run: |
pnpm add -D @commitlint/config-conventional @commitlint/cli
- name: Validate PR commits
run: npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose
+70
View File
@@ -0,0 +1,70 @@
name: Deploy Documentation
on:
push:
branches: [master]
paths:
- 'docs/**'
- 'packages/**'
- 'typedoc.json'
- 'package.json'
- '.github/workflows/docs.yml'
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Install dependencies
run: pnpm install
- name: Build core package
run: pnpm run build:core
- name: Generate API documentation
run: pnpm run docs:api
- name: Build documentation
run: pnpm run docs:build
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: docs/.vitepress/dist
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
needs: build
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
+23
View File
@@ -0,0 +1,23 @@
name: Issue Labeler
on:
issues:
types: [opened, edited]
permissions:
issues: write
contents: read
jobs:
label:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Label Issues
uses: github/issue-labeler@v3.4
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
configuration-path: .github/labeler.yml
enable-versioned-regex: 1
+28
View File
@@ -0,0 +1,28 @@
name: Issue Translator
on:
issue_comment:
types: [created]
issues:
types: [opened]
permissions:
issues: write
jobs:
translate:
runs-on: ubuntu-latest
steps:
- name: Translate Issues
uses: tomsun28/issues-translate-action@v2.7
with:
IS_MODIFY_TITLE: false
# 设置为 true 会修改标题,false 只在评论中添加翻译
CUSTOM_BOT_NOTE: |
<details>
<summary>🌏 Translation / 翻译</summary>
Bot detected the issue body's language is not English, translate it automatically.
机器人检测到 issue 内容非英文,自动翻译。
</details>
+245
View File
@@ -0,0 +1,245 @@
name: Release Editor App
on:
push:
tags:
- 'editor-v*'
workflow_dispatch:
inputs:
version:
description: 'Release version (e.g., 1.0.0)'
required: true
default: '1.0.0'
jobs:
build-tauri:
strategy:
fail-fast: false
matrix:
include:
- platform: windows-latest
target: x86_64-pc-windows-msvc
arch: x64
- platform: macos-latest
target: x86_64-apple-darwin
arch: x64
- platform: macos-latest
target: aarch64-apple-darwin
arch: arm64
runs-on: ${{ matrix.platform }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Rust cache
uses: Swatinem/rust-cache@v2
with:
workspaces: packages/editor-app/src-tauri
cache-on-failure: true
- name: Install dependencies (Ubuntu)
if: matrix.platform == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.0-dev libappindicator3-dev librsvg2-dev patchelf
- name: Install frontend dependencies
run: pnpm install
- name: Update version in config files (for manual trigger)
if: github.event_name == 'workflow_dispatch'
run: |
cd packages/editor-app
node -e "const pkg=require('./package.json'); pkg.version='${{ github.event.inputs.version }}'; require('fs').writeFileSync('./package.json', JSON.stringify(pkg, null, 2)+'\n')"
node scripts/sync-version.js
- name: Install wasm-pack
run: cargo install wasm-pack
# 使用 Turborepo 自动按依赖顺序构建所有包
# 这会自动处理:core -> asset-system -> editor-core -> ui -> 等等
- name: Build all packages with Turborepo
run: pnpm run build
- name: Copy WASM files to ecs-engine-bindgen
shell: bash
run: |
mkdir -p packages/ecs-engine-bindgen/src/wasm
cp packages/engine/pkg/es_engine.js packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine.d.ts packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine_bg.wasm packages/ecs-engine-bindgen/src/wasm/
cp packages/engine/pkg/es_engine_bg.wasm.d.ts packages/ecs-engine-bindgen/src/wasm/
- name: Bundle runtime files for Tauri
run: |
cd packages/editor-app
node scripts/bundle-runtime.mjs
- name: Build Tauri app
id: tauri
uses: tauri-apps/tauri-action@v0.5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY }}
TAURI_SIGNING_PRIVATE_KEY_PASSWORD: ${{ secrets.TAURI_SIGNING_PRIVATE_KEY_PASSWORD }}
with:
projectPath: packages/editor-app
tagName: ${{ github.event_name == 'workflow_dispatch' && format('editor-v{0}', github.event.inputs.version) || github.ref_name }}
releaseName: 'ECS Editor v${{ github.event.inputs.version || github.ref_name }}'
releaseBody: 'See the assets to download this version and install.'
releaseDraft: true
prerelease: false
includeUpdaterJson: true
updaterJsonKeepUniversal: false
args: ${{ matrix.platform == 'macos-latest' && format('--target {0}', matrix.target) || '' }}
# Windows 构建上传 artifact 供 SignPath 签名
- name: Upload Windows artifacts for signing
if: matrix.platform == 'windows-latest'
uses: actions/upload-artifact@v4
with:
name: windows-unsigned
path: |
packages/editor-app/src-tauri/target/release/bundle/nsis/*.exe
packages/editor-app/src-tauri/target/release/bundle/msi/*.msi
retention-days: 1
# SignPath 代码签名(Windows
# SignPath OSS code signing for Windows
#
# 配置步骤 | Setup Steps:
# 1. 在 SignPath 门户创建项目 | Create project in SignPath portal
# 2. 导入 .signpath/artifact-configuration.xml | Import artifact configuration
# 3. 使用 'test-signing' 策略测试 | Use 'test-signing' policy for testing
# 生产环境改为 'release-signing' | Change to 'release-signing' for production
# 4. 配置 GitHub Secrets | Configure GitHub Secrets:
# - SIGNPATH_API_TOKEN: API token from SignPath
# - SIGNPATH_ORGANIZATION_ID: Your organization ID
#
# 文档 | Documentation: https://about.signpath.io/documentation/trusted-build-systems/github
sign-windows:
needs: build-tauri
runs-on: ubuntu-latest
# 只有在构建成功时才运行 | Only run on successful build
if: success()
steps:
- name: Check SignPath configuration
id: check-signpath
run: |
if [ -n "${{ secrets.SIGNPATH_API_TOKEN }}" ] && [ -n "${{ secrets.SIGNPATH_ORGANIZATION_ID }}" ]; then
echo "enabled=true" >> $GITHUB_OUTPUT
echo "SignPath is configured, proceeding with code signing"
else
echo "enabled=false" >> $GITHUB_OUTPUT
echo "SignPath secrets not configured, skipping code signing"
echo "To enable: add SIGNPATH_API_TOKEN and SIGNPATH_ORGANIZATION_ID secrets"
fi
- name: Checkout
if: steps.check-signpath.outputs.enabled == 'true'
uses: actions/checkout@v4
- name: Download Windows artifact
if: steps.check-signpath.outputs.enabled == 'true'
uses: actions/download-artifact@v4
with:
name: windows-unsigned
path: ./artifacts
- name: List artifacts for signing
if: steps.check-signpath.outputs.enabled == 'true'
run: |
echo "Files to be signed:"
find ./artifacts -type f \( -name "*.exe" -o -name "*.msi" \) | head -20
- name: Submit to SignPath for code signing
if: steps.check-signpath.outputs.enabled == 'true'
id: signpath
uses: signpath/github-action-submit-signing-request@v1
with:
api-token: ${{ secrets.SIGNPATH_API_TOKEN }}
organization-id: ${{ secrets.SIGNPATH_ORGANIZATION_ID }}
project-slug: 'ecs-framework'
signing-policy-slug: 'test-signing'
artifact-configuration-slug: 'default'
github-artifact-name: 'windows-unsigned'
wait-for-completion: true
wait-for-completion-timeout-in-seconds: 600
output-artifact-directory: './signed'
- name: Upload signed artifacts to release
if: steps.check-signpath.outputs.enabled == 'true'
uses: softprops/action-gh-release@v1
with:
files: ./signed/*
tag_name: ${{ github.event_name == 'workflow_dispatch' && format('editor-v{0}', github.event.inputs.version) || github.ref_name }}
draft: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# 构建成功后,创建 PR 更新版本号
# Create PR to update version after successful build
update-version-pr:
needs: [build-tauri, sign-windows]
# 即使签名跳过也要运行 | Run even if signing is skipped
if: github.event_name == 'workflow_dispatch' && !failure()
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Update version files
run: |
cd packages/editor-app
node -e "const pkg=require('./package.json'); pkg.version='${{ github.event.inputs.version }}'; require('fs').writeFileSync('./package.json', JSON.stringify(pkg, null, 2)+'\n')"
node scripts/sync-version.js
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "chore(editor): bump version to ${{ github.event.inputs.version }}"
branch: release/editor-v${{ github.event.inputs.version }}
delete-branch: true
title: "chore(editor): Release v${{ github.event.inputs.version }}"
body: |
## Release v${{ github.event.inputs.version }}
This PR updates the editor version after successful release build.
### Changes
- Updated `packages/editor-app/package.json` → `${{ github.event.inputs.version }}`
- Updated `packages/editor-app/src-tauri/tauri.conf.json` → `${{ github.event.inputs.version }}`
### Release
- [GitHub Release](https://github.com/${{ github.repository }}/releases/tag/editor-v${{ github.event.inputs.version }})
---
*This PR was automatically created by the release workflow.*
labels: |
release
editor
automated pr
+229
View File
@@ -0,0 +1,229 @@
name: Release NPM Packages
on:
# 标签触发:支持 v* 和 {package}-v* 格式
# Tag trigger: supports v* and {package}-v* formats
push:
tags:
- 'v*'
- 'core-v*'
- 'behavior-tree-v*'
- 'editor-core-v*'
- 'node-editor-v*'
- 'blueprint-v*'
- 'tilemap-v*'
- 'physics-rapier2d-v*'
- 'worker-generator-v*'
# 保留手动触发选项
# Keep manual trigger option
workflow_dispatch:
inputs:
package:
description: '选择要发布的包 | Select package to publish'
required: true
type: choice
options:
- core
- behavior-tree
- editor-core
- node-editor
- blueprint
- tilemap
- physics-rapier2d
- worker-generator
version_type:
description: '版本更新类型 | Version bump type'
required: true
type: choice
options:
- patch
- minor
- major
permissions:
contents: write
pull-requests: write
id-token: write
jobs:
release-package:
name: Release Package
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.GITHUB_TOKEN }}
- name: Parse tag or input
id: parse
run: |
if [ "${{ github.event_name }}" = "push" ]; then
# 从标签解析包名和版本 | Parse package and version from tag
TAG="${GITHUB_REF#refs/tags/}"
echo "tag=$TAG" >> $GITHUB_OUTPUT
# 解析格式:v1.0.0 或 package-v1.0.0
# Parse format: v1.0.0 or package-v1.0.0
if [[ "$TAG" =~ ^v([0-9]+\.[0-9]+\.[0-9]+.*)$ ]]; then
PACKAGE="core"
VERSION="${BASH_REMATCH[1]}"
elif [[ "$TAG" =~ ^([a-z-]+)-v([0-9]+\.[0-9]+\.[0-9]+.*)$ ]]; then
PACKAGE="${BASH_REMATCH[1]}"
VERSION="${BASH_REMATCH[2]}"
else
echo "::error::Invalid tag format: $TAG"
echo "Expected: v1.0.0 or package-v1.0.0"
exit 1
fi
echo "package=$PACKAGE" >> $GITHUB_OUTPUT
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "mode=tag" >> $GITHUB_OUTPUT
echo "📦 Package: $PACKAGE"
echo "📌 Version: $VERSION"
else
# 手动触发:从 package.json 读取并 bump 版本
# Manual trigger: read from package.json and bump version
PACKAGE="${{ github.event.inputs.package }}"
echo "package=$PACKAGE" >> $GITHUB_OUTPUT
echo "mode=manual" >> $GITHUB_OUTPUT
echo "version_type=${{ github.event.inputs.version_type }}" >> $GITHUB_OUTPUT
fi
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
- name: Install dependencies
run: pnpm install
- name: Verify version (tag mode)
if: steps.parse.outputs.mode == 'tag'
run: |
PACKAGE="${{ steps.parse.outputs.package }}"
EXPECTED_VERSION="${{ steps.parse.outputs.version }}"
# 获取 package.json 中的版本
# Get version from package.json
ACTUAL_VERSION=$(node -p "require('./packages/$PACKAGE/package.json').version")
if [ "$EXPECTED_VERSION" != "$ACTUAL_VERSION" ]; then
echo "::error::Version mismatch!"
echo "Tag version: $EXPECTED_VERSION"
echo "package.json version: $ACTUAL_VERSION"
echo ""
echo "Please update packages/$PACKAGE/package.json to version $EXPECTED_VERSION before tagging."
exit 1
fi
echo "✅ Version verified: $EXPECTED_VERSION"
- name: Bump version (manual mode)
if: steps.parse.outputs.mode == 'manual'
id: bump
run: |
PACKAGE="${{ steps.parse.outputs.package }}"
cd packages/$PACKAGE
CURRENT=$(node -p "require('./package.json').version")
IFS='.' read -r MAJOR MINOR PATCH <<< "$CURRENT"
case "${{ steps.parse.outputs.version_type }}" in
major) NEW_VERSION="$((MAJOR+1)).0.0" ;;
minor) NEW_VERSION="$MAJOR.$((MINOR+1)).0" ;;
patch) NEW_VERSION="$MAJOR.$MINOR.$((PATCH+1))" ;;
esac
# Update package.json
node -e "const fs=require('fs'); const pkg=JSON.parse(fs.readFileSync('package.json')); pkg.version='$NEW_VERSION'; fs.writeFileSync('package.json', JSON.stringify(pkg, null, 2)+'\n')"
echo "version=$NEW_VERSION" >> $GITHUB_OUTPUT
echo "📌 Bumped version: $CURRENT → $NEW_VERSION"
- name: Set final version
id: version
run: |
if [ "${{ steps.parse.outputs.mode }}" = "tag" ]; then
echo "value=${{ steps.parse.outputs.version }}" >> $GITHUB_OUTPUT
else
echo "value=${{ steps.bump.outputs.version }}" >> $GITHUB_OUTPUT
fi
- name: Build core package (if needed)
if: ${{ steps.parse.outputs.package != 'core' && steps.parse.outputs.package != 'node-editor' && steps.parse.outputs.package != 'worker-generator' }}
run: |
cd packages/core
pnpm run build
- name: Build node-editor package (if needed for blueprint)
if: ${{ steps.parse.outputs.package == 'blueprint' }}
run: |
cd packages/node-editor
pnpm run build
- name: Build package
run: |
cd packages/${{ steps.parse.outputs.package }}
pnpm run build:npm
- name: Publish to npm
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
cd packages/${{ steps.parse.outputs.package }}/dist
pnpm publish --access public --no-git-checks
- name: Create GitHub Release (tag mode)
if: steps.parse.outputs.mode == 'tag'
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ steps.parse.outputs.tag }}
name: "${{ steps.parse.outputs.package }} v${{ steps.version.outputs.value }}"
body: |
## 🚀 @esengine/${{ steps.parse.outputs.package }} v${{ steps.version.outputs.value }}
📦 **NPM**: [@esengine/${{ steps.parse.outputs.package }}@${{ steps.version.outputs.value }}](https://www.npmjs.com/package/@esengine/${{ steps.parse.outputs.package }}/v/${{ steps.version.outputs.value }})
```bash
npm install @esengine/${{ steps.parse.outputs.package }}@${{ steps.version.outputs.value }}
```
---
*自动发布 | Auto-released by GitHub Actions*
generate_release_notes: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create Pull Request (manual mode)
if: steps.parse.outputs.mode == 'manual'
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "chore(${{ steps.parse.outputs.package }}): release v${{ steps.version.outputs.value }}"
branch: release/${{ steps.parse.outputs.package }}-v${{ steps.version.outputs.value }}
delete-branch: true
title: "chore(${{ steps.parse.outputs.package }}): Release v${{ steps.version.outputs.value }}"
body: |
## 🚀 Release v${{ steps.version.outputs.value }}
此 PR 更新 `@esengine/${{ steps.parse.outputs.package }}` 包的版本号
### 变更
- ✅ 已发布到 npm: [@esengine/${{ steps.parse.outputs.package }}@${{ steps.version.outputs.value }}](https://www.npmjs.com/package/@esengine/${{ steps.parse.outputs.package }}/v/${{ steps.version.outputs.value }})
- ✅ 更新 `packages/${{ steps.parse.outputs.package }}/package.json` → `${{ steps.version.outputs.value }}`
---
*此 PR 由发布工作流自动创建*
labels: |
release
${{ steps.parse.outputs.package }}
automated pr
+46
View File
@@ -0,0 +1,46 @@
name: Size Limit
on:
pull_request:
branches:
- master
- main
paths:
- 'packages/core/src/**'
- 'packages/core/package.json'
- '.size-limit.json'
permissions:
contents: read
pull-requests: write
issues: write
jobs:
size:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install dependencies
run: pnpm install
- name: Build core package
run: |
cd packages/core
pnpm run build:npm
- name: Check bundle size
uses: andresz1/size-limit-action@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
skip_step: install
+60
View File
@@ -0,0 +1,60 @@
name: Stale Issues and PRs
on:
schedule:
- cron: '0 0 * * *' # 每天运行一次
workflow_dispatch: # 允许手动触发
permissions:
issues: write
pull-requests: write
jobs:
stale:
runs-on: ubuntu-latest
steps:
- name: Stale Bot
uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
# Issue 配置
stale-issue-message: |
这个 issue 已经 60 天没有活动了,将在 14 天后自动关闭。
如果这个问题仍然存在,请留言说明情况。
This issue has been inactive for 60 days and will be closed in 14 days.
If this issue is still relevant, please leave a comment.
close-issue-message: |
由于长时间无活动,这个 issue 已被自动关闭。
如需重新打开,请留言说明。
This issue has been automatically closed due to inactivity.
Please comment if you'd like to reopen it.
days-before-issue-stale: 60
days-before-issue-close: 14
stale-issue-label: 'stale'
exempt-issue-labels: 'pinned,security,enhancement,help wanted'
# PR 配置
stale-pr-message: |
这个 PR 已经 30 天没有活动了,将在 7 天后自动关闭。
如果你还在处理这个 PR,请更新一下。
This PR has been inactive for 30 days and will be closed in 7 days.
If you're still working on it, please update it.
close-pr-message: |
由于长时间无活动,这个 PR 已被自动关闭。
如需继续,请重新打开或创建新的 PR。
This PR has been automatically closed due to inactivity.
Please reopen or create a new PR to continue.
days-before-pr-stale: 30
days-before-pr-close: 7
stale-pr-label: 'stale'
exempt-pr-labels: 'pinned,security,wip'
# 其他配置
operations-per-run: 100
remove-stale-when-updated: true
ascending: true
+58
View File
@@ -0,0 +1,58 @@
name: Welcome
on:
issues:
types: [opened]
pull_request_target:
types: [opened]
permissions:
issues: write
pull-requests: write
jobs:
welcome:
runs-on: ubuntu-latest
steps:
- name: Welcome new contributors
uses: actions/first-interaction@v1.3.0
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: |
👋 你好!感谢你提交第一个 issue!
我们会尽快查看并回复。同时,建议你:
- 📚 查看[文档](https://esengine.github.io/ecs-framework/)
- 🤖 使用 [AI 文档助手](https://deepwiki.com/esengine/esengine)
- 💬 加入 [QQ 交流群](https://jq.qq.com/?_wv=1027&k=29w1Nud6)
---
👋 Hello! Thanks for opening your first issue!
We'll review it as soon as possible. Meanwhile, you might want to:
- 📚 Check the [documentation](https://esengine.github.io/ecs-framework/)
- 🤖 Use [AI documentation assistant](https://deepwiki.com/esengine/esengine)
pr-message: |
👋 你好!感谢你提交第一个 Pull Request
在我们 Review 之前,请确保:
- ✅ 代码遵循项目规范
- ✅ 通过所有测试
- ✅ 更新了相关文档
- ✅ Commit 遵循 [Conventional Commits](https://www.conventionalcommits.org/) 规范
查看完整的[贡献指南](https://github.com/esengine/esengine/blob/master/CONTRIBUTING.md)。
---
👋 Hello! Thanks for your first Pull Request!
Before we review, please ensure:
- ✅ Code follows project conventions
- ✅ All tests pass
- ✅ Documentation is updated
- ✅ Commits follow [Conventional Commits](https://www.conventionalcommits.org/)
See the full [Contributing Guide](https://github.com/esengine/esengine/blob/master/CONTRIBUTING.md).
+92 -2
View File
@@ -1,2 +1,92 @@
/source/node_modules
/demo/bin-debug
# 依赖目录
node_modules/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
# 构建输出
bin/
dist/
*.tgz
# TypeScript
*.tsbuildinfo
# 临时文件
*.tmp
*.temp
.cache/
.build-cache/
# Turborepo
.turbo/
# IDE 配置
.idea/
.vscode/
*.swp
*.swo
*~
# 操作系统文件
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
# 日志文件
logs/
*.log
# 环境配置
.env
.env.local
.env.development.local
.env.test.local
.env.production.local
# 代码签名证书(敏感文件)
certs/
*.pfx
*.p12
*.cer
*.pem
*.key
# 测试覆盖率
coverage/
*.lcov
# 包管理器锁文件(忽略yarn,保留pnpm)
yarn.lock
package-lock.json
# 文档生成
docs/api/
docs/build/
docs/.vitepress/cache/
docs/.vitepress/dist/
# 备份文件
*.bak
*.backup
# 演示项目构建产物
/demo/bin-debug/
/demo/bin-release/
/demo/.wing/
/demo/.idea/
/demo/.vscode/
/demo_wxgame/
# Tauri 构建产物
**/src-tauri/target/
**/src-tauri/WixTools/
**/src-tauri/gen/
# Tauri 捆绑输出
**/src-tauri/target/release/bundle/
**/src-tauri/target/debug/bundle/
+18
View File
@@ -0,0 +1,18 @@
[submodule "thirdparty/BehaviourTree-ai"]
path = thirdparty/BehaviourTree-ai
url = https://github.com/esengine/BehaviourTree-ai.git
[submodule "thirdparty/admin-backend"]
path = thirdparty/admin-backend
url = https://github.com/esengine/admin-backend.git
[submodule "thirdparty/mvvm-ui-framework"]
path = thirdparty/mvvm-ui-framework
url = https://github.com/esengine/mvvm-ui-framework.git
[submodule "thirdparty/cocos-nexus"]
path = thirdparty/cocos-nexus
url = https://github.com/esengine/cocos-nexus.git
[submodule "thirdparty/ecs-astar"]
path = thirdparty/ecs-astar
url = https://github.com/esengine/ecs-astar.git
[submodule "examples/lawn-mower-demo"]
path = examples/lawn-mower-demo
url = https://github.com/esengine/lawn-mower-demo.git
+40
View File
@@ -0,0 +1,40 @@
# 源代码文件
src/
tsconfig*.json
*.ts
!bin/**/*.d.ts
# 开发文件
dev-bin/
scripts/
.vscode/
.git/
.gitignore
# 测试文件
**/*.test.*
**/*.spec.*
**/test/
**/tests/
# 构建缓存
node_modules/
*.log
*.tmp
*.temp
# 文档草稿
docs/draft/
*.draft.md
# 编辑器文件
.DS_Store
Thumbs.db
*.swp
*.swo
*~
# 环境文件
.env
.env.local
.env.*.local
+2
View File
@@ -0,0 +1,2 @@
link-workspace-packages=true
prefer-workspace-packages=true
+2
View File
@@ -0,0 +1,2 @@
examples/*/settings/**
extensions/*/settings/**
+49
View File
@@ -0,0 +1,49 @@
# 依赖和构建输出
node_modules/
dist/
bin/
build/
coverage/
*.min.js
*.min.css
# 编译输出
**/*.d.ts
tsconfig.tsbuildinfo
# 日志
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# 第三方库
thirdparty/
examples/lawn-mower-demo/
extensions/
# 文档生成
docs/.vitepress/cache/
docs/.vitepress/dist/
docs/api/
# 临时文件
*.tmp
*.bak
*.swp
*~
# 系统文件
.DS_Store
Thumbs.db
# 编辑器
.vscode/
.idea/
# 其他
*.backup
CHANGELOG.md
LICENSE
README.md
+14
View File
@@ -0,0 +1,14 @@
{
"semi": true,
"singleQuote": true,
"tabWidth": 4,
"useTabs": false,
"trailingComma": "none",
"printWidth": 120,
"arrowParens": "always",
"endOfLine": "lf",
"bracketSpacing": true,
"quoteProps": "as-needed",
"jsxSingleQuote": false,
"proseWrap": "preserve"
}
+25
View File
@@ -0,0 +1,25 @@
[
{
"name": "@esengine/ecs-framework (ESM)",
"path": "packages/core/dist/esm/index.js",
"import": "*",
"limit": "50 KB",
"webpack": false,
"gzip": true
},
{
"name": "@esengine/ecs-framework (UMD)",
"path": "packages/core/dist/umd/ecs-framework.js",
"limit": "60 KB",
"webpack": false,
"gzip": true
},
{
"name": "Core Runtime (Tree-shaking)",
"path": "packages/core/dist/esm/index.js",
"import": "{ Core, Scene, Entity, Component }",
"limit": "30 KB",
"webpack": false,
"gzip": true
}
]
+130
View File
@@ -0,0 +1,130 @@
# 贡献指南 / Contributing Guide
感谢你对 ECS Framework 的关注!
Thank you for your interest in contributing to ECS Framework!
## Commit 规范 / Commit Convention
本项目使用 [Conventional Commits](https://www.conventionalcommits.org/) 规范。
This project follows the [Conventional Commits](https://www.conventionalcommits.org/) specification.
### 格式 / Format
```
<type>(<scope>): <subject>
<body>
<footer>
```
### 类型 / Types
- **feat**: 新功能 / New feature
- **fix**: 错误修复 / Bug fix
- **docs**: 文档变更 / Documentation changes
- **style**: 代码格式(不影响代码运行) / Code style changes
- **refactor**: 重构(既不是新功能也不是修复) / Code refactoring
- **perf**: 性能优化 / Performance improvements
- **test**: 测试相关 / Test changes
- **build**: 构建系统或依赖变更 / Build system changes
- **ci**: CI 配置变更 / CI configuration changes
- **chore**: 其他变更 / Other changes
### 范围 / Scope
- **core**: 核心包 @esengine/ecs-framework
- **math**: 数学库包
- **editor**: 编辑器
- **docs**: 文档
### 示例 / Examples
```bash
# 新功能
feat(core): add component pooling system
# 错误修复
fix(core): fix entity deletion memory leak
# 破坏性变更
feat(core): redesign system lifecycle
BREAKING CHANGE: System.initialize() now requires Scene parameter
```
## 自动发布 / Automatic Release
本项目使用 Semantic Release 自动发布。
This project uses Semantic Release for automatic publishing.
### 版本规则 / Versioning Rules
根据你的 commit 类型,版本号会自动更新:
Based on your commit type, the version will be automatically updated:
- `feat`: 增加 **minor** 版本 (0.x.0)
- `fix`, `perf`, `refactor`: 增加 **patch** 版本 (0.0.x)
- `BREAKING CHANGE`: 增加 **major** 版本 (x.0.0)
### 发布流程 / Release Process
1. 提交代码到 `master` 分支 / Push commits to `master` branch
2. GitHub Actions 自动运行测试 / GitHub Actions runs tests automatically
3. Semantic Release 分析 commits / Semantic Release analyzes commits
4. 自动更新版本号 / Version is automatically updated
5. 自动生成 CHANGELOG.md / CHANGELOG.md is automatically generated
6. 自动发布到 npm / Package is automatically published to npm
7. 自动创建 GitHub Release / GitHub Release is automatically created
## 开发流程 / Development Workflow
1. Fork 本仓库 / Fork this repository
2. 创建特性分支 / Create a feature branch
```bash
git checkout -b feat/my-feature
```
3. 提交你的变更 / Commit your changes
```bash
git commit -m "feat(core): add new feature"
```
4. 推送到你的 Fork / Push to your fork
```bash
git push origin feat/my-feature
```
5. 创建 Pull Request / Create a Pull Request
## 本地测试 / Local Testing
```bash
# 安装依赖
npm install
# 运行测试
npm test
# 构建
npm run build
# 代码检查
npm run lint
# 代码格式化
npm run format
```
## 问题反馈 / Issue Reporting
如果你发现了 bug 或有新功能建议,请[创建 Issue](https://github.com/esengine/esengine/issues/new)。
If you find a bug or have a feature request, please [create an issue](https://github.com/esengine/esengine/issues/new).
## 许可证 / License
通过贡献代码,你同意你的贡献将遵循 MIT 许可证。
By contributing, you agree that your contributions will be licensed under the MIT License.
+17 -197
View File
@@ -1,201 +1,21 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
MIT License
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
Copyright (c) 2025 ESEngine Contributors
1. Definitions.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+273 -7
View File
@@ -1,11 +1,277 @@
# egret-framework
用于egret 包含众多高性能方法以供使用
(正在施工中)
<h1 align="center">
<img src="https://raw.githubusercontent.com/esengine/esengine/master/docs/public/logo.svg" alt="ESEngine" width="180">
<br>
ESEngine
</h1>
## 计划列表
<p align="center">
<strong>Cross-platform 2D Game Engine</strong>
</p>
- [ ] 包含一套适配egret的ecs框架
<p align="center">
<a href="https://www.npmjs.com/package/@esengine/ecs-framework"><img src="https://img.shields.io/npm/v/@esengine/ecs-framework?style=flat-square&color=blue" alt="npm"></a>
<a href="https://github.com/esengine/esengine/actions"><img src="https://img.shields.io/github/actions/workflow/status/esengine/esengine/ci.yml?branch=master&style=flat-square" alt="build"></a>
<a href="https://github.com/esengine/esengine/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-green?style=flat-square" alt="license"></a>
<a href="https://github.com/esengine/esengine/stargazers"><img src="https://img.shields.io/github/stars/esengine/esengine?style=flat-square" alt="stars"></a>
<img src="https://img.shields.io/badge/TypeScript-5.0+-blue?style=flat-square&logo=typescript&logoColor=white" alt="TypeScript">
</p>
- [ ] 高性能物理引擎
<p align="center">
<b>English</b> | <a href="./README_CN.md">中文</a>
</p>
> 尽可能的简单易用
<p align="center">
<a href="https://esengine.cn/">Documentation</a> ·
<a href="https://esengine.cn/api/README">API Reference</a> ·
<a href="https://github.com/esengine/esengine/releases">Download Editor</a> ·
<a href="./examples/">Examples</a>
</p>
---
## Overview
ESEngine is a cross-platform 2D game engine built from the ground up with modern web technologies. It provides a comprehensive toolset that enables developers to focus on creating games rather than building infrastructure.
Export your games to multiple platforms including web browsers, WeChat Mini Games, and other mini-game platforms from a single codebase.
## Key Features
| Feature | Description |
|---------|-------------|
| **ECS Architecture** | Data-driven Entity-Component-System pattern for flexible and cache-friendly game logic |
| **High-Performance Rendering** | Rust/WebAssembly 2D renderer with automatic sprite batching and WebGL 2.0 backend |
| **Visual Editor** | Cross-platform desktop editor built with Tauri for scene management and asset workflows |
| **Modular Design** | Import only what you need - each feature is a standalone package |
| **Multi-Platform Export** | Deploy to Web, WeChat Mini Games, and more from one codebase |
| **Physics Integration** | 2D physics powered by Rapier with editor visualization |
| **Visual Scripting** | Behavior trees and blueprint system for designers |
## Tech Stack
- **Runtime**: TypeScript, Rust, WebAssembly
- **Renderer**: WebGL 2.0, WGPU (planned)
- **Editor**: Tauri, React, Zustand
- **Physics**: Rapier2D
- **Build**: pnpm, Turborepo, Rollup
## License
ESEngine is **free and open source** under the [MIT License](LICENSE). No royalties, no strings attached.
## Installation
### npm
```bash
npm install @esengine/ecs-framework
```
### Editor
Download pre-built binaries from the [Releases](https://github.com/esengine/esengine/releases) page (Windows, macOS).
## Quick Start
```typescript
import {
Core, Scene, Entity, Component, EntitySystem,
Matcher, Time, ECSComponent, ECSSystem
} from '@esengine/ecs-framework';
@ECSComponent('Position')
class Position extends Component {
x = 0;
y = 0;
}
@ECSComponent('Velocity')
class Velocity extends Component {
dx = 0;
dy = 0;
}
@ECSSystem('Movement')
class MovementSystem extends EntitySystem {
constructor() {
super(Matcher.all(Position, Velocity));
}
protected process(entities: readonly Entity[]): void {
for (const entity of entities) {
const pos = entity.getComponent(Position);
const vel = entity.getComponent(Velocity);
pos.x += vel.dx * Time.deltaTime;
pos.y += vel.dy * Time.deltaTime;
}
}
}
// Initialize
Core.create();
const scene = new Scene();
scene.addSystem(new MovementSystem());
const player = scene.createEntity('Player');
player.addComponent(new Position());
player.addComponent(new Velocity());
Core.setScene(scene);
// Game loop
function gameLoop(currentTime: number) {
Core.update(currentTime / 1000);
requestAnimationFrame(gameLoop);
}
requestAnimationFrame(gameLoop);
```
## Packages
ESEngine is organized as a monorepo with modular packages.
### Core
| Package | Description |
|---------|-------------|
| `@esengine/ecs-framework` | Core ECS framework with entity management, component system, and queries |
| `@esengine/math` | Vector, matrix, and mathematical utilities |
| `@esengine/engine` | Rust/WASM 2D renderer |
| `@esengine/engine-core` | Engine module system and lifecycle management |
### Runtime
| Package | Description |
|---------|-------------|
| `@esengine/sprite` | 2D sprite rendering and animation |
| `@esengine/tilemap` | Tile-based map rendering |
| `@esengine/physics-rapier2d` | 2D physics simulation (Rapier) |
| `@esengine/behavior-tree` | Behavior tree AI system |
| `@esengine/blueprint` | Visual scripting runtime |
| `@esengine/camera` | Camera control and management |
| `@esengine/audio` | Audio playback |
| `@esengine/ui` | UI components |
| `@esengine/material-system` | Material and shader system |
| `@esengine/asset-system` | Asset loading and management |
### Editor Extensions
| Package | Description |
|---------|-------------|
| `@esengine/sprite-editor` | Sprite inspector and tools |
| `@esengine/tilemap-editor` | Visual tilemap editor |
| `@esengine/physics-rapier2d-editor` | Physics collider visualization |
| `@esengine/behavior-tree-editor` | Visual behavior tree editor |
| `@esengine/blueprint-editor` | Visual scripting editor |
| `@esengine/material-editor` | Material editor |
### Platform
| Package | Description |
|---------|-------------|
| `@esengine/platform-common` | Platform abstraction interfaces |
| `@esengine/platform-web` | Web browser runtime |
| `@esengine/platform-wechat` | WeChat Mini Game runtime |
## Editor
The ESEngine Editor is a cross-platform desktop application built with Tauri and React.
### Features
- Scene hierarchy and entity management
- Component inspector with custom property editors
- Asset browser with drag-and-drop
- Tilemap editor with paint and fill tools
- Behavior tree visual editor
- Blueprint visual scripting
- Material and shader editing
- Built-in performance profiler
- Localization (English, Chinese)
### Screenshot
![ESEngine Editor](screenshots/main_screetshot.png)
## Platform Support
| Platform | Runtime | Editor |
|----------|:-------:|:------:|
| Web Browser | ✓ | - |
| Windows | - | ✓ |
| macOS | - | ✓ |
| WeChat Mini Game | In Progress | - |
| Playable Ads | Planned | - |
| Android | Planned | - |
| iOS | Planned | - |
## Building from Source
### Prerequisites
- Node.js 18+
- pnpm 10+
- Rust toolchain (for WASM renderer)
- wasm-pack
### Setup
```bash
git clone https://github.com/esengine/esengine.git
cd esengine
pnpm install
pnpm build
# Optional: Build WASM renderer
pnpm build:wasm
```
### Run Editor
```bash
cd packages/editor-app
pnpm tauri:dev
```
### Project Structure
```
esengine/
├── packages/ # Engine packages (runtime, editor, platform)
├── docs/ # Documentation source
├── examples/ # Example projects
├── scripts/ # Build utilities
└── thirdparty/ # Third-party dependencies
```
## Documentation
- [Getting Started](https://esengine.cn/guide/getting-started.html)
- [Architecture Guide](https://esengine.cn/guide/)
- [API Reference](https://esengine.cn/api/README)
## Community
- [GitHub Issues](https://github.com/esengine/esengine/issues) - Bug reports and feature requests
- [GitHub Discussions](https://github.com/esengine/esengine/discussions) - Questions and ideas
## Contributing
Contributions are welcome. Please read the contributing guidelines before submitting a pull request.
1. Fork the repository
2. Create a feature branch (`git checkout -b feature/amazing-feature`)
3. Commit your changes (`git commit -m 'Add amazing feature'`)
4. Push to the branch (`git push origin feature/amazing-feature`)
5. Open a Pull Request
## License
ESEngine is licensed under the [MIT License](LICENSE).
---
<p align="center">
Made with ❤️ by the ESEngine team
</p>
+278
View File
@@ -0,0 +1,278 @@
<h1 align="center">
<img src="https://raw.githubusercontent.com/esengine/esengine/master/docs/public/logo.svg" alt="ESEngine" width="180">
<br>
ESEngine
</h1>
<p align="center">
<strong>跨平台 2D 游戏引擎</strong>
</p>
<p align="center">
<a href="https://www.npmjs.com/package/@esengine/ecs-framework"><img src="https://img.shields.io/npm/v/@esengine/ecs-framework?style=flat-square&color=blue" alt="npm"></a>
<a href="https://github.com/esengine/esengine/actions"><img src="https://img.shields.io/github/actions/workflow/status/esengine/esengine/ci.yml?branch=master&style=flat-square" alt="build"></a>
<a href="https://github.com/esengine/esengine/blob/master/LICENSE"><img src="https://img.shields.io/badge/license-MIT-green?style=flat-square" alt="license"></a>
<a href="https://github.com/esengine/esengine/stargazers"><img src="https://img.shields.io/github/stars/esengine/esengine?style=flat-square" alt="stars"></a>
<img src="https://img.shields.io/badge/TypeScript-5.0+-blue?style=flat-square&logo=typescript&logoColor=white" alt="TypeScript">
</p>
<p align="center">
<a href="./README.md">English</a> | <b>中文</b>
</p>
<p align="center">
<a href="https://esengine.cn/">文档</a> ·
<a href="https://esengine.cn/api/README">API 参考</a> ·
<a href="https://github.com/esengine/esengine/releases">下载编辑器</a> ·
<a href="./examples/">示例</a>
</p>
---
## 概述
ESEngine 是一款基于现代 Web 技术从零构建的跨平台 2D 游戏引擎。它提供完整的工具集,让开发者专注于游戏创作而非基础设施搭建。
一套代码即可导出到 Web 浏览器、微信小游戏等多个平台。
## 核心特性
| 特性 | 描述 |
|-----|------|
| **ECS 架构** | 数据驱动的实体-组件-系统模式,提供灵活且缓存友好的游戏逻辑 |
| **高性能渲染** | Rust/WebAssembly 2D 渲染器,支持自动精灵批处理和 WebGL 2.0 |
| **可视化编辑器** | 基于 Tauri 的跨平台桌面编辑器,支持场景管理和资源工作流 |
| **模块化设计** | 按需引入,每个功能都是独立的包 |
| **多平台导出** | 一套代码部署到 Web、微信小游戏等平台 |
| **物理集成** | 基于 Rapier 的 2D 物理,支持编辑器可视化 |
| **可视化脚本** | 行为树和蓝图系统,适合策划使用 |
## 技术栈
- **运行时**: TypeScript, Rust, WebAssembly
- **渲染器**: WebGL 2.0, WGPU (计划中)
- **编辑器**: Tauri, React, Zustand
- **物理**: Rapier2D
- **构建**: pnpm, Turborepo, Rollup
## 许可证
ESEngine **完全免费开源**,采用 [MIT 协议](LICENSE)。无版税,无附加条件。
## 安装
### npm
```bash
npm install @esengine/ecs-framework
```
### 编辑器
从 [Releases](https://github.com/esengine/esengine/releases) 页面下载预编译版本(支持 Windows、macOS)。
## 快速开始
```typescript
import {
Core, Scene, Entity, Component, EntitySystem,
Matcher, Time, ECSComponent, ECSSystem
} from '@esengine/ecs-framework';
@ECSComponent('Position')
class Position extends Component {
x = 0;
y = 0;
}
@ECSComponent('Velocity')
class Velocity extends Component {
dx = 0;
dy = 0;
}
@ECSSystem('Movement')
class MovementSystem extends EntitySystem {
constructor() {
super(Matcher.all(Position, Velocity));
}
protected process(entities: readonly Entity[]): void {
for (const entity of entities) {
const pos = entity.getComponent(Position);
const vel = entity.getComponent(Velocity);
pos.x += vel.dx * Time.deltaTime;
pos.y += vel.dy * Time.deltaTime;
}
}
}
// 初始化
Core.create();
const scene = new Scene();
scene.addSystem(new MovementSystem());
const player = scene.createEntity('Player');
player.addComponent(new Position());
player.addComponent(new Velocity());
Core.setScene(scene);
// 游戏循环
function gameLoop(currentTime: number) {
Core.update(currentTime / 1000);
requestAnimationFrame(gameLoop);
}
requestAnimationFrame(gameLoop);
```
## 模块
ESEngine 采用 Monorepo 组织,包含多个模块化包。
### 核心
| 包名 | 描述 |
|------|------|
| `@esengine/ecs-framework` | ECS 框架核心,包含实体管理、组件系统和查询 |
| `@esengine/math` | 向量、矩阵和数学工具 |
| `@esengine/engine` | Rust/WASM 2D 渲染器 |
| `@esengine/engine-core` | 引擎模块系统和生命周期管理 |
### 运行时
| 包名 | 描述 |
|------|------|
| `@esengine/sprite` | 2D 精灵渲染和动画 |
| `@esengine/tilemap` | Tilemap 渲染 |
| `@esengine/physics-rapier2d` | 2D 物理模拟 (Rapier) |
| `@esengine/behavior-tree` | 行为树 AI 系统 |
| `@esengine/blueprint` | 可视化脚本运行时 |
| `@esengine/camera` | 相机控制和管理 |
| `@esengine/audio` | 音频播放 |
| `@esengine/ui` | UI 组件 |
| `@esengine/material-system` | 材质和着色器系统 |
| `@esengine/asset-system` | 资源加载和管理 |
### 编辑器扩展
| 包名 | 描述 |
|------|------|
| `@esengine/sprite-editor` | 精灵检视器和工具 |
| `@esengine/tilemap-editor` | 可视化 Tilemap 编辑器 |
| `@esengine/physics-rapier2d-editor` | 物理碰撞体可视化 |
| `@esengine/behavior-tree-editor` | 可视化行为树编辑器 |
| `@esengine/blueprint-editor` | 可视化脚本编辑器 |
| `@esengine/material-editor` | 材质编辑器 |
### 平台
| 包名 | 描述 |
|------|------|
| `@esengine/platform-common` | 平台抽象接口 |
| `@esengine/platform-web` | Web 浏览器运行时 |
| `@esengine/platform-wechat` | 微信小游戏运行时 |
## 编辑器
ESEngine 编辑器是基于 Tauri 和 React 构建的跨平台桌面应用。
### 功能
- 场景层级和实体管理
- 组件检视器,支持自定义属性编辑器
- 资源浏览器,支持拖放
- Tilemap 编辑器,支持绘制和填充工具
- 行为树可视化编辑器
- 蓝图可视化脚本
- 材质和着色器编辑
- 内置性能分析器
- 多语言支持(英文、中文)
### 截图
![ESEngine Editor](screenshots/main_screetshot.png)
## 平台支持
| 平台 | 运行时 | 编辑器 |
|------|:------:|:------:|
| Web 浏览器 | ✓ | - |
| Windows | - | ✓ |
| macOS | - | ✓ |
| 微信小游戏 | 开发中 | - |
| Playable 可玩广告 | 计划中 | - |
| Android | 计划中 | - |
| iOS | 计划中 | - |
## 从源码构建
### 前置要求
- Node.js 18+
- pnpm 10+
- Rust 工具链(用于 WASM 渲染器)
- wasm-pack
### 安装
```bash
git clone https://github.com/esengine/esengine.git
cd esengine
pnpm install
pnpm build
# 可选:构建 WASM 渲染器
pnpm build:wasm
```
### 运行编辑器
```bash
cd packages/editor-app
pnpm tauri:dev
```
### 项目结构
```
esengine/
├── packages/ # 引擎包(运行时、编辑器、平台)
├── docs/ # 文档源码
├── examples/ # 示例项目
├── scripts/ # 构建工具
└── thirdparty/ # 第三方依赖
```
## 文档
- [快速入门](https://esengine.cn/guide/getting-started.html)
- [架构指南](https://esengine.cn/guide/)
- [API 参考](https://esengine.cn/api/README)
## 社区
- [GitHub Issues](https://github.com/esengine/esengine/issues) - Bug 反馈和功能建议
- [GitHub Discussions](https://github.com/esengine/esengine/discussions) - 问题和想法
- [QQ 交流群](https://jq.qq.com/?_wv=1027&k=29w1Nud6) - 中文社区
## 贡献
欢迎贡献代码。提交 PR 前请阅读贡献指南。
1. Fork 仓库
2. 创建功能分支 (`git checkout -b feature/amazing-feature`)
3. 提交修改 (`git commit -m 'Add amazing feature'`)
4. 推送分支 (`git push origin feature/amazing-feature`)
5. 发起 Pull Request
## 许可证
ESEngine 基于 [MIT 协议](LICENSE) 开源。
---
<p align="center">
由 ESEngine 团队用 ❤️ 打造
</p>
+113
View File
@@ -0,0 +1,113 @@
# Security Policy / 安全政策
**English** | [中文](#安全政策-1)
## Supported Versions
We provide security updates for the following versions:
| Version | Supported |
| ------- | ------------------ |
| 2.x.x | :white_check_mark: |
| 1.x.x | :x: |
## Reporting a Vulnerability
If you discover a security vulnerability, please report it through the following channels:
### Reporting Channels
- **GitHub Security Advisories**: [Report a vulnerability](https://github.com/esengine/esengine/security/advisories/new) (Recommended)
- **Email**: security@esengine.dev
### Reporting Guidelines
1. **Do NOT** report security vulnerabilities in public issues
2. Provide a detailed description of the vulnerability, including:
- Affected versions
- Steps to reproduce
- Potential impact
- Suggested fix (if available)
### Response Timeline
- **Acknowledgment**: Within 72 hours
- **Initial Assessment**: Within 1 week
- **Fix Release**: Typically within 2-4 weeks, depending on severity
### Process
1. We will confirm the existence and severity of the vulnerability
2. Develop and test a fix
3. Release a security update
4. Publicly disclose the vulnerability details after the fix is released
## Security Best Practices
When using ESEngine, please follow these security recommendations:
- Always use the latest stable version
- Regularly update dependencies
- Disable debug mode in production
- Validate all external input data
- Do not store sensitive information on the client side
---
# 安全政策
[English](#security-policy--安全政策) | **中文**
## 支持的版本
我们为以下版本提供安全更新:
| 版本 | 支持状态 |
| ------- | ------------------ |
| 2.x.x | :white_check_mark: |
| 1.x.x | :x: |
## 报告漏洞
如果您发现了安全漏洞,请通过以下方式报告:
### 报告渠道
- **GitHub 安全公告**: [报告漏洞](https://github.com/esengine/esengine/security/advisories/new)(推荐)
- **邮箱**: security@esengine.dev
### 报告指南
1. **不要**在公开的 issue 中报告安全漏洞
2. 提供详细的漏洞描述,包括:
- 受影响的版本
- 复现步骤
- 潜在的影响范围
- 如果可能,提供修复建议
### 响应时间
- **确认收到**: 72小时内
- **初步评估**: 1周内
- **修复发布**: 根据严重程度,通常在2-4周内
### 处理流程
1. 我们会确认漏洞的存在和严重程度
2. 开发修复方案并进行测试
3. 发布安全更新
4. 在修复发布后,会在相关渠道公布漏洞详情
## 安全最佳实践
使用 ESEngine 时,请遵循以下安全建议:
- 始终使用最新的稳定版本
- 定期更新依赖项
- 在生产环境中禁用调试模式
- 验证所有外部输入数据
- 不要在客户端存储敏感信息
感谢您帮助保持 ESEngine 的安全性!
Thank you for helping keep ESEngine secure!
+53
View File
@@ -0,0 +1,53 @@
# Codecov 配置文件
# https://docs.codecov.com/docs/codecov-yaml
coverage:
status:
# 项目整体覆盖率要求
project:
default:
target: auto
threshold: 1%
base: auto
# 补丁覆盖率要求(针对 PR 中的新代码)
patch:
default:
target: 50% # 降低补丁覆盖率要求到 50%
threshold: 5%
base: auto
# 精确度设置
precision: 2
round: down
range: "70...100"
# 注释设置
comment:
layout: "reach,diff,flags,tree,files"
behavior: default
require_changes: false
require_base: false
require_head: true
# 忽略的文件/目录
ignore:
- "tests/**/*"
- "**/*.test.ts"
- "**/*.spec.ts"
- "**/test/**/*"
- "**/tests/**/*"
- "bin/**/*"
- "dist/**/*"
- "node_modules/**/*"
# 标志组
flags:
core:
paths:
- packages/core/src/
carryforward: true
# GitHub Checks 配置
github_checks:
annotations: true
-29
View File
@@ -1,29 +0,0 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch Wing Player",
"type": "chrome",
"request": "launch",
"file": "index.html",
"runtimeExecutable": "${execPath}",
"useBuildInServer": true,
"sourceMaps": true,
"webRoot": "${workspaceRoot}",
"preLaunchTask":"build",
"port":5479
},
{
"name": "Launch Chrome",
"type": "chrome",
"request": "launch",
"file": "index.html",
"useBuildInServer": true,
"sourceMaps": true,
"webRoot": "${workspaceRoot}",
"preLaunchTask":"build",
"userDataDir":"${tmpdir}",
"port":5479
}
]
}
-6
View File
@@ -1,6 +0,0 @@
{
"search.exclude": {
"**/bin-debug": true,
"**/bin-release": true
}
}
-34
View File
@@ -1,34 +0,0 @@
{
"version": "0.1.0",
"command": "egret",
"isShellCommand": true,
"suppressTaskName": true,
"tasks": [
{
"taskName": "build",
"showOutput": "always",
"args": [
"build",
"-sourcemap"
],
"problemMatcher": "$tsc"
},
{
"taskName": "clean",
"showOutput": "always",
"args": [
"build",
"-e"
],
"problemMatcher": "$tsc"
},
{
"taskName": "publish",
"showOutput": "always",
"args": [
"publish"
],
"problemMatcher": "$tsc"
}
]
}
-32
View File
@@ -1,32 +0,0 @@
{
"engineVersion": "5.2.33",
"compilerVersion": "5.2.33",
"template": {},
"target": {
"current": "web"
},
"modules": [
{
"name": "egret"
},
{
"name": "eui"
},
{
"name": "assetsmanager"
},
{
"name": "game"
},
{
"name": "tween"
},
{
"name": "promise"
},
{
"name": "framework",
"path": "./libs/framework"
}
]
}
BIN
View File
Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.2 KiB

-95
View File
@@ -1,95 +0,0 @@
<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<title>Egret</title>
<meta name="viewport" content="width=device-width,initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="full-screen" content="true" />
<meta name="screen-orientation" content="portrait" />
<meta name="x5-fullscreen" content="true" />
<meta name="360-fullscreen" content="true" />
<style>
html, body {
-ms-touch-action: none;
background: #888888;
padding: 0;
border: 0;
margin: 0;
height: 100%;
}
</style>
</head>
<body>
<div style="margin: auto;width: 100%;height: 100%;" class="egret-player"
data-entry-class="Main"
data-orientation="auto"
data-scale-mode="fixedWidth"
data-frame-rate="30"
data-content-width="640"
data-content-height="1136"
data-multi-fingered="2"
data-show-fps="false" data-show-log="false"
data-show-fps-style="x:0,y:0,size:12,textColor:0xffffff,bgAlpha:0.9">
</div>
<script>
var loadScript = function (list, callback) {
var loaded = 0;
var loadNext = function () {
loadSingleScript(list[loaded], function () {
loaded++;
if (loaded >= list.length) {
callback();
}
else {
loadNext();
}
})
};
loadNext();
};
var loadSingleScript = function (src, callback) {
var s = document.createElement('script');
s.async = false;
s.src = src;
s.addEventListener('load', function () {
s.parentNode.removeChild(s);
s.removeEventListener('load', arguments.callee, false);
callback();
}, false);
document.body.appendChild(s);
};
var xhr = new XMLHttpRequest();
xhr.open('GET', './manifest.json?v=' + Math.random(), true);
xhr.addEventListener("load", function () {
var manifest = JSON.parse(xhr.response);
var list = manifest.initial.concat(manifest.game);
loadScript(list, function () {
/**
* {
* "renderMode":, //Engine rendering mode, "canvas" or "webgl"
* "audioType": 0 //Use the audio type, 0: default, 2: web audio, 3: audio
* "antialias": //Whether the anti-aliasing is enabled in WebGL mode, true: on, false: off, defaults to false
* "calculateCanvasScaleFactor": //a function return canvas scale factor
* }
**/
egret.runEgret({ renderMode: "webgl", audioType: 0, calculateCanvasScaleFactor:function(context) {
var backingStore = context.backingStorePixelRatio ||
context.webkitBackingStorePixelRatio ||
context.mozBackingStorePixelRatio ||
context.msBackingStorePixelRatio ||
context.oBackingStorePixelRatio ||
context.backingStorePixelRatio || 1;
return (window.devicePixelRatio || 1) / backingStore;
}});
});
});
xhr.send(null);
</script>
</body>
</html>
-52
View File
@@ -1,52 +0,0 @@
declare module skins{
class ButtonSkin extends eui.Skin{
}
}
declare module skins{
class CheckBoxSkin extends eui.Skin{
}
}
declare module skins{
class HScrollBarSkin extends eui.Skin{
}
}
declare module skins{
class HSliderSkin extends eui.Skin{
}
}
declare module skins{
class ItemRendererSkin extends eui.Skin{
}
}
declare module skins{
class PanelSkin extends eui.Skin{
}
}
declare module skins{
class ProgressBarSkin extends eui.Skin{
}
}
declare module skins{
class RadioButtonSkin extends eui.Skin{
}
}
declare module skins{
class ScrollerSkin extends eui.Skin{
}
}
declare module skins{
class TextInputSkin extends eui.Skin{
}
}
declare module skins{
class ToggleSwitchSkin extends eui.Skin{
}
}
declare module skins{
class VScrollBarSkin extends eui.Skin{
}
}
declare module skins{
class VSliderSkin extends eui.Skin{
}
}
-413
View File
@@ -1,413 +0,0 @@
declare interface Array<T> {
findIndex(predicate: Function): number;
any(predicate: Function): boolean;
firstOrDefault(predicate: Function): T;
find(predicate: Function): T;
where(predicate: Function): Array<T>;
count(predicate: Function): number;
findAll(predicate: Function): Array<T>;
contains(value: any): boolean;
removeAll(predicate: Function): void;
remove(element: any): boolean;
removeAt(index: any): void;
removeRange(index: any, count: any): void;
select(selector: Function): Array<T>;
orderBy(keySelector: Function, comparer: Function): Array<T>;
orderByDescending(keySelector: Function, comparer: Function): Array<T>;
groupBy(keySelector: Function): Array<T>;
sum(selector: any): any;
}
declare class PriorityQueueNode {
priority: number;
insertionIndex: number;
queueIndex: number;
}
declare class AStarPathfinder {
static search<T>(graph: IAstarGraph<T>, start: T, goal: T): T[];
private static hasKey;
private static getKey;
static recontructPath<T>(cameFrom: Map<T, T>, start: T, goal: T): T[];
}
declare class AStarNode<T> extends PriorityQueueNode {
data: T;
constructor(data: T);
}
declare class AstarGridGraph implements IAstarGraph<Point> {
dirs: Point[];
walls: Point[];
weightedNodes: Point[];
defaultWeight: number;
weightedNodeWeight: number;
private _width;
private _height;
private _neighbors;
constructor(width: number, height: number);
isNodeInBounds(node: Point): boolean;
isNodePassable(node: Point): boolean;
search(start: Point, goal: Point): Point[];
getNeighbors(node: Point): Point[];
cost(from: Point, to: Point): number;
heuristic(node: Point, goal: Point): number;
}
interface IAstarGraph<T> {
getNeighbors(node: T): Array<T>;
cost(from: T, to: T): number;
heuristic(node: T, goal: T): any;
}
declare class PriorityQueue<T extends PriorityQueueNode> {
private _numNodes;
private _nodes;
private _numNodesEverEnqueued;
constructor(maxNodes: number);
clear(): void;
readonly count: number;
contains(node: T): boolean;
enqueue(node: T, priority: number): void;
dequeue(): T;
remove(node: T): void;
isValidQueue(): boolean;
private onNodeUpdated;
private cascadeDown;
private cascadeUp;
private swap;
private hasHigherPriority;
}
declare abstract class Component {
entity: Entity;
displayRender: egret.DisplayObject;
private _enabled;
updateInterval: number;
readonly transform: Transform;
enabled: boolean;
setEnabled(isEnabled: boolean): this;
abstract initialize(): any;
onAddedToEntity(): void;
onRemovedFromEntity(): void;
onEnabled(): void;
onDisabled(): void;
onEntityTransformChanged(comp: ComponentTransform): void;
update(): void;
bind(displayRender: egret.DisplayObject): this;
registerComponent(): void;
deregisterComponent(): void;
}
declare class Entity {
name: string;
scene: Scene;
readonly transform: Transform;
readonly components: ComponentList;
private _updateOrder;
private _enabled;
private _isDestoryed;
componentBits: BitSet;
parent: Transform;
position: Vector2;
localPosition: Vector2;
rotation: number;
rotationDegrees: number;
localRotation: number;
localRotationDegrees: number;
scale: Vector2;
localScale: Vector2;
readonly worldInverseTransform: Matrix2D;
readonly localToWorldTransform: Matrix2D;
readonly worldToLocalTransform: Matrix2D;
readonly isDestoryed: boolean;
enabled: boolean;
setEnabled(isEnabled: boolean): this;
constructor(name: string);
updateOrder: number;
setUpdateOrder(updateOrder: number): this;
attachToScene(newScene: Scene): void;
detachFromScene(): void;
addComponent<T extends Component>(component: T): T;
hasComponent<T extends Component>(type: any): boolean;
getOrCreateComponent<T extends Component>(type: T): T;
getComponent<T extends Component>(type: any): T;
removeComponentForType<T extends Component>(type: any): boolean;
removeComponent(component: Component): void;
removeAllComponents(): void;
update(): void;
onAddedToScene(): void;
onRemovedFromScene(): void;
onTransformChanged(comp: ComponentTransform): void;
destory(): void;
}
declare class Scene extends egret.DisplayObjectContainer {
camera: Camera;
readonly entities: EntityList;
private _projectionMatrix;
private _transformMatrix;
private _matrixTransformMatrix;
readonly entityProcessors: EntityProcessorList;
constructor(displayObject: egret.DisplayObject);
createEntity(name: string): Entity;
addEntity(entity: Entity): Entity;
destroyAllEntities(): void;
findEntity(name: string): Entity;
addEntityProcessor(processor: EntitySystem): EntitySystem;
removeEntityProcessor(processor: EntitySystem): void;
getEntityProcessor<T extends EntitySystem>(): T;
setActive(): Scene;
initialize(): void;
onActive(): void;
onDeactive(): void;
update(): void;
prepRenderState(): void;
destory(): void;
}
declare class SceneManager {
private static _loadedScenes;
private static _lastScene;
private static _activeScene;
static createScene(name: string, scene: Scene): Scene;
static setActiveScene(scene: Scene): Scene;
static getActiveScene(): Scene;
}
declare enum DirtyType {
clean = 0,
positionDirty = 1,
scaleDirty = 2,
rotationDirty = 3
}
declare enum ComponentTransform {
position = 0,
scale = 1,
rotation = 2
}
declare class Transform {
readonly entity: Entity;
private _children;
private _parent;
private _localPosition;
private _localRotation;
private _localScale;
private _translationMatrix;
private _rotationMatrix;
private _scaleMatrix;
private _worldTransform;
private _worldToLocalTransform;
private _worldInverseTransform;
private _rotation;
private _position;
private _scale;
private _localTransform;
private _hierachyDirty;
private _localDirty;
private _localPositionDirty;
private _localScaleDirty;
private _localRotationDirty;
private _positionDirty;
private _worldToLocalDirty;
private _worldInverseDirty;
readonly childCount: number;
constructor(entity: Entity);
getChild(index: number): Transform;
readonly worldInverseTransform: Matrix2D;
readonly localToWorldTransform: Matrix2D;
readonly worldToLocalTransform: Matrix2D;
parent: Transform;
setParent(parent: Transform): this;
rotation: number;
localRotation: number;
position: Vector2;
localPosition: Vector2;
scale: Vector2;
localScale: Vector2;
rotationDegrees: number;
localRotationDegrees: number;
setLocalScale(scale: Vector2): this;
setScale(scale: Vector2): this;
setLocalRotationDegrees(degrees: number): this;
setLocalRotation(radians: number): this;
setRotation(radians: number): this;
setRotationDegrees(degrees: number): this;
setLocalPosition(localPosition: Vector2): this;
setPosition(position: Vector2): this;
setDirty(dirtyFlagType: DirtyType): void;
updateTransform(): void;
}
declare class Camera extends Component {
private _zoom;
private _origin;
private _transformMatrix;
private _inverseTransformMatrix;
private _minimumZoom;
private _maximumZoom;
private _areMatrixesDirty;
zoom: number;
minimumZoom: number;
maximumZoom: number;
origin: Vector2;
readonly transformMatrix: Matrix2D;
constructor();
setMinimumZoom(minZoom: number): Camera;
setMaximumZoom(maxZoom: number): Camera;
setZoom(zoom: number): this;
initialize(): void;
update(): void;
setPosition(position: Vector2): this;
updateMatrixes(): void;
destory(): void;
}
declare class EntitySystem {
private _scene;
private _entities;
private _matcher;
readonly matcher: Matcher;
scene: Scene;
constructor(matcher?: Matcher);
initialize(): void;
onChanged(entity: Entity): void;
add(entity: Entity): void;
onAdded(entity: Entity): void;
remove(entity: Entity): void;
onRemoved(entity: Entity): void;
update(): void;
lateUpdate(): void;
protected begin(): void;
protected process(entities: Entity[]): void;
protected lateProcess(entities: Entity[]): void;
protected end(): void;
}
declare abstract class EntityProcessingSystem extends EntitySystem {
constructor(matcher: Matcher);
abstract processEntity(entity: Entity): any;
lateProcessEntity(entity: Entity): void;
protected process(entities: Entity[]): void;
protected lateProcess(entities: Entity[]): void;
}
declare class BitSet {
private static LONG_MASK;
private _bits;
constructor(nbits?: number);
and(bs: BitSet): void;
andNot(bs: BitSet): void;
cardinality(): number;
clear(pos?: number): void;
private ensure;
get(pos: number): boolean;
intersects(set: BitSet): boolean;
isEmpty(): boolean;
nextSetBit(from: number): number;
set(pos: number, value?: boolean): void;
}
declare class ComponentList {
private _entity;
private _components;
private _componentsToAdd;
private _componentsToRemove;
private _tempBufferList;
constructor(entity: Entity);
readonly count: number;
readonly buffer: Component[];
add(component: Component): void;
remove(component: Component): void;
removeAllComponents(): void;
deregisterAllComponents(): void;
registerAllComponents(): void;
updateLists(): void;
private handleRemove;
getComponent<T extends Component>(type: any, onlyReturnInitializedComponents: boolean): T;
update(): void;
onEntityTransformChanged(comp: any): void;
}
declare class ComponentTypeManager {
private static _componentTypesMask;
static add(type: any): void;
static getIndexFor(type: any): number;
}
declare class EntityList {
scene: Scene;
private _entitiesToRemove;
private _entitiesToAdded;
private _tempEntityList;
private _entities;
constructor(scene: Scene);
readonly count: number;
readonly buffer: Entity[];
add(entity: Entity): void;
remove(entity: Entity): void;
findEntity(name: string): Entity;
update(): void;
removeAllEntities(): void;
updateLists(): void;
}
declare class EntityProcessorList {
private _processors;
add(processor: EntitySystem): void;
remove(processor: EntitySystem): void;
onComponentAdded(entity: Entity): void;
onComponentRemoved(entity: Entity): void;
onEntityAdded(entity: Entity): void;
onEntityRemoved(entity: Entity): void;
protected notifyEntityChanged(entity: Entity): void;
protected removeFromProcessors(entity: Entity): void;
begin(): void;
update(): void;
lateUpdate(): void;
end(): void;
getProcessor<T extends EntitySystem>(): T;
}
declare class Matcher {
protected allSet: BitSet;
protected exclusionSet: BitSet;
protected oneSet: BitSet;
static empty(): Matcher;
IsIntersted(e: Entity): boolean;
}
declare class Time {
static unscaledDeltaTime: any;
static deltaTime: number;
static timeScale: number;
private static _lastTime;
static update(currentTime: number): void;
}
declare class MathHelper {
static toDegrees(radians: number): number;
static toRadians(degrees: number): number;
static map(value: number, leftMin: number, leftMax: number, rightMin: number, rightMax: number): number;
static clamp(value: number, min: number, max: number): number;
}
declare class Matrix2D {
m11: number;
m12: number;
m21: number;
m22: number;
m31: number;
m32: number;
private static _identity;
static readonly identity: Matrix2D;
constructor(m11: number, m12: number, m21: number, m22: number, m31: number, m32: number);
translation: Vector2;
rotation: number;
rotationDegrees: number;
scale: Vector2;
static add(matrix1: Matrix2D, matrix2: Matrix2D): Matrix2D;
static divide(matrix1: Matrix2D, matrix2: Matrix2D): Matrix2D;
static multiply(matrix1: Matrix2D, matrix2: Matrix2D): Matrix2D;
static multiplyTranslation(matrix: Matrix2D, x: number, y: number): Matrix2D;
determinant(): number;
static invert(matrix: Matrix2D, result?: Matrix2D): Matrix2D;
static createTranslation(xPosition: number, yPosition: number, result?: Matrix2D): Matrix2D;
static createRotation(radians: number, result?: Matrix2D): Matrix2D;
static createScale(xScale: number, yScale: number, result?: Matrix2D): Matrix2D;
}
declare class Point {
x: number;
y: number;
constructor(x: number, y: number);
}
declare class Vector2 {
x: number;
y: number;
private static readonly unitVector2;
static readonly One: Vector2;
constructor(x: number, y: number);
static add(value1: Vector2, value2: Vector2): Vector2;
static divide(value1: Vector2, value2: Vector2): Vector2;
static multiply(value1: Vector2, value2: Vector2): Vector2;
static subtract(value1: Vector2, value2: Vector2): Vector2;
normalize(): void;
static transform(position: Vector2, matrix: Matrix2D): Vector2;
}
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
-15371
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
-15047
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
-2502
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
-1350
View File
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
File diff suppressed because one or more lines are too long
-22
View File
@@ -1,22 +0,0 @@
{
"initial": [
"libs/modules/egret/egret.js",
"libs/modules/egret/egret.web.js",
"libs/modules/eui/eui.js",
"libs/modules/assetsmanager/assetsmanager.js",
"libs/modules/game/game.js",
"libs/modules/tween/tween.js",
"libs/modules/promise/promise.js",
"libs/framework/framework.js"
],
"game": [
"bin-debug/AssetAdapter.js",
"bin-debug/LoadingUI.js",
"bin-debug/Main.js",
"bin-debug/Platform.js",
"bin-debug/ThemeAdapter.js",
"bin-debug/game/MainScene.js",
"bin-debug/game/SpawnerComponent.js",
"bin-debug/game/SpawnerSystem.js"
]
}
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1019 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1002 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 938 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 938 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 976 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 970 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 933 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 933 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 933 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 933 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 136 KiB

Some files were not shown because too many files have changed in this diff Show More