Render material asset type support
This commit is contained in:
@@ -11,8 +11,8 @@ import { Logger } from './Logger';
|
||||
import { GlobalPosition } from './public/interfaces/GlobalPosition';
|
||||
import { Quaternion } from './Quaternion';
|
||||
import { Vector3 } from './Vector3';
|
||||
import Timeout = NodeJS.Timeout;
|
||||
import * as crypto from 'crypto';
|
||||
import Timeout = NodeJS.Timeout;
|
||||
|
||||
export class Utils
|
||||
{
|
||||
@@ -189,6 +189,8 @@ export class Utils
|
||||
return 'person';
|
||||
case InventoryType.Settings:
|
||||
return 'settings';
|
||||
case InventoryType.Material:
|
||||
return 'material';
|
||||
default:
|
||||
console.error('Unknown inventory type: ' + InventoryType[type]);
|
||||
return 'texture';
|
||||
@@ -233,6 +235,8 @@ export class Utils
|
||||
return AssetType.Widget;
|
||||
case HTTPAssets.ASSET_PERSON:
|
||||
return AssetType.Person;
|
||||
case HTTPAssets.ASSET_MATERIAL:
|
||||
return AssetType.Material;
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
@@ -276,6 +280,8 @@ export class Utils
|
||||
return HTTPAssets.ASSET_PERSON;
|
||||
case AssetType.Widget:
|
||||
return HTTPAssets.ASSET_WIDGET;
|
||||
case AssetType.Material:
|
||||
return HTTPAssets.ASSET_MATERIAL;
|
||||
default:
|
||||
return HTTPAssets.ASSET_TEXTURE;
|
||||
}
|
||||
@@ -314,6 +320,8 @@ export class Utils
|
||||
return InventoryType.Wearable;
|
||||
case HTTPAssets.ASSET_MESH:
|
||||
return InventoryType.Mesh;
|
||||
case HTTPAssets.ASSET_MATERIAL:
|
||||
return InventoryType.Material;
|
||||
default:
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -28,5 +28,6 @@ export enum AssetType
|
||||
Widget = 40,
|
||||
Person = 46,
|
||||
Mesh = 49,
|
||||
Settings = 56
|
||||
Settings = 56,
|
||||
Material = 57
|
||||
}
|
||||
|
||||
@@ -22,5 +22,6 @@ export enum InventoryType
|
||||
Mesh = 22,
|
||||
Widget = 23,
|
||||
Person = 24,
|
||||
Settings = 25
|
||||
Settings = 25,
|
||||
Material = 26,
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@caspertech/node-metaverse",
|
||||
"version": "0.6.1",
|
||||
"version": "0.6.2",
|
||||
"description": "A node.js interface for Second Life.",
|
||||
"main": "dist/lib/index.js",
|
||||
"types": "dist/lib/index.d.ts",
|
||||
|
||||
Reference in New Issue
Block a user