一键导入
enforcescript-patterns
EnforceScript component patterns, networking, persistence, and memory management for Enfusion engine
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
EnforceScript component patterns, networking, persistence, and memory management for Enfusion engine
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | enforcescript-patterns |
| description | EnforceScript component patterns, networking, persistence, and memory management for Enfusion engine |
| version | 1.0.0 |
Quick reference for EnforceScript development in Arma Reforger. For detailed patterns, see resource files below.
Use this skill when:
Three main component types in Overthrow: Managers (singletons on game mode), Controllers (instance managers), and Components (sub-systems). Each has specific lifecycle and registration patterns.
See: component-patterns.md for detailed patterns and examples
Use RplProp for simple value synchronization, RPC for server/client communication, and JIP for late-join state sync. Never replicate EntityID - use RplId instead.
See: networking.md for comprehensive replication patterns
EPF requires SaveData classes that extend EPF_ComponentSaveDataClass. ReadFrom extracts data, ApplyTo restores it. Console platforms require PLATFORM_CONSOLE guards.
See: persistence.md for EPF save/load patterns
All Managed class references must use ref keyword to prevent garbage collection. Store EntityID instead of IEntity for long-term references. Check entity existence before use.
See: memory-management.md for garbage collection patterns
UI contexts extend OVT_UIContext with m_Layout property. Activate contexts via OVT_Global.GetUI().ShowContext(). Each context manages its own .layout file lifecycle.
See: ui-patterns.md for UI context patterns
EnforceScript has unique constraints: no ternary operators, specific replication patterns, strict typing. Knowing these pitfalls saves debugging time.
See: common-pitfalls.md for anti-patterns and solutions
ref keyword for arrays/maps of Managed classesDetailed documentation organized by concern:
EnforceScript is a C++ variant with unique characteristics:
Pattern: Start here for quick reference, dive into resource files for implementation details.