mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2025-01-18 22:36:27 +01:00
cleaned RoomObjectSpriteType
This commit is contained in:
parent
a4121cd78b
commit
3584040d78
@ -334,11 +334,11 @@ export class AvatarVisualization extends RoomObjectSpriteVisualization implement
|
||||
if(this._ownUser)
|
||||
{
|
||||
sprite.relativeDepth -= AvatarVisualization._Str_17708;
|
||||
sprite.spriteType = RoomObjectSpriteType._Str_10494;
|
||||
sprite.spriteType = RoomObjectSpriteType.AVATAR_OWN;
|
||||
}
|
||||
else
|
||||
{
|
||||
sprite.spriteType = RoomObjectSpriteType._Str_11629;
|
||||
sprite.spriteType = RoomObjectSpriteType.AVATAR;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -669,7 +669,7 @@ export class RoomVisualization extends RoomObjectSpriteVisualization implements
|
||||
sprite.tag = 'plane@' + (planeIndex + 1);
|
||||
}
|
||||
|
||||
sprite.spriteType = RoomObjectSpriteType._Str_8616;
|
||||
sprite.spriteType = RoomObjectSpriteType.ROOM_PLANE;
|
||||
}
|
||||
|
||||
planeIndex++;
|
||||
|
@ -1,7 +1,7 @@
|
||||
export class RoomObjectSpriteType
|
||||
{
|
||||
public static DEFAULT: number = 1;
|
||||
public static _Str_8616: number = 2;
|
||||
public static _Str_11629: number = 3;
|
||||
public static _Str_10494: number = 4;
|
||||
public static ROOM_PLANE: number = 2;
|
||||
public static AVATAR: number = 3;
|
||||
public static AVATAR_OWN: number = 4;
|
||||
}
|
@ -510,7 +510,7 @@ export class RoomSpriteCanvas implements IRoomRenderingCanvas
|
||||
|
||||
sortableSprite.sprite = sprite;
|
||||
|
||||
if((sprite.spriteType === RoomObjectSpriteType._Str_11629) || (sprite.spriteType === RoomObjectSpriteType._Str_10494))
|
||||
if((sprite.spriteType === RoomObjectSpriteType.AVATAR) || (sprite.spriteType === RoomObjectSpriteType.AVATAR_OWN))
|
||||
{
|
||||
sortableSprite.sprite.libraryAssetName = 'avatar_' + object.id;
|
||||
}
|
||||
@ -724,12 +724,12 @@ export class RoomSpriteCanvas implements IRoomRenderingCanvas
|
||||
|
||||
switch(_arg_2.spriteType)
|
||||
{
|
||||
case RoomObjectSpriteType._Str_10494:
|
||||
case RoomObjectSpriteType.AVATAR_OWN:
|
||||
return;
|
||||
case RoomObjectSpriteType._Str_8616:
|
||||
case RoomObjectSpriteType.ROOM_PLANE:
|
||||
sprite.alpha = RoomEnterEffect.getDelta(0.9);
|
||||
return;
|
||||
case RoomObjectSpriteType._Str_11629:
|
||||
case RoomObjectSpriteType.AVATAR:
|
||||
sprite.alpha = RoomEnterEffect.getDelta(0.5);
|
||||
return;
|
||||
default:
|
||||
|
4
src/room/renderer/cache/RoomObjectCache.ts
vendored
4
src/room/renderer/cache/RoomObjectCache.ts
vendored
@ -75,7 +75,7 @@ export class RoomObjectCache
|
||||
{
|
||||
if(!sprite) continue;
|
||||
|
||||
if((sprite.sprite.spriteType !== RoomObjectSpriteType._Str_8616) && (sprite.sprite.name !== ''))
|
||||
if((sprite.sprite.spriteType !== RoomObjectSpriteType.ROOM_PLANE) && (sprite.sprite.name !== ''))
|
||||
{
|
||||
const data = new RoomObjectSpriteData();
|
||||
|
||||
@ -139,7 +139,7 @@ export class RoomObjectCache
|
||||
{
|
||||
for(const sprite of item.sprites.sprites)
|
||||
{
|
||||
if(sprite.sprite.spriteType === RoomObjectSpriteType._Str_8616) sprites.push(sprite);
|
||||
if(sprite.sprite.spriteType === RoomObjectSpriteType.ROOM_PLANE) sprites.push(sprite);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user