mirror of
https://github.com/billsonnn/nitro-renderer.git
synced 2024-11-22 23:50:52 +01:00
Fix more ambiguities
This commit is contained in:
parent
ef25f9c69c
commit
c0800343fa
@ -1,7 +1,7 @@
|
||||
import { IMessageDataWrapper } from '../../../../../core/communication/messages/IMessageDataWrapper';
|
||||
import { Triggerable } from './Triggerable';
|
||||
|
||||
export class ActionDefinition extends Triggerable
|
||||
export class WiredActionDefinition extends Triggerable
|
||||
{
|
||||
private _type: number;
|
||||
private _delayInPulses: number;
|
@ -1,8 +1,8 @@
|
||||
export * from './ActionDefinition';
|
||||
export * from './ConditionDefinition';
|
||||
export * from './RoomMutedEvent';
|
||||
export * from './Triggerable';
|
||||
export * from './TriggerDefinition';
|
||||
export * from './WiredActionDefinition';
|
||||
export * from './WiredFurniActionEvent';
|
||||
export * from './WiredFurniConditionEvent';
|
||||
export * from './WiredFurniTriggerEvent';
|
||||
|
@ -11,3 +11,5 @@ export * from './navigator';
|
||||
export * from './OutgoingHeader';
|
||||
export * from './pet';
|
||||
export * from './room';
|
||||
export * from './roomevents';
|
||||
export * from './user';
|
||||
|
@ -0,0 +1,6 @@
|
||||
export * from './ApplySnapshotMessageComposer';
|
||||
export * from './OpenMessageComposer';
|
||||
export * from './RoomMuteComposer';
|
||||
export * from './UpdateActionMessageComposer';
|
||||
export * from './UpdateConditionMessageComposer';
|
||||
export * from './UpdateTriggerMessageComposer';
|
10
src/nitro/communication/messages/outgoing/user/data/index.ts
Normal file
10
src/nitro/communication/messages/outgoing/user/data/index.ts
Normal file
@ -0,0 +1,10 @@
|
||||
export * from './GetIgnoredUsersComposer';
|
||||
export * from './IgnoreUserComposer';
|
||||
export * from './IgnoreUserIdComposer';
|
||||
export * from './UnignoreUserComposer';
|
||||
export * from './UserCurrentBadgesComposer';
|
||||
export * from './UserFigureComposer';
|
||||
export * from './UserHomeRoomComposer';
|
||||
export * from './UserMottoComposer';
|
||||
export * from './UserProfileComposer';
|
||||
export * from './UserRelationshipsComposer';
|
5
src/nitro/communication/messages/outgoing/user/index.ts
Normal file
5
src/nitro/communication/messages/outgoing/user/index.ts
Normal file
@ -0,0 +1,5 @@
|
||||
export * from './data';
|
||||
export * from './inventory';
|
||||
export * from './settings';
|
||||
export * from './UserRespectComposer';
|
||||
export * from './wardrobe';
|
@ -0,0 +1 @@
|
||||
export * from './UserCurrencyComposer';
|
@ -0,0 +1,2 @@
|
||||
export * from './currency';
|
||||
export * from './subscription';
|
@ -0,0 +1 @@
|
||||
export * from './UserSubscriptionComposer';
|
@ -0,0 +1,4 @@
|
||||
export * from './UserSettingsCameraFollowComposer';
|
||||
export * from './UserSettingsOldChatComposer';
|
||||
export * from './UserSettingsRoomInvitesComposer';
|
||||
export * from './UserSettingsSoundComposer';
|
@ -0,0 +1,2 @@
|
||||
export * from './UserWardrobePageComposer';
|
||||
export * from './UserWardrobeSaveComposer';
|
@ -1,11 +1,11 @@
|
||||
import { IMessageDataWrapper } from '../../../../../../core/communication/messages/IMessageDataWrapper';
|
||||
import { PetFigureData } from './PetFigureData';
|
||||
import { PetFigureDataParser } from './PetFigureDataParser';
|
||||
|
||||
export class PetData
|
||||
{
|
||||
private _id: number;
|
||||
private _name: string;
|
||||
private _figureData: PetFigureData;
|
||||
private _figureData: PetFigureDataParser;
|
||||
private _level: number;
|
||||
|
||||
constructor(wrapper: IMessageDataWrapper)
|
||||
@ -14,7 +14,7 @@ export class PetData
|
||||
|
||||
this._id = wrapper.readInt();
|
||||
this._name = wrapper.readString();
|
||||
this._figureData = new PetFigureData(wrapper);
|
||||
this._figureData = new PetFigureDataParser(wrapper);
|
||||
this._level = wrapper.readInt();
|
||||
}
|
||||
|
||||
@ -58,7 +58,7 @@ export class PetData
|
||||
return this._figureData.figuredata;
|
||||
}
|
||||
|
||||
public get figureData():PetFigureData
|
||||
public get figureData():PetFigureDataParser
|
||||
{
|
||||
return this._figureData;
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
import { IMessageDataWrapper } from '../../../../../../core/communication/messages/IMessageDataWrapper';
|
||||
|
||||
export class PetFigureData
|
||||
export class PetFigureDataParser
|
||||
{
|
||||
private _typeId: number;
|
||||
private _paletteId: number;
|
@ -1,7 +1,7 @@
|
||||
export * from './PetAddedToInventoryParser';
|
||||
export * from './PetBoughtNotificationMessageParser';
|
||||
export * from './PetData';
|
||||
export * from './PetFigureData';
|
||||
export * from './PetFigureDataParser';
|
||||
export * from './PetInventoryParser';
|
||||
export * from './PetRemovedFromInventoryParser';
|
||||
export * from './_Str_6256';
|
||||
|
@ -1,12 +1,12 @@
|
||||
import { IMessageDataWrapper } from '../../../../../../core/communication/messages/IMessageDataWrapper';
|
||||
import { IMessageParser } from '../../../../../../core/communication/messages/IMessageParser';
|
||||
import { PetFigureData } from '../../inventory/pets/PetFigureData';
|
||||
import { PetFigureDataParser } from '../../inventory/pets/PetFigureDataParser';
|
||||
|
||||
export class PetFigureUpdateParser implements IMessageParser
|
||||
{
|
||||
private _roomIndex: number;
|
||||
private _petId: number;
|
||||
private _figureData: PetFigureData;
|
||||
private _figureData: PetFigureDataParser;
|
||||
private _hasSaddle: boolean;
|
||||
private _isRiding: boolean;
|
||||
|
||||
@ -21,7 +21,7 @@ export class PetFigureUpdateParser implements IMessageParser
|
||||
|
||||
this._roomIndex = wrapper.readInt();
|
||||
this._petId = wrapper.readInt();
|
||||
this._figureData = new PetFigureData(wrapper);
|
||||
this._figureData = new PetFigureDataParser(wrapper);
|
||||
this._hasSaddle = wrapper.readBoolean();
|
||||
this._isRiding = wrapper.readBoolean();
|
||||
|
||||
@ -38,7 +38,7 @@ export class PetFigureUpdateParser implements IMessageParser
|
||||
return this._petId;
|
||||
}
|
||||
|
||||
public get figureData(): PetFigureData
|
||||
public get figureData(): PetFigureDataParser
|
||||
{
|
||||
return this._figureData;
|
||||
}
|
||||
|
@ -1,10 +1,10 @@
|
||||
import { IMessageDataWrapper } from '../../../../../core/communication/messages/IMessageDataWrapper';
|
||||
import { IMessageParser } from '../../../../../core/communication/messages/IMessageParser';
|
||||
import { ActionDefinition } from '../../incoming/roomevents/ActionDefinition';
|
||||
import { WiredActionDefinition } from '../../incoming/roomevents/WiredActionDefinition';
|
||||
|
||||
export class WiredFurniActionParser implements IMessageParser
|
||||
{
|
||||
private _definition: ActionDefinition;
|
||||
private _definition: WiredActionDefinition;
|
||||
|
||||
public flush(): boolean
|
||||
{
|
||||
@ -17,12 +17,12 @@ export class WiredFurniActionParser implements IMessageParser
|
||||
{
|
||||
if(!wrapper) return false;
|
||||
|
||||
this._definition = new ActionDefinition(wrapper);
|
||||
this._definition = new WiredActionDefinition(wrapper);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
public get definition(): ActionDefinition
|
||||
public get definition(): WiredActionDefinition
|
||||
{
|
||||
return this._definition;
|
||||
}
|
||||
|
@ -149,10 +149,13 @@ export class NitroLocalizationManager extends NitroManager implements INitroLoca
|
||||
{
|
||||
let value = this.getValue(key, false);
|
||||
|
||||
if(parameters)
|
||||
{
|
||||
for(let i = 0; i < parameters.length; i++)
|
||||
{
|
||||
value = value.replace('%' + parameters[i] + '%', replacements[i]);
|
||||
}
|
||||
}
|
||||
|
||||
return value;
|
||||
}
|
||||
|
@ -22,14 +22,14 @@ import { BadgeImageManager } from './BadgeImageManager';
|
||||
import { SecurityLevel } from './enum/SecurityLevel';
|
||||
import { SessionDataPreferencesEvent } from './events/SessionDataPreferencesEvent';
|
||||
import { UserNameUpdateEvent } from './events/UserNameUpdateEvent';
|
||||
import { FurnitureDataParser } from './furniture/FurnitureDataParser';
|
||||
import { FurnitureDataLoader } from './furniture/FurnitureDataLoader';
|
||||
import { IFurnitureData } from './furniture/IFurnitureData';
|
||||
import { IFurnitureDataListener } from './furniture/IFurnitureDataListener';
|
||||
import { IgnoredUsersManager } from './IgnoredUsersManager';
|
||||
import { ISessionDataManager } from './ISessionDataManager';
|
||||
import { IProductData } from './product/IProductData';
|
||||
import { IProductDataListener } from './product/IProductDataListener';
|
||||
import { ProductDataParser } from './product/ProductDataParser';
|
||||
import { ProductDataLoader } from './product/ProductDataLoader';
|
||||
|
||||
export class SessionDataManager extends NitroManager implements ISessionDataManager
|
||||
{
|
||||
@ -61,8 +61,8 @@ export class SessionDataManager extends NitroManager implements ISessionDataMana
|
||||
private _floorItems: Map<number, IFurnitureData>;
|
||||
private _wallItems: Map<number, IFurnitureData>;
|
||||
private _products: Map<string, IProductData>;
|
||||
private _furnitureData: FurnitureDataParser;
|
||||
private _productData: ProductDataParser;
|
||||
private _furnitureData: FurnitureDataLoader;
|
||||
private _productData: ProductDataLoader;
|
||||
|
||||
private _furnitureReady: boolean;
|
||||
private _productsReady: boolean;
|
||||
@ -161,9 +161,9 @@ export class SessionDataManager extends NitroManager implements ISessionDataMana
|
||||
{
|
||||
this.destroyFurnitureData();
|
||||
|
||||
this._furnitureData = new FurnitureDataParser(this._floorItems, this._wallItems, Nitro.instance.localization);
|
||||
this._furnitureData = new FurnitureDataLoader(this._floorItems, this._wallItems, Nitro.instance.localization);
|
||||
|
||||
this._furnitureData.addEventListener(FurnitureDataParser.FURNITURE_DATA_READY, this.onFurnitureDataReadyEvent);
|
||||
this._furnitureData.addEventListener(FurnitureDataLoader.FURNITURE_DATA_READY, this.onFurnitureDataReadyEvent);
|
||||
|
||||
this._furnitureData.loadFurnitureData(Nitro.instance.getConfiguration<string>('furnidata.url'));
|
||||
}
|
||||
@ -172,9 +172,9 @@ export class SessionDataManager extends NitroManager implements ISessionDataMana
|
||||
{
|
||||
this.destroyProductData();
|
||||
|
||||
this._productData = new ProductDataParser(this._products);
|
||||
this._productData = new ProductDataLoader(this._products);
|
||||
|
||||
this._productData.addEventListener(ProductDataParser.PDP_PRODUCT_DATA_READY, this.onProductDataReadyEvent);
|
||||
this._productData.addEventListener(ProductDataLoader.PDP_PRODUCT_DATA_READY, this.onProductDataReadyEvent);
|
||||
|
||||
this._productData.loadProductData(Nitro.instance.getConfiguration<string>('productdata.url'));
|
||||
}
|
||||
@ -335,7 +335,7 @@ export class SessionDataManager extends NitroManager implements ISessionDataMana
|
||||
|
||||
private onFurnitureDataReadyEvent(event: NitroEvent): void
|
||||
{
|
||||
this._furnitureData.removeEventListener(FurnitureDataParser.FURNITURE_DATA_READY, this.onFurnitureDataReadyEvent);
|
||||
this._furnitureData.removeEventListener(FurnitureDataLoader.FURNITURE_DATA_READY, this.onFurnitureDataReadyEvent);
|
||||
|
||||
this._furnitureReady = true;
|
||||
|
||||
@ -354,7 +354,7 @@ export class SessionDataManager extends NitroManager implements ISessionDataMana
|
||||
|
||||
private onProductDataReadyEvent(event: NitroEvent): void
|
||||
{
|
||||
this._productData.removeEventListener(ProductDataParser.PDP_PRODUCT_DATA_READY, this.onProductDataReadyEvent);
|
||||
this._productData.removeEventListener(ProductDataLoader.PDP_PRODUCT_DATA_READY, this.onProductDataReadyEvent);
|
||||
|
||||
this._productsReady = true;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { PetFigureData } from '../../communication/messages/parser/inventory/pets/PetFigureData';
|
||||
import { PetFigureDataParser } from '../../communication/messages/parser/inventory/pets/PetFigureDataParser';
|
||||
import { IRoomSession } from '../IRoomSession';
|
||||
import { RoomSessionEvent } from './RoomSessionEvent';
|
||||
|
||||
@ -8,11 +8,11 @@ export class RoomSessionPetPackageEvent extends RoomSessionEvent
|
||||
public static RSOPPE_OPEN_PET_PACKAGE_RESULT: string = 'RSOPPE_OPEN_PET_PACKAGE_RESULT';
|
||||
|
||||
private _objectId: number = -1;
|
||||
private _figureData:PetFigureData;
|
||||
private _figureData:PetFigureDataParser;
|
||||
private _nameValidationStatus: number = 0;
|
||||
private _nameValidationInfo: string = null;
|
||||
|
||||
constructor(k: string, _arg_2: IRoomSession, _arg_3: number, _arg_4: PetFigureData, _arg_5: number, _arg_6: string)
|
||||
constructor(k: string, _arg_2: IRoomSession, _arg_3: number, _arg_4: PetFigureDataParser, _arg_5: number, _arg_6: string)
|
||||
{
|
||||
super(k, _arg_2);
|
||||
this._objectId = _arg_3;
|
||||
@ -26,7 +26,7 @@ export class RoomSessionPetPackageEvent extends RoomSessionEvent
|
||||
return this._objectId;
|
||||
}
|
||||
|
||||
public get figureData():PetFigureData
|
||||
public get figureData():PetFigureDataParser
|
||||
{
|
||||
return this._figureData;
|
||||
}
|
||||
|
@ -1,12 +1,12 @@
|
||||
import { NitroLogger } from '../../../core/common/logger/NitroLogger';
|
||||
import { EventDispatcher } from '../../../core/events/EventDispatcher';
|
||||
import { NitroEvent } from '../../../core/events/NitroEvent';
|
||||
import { INitroLocalizationManager } from '../../localization/INitroLocalizationManager';
|
||||
import { FurnitureData } from './FurnitureData';
|
||||
import { FurnitureType } from './FurnitureType';
|
||||
import { IFurnitureData } from './IFurnitureData';
|
||||
import { NitroLogger } from '../../../core/common/logger/NitroLogger';
|
||||
|
||||
export class FurnitureDataParser extends EventDispatcher
|
||||
export class FurnitureDataLoader extends EventDispatcher
|
||||
{
|
||||
public static FURNITURE_DATA_READY: string = 'FDP_FURNITURE_DATA_READY';
|
||||
public static FURNITURE_DATA_ERROR: string = 'FDP_FURNITURE_DATA_ERROR';
|
||||
@ -47,7 +47,7 @@ export class FurnitureDataParser extends EventDispatcher
|
||||
|
||||
if(data.wallitemtypes) this.parseWallItems(data.wallitemtypes);
|
||||
|
||||
this.dispatchEvent(new NitroEvent(FurnitureDataParser.FURNITURE_DATA_READY));
|
||||
this.dispatchEvent(new NitroEvent(FurnitureDataLoader.FURNITURE_DATA_READY));
|
||||
}
|
||||
|
||||
private onFurnitureDataError(error: Error): void
|
||||
@ -56,7 +56,7 @@ export class FurnitureDataParser extends EventDispatcher
|
||||
|
||||
console.error(error);
|
||||
|
||||
this.dispatchEvent(new NitroEvent(FurnitureDataParser.FURNITURE_DATA_ERROR));
|
||||
this.dispatchEvent(new NitroEvent(FurnitureDataLoader.FURNITURE_DATA_ERROR));
|
||||
}
|
||||
|
||||
private parseFloorItems(data: any): void
|
@ -1,5 +1,5 @@
|
||||
export * from './FurnitureData';
|
||||
export * from './FurnitureDataParser';
|
||||
export * from './FurnitureDataLoader';
|
||||
export * from './FurnitureType';
|
||||
export * from './IFurnitureData';
|
||||
export * from './IFurnitureDataListener';
|
||||
|
@ -3,7 +3,7 @@ import { NitroEvent } from '../../../core/events/NitroEvent';
|
||||
import { IProductData } from './IProductData';
|
||||
import { ProductData } from './ProductData';
|
||||
|
||||
export class ProductDataParser extends EventDispatcher
|
||||
export class ProductDataLoader extends EventDispatcher
|
||||
{
|
||||
public static PDP_PRODUCT_DATA_READY: string = 'PDP_PRODUCT_DATA_READY';
|
||||
public static PDP_PRODUCT_DATA_FAILED: string = 'PDP_PRODUCT_DATA_FAILED';
|
||||
@ -38,14 +38,14 @@ export class ProductDataParser extends EventDispatcher
|
||||
|
||||
this.parseProducts(data.productdata);
|
||||
|
||||
this.dispatchEvent(new NitroEvent(ProductDataParser.PDP_PRODUCT_DATA_READY));
|
||||
this.dispatchEvent(new NitroEvent(ProductDataLoader.PDP_PRODUCT_DATA_READY));
|
||||
}
|
||||
|
||||
private onProductDataError(error: Error): void
|
||||
{
|
||||
if(!error) return;
|
||||
|
||||
this.dispatchEvent(new NitroEvent(ProductDataParser.PDP_PRODUCT_DATA_FAILED));
|
||||
this.dispatchEvent(new NitroEvent(ProductDataLoader.PDP_PRODUCT_DATA_FAILED));
|
||||
}
|
||||
|
||||
private parseProducts(data: { [index: string]: any }): void
|
@ -1,4 +1,4 @@
|
||||
export * from './IProductData';
|
||||
export * from './IProductDataListener';
|
||||
export * from './ProductData';
|
||||
export * from './ProductDataParser';
|
||||
export * from './ProductDataLoader';
|
||||
|
Loading…
Reference in New Issue
Block a user