mirror of
https://github.com/billsonnn/nitro-react.git
synced 2025-01-19 05:46:27 +01:00
Random changes
This commit is contained in:
parent
7a84fde7c3
commit
f6dd2efbd2
@ -28,7 +28,7 @@
|
|||||||
"system.animation.fps": 24,
|
"system.animation.fps": 24,
|
||||||
"system.limits.fps": false,
|
"system.limits.fps": false,
|
||||||
"system.dispatcher.log": false,
|
"system.dispatcher.log": false,
|
||||||
"system.packet.log": true,
|
"system.packet.log": false,
|
||||||
"system.pong.manually": true,
|
"system.pong.manually": true,
|
||||||
"system.pong.interval.ms": 20000,
|
"system.pong.interval.ms": 20000,
|
||||||
"room.color.skip.transition": true,
|
"room.color.skip.transition": true,
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { IFurnitureData, IGetImageListener, NitroEvent, NitroRenderTexture, PetFigureData, RoomObjectCategory, RoomObjectVariable, RoomSessionPresentEvent, RoomWidgetEnum, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
import { IFurnitureData, IGetImageListener, NitroEvent, NitroRenderTexture, PetFigureData, RoomObjectCategory, RoomObjectVariable, RoomSessionPresentEvent, RoomWidgetEnum, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
||||||
import { GetSessionDataManager, IsOwnerOfFurniture } from '../../..';
|
import { GetSessionDataManager, IsOwnerOfFurniture } from '../../..';
|
||||||
import { GetRoomEngine, LocalizeText } from '../../../..';
|
import { GetRoomEngine, LocalizeText } from '../../../..';
|
||||||
import { ProductTypeEnum } from '../../../../../views/catalog/common/ProductTypeEnum';
|
import { ProductTypeEnum } from '../../../../../components/catalog/common/ProductTypeEnum';
|
||||||
import { RoomWidgetUpdateEvent, RoomWidgetUpdatePresentDataEvent } from '../events';
|
import { RoomWidgetUpdateEvent, RoomWidgetUpdatePresentDataEvent } from '../events';
|
||||||
import { RoomWidgetFurniToWidgetMessage, RoomWidgetPresentOpenMessage } from '../messages';
|
import { RoomWidgetFurniToWidgetMessage, RoomWidgetPresentOpenMessage } from '../messages';
|
||||||
import { RoomWidgetMessage } from '../messages/RoomWidgetMessage';
|
import { RoomWidgetMessage } from '../messages/RoomWidgetMessage';
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { IFurnitureData } from '@nitrots/nitro-renderer';
|
import { IFurnitureData } from '@nitrots/nitro-renderer';
|
||||||
import { GetSessionDataManager } from '.';
|
import { GetSessionDataManager } from '.';
|
||||||
import { ProductTypeEnum } from '../../../views/catalog/common/ProductTypeEnum';
|
import { ProductTypeEnum } from '../../../components/catalog/common/ProductTypeEnum';
|
||||||
|
|
||||||
export function GetFurnitureData(furniClassId: number, productType: string): IFurnitureData
|
export function GetFurnitureData(furniClassId: number, productType: string): IFurnitureData
|
||||||
{
|
{
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { FC, useMemo } from 'react';
|
import { FC, useMemo } from 'react';
|
||||||
import { ItemCountView } from '../../../../views/shared/item-count/ItemCountView';
|
import { ItemCountView } from '../../../../views/shared/item-count/ItemCountView';
|
||||||
import { LimitedEditionStyledNumberView } from '../../../../views/shared/limited-edition/styled-number/LimitedEditionStyledNumberView';
|
import { LimitedEditionStyledNumberView } from '../../../../views/shared/limited-edition/LimitedEditionStyledNumberView';
|
||||||
import { NitroCardGridItemViewProps } from './NitroCardGridItemView.types';
|
import { NitroCardGridItemViewProps } from './NitroCardGridItemView.types';
|
||||||
|
|
||||||
export const NitroCardGridItemView: FC<NitroCardGridItemViewProps> = props =>
|
export const NitroCardGridItemView: FC<NitroCardGridItemViewProps> = props =>
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
@import "./shared/Shared";
|
@import "./shared/Shared";
|
||||||
@import "./camera/CameraWidgetView";
|
@import "./camera/CameraWidgetView";
|
||||||
@import "./catalog/CatalogView";
|
|
||||||
@import "./friends/FriendsView";
|
@import "./friends/FriendsView";
|
||||||
@import "./groups/GroupView";
|
@import "./groups/GroupView";
|
||||||
@import "./hotel-view/HotelView";
|
@import "./hotel-view/HotelView";
|
||||||
@ -12,7 +11,6 @@
|
|||||||
@import "./right-side/RightSideView";
|
@import "./right-side/RightSideView";
|
||||||
@import "./room/RoomView";
|
@import "./room/RoomView";
|
||||||
@import "./room-host/RoomHostView";
|
@import "./room-host/RoomHostView";
|
||||||
@import "./toolbar/ToolbarView";
|
|
||||||
@import "./wired/WiredView";
|
@import "./wired/WiredView";
|
||||||
@import "./mod-tools/ModToolsView";
|
@import "./mod-tools/ModToolsView";
|
||||||
@import "./user-settings/UserSettingsView";
|
@import "./user-settings/UserSettingsView";
|
||||||
|
@ -4,8 +4,8 @@ import { CreateLinkEvent, GetSessionDataManager, LocalizeText, TryVisitRoom } fr
|
|||||||
import { GetGroupManager } from '../../../../api/groups/GetGroupManager';
|
import { GetGroupManager } from '../../../../api/groups/GetGroupManager';
|
||||||
import { GetGroupMembers } from '../../../../api/groups/GetGroupMembers';
|
import { GetGroupMembers } from '../../../../api/groups/GetGroupMembers';
|
||||||
import { TryJoinGroup } from '../../../../api/groups/TryJoinGroup';
|
import { TryJoinGroup } from '../../../../api/groups/TryJoinGroup';
|
||||||
|
import { CatalogPageName } from '../../../../components/catalog/common/CatalogPageName';
|
||||||
import { SendMessageHook } from '../../../../hooks';
|
import { SendMessageHook } from '../../../../hooks';
|
||||||
import { CatalogPageName } from '../../../catalog/common/CatalogPageName';
|
|
||||||
import { BadgeImageView } from '../../../shared/badge-image/BadgeImageView';
|
import { BadgeImageView } from '../../../shared/badge-image/BadgeImageView';
|
||||||
import { GroupMembershipType } from '../../common/GroupMembershipType';
|
import { GroupMembershipType } from '../../common/GroupMembershipType';
|
||||||
import { GroupType } from '../../common/GroupType';
|
import { GroupType } from '../../common/GroupType';
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import { ClubGiftInfoEvent, FriendlyTime, GetClubGiftInfo, RequestBadgesComposer, ScrKickbackData, ScrSendKickbackInfoMessageEvent, UserInfoEvent, UserSubscriptionEvent } from '@nitrots/nitro-renderer';
|
import { ClubGiftInfoEvent, FriendlyTime, GetClubGiftInfo, ILinkEventTracker, RequestBadgesComposer, ScrKickbackData, ScrSendKickbackInfoMessageEvent, UserInfoEvent, UserSubscriptionEvent } from '@nitrots/nitro-renderer';
|
||||||
import { BadgesEvent, FigureUpdateEvent } from '@nitrots/nitro-renderer/src';
|
import { BadgesEvent, FigureUpdateEvent } from '@nitrots/nitro-renderer/src';
|
||||||
import { ScrGetKickbackInfoMessageComposer } from '@nitrots/nitro-renderer/src/nitro/communication/messages/outgoing/user/ScrGetKickbackInfoMessageComposer';
|
import { ScrGetKickbackInfoMessageComposer } from '@nitrots/nitro-renderer/src/nitro/communication/messages/outgoing/user/ScrGetKickbackInfoMessageComposer';
|
||||||
import { FC, useCallback, useEffect, useState } from 'react';
|
import { FC, useCallback, useEffect, useState } from 'react';
|
||||||
import { OverlayTrigger, Popover } from 'react-bootstrap';
|
import { OverlayTrigger, Popover } from 'react-bootstrap';
|
||||||
import { CreateLinkEvent, GetConfiguration, LocalizeText } from '../../api';
|
import { AddEventLinkTracker, CreateLinkEvent, GetConfiguration, LocalizeText, RemoveLinkEventTracker } from '../../api';
|
||||||
import { HcCenterEvent } from '../../events/hc-center/HcCenterEvent';
|
import { HcCenterEvent } from '../../events/hc-center/HcCenterEvent';
|
||||||
import { CreateMessageHook, SendMessageHook, useUiEvent } from '../../hooks';
|
import { CreateMessageHook, SendMessageHook, useUiEvent } from '../../hooks';
|
||||||
import { NitroCardContentView, NitroCardHeaderView, NitroCardView } from '../../layout';
|
import { NitroCardContentView, NitroCardHeaderView, NitroCardView } from '../../layout';
|
||||||
@ -27,6 +27,40 @@ export const HcCenterView: FC<{}> = props =>
|
|||||||
|
|
||||||
const [badgeCode, setBadgeCode] = useState(BadgeResolver.default_badge);
|
const [badgeCode, setBadgeCode] = useState(BadgeResolver.default_badge);
|
||||||
|
|
||||||
|
const linkReceived = useCallback((url: string) =>
|
||||||
|
{
|
||||||
|
const parts = url.split('/');
|
||||||
|
|
||||||
|
if(parts.length < 2) return;
|
||||||
|
|
||||||
|
switch(parts[1])
|
||||||
|
{
|
||||||
|
case 'open':
|
||||||
|
if(parts.length > 2)
|
||||||
|
{
|
||||||
|
switch(parts[2])
|
||||||
|
{
|
||||||
|
case 'hccenter':
|
||||||
|
setIsVisible(true);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
useEffect(() =>
|
||||||
|
{
|
||||||
|
const linkTracker: ILinkEventTracker = {
|
||||||
|
linkReceived,
|
||||||
|
eventUrlPrefix: 'habboUI/'
|
||||||
|
};
|
||||||
|
|
||||||
|
AddEventLinkTracker(linkTracker);
|
||||||
|
|
||||||
|
return () => RemoveLinkEventTracker(linkTracker);
|
||||||
|
}, [ linkReceived]);
|
||||||
|
|
||||||
const onUserInfoEvent = useCallback((event: UserInfoEvent) =>
|
const onUserInfoEvent = useCallback((event: UserInfoEvent) =>
|
||||||
{
|
{
|
||||||
const parser = event.getParser();
|
const parser = event.getParser();
|
||||||
|
@ -3,12 +3,13 @@ import { FC, useCallback, useEffect, useState } from 'react';
|
|||||||
import { AddEventLinkTracker, GetCommunication, RemoveLinkEventTracker } from '../../api';
|
import { AddEventLinkTracker, GetCommunication, RemoveLinkEventTracker } from '../../api';
|
||||||
import { AchievementsView } from '../../components/achievements/AchievementsView';
|
import { AchievementsView } from '../../components/achievements/AchievementsView';
|
||||||
import { AvatarEditorView } from '../../components/avatar-editor/AvatarEditorView';
|
import { AvatarEditorView } from '../../components/avatar-editor/AvatarEditorView';
|
||||||
|
import { CatalogView } from '../../components/catalog/CatalogView';
|
||||||
import { InventoryView } from '../../components/inventory/InventoryView';
|
import { InventoryView } from '../../components/inventory/InventoryView';
|
||||||
|
import { ToolbarView } from '../../components/toolbar/ToolbarView';
|
||||||
import { useRoomSessionManagerEvent } from '../../hooks/events/nitro/session/room-session-manager-event';
|
import { useRoomSessionManagerEvent } from '../../hooks/events/nitro/session/room-session-manager-event';
|
||||||
import { TransitionAnimation, TransitionAnimationTypes } from '../../layout';
|
import { TransitionAnimation, TransitionAnimationTypes } from '../../layout';
|
||||||
import { CameraWidgetView } from '../camera/CameraWidgetView';
|
import { CameraWidgetView } from '../camera/CameraWidgetView';
|
||||||
import { CampaignView } from '../campaign/CampaignView';
|
import { CampaignView } from '../campaign/CampaignView';
|
||||||
import { CatalogView } from '../catalog/CatalogView';
|
|
||||||
import { ChatHistoryView } from '../chat-history/ChatHistoryView';
|
import { ChatHistoryView } from '../chat-history/ChatHistoryView';
|
||||||
import { FloorplanEditorView } from '../floorplan-editor/FloorplanEditorView';
|
import { FloorplanEditorView } from '../floorplan-editor/FloorplanEditorView';
|
||||||
import { FriendsView } from '../friends/FriendsView';
|
import { FriendsView } from '../friends/FriendsView';
|
||||||
@ -21,7 +22,6 @@ import { NavigatorView } from '../navigator/NavigatorView';
|
|||||||
import { NitropediaView } from '../nitropedia/NitropediaView';
|
import { NitropediaView } from '../nitropedia/NitropediaView';
|
||||||
import { RightSideView } from '../right-side/RightSideView';
|
import { RightSideView } from '../right-side/RightSideView';
|
||||||
import { RoomHostView } from '../room-host/RoomHostView';
|
import { RoomHostView } from '../room-host/RoomHostView';
|
||||||
import { ToolbarView } from '../toolbar/ToolbarView';
|
|
||||||
import { UserProfileView } from '../user-profile/UserProfileView';
|
import { UserProfileView } from '../user-profile/UserProfileView';
|
||||||
import { UserSettingsView } from '../user-settings/UserSettingsView';
|
import { UserSettingsView } from '../user-settings/UserSettingsView';
|
||||||
import { WiredView } from '../wired/WiredView';
|
import { WiredView } from '../wired/WiredView';
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import { HabboWebTools, RoomEnterEffect } from '@nitrots/nitro-renderer';
|
import { HabboWebTools, RoomEnterEffect } from '@nitrots/nitro-renderer';
|
||||||
import { CreateLinkEvent, GetConfiguration, GetNitroInstance, LocalizeText } from '../../../api';
|
import { CreateLinkEvent, GetConfiguration, GetNitroInstance, LocalizeText } from '../../../api';
|
||||||
|
import { CatalogPageName } from '../../../components/catalog/common/CatalogPageName';
|
||||||
import { NotificationAlertEvent, NotificationConfirmEvent } from '../../../events';
|
import { NotificationAlertEvent, NotificationConfirmEvent } from '../../../events';
|
||||||
import { NotificationBubbleEvent } from '../../../events/notification-center/NotificationBubbleEvent';
|
import { NotificationBubbleEvent } from '../../../events/notification-center/NotificationBubbleEvent';
|
||||||
import { dispatchUiEvent } from '../../../hooks';
|
import { dispatchUiEvent } from '../../../hooks';
|
||||||
import { CatalogPageName } from '../../catalog/common/CatalogPageName';
|
|
||||||
import { NotificationAlertType } from './NotificationAlertType';
|
import { NotificationAlertType } from './NotificationAlertType';
|
||||||
import { NotificationBubbleType } from './NotificationBubbleType';
|
import { NotificationBubbleType } from './NotificationBubbleType';
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { CatalogPageMessageProductData } from '@nitrots/nitro-renderer';
|
import { CatalogPageMessageProductData } from '@nitrots/nitro-renderer';
|
||||||
import { GetRoomEngine } from '../../../api';
|
import { GetRoomEngine } from '../../../api';
|
||||||
import { FurniCategory } from '../../catalog/common/FurniCategory';
|
import { FurniCategory } from '../../../components/catalog/common/FurniCategory';
|
||||||
|
|
||||||
export class ProductImageUtility
|
export class ProductImageUtility
|
||||||
{
|
{
|
||||||
|
@ -1,11 +1,11 @@
|
|||||||
import { RoomObjectCategory, RoomObjectOperationType } from '@nitrots/nitro-renderer';
|
import { RoomObjectCategory, RoomObjectOperationType } from '@nitrots/nitro-renderer';
|
||||||
import { FC, useCallback, useMemo, useState } from 'react';
|
import { FC, useCallback, useMemo, useState } from 'react';
|
||||||
import { CreateLinkEvent, GetRoomEngine, GetSessionDataManager, LocalizeText, RoomWidgetPresentOpenMessage, RoomWidgetUpdatePresentDataEvent, RoomWidgetUpdateRoomObjectEvent } from '../../../../../api';
|
import { CreateLinkEvent, GetRoomEngine, GetSessionDataManager, LocalizeText, RoomWidgetPresentOpenMessage, RoomWidgetUpdatePresentDataEvent, RoomWidgetUpdateRoomObjectEvent } from '../../../../../api';
|
||||||
|
import { ProductTypeEnum } from '../../../../../components/catalog/common/ProductTypeEnum';
|
||||||
import { BatchUpdates } from '../../../../../hooks';
|
import { BatchUpdates } from '../../../../../hooks';
|
||||||
import { CreateEventDispatcherHook } from '../../../../../hooks/events/event-dispatcher.base';
|
import { CreateEventDispatcherHook } from '../../../../../hooks/events/event-dispatcher.base';
|
||||||
import { NitroCardContentView, NitroCardHeaderView, NitroCardView, NitroLayoutButton, NitroLayoutFlex, NitroLayoutFlexColumn, NitroLayoutGiftCardView, NitroLayoutGrid, NitroLayoutGridColumn } from '../../../../../layout';
|
import { NitroCardContentView, NitroCardHeaderView, NitroCardView, NitroLayoutButton, NitroLayoutFlex, NitroLayoutFlexColumn, NitroLayoutGiftCardView, NitroLayoutGrid, NitroLayoutGridColumn } from '../../../../../layout';
|
||||||
import { NitroLayoutBase } from '../../../../../layout/base';
|
import { NitroLayoutBase } from '../../../../../layout/base';
|
||||||
import { ProductTypeEnum } from '../../../../catalog/common/ProductTypeEnum';
|
|
||||||
import { useRoomContext } from '../../../context/RoomContext';
|
import { useRoomContext } from '../../../context/RoomContext';
|
||||||
|
|
||||||
const FLOOR: string = 'floor';
|
const FLOOR: string = 'floor';
|
||||||
|
@ -4,7 +4,7 @@ import { CreateLinkEvent, GetGroupInformation, GetRoomEngine, LocalizeText, Room
|
|||||||
import { CreateMessageHook, SendMessageHook } from '../../../../../../hooks';
|
import { CreateMessageHook, SendMessageHook } from '../../../../../../hooks';
|
||||||
import { UserProfileIconView } from '../../../../../../layout';
|
import { UserProfileIconView } from '../../../../../../layout';
|
||||||
import { BadgeImageView } from '../../../../../shared/badge-image/BadgeImageView';
|
import { BadgeImageView } from '../../../../../shared/badge-image/BadgeImageView';
|
||||||
import { LimitedEditionCompactPlateView } from '../../../../../shared/limited-edition/compact-plate/LimitedEditionCompactPlateView';
|
import { LimitedEditionCompactPlateView } from '../../../../../shared/limited-edition/LimitedEditionCompactPlateView';
|
||||||
import { RarityLevelView } from '../../../../../shared/rarity-level/RarityLevelView';
|
import { RarityLevelView } from '../../../../../shared/rarity-level/RarityLevelView';
|
||||||
import { useRoomContext } from '../../../../context/RoomContext';
|
import { useRoomContext } from '../../../../context/RoomContext';
|
||||||
import { InfoStandBaseView } from '../base/InfoStandBaseView';
|
import { InfoStandBaseView } from '../base/InfoStandBaseView';
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import { IGetImageListener, ImageResult, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
import { IGetImageListener, ImageResult, TextureUtils, Vector3d } from '@nitrots/nitro-renderer';
|
||||||
import { FC, useCallback, useEffect, useState } from 'react';
|
import { FC, useCallback, useEffect, useState } from 'react';
|
||||||
import { GetRoomEngine } from '../../../api';
|
import { GetRoomEngine } from '../../../api';
|
||||||
import { ProductTypeEnum } from '../../catalog/common/ProductTypeEnum';
|
import { ProductTypeEnum } from '../../../components/catalog/common/ProductTypeEnum';
|
||||||
import { FurniImageViewProps } from './FurniImageView.types';
|
import { FurniImageViewProps } from './FurniImageView.types';
|
||||||
|
|
||||||
export const FurniImageView: FC<FurniImageViewProps> = props =>
|
export const FurniImageView: FC<FurniImageViewProps> = props =>
|
||||||
|
Loading…
Reference in New Issue
Block a user