mirror of
https://github.com/billsonnn/nitro-react.git
synced 2025-01-19 05:46:27 +01:00
Merge branch 'dev' of https://git.krews.org/nitro/nitro-react into dev
This commit is contained in:
commit
b5e876c22b
@ -1,4 +1,4 @@
|
|||||||
import { AvatarFigurePartType, AvatarScaleType, AvatarSetType, IAvatarImageListener, INitroPoint, IVector3D, NitroEvent, NitroPoint, PetFigureData, RoomObjectCategory, RoomObjectType, RoomObjectVariable, RoomSessionChatEvent, RoomWidgetEnum, SystemChatStyleEnum, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
import { AvatarFigurePartType, AvatarScaleType, AvatarSetType, IAvatarImageListener, INitroPoint, IVector3D, NitroEvent, NitroPoint, PetFigureData, RoomObjectCategory, RoomObjectType, RoomObjectVariable, RoomSessionChatEvent, RoomUserData, RoomWidgetEnum, SystemChatStyleEnum, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
||||||
import { GetAvatarRenderManager, GetConfigurationManager, GetRoomEngine, PlaySound } from '../../../..';
|
import { GetAvatarRenderManager, GetConfigurationManager, GetRoomEngine, PlaySound } from '../../../..';
|
||||||
import { LocalizeText } from '../../../../utils/LocalizeText';
|
import { LocalizeText } from '../../../../utils/LocalizeText';
|
||||||
import { RoomWidgetUpdateChatEvent, RoomWidgetUpdateEvent } from '../events';
|
import { RoomWidgetUpdateChatEvent, RoomWidgetUpdateEvent } from '../events';
|
||||||
@ -20,11 +20,9 @@ export class RoomWidgetChatHandler extends RoomWidgetHandler implements IAvatarI
|
|||||||
|
|
||||||
const roomObject = GetRoomEngine().getRoomObject(chatEvent.session.roomId, chatEvent.objectId, RoomObjectCategory.UNIT);
|
const roomObject = GetRoomEngine().getRoomObject(chatEvent.session.roomId, chatEvent.objectId, RoomObjectCategory.UNIT);
|
||||||
|
|
||||||
if(!roomObject) return;
|
const objectLocation = roomObject ? roomObject.getLocation() : new Vector3d();
|
||||||
|
|
||||||
const objectLocation = roomObject.getLocation();
|
|
||||||
const bubbleLocation = this.getBubbleLocation(chatEvent.session.roomId, objectLocation);
|
const bubbleLocation = this.getBubbleLocation(chatEvent.session.roomId, objectLocation);
|
||||||
const userData = this.container.roomSession.userDataManager.getUserDataByIndex(chatEvent.objectId);
|
const userData = roomObject ? this.container.roomSession.userDataManager.getUserDataByIndex(chatEvent.objectId) : new RoomUserData(-1);
|
||||||
|
|
||||||
let username = '';
|
let username = '';
|
||||||
let avatarColor = 0;
|
let avatarColor = 0;
|
||||||
|
@ -47,6 +47,7 @@
|
|||||||
height: calc(100% - 0.5px);
|
height: calc(100% - 0.5px);
|
||||||
border-radius: 7px;
|
border-radius: 7px;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
background-color: #C8C8C8;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chat-bubble {
|
.chat-bubble {
|
||||||
|
Loading…
Reference in New Issue
Block a user