mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2024-11-26 09:20:51 +01:00
Feature - Rentable Spaces fix error packet (#102)
This commit is contained in:
parent
9efb90b930
commit
becf87b668
@ -2,6 +2,17 @@ import { IMessageDataWrapper, IMessageParser } from '../../../../../../api';
|
|||||||
|
|
||||||
export class RentableSpaceStatusMessageParser implements IMessageParser
|
export class RentableSpaceStatusMessageParser implements IMessageParser
|
||||||
{
|
{
|
||||||
|
public static readonly SPACE_ALREADY_RENTED = 100;
|
||||||
|
public static readonly SPACE_EXTEND_NOT_RENTED = 101;
|
||||||
|
public static readonly SPACE_EXTEND_NOT_RENTED_BY_YOU = 102;
|
||||||
|
public static readonly CAN_RENT_ONLY_ONE_SPACE = 103;
|
||||||
|
public static readonly NOT_ENOUGH_CREDITS = 200;
|
||||||
|
public static readonly NOT_ENOUGH_PIXELS = 201;
|
||||||
|
public static readonly CANT_RENT_NO_PERMISSION = 202;
|
||||||
|
public static readonly CANT_RENT_NO_HABBO_CLUB = 203;
|
||||||
|
public static readonly CANT_RENT = 300;
|
||||||
|
public static readonly CANT_RENT_GENERIC = 400;
|
||||||
|
|
||||||
private _rented: boolean;
|
private _rented: boolean;
|
||||||
private _renterId: number;
|
private _renterId: number;
|
||||||
private _renterName: string;
|
private _renterName: string;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { AdvancedMap, RoomObjectVariable, RoomWidgetEnum } from '../../../../../api';
|
import { RoomObjectVariable, RoomWidgetEnum } from '../../../../../api';
|
||||||
import { RoomObjectDataRequestEvent } from '../../../../../events';
|
import { RoomObjectDataRequestEvent } from '../../../../../events';
|
||||||
import { FurnitureLogic } from './FurnitureLogic';
|
import { FurnitureLogic } from './FurnitureLogic';
|
||||||
|
|
||||||
@ -24,7 +24,7 @@ export class FurnitureRentableSpaceLogic extends FurnitureLogic
|
|||||||
this.eventDispatcher.dispatchEvent(new RoomObjectDataRequestEvent(RoomObjectDataRequestEvent.RODRE_CURRENT_USER_ID, this.object));
|
this.eventDispatcher.dispatchEvent(new RoomObjectDataRequestEvent(RoomObjectDataRequestEvent.RODRE_CURRENT_USER_ID, this.object));
|
||||||
}
|
}
|
||||||
|
|
||||||
const renterId = this.object.model.getValue<AdvancedMap<string, string>>(RoomObjectVariable.FURNITURE_DATA).getValue('renterId');
|
const renterId = this.object.model.getValue<string>(RoomObjectVariable.FURNITURE_DATA)['renterId'];
|
||||||
const userId = this.object.model.getValue<number>(RoomObjectVariable.SESSION_CURRENT_USER_ID);
|
const userId = this.object.model.getValue<number>(RoomObjectVariable.SESSION_CURRENT_USER_ID);
|
||||||
|
|
||||||
if(renterId)
|
if(renterId)
|
||||||
|
Loading…
Reference in New Issue
Block a user