- Add grabObject, deGrabObject, dragGrabbedObject, touchObject to RegionCommands (closes #8)
- Properly decode object TextureEntry - Properly decode object ParticleSystem - Properly decode object ObjectData - Properly decode object TextColor - Properly decode Linden Tree species - Correct handling of ObjectUpdateCached (only request objects if we don't already have them) - Implement handling of ImprovedTerseObjectUpdate to complete support for R-Tree object searching - Object store interface: getObjectByUUID, getObjectByLocalID
This commit is contained in:
16
dist/classes/ObjectStoreLite.js
vendored
16
dist/classes/ObjectStoreLite.js
vendored
@@ -328,6 +328,22 @@ class ObjectStoreLite {
|
||||
getObjectsInArea(minX, maxX, minY, maxY, minZ, maxZ) {
|
||||
throw new Error('GetObjectsInArea not available with the Lite object store.');
|
||||
}
|
||||
getObjectByUUID(fullID) {
|
||||
if (fullID instanceof UUID_1.UUID) {
|
||||
fullID = fullID.toString();
|
||||
}
|
||||
if (!this.objectsByUUID[fullID]) {
|
||||
throw new Error('No object found with that UUID');
|
||||
}
|
||||
const localID = this.objectsByUUID[fullID];
|
||||
return this.objects[localID];
|
||||
}
|
||||
getObjectByLocalID(localID) {
|
||||
if (!this.objects[localID]) {
|
||||
throw new Error('No object found with that UUID');
|
||||
}
|
||||
return this.objects[localID];
|
||||
}
|
||||
}
|
||||
exports.ObjectStoreLite = ObjectStoreLite;
|
||||
//# sourceMappingURL=ObjectStoreLite.js.map
|
||||
Reference in New Issue
Block a user