mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2024-11-22 23:50:52 +01:00
#28 - BotForceOpenContextMenuEvent added
This commit is contained in:
parent
26741b78a7
commit
0ea34bb99a
File diff suppressed because one or more lines are too long
@ -277,6 +277,7 @@ export class IncomingHeader
|
|||||||
public static REDEEM_VOUCHER_OK = 3336;
|
public static REDEEM_VOUCHER_OK = 3336;
|
||||||
public static IN_CLIENT_LINK = 2023;
|
public static IN_CLIENT_LINK = 2023;
|
||||||
public static BOT_COMMAND_CONFIGURATION = 1618;
|
public static BOT_COMMAND_CONFIGURATION = 1618;
|
||||||
|
public static BOT_FORCE_OPEN_CONTEXT_MENU = 296;
|
||||||
public static HAND_ITEM_RECEIVED = 354;
|
public static HAND_ITEM_RECEIVED = 354;
|
||||||
public static PET_PLACING_ERROR = 2913;
|
public static PET_PLACING_ERROR = 2913;
|
||||||
public static BOT_ERROR = 639;
|
public static BOT_ERROR = 639;
|
||||||
|
@ -0,0 +1,16 @@
|
|||||||
|
import { IMessageEvent } from '../../../../../../api';
|
||||||
|
import { MessageEvent } from '../../../../../../events';
|
||||||
|
import { BotForceOpenContextMenuParser } from '../../../parser';
|
||||||
|
|
||||||
|
export class BotForceOpenContextMenuEvent extends MessageEvent implements IMessageEvent
|
||||||
|
{
|
||||||
|
constructor(callBack: Function)
|
||||||
|
{
|
||||||
|
super(callBack, BotForceOpenContextMenuParser);
|
||||||
|
}
|
||||||
|
|
||||||
|
public getParser(): BotForceOpenContextMenuParser
|
||||||
|
{
|
||||||
|
return this.parser as BotForceOpenContextMenuParser;
|
||||||
|
}
|
||||||
|
}
|
@ -1 +1,2 @@
|
|||||||
export * from './BotCommandConfigurationEvent';
|
export * from './BotCommandConfigurationEvent';
|
||||||
|
export * from './BotForceOpenContextMenuEvent';
|
||||||
|
@ -0,0 +1,27 @@
|
|||||||
|
import { IMessageDataWrapper, IMessageParser } from '../../../../../../api';
|
||||||
|
|
||||||
|
export class BotForceOpenContextMenuParser implements IMessageParser
|
||||||
|
{
|
||||||
|
private _botId: number;
|
||||||
|
|
||||||
|
public flush(): boolean
|
||||||
|
{
|
||||||
|
this._botId = -1;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public parse(wrapper: IMessageDataWrapper): boolean
|
||||||
|
{
|
||||||
|
if(!wrapper) return false;
|
||||||
|
|
||||||
|
this._botId = wrapper.readInt();
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
public get botId(): number
|
||||||
|
{
|
||||||
|
return this._botId;
|
||||||
|
}
|
||||||
|
}
|
@ -1 +1,2 @@
|
|||||||
export * from './BotCommandConfigurationParser';
|
export * from './BotCommandConfigurationParser';
|
||||||
|
export * from './BotForceOpenContextMenuParser';
|
||||||
|
Loading…
Reference in New Issue
Block a user