@nice2dev/game-engine 1.3.13 → 1.3.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (253) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/package.json +2 -2
  3. package/dist/types/accessibility/index.d.ts +0 -1
  4. package/dist/types/ai/index.d.ts +0 -1
  5. package/dist/types/animation/index.d.ts +0 -1
  6. package/dist/types/audio/HRTFAudio.d.ts +0 -180
  7. package/dist/types/audio/index.d.ts +0 -2
  8. package/dist/types/community/Community.d.ts +0 -112
  9. package/dist/types/community/index.d.ts +0 -1
  10. package/dist/types/core/TypeSafety.d.ts +0 -190
  11. package/dist/types/core/index.d.ts +0 -7
  12. package/dist/types/devtools/AssetStore.d.ts +0 -133
  13. package/dist/types/devtools/index.d.ts +0 -3
  14. package/dist/types/dialogue/index.d.ts +0 -2
  15. package/dist/types/docs/APIPlayground.d.ts +0 -26
  16. package/dist/types/docs/Cookbook.d.ts +0 -18
  17. package/dist/types/docs/Guides.d.ts +0 -18
  18. package/dist/types/docs/index.d.ts +0 -4
  19. package/dist/types/ecs/ECSOptimized.d.ts +0 -131
  20. package/dist/types/ecs/index.d.ts +0 -2
  21. package/dist/types/editor/NiceAnimationTimeline.d.ts +0 -114
  22. package/dist/types/editor/NiceLevelEditor.d.ts +0 -232
  23. package/dist/types/editor/NiceMaterialEditor.d.ts +0 -105
  24. package/dist/types/editor/NiceNodeGraph.d.ts +0 -87
  25. package/dist/types/editor/NiceParticleEditor.d.ts +0 -127
  26. package/dist/types/editor/behavior-tree/BTDebugPanel.d.ts +0 -102
  27. package/dist/types/editor/behavior-tree/BTEditorCanvas.d.ts +0 -79
  28. package/dist/types/editor/behavior-tree/BTEditorNode.d.ts +0 -58
  29. package/dist/types/editor/behavior-tree/BTEditorToolbar.d.ts +0 -75
  30. package/dist/types/editor/behavior-tree/BTNodePalette.d.ts +0 -72
  31. package/dist/types/editor/behavior-tree/BTPropertyPanel.d.ts +0 -66
  32. package/dist/types/editor/behavior-tree/BehaviorTreeEditor.d.ts +0 -186
  33. package/dist/types/editor/behavior-tree/index.d.ts +0 -14
  34. package/dist/types/editor/behavior-tree/serialization.d.ts +0 -30
  35. package/dist/types/editor/behavior-tree/types.d.ts +0 -299
  36. package/dist/types/editor/index.d.ts +0 -20
  37. package/dist/types/editor/state-machine/SMEditorCanvas.d.ts +0 -61
  38. package/dist/types/editor/state-machine/StateMachineEditor.d.ts +0 -139
  39. package/dist/types/editor/state-machine/index.d.ts +0 -11
  40. package/dist/types/editor/state-machine/serialization.d.ts +0 -23
  41. package/dist/types/editor/state-machine/types.d.ts +0 -241
  42. package/dist/types/engine/index.d.ts +0 -2
  43. package/dist/types/enterprise/index.d.ts +0 -1
  44. package/dist/types/epic/index.d.ts +0 -10
  45. package/dist/types/i18n/index.d.ts +0 -2
  46. package/dist/types/input/index.d.ts +0 -3
  47. package/dist/types/kids/index.d.ts +0 -2
  48. package/dist/types/legendary/index.d.ts +0 -57
  49. package/dist/types/monetization/index.d.ts +0 -1
  50. package/dist/types/multiplayer/NiceNetcode.d.ts +0 -434
  51. package/dist/types/multiplayer/index.d.ts +0 -5
  52. package/dist/types/network/index.d.ts +0 -2
  53. package/dist/types/pathfinding/index.d.ts +0 -1
  54. package/dist/types/performance/AssetCompression.d.ts +0 -137
  55. package/dist/types/performance/WASMModules.d.ts +0 -65
  56. package/dist/types/performance/WebGPUCompute.d.ts +0 -71
  57. package/dist/types/performance/index.d.ts +0 -1
  58. package/dist/types/physics/RapierIntegration.d.ts +0 -404
  59. package/dist/types/physics/index.d.ts +0 -2
  60. package/dist/types/plugins/index.d.ts +0 -2
  61. package/dist/types/procedural/index.d.ts +0 -2
  62. package/dist/types/release/index.d.ts +0 -1
  63. package/dist/types/rendering/WebGPUv2.d.ts +0 -173
  64. package/dist/types/rendering/index.d.ts +0 -3
  65. package/dist/types/runtime3d/index.d.ts +0 -2
  66. package/dist/types/scene/index.d.ts +0 -2
  67. package/dist/types/scripting/WasmCompiler.d.ts +0 -182
  68. package/dist/types/scripting/index.d.ts +0 -19
  69. package/dist/types/social/index.d.ts +0 -1
  70. package/dist/types/systems/NiceAI.d.ts +0 -637
  71. package/dist/types/systems/NiceAbility.d.ts +0 -225
  72. package/dist/types/systems/NiceAccessibility.d.ts +0 -230
  73. package/dist/types/systems/NiceAchievement.d.ts +0 -153
  74. package/dist/types/systems/NiceAchievementUI.d.ts +0 -196
  75. package/dist/types/systems/NiceAchievements.d.ts +0 -230
  76. package/dist/types/systems/NiceAction.d.ts +0 -81
  77. package/dist/types/systems/NiceAlchemy.d.ts +0 -195
  78. package/dist/types/systems/NiceAnalytics.d.ts +0 -493
  79. package/dist/types/systems/NiceAnimation.d.ts +0 -350
  80. package/dist/types/systems/NiceArena.d.ts +0 -215
  81. package/dist/types/systems/NiceAssetLoader.d.ts +0 -136
  82. package/dist/types/systems/NiceAuction.d.ts +0 -157
  83. package/dist/types/systems/NiceAudio.d.ts +0 -224
  84. package/dist/types/systems/NiceAugment.d.ts +0 -187
  85. package/dist/types/systems/NiceAura.d.ts +0 -193
  86. package/dist/types/systems/NiceBank.d.ts +0 -158
  87. package/dist/types/systems/NiceBattlePass.d.ts +0 -150
  88. package/dist/types/systems/NiceBehavior.d.ts +0 -160
  89. package/dist/types/systems/NiceBinding.d.ts +0 -96
  90. package/dist/types/systems/NiceBlacksmith.d.ts +0 -221
  91. package/dist/types/systems/NiceBuff.d.ts +0 -177
  92. package/dist/types/systems/NiceBuilding.d.ts +0 -207
  93. package/dist/types/systems/NiceBullet.d.ts +0 -167
  94. package/dist/types/systems/NiceCamera.d.ts +0 -252
  95. package/dist/types/systems/NiceCard.d.ts +0 -171
  96. package/dist/types/systems/NiceChat.d.ts +0 -148
  97. package/dist/types/systems/NiceCheat.d.ts +0 -375
  98. package/dist/types/systems/NiceClimbing.d.ts +0 -186
  99. package/dist/types/systems/NiceCloud.d.ts +0 -422
  100. package/dist/types/systems/NiceCollision.d.ts +0 -238
  101. package/dist/types/systems/NiceCombo.d.ts +0 -131
  102. package/dist/types/systems/NiceCommand.d.ts +0 -112
  103. package/dist/types/systems/NiceCompanion.d.ts +0 -182
  104. package/dist/types/systems/NiceController.d.ts +0 -144
  105. package/dist/types/systems/NiceCooking.d.ts +0 -193
  106. package/dist/types/systems/NiceCoroutine.d.ts +0 -101
  107. package/dist/types/systems/NiceCrafting.d.ts +0 -228
  108. package/dist/types/systems/NiceCutscene.d.ts +0 -437
  109. package/dist/types/systems/NiceDaily.d.ts +0 -133
  110. package/dist/types/systems/NiceDamage.d.ts +0 -271
  111. package/dist/types/systems/NiceDayNight.d.ts +0 -126
  112. package/dist/types/systems/NiceDebug.d.ts +0 -255
  113. package/dist/types/systems/NiceDestructible.d.ts +0 -150
  114. package/dist/types/systems/NiceDialogue.d.ts +0 -629
  115. package/dist/types/systems/NiceDungeon.d.ts +0 -202
  116. package/dist/types/systems/NiceECS.d.ts +0 -151
  117. package/dist/types/systems/NiceEnchant.d.ts +0 -148
  118. package/dist/types/systems/NiceEntityPool.d.ts +0 -127
  119. package/dist/types/systems/NiceEquipment.d.ts +0 -137
  120. package/dist/types/systems/NiceEvent.d.ts +0 -202
  121. package/dist/types/systems/NiceEventBus.d.ts +0 -164
  122. package/dist/types/systems/NiceFaction.d.ts +0 -173
  123. package/dist/types/systems/NiceFarming.d.ts +0 -163
  124. package/dist/types/systems/NiceFishing.d.ts +0 -196
  125. package/dist/types/systems/NiceFlocking.d.ts +0 -156
  126. package/dist/types/systems/NiceFog.d.ts +0 -137
  127. package/dist/types/systems/NiceFormation.d.ts +0 -140
  128. package/dist/types/systems/NiceGacha.d.ts +0 -134
  129. package/dist/types/systems/NiceGambling.d.ts +0 -175
  130. package/dist/types/systems/NiceGem.d.ts +0 -165
  131. package/dist/types/systems/NiceGesture.d.ts +0 -502
  132. package/dist/types/systems/NiceGrappling.d.ts +0 -154
  133. package/dist/types/systems/NiceGrid.d.ts +0 -142
  134. package/dist/types/systems/NiceGuild.d.ts +0 -162
  135. package/dist/types/systems/NiceHaptics.d.ts +0 -112
  136. package/dist/types/systems/NiceHousing.d.ts +0 -197
  137. package/dist/types/systems/NiceInput.d.ts +0 -280
  138. package/dist/types/systems/NiceInventory.d.ts +0 -534
  139. package/dist/types/systems/NiceLOD.d.ts +0 -144
  140. package/dist/types/systems/NiceLeaderboard.d.ts +0 -191
  141. package/dist/types/systems/NiceLevel.d.ts +0 -304
  142. package/dist/types/systems/NiceLighting.d.ts +0 -214
  143. package/dist/types/systems/NiceLocalization.d.ts +0 -148
  144. package/dist/types/systems/NiceLocomotion.d.ts +0 -398
  145. package/dist/types/systems/NiceLogger.d.ts +0 -117
  146. package/dist/types/systems/NiceLoot.d.ts +0 -176
  147. package/dist/types/systems/NiceMail.d.ts +0 -164
  148. package/dist/types/systems/NiceMap.d.ts +0 -234
  149. package/dist/types/systems/NiceMarriage.d.ts +0 -150
  150. package/dist/types/systems/NiceMastery.d.ts +0 -171
  151. package/dist/types/systems/NiceMatch.d.ts +0 -196
  152. package/dist/types/systems/NiceMatch3.d.ts +0 -118
  153. package/dist/types/systems/NiceMessageBus.d.ts +0 -115
  154. package/dist/types/systems/NiceMinimap.d.ts +0 -258
  155. package/dist/types/systems/NiceMining.d.ts +0 -175
  156. package/dist/types/systems/NiceModding.d.ts +0 -452
  157. package/dist/types/systems/NiceMount.d.ts +0 -152
  158. package/dist/types/systems/NiceNavigation.d.ts +0 -307
  159. package/dist/types/systems/NiceNetwork.d.ts +0 -568
  160. package/dist/types/systems/NiceNotification.d.ts +0 -438
  161. package/dist/types/systems/NiceObjective.d.ts +0 -395
  162. package/dist/types/systems/NiceParticle.d.ts +0 -639
  163. package/dist/types/systems/NiceParty.d.ts +0 -168
  164. package/dist/types/systems/NicePerformance.d.ts +0 -144
  165. package/dist/types/systems/NicePet.d.ts +0 -167
  166. package/dist/types/systems/NicePhotoMode.d.ts +0 -270
  167. package/dist/types/systems/NicePhysics.d.ts +0 -326
  168. package/dist/types/systems/NicePlatformer.d.ts +0 -158
  169. package/dist/types/systems/NicePool.d.ts +0 -128
  170. package/dist/types/systems/NicePortal.d.ts +0 -178
  171. package/dist/types/systems/NicePostProcess.d.ts +0 -254
  172. package/dist/types/systems/NiceProcedural.d.ts +0 -202
  173. package/dist/types/systems/NiceProfile.d.ts +0 -223
  174. package/dist/types/systems/NiceProjectile.d.ts +0 -157
  175. package/dist/types/systems/NicePvP.d.ts +0 -199
  176. package/dist/types/systems/NiceQTE.d.ts +0 -160
  177. package/dist/types/systems/NiceQuest.d.ts +0 -620
  178. package/dist/types/systems/NiceRaid.d.ts +0 -215
  179. package/dist/types/systems/NiceRanking.d.ts +0 -399
  180. package/dist/types/systems/NiceReplay.d.ts +0 -180
  181. package/dist/types/systems/NiceReputation.d.ts +0 -151
  182. package/dist/types/systems/NiceResource.d.ts +0 -200
  183. package/dist/types/systems/NiceRhythm.d.ts +0 -148
  184. package/dist/types/systems/NiceRoguelike.d.ts +0 -276
  185. package/dist/types/systems/NiceRune.d.ts +0 -202
  186. package/dist/types/systems/NiceSaveSystem.d.ts +0 -194
  187. package/dist/types/systems/NiceSceneManager.d.ts +0 -112
  188. package/dist/types/systems/NiceScore.d.ts +0 -186
  189. package/dist/types/systems/NiceScreenFX.d.ts +0 -235
  190. package/dist/types/systems/NiceScreenshot.d.ts +0 -443
  191. package/dist/types/systems/NiceScribe.d.ts +0 -239
  192. package/dist/types/systems/NiceSeason.d.ts +0 -176
  193. package/dist/types/systems/NiceSerialization.d.ts +0 -89
  194. package/dist/types/systems/NiceServiceLocator.d.ts +0 -94
  195. package/dist/types/systems/NiceShop.d.ts +0 -528
  196. package/dist/types/systems/NiceSignal.d.ts +0 -112
  197. package/dist/types/systems/NiceSkillTree.d.ts +0 -237
  198. package/dist/types/systems/NiceSocial.d.ts +0 -580
  199. package/dist/types/systems/NiceSpawner.d.ts +0 -237
  200. package/dist/types/systems/NiceSpell.d.ts +0 -216
  201. package/dist/types/systems/NiceState.d.ts +0 -224
  202. package/dist/types/systems/NiceStateMachine.d.ts +0 -108
  203. package/dist/types/systems/NiceStatus.d.ts +0 -116
  204. package/dist/types/systems/NiceStealth.d.ts +0 -204
  205. package/dist/types/systems/NiceSteam.d.ts +0 -255
  206. package/dist/types/systems/NiceStreaming.d.ts +0 -173
  207. package/dist/types/systems/NiceSwimming.d.ts +0 -166
  208. package/dist/types/systems/NiceTalent.d.ts +0 -154
  209. package/dist/types/systems/NiceTarget.d.ts +0 -121
  210. package/dist/types/systems/NiceTerrain.d.ts +0 -143
  211. package/dist/types/systems/NiceTilemap.d.ts +0 -218
  212. package/dist/types/systems/NiceTimer.d.ts +0 -153
  213. package/dist/types/systems/NiceTournament.d.ts +0 -190
  214. package/dist/types/systems/NiceTrading.d.ts +0 -238
  215. package/dist/types/systems/NiceTransmog.d.ts +0 -142
  216. package/dist/types/systems/NiceTutorial.d.ts +0 -248
  217. package/dist/types/systems/NiceTween.d.ts +0 -164
  218. package/dist/types/systems/NiceUI.d.ts +0 -364
  219. package/dist/types/systems/NiceVFX.d.ts +0 -333
  220. package/dist/types/systems/NiceVehicle.d.ts +0 -176
  221. package/dist/types/systems/NiceVoice.d.ts +0 -502
  222. package/dist/types/systems/NiceWater.d.ts +0 -162
  223. package/dist/types/systems/NiceWave.d.ts +0 -174
  224. package/dist/types/systems/NiceWaypoint.d.ts +0 -165
  225. package/dist/types/systems/NiceWeather.d.ts +0 -225
  226. package/dist/types/systems/NiceXR.d.ts +0 -187
  227. package/dist/types/systems/index.d.ts +0 -182
  228. package/dist/types/templates/index.d.ts +0 -2
  229. package/dist/types/tilemap/index.d.ts +0 -1
  230. package/dist/types/tutorials/TutorialEditor.d.ts +0 -43
  231. package/dist/types/tutorials/VoiceNarration.d.ts +0 -75
  232. package/dist/types/tutorials/content/Tutorials_T04.d.ts +0 -3
  233. package/dist/types/tutorials/content/UITutorials.d.ts +0 -14
  234. package/dist/types/tutorials/content/index.d.ts +0 -5
  235. package/dist/types/tutorials/index.d.ts +0 -6
  236. package/dist/types/ui/index.d.ts +0 -2
  237. package/dist/types/visual-scripting/VisualScriptDebugger.d.ts +0 -145
  238. package/dist/types/visual-scripting/VisualScriptExecutor.d.ts +0 -100
  239. package/dist/types/visual-scripting/VisualScriptGraph.d.ts +0 -173
  240. package/dist/types/visual-scripting/VisualScriptNode.d.ts +0 -157
  241. package/dist/types/visual-scripting/index.d.ts +0 -6
  242. package/dist/types/visual-scripting/nodes/ActionNodes.d.ts +0 -152
  243. package/dist/types/visual-scripting/nodes/EventNodes.d.ts +0 -95
  244. package/dist/types/visual-scripting/nodes/FlowControlNodes.d.ts +0 -134
  245. package/dist/types/visual-scripting/nodes/LogicNodes.d.ts +0 -122
  246. package/dist/types/visual-scripting/nodes/MathNodes.d.ts +0 -170
  247. package/dist/types/visual-scripting/nodes/UtilityNodes.d.ts +0 -131
  248. package/dist/types/visual-scripting/nodes/VariableNodes.d.ts +0 -107
  249. package/dist/types/visual-scripting/nodes/index.d.ts +0 -21
  250. package/dist/types/visual-scripting/nodes/registerNodes.d.ts +0 -29
  251. package/dist/types/visual-scripting/types.d.ts +0 -402
  252. package/dist/types/xr/WebXRLayers.d.ts +0 -319
  253. package/dist/types/xr/index.d.ts +0 -2
@@ -1,148 +0,0 @@
1
- import { EventEmitter } from 'events';
2
- export type EntityId = string;
3
- export type ChannelId = string;
4
- export type MessageId = string;
5
- export type ChannelType = 'global' | 'local' | 'party' | 'guild' | 'trade' | 'help' | 'combat' | 'system' | 'whisper' | 'custom';
6
- export interface ChatChannel {
7
- id: ChannelId;
8
- name: string;
9
- type: ChannelType;
10
- color?: string;
11
- prefix?: string;
12
- permission?: string;
13
- isModerated: boolean;
14
- moderators: Set<EntityId>;
15
- bannedUsers: Map<EntityId, number>;
16
- members?: Set<EntityId>;
17
- maxRange?: number;
18
- }
19
- export interface ChatMessage {
20
- id: MessageId;
21
- channelId: ChannelId;
22
- senderId: EntityId;
23
- senderName: string;
24
- content: string;
25
- formattedContent?: string;
26
- timestamp: number;
27
- isSystem: boolean;
28
- metadata?: Record<string, unknown>;
29
- }
30
- export interface DirectMessage {
31
- id: MessageId;
32
- senderId: EntityId;
33
- senderName: string;
34
- recipientId: EntityId;
35
- content: string;
36
- timestamp: number;
37
- isRead: boolean;
38
- }
39
- export type CommandHandler = (senderId: EntityId, args: string[], rawMessage: string) => void | string;
40
- export interface ChatCommand {
41
- name: string;
42
- aliases: string[];
43
- description: string;
44
- usage: string;
45
- permission?: string;
46
- handler: CommandHandler;
47
- }
48
- export type FilterAction = 'block' | 'censor' | 'warn' | 'flag';
49
- export interface ChatFilter {
50
- id: string;
51
- pattern: RegExp;
52
- action: FilterAction;
53
- replacement?: string;
54
- reason?: string;
55
- }
56
- export interface MuteEntry {
57
- entityId: EntityId;
58
- mutedBy: EntityId;
59
- reason?: string;
60
- expiresAt: number;
61
- channelId?: ChannelId;
62
- }
63
- export interface Emote {
64
- code: string;
65
- name: string;
66
- image?: string;
67
- animation?: string;
68
- unlockRequirement?: string;
69
- }
70
- export type ChatEventType = 'message-sent' | 'message-received' | 'message-blocked' | 'message-deleted' | 'dm-sent' | 'dm-received' | 'channel-joined' | 'channel-left' | 'channel-created' | 'channel-deleted' | 'user-muted' | 'user-unmuted' | 'user-banned' | 'user-unbanned' | 'command-executed' | 'filter-triggered';
71
- export interface ChatEvent {
72
- type: ChatEventType;
73
- channelId?: ChannelId;
74
- senderId?: EntityId;
75
- messageId?: MessageId;
76
- data?: Record<string, unknown>;
77
- }
78
- export interface ChatSystemConfig {
79
- maxMessageLength?: number;
80
- maxHistoryPerChannel?: number;
81
- maxDmHistory?: number;
82
- rateLimitMessages?: number;
83
- rateLimitWindowMs?: number;
84
- enableFiltering?: boolean;
85
- enableCommands?: boolean;
86
- commandPrefix?: string;
87
- allowLinks?: boolean;
88
- linkWhitelist?: string[];
89
- }
90
- export declare const DEFAULT_CHAT_CONFIG: ChatSystemConfig;
91
- export declare class NiceChat extends EventEmitter {
92
- private channels;
93
- private messages;
94
- private directMessages;
95
- private commands;
96
- private filters;
97
- private emotes;
98
- private mutes;
99
- private ignoreList;
100
- private rateLimits;
101
- private entityChannels;
102
- private nextMessageId;
103
- private config;
104
- constructor(config?: Partial<ChatSystemConfig>);
105
- private initializeDefaultChannels;
106
- createChannel(channel: ChatChannel): void;
107
- deleteChannel(channelId: ChannelId): boolean;
108
- getChannel(id: ChannelId): ChatChannel | undefined;
109
- getAllChannels(): ChatChannel[];
110
- joinChannel(entityId: EntityId, channelId: ChannelId): boolean;
111
- leaveChannel(entityId: EntityId, channelId: ChannelId): boolean;
112
- sendMessage(senderId: EntityId, senderName: string, channelId: ChannelId, content: string, metadata?: Record<string, unknown>): MessageId | null;
113
- sendSystemMessage(channelId: ChannelId, content: string): MessageId | null;
114
- deleteMessage(channelId: ChannelId, messageId: MessageId, moderatorId?: EntityId): boolean;
115
- getHistory(channelId: ChannelId, limit?: number): ChatMessage[];
116
- sendDirectMessage(senderId: EntityId, senderName: string, recipientId: EntityId, content: string): MessageId | null;
117
- private getConversationKey;
118
- getDirectMessageHistory(entityId1: EntityId, entityId2: EntityId, limit?: number): DirectMessage[];
119
- markDirectMessageRead(messageId: MessageId): void;
120
- registerCommand(command: ChatCommand): void;
121
- unregisterCommand(name: string): void;
122
- private handleCommand;
123
- getCommands(): ChatCommand[];
124
- addFilter(filter: ChatFilter): void;
125
- removeFilter(filterId: string): void;
126
- private applyFilters;
127
- registerEmote(emote: Emote): void;
128
- unregisterEmote(code: string): void;
129
- private formatEmotes;
130
- getEmotes(): Emote[];
131
- mute(entityId: EntityId, moderatorId: EntityId, durationMs: number, reason?: string, channelId?: ChannelId): void;
132
- unmute(entityId: EntityId, channelId?: ChannelId): void;
133
- isMuted(entityId: EntityId, channelId?: ChannelId): boolean;
134
- ban(entityId: EntityId, channelId: ChannelId, durationMs: number): void;
135
- unban(entityId: EntityId, channelId: ChannelId): void;
136
- setModerator(channelId: ChannelId, entityId: EntityId, isModerator: boolean): void;
137
- ignore(entityId: EntityId, targetId: EntityId): void;
138
- unignore(entityId: EntityId, targetId: EntityId): void;
139
- isIgnoring(entityId: EntityId, targetId: EntityId): boolean;
140
- getIgnoreList(entityId: EntityId): EntityId[];
141
- private checkRateLimit;
142
- getEntityChannels(entityId: EntityId): ChatChannel[];
143
- searchMessages(channelId: ChannelId, query: string, limit?: number): ChatMessage[];
144
- }
145
- export declare function createChatSystem(config?: Partial<ChatSystemConfig>): NiceChat;
146
- export declare function defineChatFilter(options: Omit<ChatFilter, 'id'>): ChatFilter;
147
- export declare function defineChatCommand(options: ChatCommand): ChatCommand;
148
- export default NiceChat;
@@ -1,375 +0,0 @@
1
- /**
2
- * NiceCheat - Debug & Cheat Code System
3
- *
4
- * Comprehensive cheat code and debug command system for game development,
5
- * testing, and (optionally) player use.
6
- *
7
- * Features:
8
- * - Cheat code registration
9
- * - Konami code detection
10
- * - Console commands
11
- * - Key sequence detection
12
- * - Debug variables
13
- * - God mode, noclip, etc.
14
- * - Resource manipulation
15
- * - Teleportation
16
- * - Spawn entities
17
- * - Time manipulation
18
- * - Access control
19
- * - Cheat categories
20
- * - History tracking
21
- * - Anti-cheat detection
22
- *
23
- * @packageDocumentation
24
- */
25
- import { EventEmitter } from 'events';
26
- /** Unique cheat ID */
27
- export type CheatId = string;
28
- /** Unique command ID */
29
- export type CommandId = string;
30
- /** Cheat category */
31
- export type CheatCategory = 'player' | 'world' | 'items' | 'resources' | 'debug' | 'fun' | 'developer' | 'custom';
32
- /** Access level */
33
- export type AccessLevel = 'public' | 'dev' | 'admin' | 'internal';
34
- /** Input method */
35
- export type InputMethod = 'keyboard' | 'gamepad' | 'console' | 'api';
36
- /** Konami code sequence */
37
- export declare const KONAMI_CODE: string[];
38
- /** Classic cheats */
39
- export declare const CLASSIC_CHEATS: {
40
- IDDQD: string;
41
- IDKFA: string;
42
- IDCLIP: string;
43
- IDNOCLIP: string;
44
- };
45
- /** Cheat definition */
46
- export interface CheatDefinition {
47
- id: CheatId;
48
- name: string;
49
- description: string;
50
- category: CheatCategory;
51
- code?: string;
52
- keySequence?: string[];
53
- accessLevel: AccessLevel;
54
- enabled: boolean;
55
- handler: CheatHandler;
56
- params?: CheatParam[];
57
- cooldown?: number;
58
- singleUse?: boolean;
59
- disablesAchievements?: boolean;
60
- icon?: string;
61
- }
62
- /** Cheat parameter */
63
- export interface CheatParam {
64
- name: string;
65
- type: 'string' | 'number' | 'boolean' | 'select';
66
- required?: boolean;
67
- defaultValue?: unknown;
68
- min?: number;
69
- max?: number;
70
- options?: string[];
71
- description?: string;
72
- }
73
- /** Cheat handler function */
74
- export type CheatHandler = (params: Record<string, unknown>, context: CheatContext) => CheatResult | Promise<CheatResult>;
75
- /** Cheat context */
76
- export interface CheatContext {
77
- inputMethod: InputMethod;
78
- accessLevel: AccessLevel;
79
- timestamp: number;
80
- playerData?: unknown;
81
- worldData?: unknown;
82
- }
83
- /** Cheat result */
84
- export interface CheatResult {
85
- success: boolean;
86
- message?: string;
87
- data?: unknown;
88
- sideEffects?: string[];
89
- }
90
- /** Console command */
91
- export interface ConsoleCommand {
92
- id: CommandId;
93
- name: string;
94
- aliases?: string[];
95
- description: string;
96
- usage: string;
97
- accessLevel: AccessLevel;
98
- handler: CommandHandler;
99
- params?: CommandParam[];
100
- autoComplete?: boolean;
101
- }
102
- /** Command parameter */
103
- export interface CommandParam {
104
- name: string;
105
- type: 'string' | 'number' | 'boolean' | 'entity' | 'item' | 'position';
106
- required?: boolean;
107
- description?: string;
108
- suggestions?: string[];
109
- }
110
- /** Command handler function */
111
- export type CommandHandler = (args: string[], context: CommandContext) => CommandResult | Promise<CommandResult>;
112
- /** Command context */
113
- export interface CommandContext {
114
- rawInput: string;
115
- accessLevel: AccessLevel;
116
- timestamp: number;
117
- }
118
- /** Command result */
119
- export interface CommandResult {
120
- success: boolean;
121
- output: string;
122
- data?: unknown;
123
- }
124
- /** Debug variable */
125
- export interface DebugVariable {
126
- name: string;
127
- value: unknown;
128
- type: string;
129
- readonly?: boolean;
130
- watchable?: boolean;
131
- category?: string;
132
- }
133
- /** Key sequence tracker */
134
- export interface KeySequenceTracker {
135
- cheatId: CheatId;
136
- sequence: string[];
137
- currentIndex: number;
138
- timeout: number;
139
- lastKeyTime: number;
140
- }
141
- /** Cheat activation record */
142
- export interface CheatActivation {
143
- cheatId: CheatId;
144
- timestamp: number;
145
- inputMethod: InputMethod;
146
- params?: Record<string, unknown>;
147
- result: CheatResult;
148
- }
149
- /** Cheat statistics */
150
- export interface CheatStatistics {
151
- totalActivations: number;
152
- uniqueCheatsUsed: number;
153
- categoryUsage: Record<CheatCategory, number>;
154
- achievementsDisabled: boolean;
155
- lastActivation?: number;
156
- activationHistory: CheatActivation[];
157
- }
158
- /** Quick toggles */
159
- export interface QuickToggles {
160
- godMode: boolean;
161
- noclip: boolean;
162
- infiniteAmmo: boolean;
163
- infiniteHealth: boolean;
164
- infiniteResources: boolean;
165
- superSpeed: boolean;
166
- slowMotion: boolean;
167
- invisibility: boolean;
168
- oneHitKill: boolean;
169
- freezeEnemies: boolean;
170
- }
171
- /** Cheat event types */
172
- export type CheatEventType = 'cheat_activated' | 'cheat_failed' | 'cheat_registered' | 'cheat_unregistered' | 'command_executed' | 'command_failed' | 'konami_code' | 'sequence_progress' | 'toggle_changed' | 'achievements_disabled' | 'console_opened' | 'console_closed';
173
- /** Cheat event data */
174
- export interface CheatEvent {
175
- type: CheatEventType;
176
- timestamp: number;
177
- cheatId?: CheatId;
178
- commandId?: CommandId;
179
- data?: unknown;
180
- error?: string;
181
- }
182
- /** Cheat event callback */
183
- export type CheatEventCallback = (event: CheatEvent) => void;
184
- /** Cheat system configuration */
185
- export interface CheatConfig {
186
- enabled: boolean;
187
- consoleEnabled: boolean;
188
- consoleKey: string;
189
- accessLevel: AccessLevel;
190
- sequenceTimeout: number;
191
- maxHistorySize: number;
192
- disableAchievementsOnCheat: boolean;
193
- showNotifications: boolean;
194
- logActivations: boolean;
195
- allowInMultiplayer: boolean;
196
- developerMode: boolean;
197
- antiCheatEnabled: boolean;
198
- }
199
- /** Default configuration */
200
- export declare const DEFAULT_CHEAT_CONFIG: CheatConfig;
201
- /**
202
- * Debug and cheat code system
203
- */
204
- export declare class NiceCheat extends EventEmitter {
205
- private config;
206
- private cheats;
207
- private commands;
208
- private commandAliases;
209
- private debugVariables;
210
- private keySequenceTrackers;
211
- private quickToggles;
212
- private statistics;
213
- private consoleOpen;
214
- private consoleHistory;
215
- private consoleHistoryIndex;
216
- private inputBuffer;
217
- private konamiProgress;
218
- private lastKeyTime;
219
- private cooldowns;
220
- private usedCheats;
221
- constructor(config?: Partial<CheatConfig>);
222
- /**
223
- * Emit cheat event
224
- */
225
- private emitEvent;
226
- /**
227
- * Setup keyboard listener
228
- */
229
- private setupKeyboardListener;
230
- /**
231
- * Handle key down
232
- */
233
- private handleKeyDown;
234
- /**
235
- * Check Konami code
236
- */
237
- private checkKonamiCode;
238
- /**
239
- * Check key sequences
240
- */
241
- private checkKeySequences;
242
- /**
243
- * Check text codes
244
- */
245
- private checkTextCodes;
246
- /**
247
- * Reset sequence trackers
248
- */
249
- private resetSequenceTrackers;
250
- /**
251
- * Register cheat
252
- */
253
- registerCheat(cheat: CheatDefinition): void;
254
- /**
255
- * Unregister cheat
256
- */
257
- unregisterCheat(cheatId: CheatId): boolean;
258
- /**
259
- * Get cheat
260
- */
261
- getCheat(cheatId: CheatId): CheatDefinition | undefined;
262
- /**
263
- * Get all cheats
264
- */
265
- getAllCheats(category?: CheatCategory): CheatDefinition[];
266
- /**
267
- * Register built-in cheats
268
- */
269
- private registerBuiltInCheats;
270
- /**
271
- * Activate cheat
272
- */
273
- activateCheat(cheatId: CheatId, params?: Record<string, unknown>, inputMethod?: InputMethod): Promise<CheatResult>;
274
- /**
275
- * Check if has access
276
- */
277
- private hasAccess;
278
- /**
279
- * Check if multiplayer (placeholder)
280
- */
281
- private isMultiplayer;
282
- /**
283
- * Toggle quick option
284
- */
285
- toggleQuick(toggle: keyof QuickToggles): boolean;
286
- /**
287
- * Set quick toggle
288
- */
289
- setQuickToggle(toggle: keyof QuickToggles, value: boolean): void;
290
- /**
291
- * Get quick toggles
292
- */
293
- getQuickToggles(): QuickToggles;
294
- /**
295
- * Is toggle active
296
- */
297
- isToggleActive(toggle: keyof QuickToggles): boolean;
298
- /**
299
- * Register command
300
- */
301
- registerCommand(command: ConsoleCommand): void;
302
- /**
303
- * Unregister command
304
- */
305
- unregisterCommand(commandId: CommandId): boolean;
306
- /**
307
- * Execute command
308
- */
309
- executeCommand(input: string): Promise<CommandResult>;
310
- /**
311
- * Parse command input
312
- */
313
- private parseCommandInput;
314
- /**
315
- * Register built-in commands
316
- */
317
- private registerBuiltInCommands;
318
- /**
319
- * Toggle console
320
- */
321
- toggleConsole(): void;
322
- /**
323
- * Open console
324
- */
325
- openConsole(): void;
326
- /**
327
- * Close console
328
- */
329
- closeConsole(): void;
330
- /**
331
- * Is console open
332
- */
333
- isConsoleOpen(): boolean;
334
- /**
335
- * Get console history
336
- */
337
- getConsoleHistory(): string[];
338
- /**
339
- * Get autocomplete suggestions
340
- */
341
- getAutocompleteSuggestions(input: string): string[];
342
- /**
343
- * Set debug variable
344
- */
345
- setDebugVariable(name: string, value: unknown, readonly?: boolean): void;
346
- /**
347
- * Get debug variable
348
- */
349
- getDebugVariable(name: string): unknown;
350
- /**
351
- * Get all debug variables
352
- */
353
- getDebugVariables(): DebugVariable[];
354
- /**
355
- * Get statistics
356
- */
357
- getStatistics(): CheatStatistics;
358
- /**
359
- * Are achievements disabled
360
- */
361
- areAchievementsDisabled(): boolean;
362
- /**
363
- * Reset cheat state (for new game)
364
- */
365
- resetState(): void;
366
- /**
367
- * Destroy cheat system
368
- */
369
- destroy(): void;
370
- }
371
- /**
372
- * Create cheat system instance
373
- */
374
- export declare function createCheatSystem(config?: Partial<CheatConfig>): NiceCheat;
375
- export default NiceCheat;
@@ -1,186 +0,0 @@
1
- import { EventEmitter } from 'events';
2
- export type EntityId = string;
3
- export type SurfaceId = string;
4
- export type ClimbableId = string;
5
- export interface Vector3 {
6
- x: number;
7
- y: number;
8
- z: number;
9
- }
10
- export type SurfaceType = 'rock' | 'wood' | 'metal' | 'ice' | 'vine' | 'rope' | 'ladder' | 'ledge' | 'wall' | 'custom';
11
- export interface ClimbingSurface {
12
- id: SurfaceId;
13
- type: SurfaceType;
14
- friction: number;
15
- staminaCost: number;
16
- speedModifier: number;
17
- requiresTool: boolean;
18
- toolId?: string;
19
- canRest: boolean;
20
- damageOnFall?: number;
21
- }
22
- export interface ClimbableObject {
23
- id: ClimbableId;
24
- surfaceId: SurfaceId;
25
- bounds: {
26
- min: Vector3;
27
- max: Vector3;
28
- };
29
- holdPoints: HoldPoint[];
30
- ledges: Ledge[];
31
- vaultPoints: VaultPoint[];
32
- isEnabled: boolean;
33
- }
34
- export interface HoldPoint {
35
- id: string;
36
- position: Vector3;
37
- normal: Vector3;
38
- type: 'grip' | 'edge' | 'crack' | 'hold';
39
- size: 'small' | 'medium' | 'large';
40
- stability: number;
41
- maxWeight?: number;
42
- }
43
- export interface Ledge {
44
- id: string;
45
- start: Vector3;
46
- end: Vector3;
47
- width: number;
48
- canHang: boolean;
49
- canPullUp: boolean;
50
- canShimmy: boolean;
51
- canJumpFrom: boolean;
52
- }
53
- export interface VaultPoint {
54
- id: string;
55
- position: Vector3;
56
- direction: Vector3;
57
- height: number;
58
- type: 'vault' | 'slide' | 'roll' | 'climb_over';
59
- speedRequired: number;
60
- }
61
- export type ClimbingState = 'idle' | 'approaching' | 'grabbing' | 'climbing' | 'hanging' | 'shimmying' | 'pulling_up' | 'jumping' | 'falling' | 'resting' | 'vaulting';
62
- export interface Climber {
63
- entityId: EntityId;
64
- state: ClimbingState;
65
- stamina: number;
66
- maxStamina: number;
67
- staminaRegen: number;
68
- climbSpeed: number;
69
- gripStrength: number;
70
- currentClimbable?: ClimbableId;
71
- currentHold?: string;
72
- currentLedge?: string;
73
- position: Vector3;
74
- targetPosition?: Vector3;
75
- handsState: {
76
- left: {
77
- attached: boolean;
78
- holdId?: string;
79
- };
80
- right: {
81
- attached: boolean;
82
- holdId?: string;
83
- };
84
- };
85
- feetState: {
86
- left: {
87
- attached: boolean;
88
- holdId?: string;
89
- };
90
- right: {
91
- attached: boolean;
92
- holdId?: string;
93
- };
94
- };
95
- timeClimbing: number;
96
- skills: ClimbingSkills;
97
- }
98
- export interface ClimbingSkills {
99
- efficiency: number;
100
- balance: number;
101
- strength: number;
102
- agility: number;
103
- endurance: number;
104
- }
105
- export type ClimbingEventType = 'climb-started' | 'climb-ended' | 'hold-grabbed' | 'hold-released' | 'ledge-grabbed' | 'ledge-pullup' | 'vault-started' | 'vault-completed' | 'stamina-depleted' | 'fall-started' | 'fall-ended' | 'skill-improved';
106
- export interface ClimbingEvent {
107
- type: ClimbingEventType;
108
- entityId: EntityId;
109
- climbableId?: ClimbableId;
110
- data?: Record<string, unknown>;
111
- }
112
- export interface ClimbingSystemConfig {
113
- baseStamina?: number;
114
- staminaRegenRate?: number;
115
- staminaRegenDelay?: number;
116
- restingRegenMultiplier?: number;
117
- baseClimbSpeed?: number;
118
- baseJumpForce?: number;
119
- maxFallDistance?: number;
120
- fallDamageThreshold?: number;
121
- fallDamageMultiplier?: number;
122
- autoGrabRange?: number;
123
- ledgeDetectionRange?: number;
124
- vaultDetectionRange?: number;
125
- }
126
- export declare const DEFAULT_CLIMBING_CONFIG: ClimbingSystemConfig;
127
- export declare class NiceClimbing extends EventEmitter {
128
- private surfaces;
129
- private climbables;
130
- private climbers;
131
- private config;
132
- private lastStaminaRegen;
133
- constructor(config?: Partial<ClimbingSystemConfig>);
134
- private initializeDefaultSurfaces;
135
- registerSurface(surface: ClimbingSurface): void;
136
- getSurface(id: SurfaceId): ClimbingSurface | undefined;
137
- registerClimbable(climbable: ClimbableObject): void;
138
- unregisterClimbable(id: ClimbableId): void;
139
- getClimbable(id: ClimbableId): ClimbableObject | undefined;
140
- setClimbableEnabled(id: ClimbableId, enabled: boolean): void;
141
- registerClimber(entityId: EntityId, skills?: Partial<ClimbingSkills>): void;
142
- unregisterClimber(entityId: EntityId): void;
143
- getClimber(entityId: EntityId): Climber | undefined;
144
- startClimbing(entityId: EntityId, climbableId: ClimbableId, position: Vector3): boolean;
145
- stopClimbing(entityId: EntityId): void;
146
- grabHold(entityId: EntityId, holdId: string, hand: 'left' | 'right'): boolean;
147
- releaseHold(entityId: EntityId, hand: 'left' | 'right'): void;
148
- grabLedge(entityId: EntityId, ledgeId: string): boolean;
149
- pullUp(entityId: EntityId): boolean;
150
- shimmy(entityId: EntityId, direction: number, distance: number): boolean;
151
- climb(entityId: EntityId, direction: Vector3): boolean;
152
- jumpFromClimb(entityId: EntityId, direction: Vector3): boolean;
153
- vault(entityId: EntityId, vaultPointId: string): boolean;
154
- private startFall;
155
- endFall(entityId: EntityId, fallHeight: number): {
156
- damage: number;
157
- };
158
- rest(entityId: EntityId): boolean;
159
- update(deltaTime: number): void;
160
- private updateClimber;
161
- improveSkill(entityId: EntityId, skill: keyof ClimbingSkills, amount: number): void;
162
- detectNearbyClimbables(position: Vector3, radius: number): ClimbableObject[];
163
- detectNearbyLedges(position: Vector3, radius: number): {
164
- climbable: ClimbableObject;
165
- ledge: Ledge;
166
- }[];
167
- detectNearbyVaultPoints(position: Vector3, radius: number): {
168
- climbable: ClimbableObject;
169
- vaultPoint: VaultPoint;
170
- }[];
171
- private calculateDistance;
172
- private normalizeVector;
173
- private isWithinBounds;
174
- private findNearbyLedge;
175
- private findClimbableAtPosition;
176
- isClimbing(entityId: EntityId): boolean;
177
- getClimberState(entityId: EntityId): ClimbingState | undefined;
178
- getStamina(entityId: EntityId): {
179
- current: number;
180
- max: number;
181
- } | undefined;
182
- }
183
- export declare function createClimbingSystem(config?: Partial<ClimbingSystemConfig>): NiceClimbing;
184
- export declare function defineClimbingSurface(options: ClimbingSurface): ClimbingSurface;
185
- export declare function defineClimbable(options: ClimbableObject): ClimbableObject;
186
- export default NiceClimbing;