rbxts-chrono 2.0.0-experimental.5 → 2.0.0-experimental.6
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.
- package/package.json +1 -1
- package/src/index.d.ts +46 -44
package/package.json
CHANGED
package/src/index.d.ts
CHANGED
|
@@ -142,98 +142,100 @@ interface EntityConstructor {
|
|
|
142
142
|
): Entity;
|
|
143
143
|
|
|
144
144
|
/** Sets or changes the model for an entity */
|
|
145
|
-
SetModel(
|
|
145
|
+
SetModel: (
|
|
146
146
|
entity: Entity,
|
|
147
147
|
model?: Model | BasePart | string,
|
|
148
148
|
modelReplicationMode?: ModelReplicationMode,
|
|
149
149
|
noDestroy?: boolean,
|
|
150
|
-
)
|
|
150
|
+
) => void;
|
|
151
151
|
|
|
152
152
|
/** Sets the entity configuration type */
|
|
153
|
-
SetConfig(entity: Entity, entityConfig: string)
|
|
153
|
+
SetConfig: (entity: Entity, entityConfig: string) => void;
|
|
154
154
|
|
|
155
155
|
/** Sets the broad phase collision bounds */
|
|
156
|
-
SetBroadPhase(entity: Entity, broadPhase?: Vector3)
|
|
156
|
+
SetBroadPhase: (entity: Entity, broadPhase?: Vector3) => void;
|
|
157
157
|
|
|
158
158
|
/** Gets custom data associated with an entity */
|
|
159
|
-
GetData<T = unknown>(entity: Entity)
|
|
159
|
+
GetData: <T = unknown>(entity: Entity) => T;
|
|
160
160
|
|
|
161
161
|
/** Gets the model associated with an entity */
|
|
162
|
-
GetModel(entity: Entity)
|
|
162
|
+
GetModel: (entity: Entity) => Model | BasePart | undefined;
|
|
163
163
|
|
|
164
164
|
/** Sets custom data for an entity */
|
|
165
|
-
SetData(entity: Entity, data: unknown)
|
|
165
|
+
SetData: (entity: Entity, data: unknown) => void;
|
|
166
166
|
|
|
167
167
|
/** Clears the mount relationship */
|
|
168
|
-
ClearMount(entity: Entity)
|
|
168
|
+
ClearMount: (entity: Entity) => void;
|
|
169
169
|
|
|
170
170
|
/** Mounts an entity to a parent entity with optional offset */
|
|
171
|
-
SetMount(entity: Entity, parent?: Entity, offset?: CFrame)
|
|
171
|
+
SetMount: (entity: Entity, parent?: Entity, offset?: CFrame) => void;
|
|
172
172
|
|
|
173
173
|
/** Sets the network owner (player who controls this entity) */
|
|
174
|
-
SetNetworkOwner(entity: Entity, player?: Player)
|
|
174
|
+
SetNetworkOwner: (entity: Entity, player?: Player) => void;
|
|
175
175
|
|
|
176
176
|
/** Clears the entity's snapshot buffer */
|
|
177
|
-
Clear(entity: Entity)
|
|
177
|
+
Clear: (entity: Entity) => void;
|
|
178
178
|
|
|
179
179
|
/** Pauses replication for an entity */
|
|
180
|
-
PauseReplication(entity: Entity)
|
|
180
|
+
PauseReplication: (entity: Entity) => void;
|
|
181
181
|
|
|
182
182
|
/** Resumes replication for an entity */
|
|
183
|
-
ResumeReplication(entity: Entity)
|
|
183
|
+
ResumeReplication: (entity: Entity) => void;
|
|
184
184
|
|
|
185
185
|
/** Pushes a new CFrame snapshot at the given time */
|
|
186
|
-
Push(entity: Entity, time: number, value: CFrame)
|
|
186
|
+
Push: (entity: Entity, time: number, value: CFrame) => boolean;
|
|
187
187
|
|
|
188
188
|
/** Gets the interpolated CFrame at a specific time */
|
|
189
|
-
GetAt(entity: Entity, time: number)
|
|
189
|
+
GetAt: (entity: Entity, time: number) => CFrame | undefined;
|
|
190
190
|
|
|
191
191
|
/** Gets the target render time for interpolation */
|
|
192
|
-
GetTargetRenderTime(entity: Entity)
|
|
192
|
+
GetTargetRenderTime: (entity: Entity) => number;
|
|
193
193
|
|
|
194
194
|
/** Sets whether position updates automatically */
|
|
195
|
-
SetAutoUpdatePos(entity: Entity, autoUpdate: boolean)
|
|
195
|
+
SetAutoUpdatePos: (entity: Entity, autoUpdate: boolean) => void;
|
|
196
196
|
|
|
197
197
|
/** Gets the current CFrame */
|
|
198
|
-
GetCFrame(entity: Entity)
|
|
198
|
+
GetCFrame: (entity: Entity) => CFrame | undefined;
|
|
199
199
|
|
|
200
200
|
/** Sets the current CFrame */
|
|
201
|
-
SetCFrame(entity: Entity, cframe: CFrame)
|
|
201
|
+
SetCFrame: (entity: Entity, cframe: CFrame) => void;
|
|
202
202
|
|
|
203
203
|
/** Gets the primary part of the model */
|
|
204
|
-
GetPrimaryPart(entity: Entity)
|
|
204
|
+
GetPrimaryPart: (entity: Entity) => BasePart | undefined;
|
|
205
205
|
|
|
206
206
|
/** Locks native server CFrame replication */
|
|
207
|
-
LockNativeServerCFrameReplication(entity: Entity)
|
|
207
|
+
LockNativeServerCFrameReplication: (entity: Entity) => void;
|
|
208
208
|
|
|
209
209
|
/** Unlocks native server CFrame replication */
|
|
210
|
-
UnlockNativeServerCFrameReplication(entity: Entity)
|
|
210
|
+
UnlockNativeServerCFrameReplication: (entity: Entity) => void;
|
|
211
211
|
|
|
212
212
|
/** Destroys an entity */
|
|
213
|
-
Destroy(entity: Entity)
|
|
213
|
+
Destroy: (entity: Entity) => void;
|
|
214
214
|
|
|
215
215
|
/** Gets an event by name */
|
|
216
|
-
GetEvent(entity: Entity, name: "Destroying")
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
216
|
+
GetEvent: ((entity: Entity, name: "Destroying") => ChronoEvent<(entity: Entity) => void>) &
|
|
217
|
+
((
|
|
218
|
+
entity: Entity,
|
|
219
|
+
name: "NetworkOwnerChanged",
|
|
220
|
+
) => ChronoEvent<(entity: Entity, newOwner: Player | undefined, prevOwner: Player | undefined) => void>) &
|
|
221
|
+
((
|
|
222
|
+
entity: Entity,
|
|
223
|
+
name: "PushedSnapShot",
|
|
224
|
+
) => ChronoEvent<(entity: Entity, time: number, value: CFrame, isNewest: boolean) => void>) &
|
|
225
|
+
((
|
|
226
|
+
entity: Entity,
|
|
227
|
+
name: "TickChanged",
|
|
228
|
+
) => ChronoEvent<(entity: Entity, newTickType: "NONE" | "HALF" | "NORMAL") => void>) &
|
|
229
|
+
((entity: Entity, name: "DataChanged") => ChronoEvent<(entity: Entity, data: unknown) => void>) &
|
|
230
|
+
((entity: Entity, name: "Ticked") => ChronoEvent<(entity: Entity, dt: number) => void>) &
|
|
231
|
+
((
|
|
232
|
+
entity: Entity,
|
|
233
|
+
name: "ModelChanged",
|
|
234
|
+
) => ChronoEvent<
|
|
235
|
+
(entity: Entity, newModel: Model | BasePart | undefined, oldModel: Model | BasePart | undefined) => void
|
|
236
|
+
>) &
|
|
237
|
+
((entity: Entity, name: "LockChanged") => ChronoEvent<(entity: Entity, isLocked: boolean) => void>) &
|
|
238
|
+
((entity: Entity, name: EntityEventName) => ChronoEvent);
|
|
237
239
|
}
|
|
238
240
|
|
|
239
241
|
// Replication rule types
|