Merge branch 'composer-user-classification' of https://github.com/oobjectt/nitro-renderer into oobjectt-composer-user-classification

This commit is contained in:
dank074 2023-01-12 01:38:04 -06:00
commit adab4fa088
6 changed files with 32 additions and 2 deletions

View File

@ -32,6 +32,7 @@ export interface IRoomSession extends IDisposable
sendPollRejectMessage(pollId: number): void; sendPollRejectMessage(pollId: number): void;
sendPollAnswerMessage(pollId: number, questionId: number, answers: string[]): void; sendPollAnswerMessage(pollId: number, questionId: number, answers: string[]): void;
sendPeerUsersClassificationMessage(userClassType: string): void; sendPeerUsersClassificationMessage(userClassType: string): void;
sendRoomUsersClassificationMessage(userClassType: string): void;
updateMoodlightData(id: number, effectId: number, color: number, brightness: number, apply: boolean): void; updateMoodlightData(id: number, effectId: number, color: number, brightness: number, apply: boolean): void;
toggleMoodlightState(): void; toggleMoodlightState(): void;
pickupPet(id: number): void; pickupPet(id: number): void;

File diff suppressed because one or more lines are too long

View File

@ -261,6 +261,7 @@ export class OutgoingHeader
public static SAVE_WARDROBE_OUTFIT = 800; public static SAVE_WARDROBE_OUTFIT = 800;
public static USER_TAGS = 17; public static USER_TAGS = 17;
public static PEER_USERS_CLASSIFICATION = 1160; public static PEER_USERS_CLASSIFICATION = 1160;
public static USER_CLASSIFICATION = 2285;
public static VISIT_USER = 2970; public static VISIT_USER = 2970;
public static WIRED_ACTION_SAVE = 2281; public static WIRED_ACTION_SAVE = 2281;
public static WIRED_APPLY_SNAPSHOT = 3373; public static WIRED_APPLY_SNAPSHOT = 3373;

View File

@ -0,0 +1,21 @@
import { IMessageComposer } from '../../../../../api';
export class RoomUsersClassificationMessageComposer implements IMessageComposer<ConstructorParameters<typeof RoomUsersClassificationMessageComposer>>
{
private _data: ConstructorParameters<typeof RoomUsersClassificationMessageComposer>;
constructor(userClassType: string)
{
this._data = [userClassType];
}
public getMessageArray()
{
return this._data;
}
public dispose(): void
{
return;
}
}

View File

@ -1 +1,2 @@
export * from './PeerUsersClassificationMessageComposer'; export * from './PeerUsersClassificationMessageComposer';
export * from './RoomUsersClassificationMessageComposer';

View File

@ -1,7 +1,7 @@
import { IConnection, IRoomSession, RoomControllerLevel, RoomTradingLevelEnum } from '../../api'; import { IConnection, IRoomSession, RoomControllerLevel, RoomTradingLevelEnum } from '../../api';
import { Disposable } from '../../core'; import { Disposable } from '../../core';
import { RoomSessionEvent } from '../../events'; import { RoomSessionEvent } from '../../events';
import { BotRemoveComposer, ChangeQueueMessageComposer, CompostPlantMessageComposer, FurnitureMultiStateComposer, GetPetCommandsComposer, HarvestPetMessageComposer, MoodlightSettingsComposer, MoodlightSettingsSaveComposer, MoodlightTogggleStateComposer, NewUserExperienceScriptProceedComposer, OpenPetPackageMessageComposer, OpenPresentComposer, PeerUsersClassificationMessageComposer, PetMountComposer, PetRemoveComposer, PollAnswerComposer, PollRejectComposer, PollStartComposer, RemovePetSaddleComposer, RoomAmbassadorAlertComposer, RoomBanUserComposer, RoomDoorbellAccessComposer, RoomEnterComposer, RoomGiveRightsComposer, RoomKickUserComposer, RoomModerationSettings, RoomMuteUserComposer, RoomTakeRightsComposer, RoomUnitActionComposer, RoomUnitChatComposer, RoomUnitChatShoutComposer, RoomUnitChatWhisperComposer, RoomUnitDanceComposer, RoomUnitPostureComposer, RoomUnitSignComposer, RoomUnitTypingStartComposer, RoomUnitTypingStopComposer, SetClothingChangeDataMessageComposer, TogglePetBreedingComposer, TogglePetRidingComposer, UsePetProductComposer, UserMottoComposer } from '../communication'; import { BotRemoveComposer, ChangeQueueMessageComposer, CompostPlantMessageComposer, FurnitureMultiStateComposer, GetPetCommandsComposer, HarvestPetMessageComposer, MoodlightSettingsComposer, MoodlightSettingsSaveComposer, MoodlightTogggleStateComposer, NewUserExperienceScriptProceedComposer, OpenPetPackageMessageComposer, OpenPresentComposer, PeerUsersClassificationMessageComposer, PetMountComposer, PetRemoveComposer, PollAnswerComposer, PollRejectComposer, PollStartComposer, RemovePetSaddleComposer, RoomAmbassadorAlertComposer, RoomBanUserComposer, RoomDoorbellAccessComposer, RoomEnterComposer, RoomGiveRightsComposer, RoomKickUserComposer, RoomModerationSettings, RoomMuteUserComposer, RoomTakeRightsComposer, RoomUnitActionComposer, RoomUnitChatComposer, RoomUnitChatShoutComposer, RoomUnitChatWhisperComposer, RoomUnitDanceComposer, RoomUnitPostureComposer, RoomUnitSignComposer, RoomUnitTypingStartComposer, RoomUnitTypingStopComposer, RoomUsersClassificationMessageComposer, SetClothingChangeDataMessageComposer, TogglePetBreedingComposer, TogglePetRidingComposer, UsePetProductComposer, UserMottoComposer } from '../communication';
import { UserDataManager } from './UserDataManager'; import { UserDataManager } from './UserDataManager';
export class RoomSession extends Disposable implements IRoomSession export class RoomSession extends Disposable implements IRoomSession
@ -222,6 +222,11 @@ export class RoomSession extends Disposable implements IRoomSession
this._connection.send(new OpenPetPackageMessageComposer(objectId, petName)); this._connection.send(new OpenPetPackageMessageComposer(objectId, petName));
} }
public sendRoomUsersClassificationMessage(userClassType: string): void
{
this._connection.send(new RoomUsersClassificationMessageComposer(userClassType));
}
public updateMoodlightData(id: number, effectId: number, color: number, brightness: number, apply: boolean): void public updateMoodlightData(id: number, effectId: number, color: number, brightness: number, apply: boolean): void
{ {
let colorString = '000000' + color.toString(16).toUpperCase(); let colorString = '000000' + color.toString(16).toUpperCase();