mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2024-11-22 23:50:52 +01:00
Merge branch 'oobjectt-notification-element-pointer'
This commit is contained in:
commit
86412620b8
File diff suppressed because one or more lines are too long
@ -123,6 +123,7 @@ export class IncomingHeader
|
||||
public static GUEST_ROOM_SEARCH_RESULT = 52;
|
||||
public static NOTIFICATION_LIST = 1992;
|
||||
public static NOTIFICATION_SIMPLE_ALERT = 5100;
|
||||
public static NOTIFICATION_ELEMENT_POINTER = 1787;
|
||||
public static PET_FIGURE_UPDATE = 1924;
|
||||
public static PET_INFO = 2901;
|
||||
public static PET_TRAINING_PANEL = 1164;
|
||||
|
@ -0,0 +1,16 @@
|
||||
import { IMessageEvent } from '../../../../../api';
|
||||
import { MessageEvent } from '../../../../../events';
|
||||
import { ElementPointerMessageParser } from '../../parser';
|
||||
|
||||
export class ElementPointerMessageEvent extends MessageEvent implements IMessageEvent
|
||||
{
|
||||
constructor(callBack: Function)
|
||||
{
|
||||
super(callBack, ElementPointerMessageParser);
|
||||
}
|
||||
|
||||
public getParser(): ElementPointerMessageParser
|
||||
{
|
||||
return this.parser as ElementPointerMessageParser;
|
||||
}
|
||||
}
|
@ -3,6 +3,7 @@ export * from './ActivityPointNotificationMessageEvent';
|
||||
export * from './BotErrorEvent';
|
||||
export * from './ClubGiftNotificationEvent';
|
||||
export * from './ConnectionErrorEvent';
|
||||
export * from './ElementPointerMessageEvent';
|
||||
export * from './HabboBroadcastMessageEvent';
|
||||
export * from './HotelWillShutdownEvent';
|
||||
export * from './InfoFeedEnableMessageEvent';
|
||||
|
@ -0,0 +1,26 @@
|
||||
import { IMessageDataWrapper, IMessageParser } from '../../../../../api';
|
||||
|
||||
export class ElementPointerMessageParser implements IMessageParser
|
||||
{
|
||||
private _key: string;
|
||||
|
||||
public flush(): boolean
|
||||
{
|
||||
this._key = null;
|
||||
return true;
|
||||
}
|
||||
|
||||
public parse(wrapper: IMessageDataWrapper): boolean
|
||||
{
|
||||
if(!wrapper) return false;
|
||||
|
||||
this._key = wrapper.readString();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public get key(): string
|
||||
{
|
||||
return this._key;
|
||||
}
|
||||
}
|
@ -4,6 +4,7 @@ export * from './ActivityPointNotificationParser';
|
||||
export * from './BotErrorEventParser';
|
||||
export * from './ClubGiftNotificationParser';
|
||||
export * from './ConnectionErrorMessageParser';
|
||||
export * from './ElementPointerMessageParser';
|
||||
export * from './HabboBroadcastMessageParser';
|
||||
export * from './HotelWillShutdownParser';
|
||||
export * from './InfoFeedEnableMessageParser';
|
||||
|
Loading…
Reference in New Issue
Block a user