Skip to content

Commit

Permalink
billsonnn#28 - RestoreClientMessageEvent added
Browse files Browse the repository at this point in the history
  • Loading branch information
oobjectt committed Dec 24, 2022
1 parent 26741b7 commit ee96260
Show file tree
Hide file tree
Showing 6 changed files with 37 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/nitro/communication/NitroMessages.ts

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -414,4 +414,5 @@ export class IncomingHeader
public static SHOW_ENFORCE_ROOM_CATEGORY = 3896;
public static CUSTOM_USER_NOTIFICATION = 909;
public static NEW_USER_EXPERIENCE_GIFT_OFFER = 3575;
public static RESTORE_CLIENT = 426;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { IMessageEvent } from '../../../../../api';
import { MessageEvent } from '../../../../../events';
import { RestoreClientMessageParser } from '../../parser';

export class RestoreClientMessageEvent extends MessageEvent implements IMessageEvent
{
constructor(callBack: Function)
{
super(callBack, RestoreClientMessageParser);
}

public getParser(): RestoreClientMessageParser
{
return this.parser as RestoreClientMessageParser;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ export * from './MOTDNotificationEvent';
export * from './NotificationDialogMessageEvent';
export * from './PetLevelNotificationEvent';
export * from './PetPlacingErrorEvent';
export * from './RestoreClientMessageEvent';
export * from './UnseenItemsEvent';
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { IMessageDataWrapper, IMessageParser } from '../../../../../api';

export class RestoreClientMessageParser implements IMessageParser
{
public flush(): boolean
{
return true;
}

public parse(wrapper: IMessageDataWrapper): boolean
{
return true;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ export * from './MOTDNotificationParser';
export * from './NotificationDialogMessageParser';
export * from './PetLevelNotificationParser';
export * from './PetPlacingErrorEventParser';
export * from './RestoreClientMessageParser';
export * from './UnseenItemsParser';

0 comments on commit ee96260

Please sign in to comment.