Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -225,11 +225,6 @@ MonoBehaviour:
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: d65049d6f7a244863b39c4dda5ba538e
m_Address: NametagsData
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: d9a7adc162dc338449107a4654a26d50
m_Address: WorldAudioContainer
m_ReadOnly: 0
Expand Down
15 changes: 5 additions & 10 deletions Explorer/Assets/AddressableAssetsData/AssetGroups/UI.asset
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,6 @@ MonoBehaviour:
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 1d026bc5d9fd448798b32a455c0f3978
m_Address: Nametag
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 1f557ed079be146f9aeb090104c115c9
m_Address: Assets/DCL/MapRenderer/Addressables/SceneOfInterest.prefab
m_ReadOnly: 0
Expand Down Expand Up @@ -220,6 +215,11 @@ MonoBehaviour:
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 3df1198e2008a4f0abdf407103681813
m_Address: Assets/DCL/NameTags/Assets/NametagUIDocument.prefab
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: 3efe8a48fc3905f47a0648abd6859394
m_Address: MapCameraObject
m_ReadOnly: 0
Expand Down Expand Up @@ -590,11 +590,6 @@ MonoBehaviour:
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: b028edf69a2c54c9194c4ce6524befff
m_Address: ChatBubbleConfiguration
m_ReadOnly: 0
m_SerializedLabels: []
FlaggedDuringContentUpdateRestriction: 0
- m_GUID: b54d9d4189903c2438fa811308f14ceb
m_Address: MapConfiguration
m_ReadOnly: 0
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,9 @@ private bool IsUserAllowedToAccessToBeta(IWeb3Identity storedIdentity)

FeatureFlagsConfiguration flags = FeatureFlagsConfiguration.Instance;

if (!flags.IsEnabled(FeatureFlagsStrings.USER_ALLOW_LIST, FeatureFlagsStrings.WALLETS_VARIANT)) return true;
if (!flags.IsEnabled(FeatureFlagsStrings.USER_ALLOW_LIST, FeatureFlagsStrings.WALLET_VARIANT)) return true;

if (!flags.TryGetCsvPayload(FeatureFlagsStrings.USER_ALLOW_LIST, FeatureFlagsStrings.WALLETS_VARIANT, out List<List<string>>? allowedUsersCsv))
if (!flags.TryGetCsvPayload(FeatureFlagsStrings.USER_ALLOW_LIST, FeatureFlagsStrings.WALLET_VARIANT, out List<List<string>>? allowedUsersCsv))
return true;

bool isUserAllowed = allowedUsersCsv![0]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public async UniTask<bool> IsUserAllowedToUseTheFeatureAsync(CancellationToken c
result = false;
else
{
FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.COMMUNITIES, FeatureFlagsStrings.COMMUNITIES_WALLETS_VARIANT, out string? walletsAllowlist);
FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.COMMUNITIES, FeatureFlagsStrings.WALLETS_VARIANT, out string? walletsAllowlist);
result = string.IsNullOrEmpty(walletsAllowlist) || walletsAllowlist.Contains(ownWalletId, StringComparison.OrdinalIgnoreCase);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public async UniTask<bool> IsFeatureEnabledAsync(CancellationToken ct)
result = false;
else
{
FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.COMMUNITIES, FeatureFlagsStrings.COMMUNITIES_WALLETS_VARIANT, out string? walletsAllowlist);
FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.COMMUNITIES, FeatureFlagsStrings.WALLETS_VARIANT, out string? walletsAllowlist);
result = string.IsNullOrEmpty(walletsAllowlist) || walletsAllowlist.Contains(ownWalletId, StringComparison.OrdinalIgnoreCase);
}
}
Expand Down
10 changes: 5 additions & 5 deletions Explorer/Assets/DCL/FeatureFlags/FeatureFlagsStrings.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ public static class FeatureFlagsStrings
public const string USER_ALLOW_LIST = "user-allow-list";
public const string CSV_VARIANT = "csv-variant";
public const string STRING_VARIANT = "string-variant";
public const string WALLETS_VARIANT = "wallet";
public const string WALLET_VARIANT = "wallet";
public const string WALLETS_VARIANT = "wallets";
public const string ONBOARDING = "onboarding";
public const string GREETING_ONBOARDING = "greeting-onboarding";
public const string ONBOARDING_ENABLED_VARIANT = "enabled";
Expand All @@ -26,6 +27,7 @@ public static class FeatureFlagsStrings
public const string CHAT_HISTORY_LOCAL_STORAGE = "alfa-chat-history-local-storage";
public const string VOICE_CHAT = "alfa-voice-chat";
public const string COMMUNITY_VOICE_CHAT = "alfa-community-voice-chat";
public const string OFFICIAL_WALLETS = "alfa-official-wallets";
public const string CAMERA_REEL = "alfa-camera-reel";
public const string FRIENDS = "alfa-friends";
public const string FRIENDS_USER_BLOCKING = "alfa-friends-user-blocking";
Expand All @@ -34,9 +36,7 @@ public static class FeatureFlagsStrings
public const string SCENE_MEMORY_LIMIT = "alfa-use-scene-memory-limit";
public const string KTX2_CONVERSION = "ktx2-conversion";
public const string MARKETPLACE_CREDITS = "alfa-marketplace-credits";
public const string MARKETPLACE_CREDITS_WALLETS_VARIANT = "wallets";
public const string COMMUNITIES = "alfa-communities";
public const string COMMUNITIES_WALLETS_VARIANT = "wallets";
public const string COMMUNITIES_MEMBERS_COUNTER = "alfa-communities-members-counter";
public const string AUTH_CODE_VALIDATION = "number-validation";
[Obsolete("GPU Instancer Pro terrain is no longer optional so the flag is not needed")]
Expand Down Expand Up @@ -100,7 +100,7 @@ public static string GetStringValue(this FeatureFlag flag)
FeatureFlag.UserAllowList => FeatureFlagsStrings.USER_ALLOW_LIST,
FeatureFlag.CsvVariant => FeatureFlagsStrings.CSV_VARIANT,
FeatureFlag.StringVariant => FeatureFlagsStrings.STRING_VARIANT,
FeatureFlag.WalletsVariant => FeatureFlagsStrings.WALLETS_VARIANT,
FeatureFlag.WalletsVariant => FeatureFlagsStrings.WALLET_VARIANT,
FeatureFlag.Onboarding => FeatureFlagsStrings.ONBOARDING,
FeatureFlag.GreetingOnboarding => FeatureFlagsStrings.GREETING_ONBOARDING,
FeatureFlag.OnboardingEnabledVariant => FeatureFlagsStrings.ONBOARDING_ENABLED_VARIANT,
Expand All @@ -119,7 +119,7 @@ public static string GetStringValue(this FeatureFlag flag)
FeatureFlag.SceneMemoryLimit => FeatureFlagsStrings.SCENE_MEMORY_LIMIT,
FeatureFlag.Ktx2Conversion => FeatureFlagsStrings.KTX2_CONVERSION,
FeatureFlag.MarketplaceCredits => FeatureFlagsStrings.MARKETPLACE_CREDITS,
FeatureFlag.MarketplaceCreditsWalletsVariant => FeatureFlagsStrings.MARKETPLACE_CREDITS_WALLETS_VARIANT,
FeatureFlag.MarketplaceCreditsWalletsVariant => FeatureFlagsStrings.WALLETS_VARIANT,
FeatureFlag.AuthCodeValidation => FeatureFlagsStrings.AUTH_CODE_VALIDATION,
FeatureFlag.GpuiEnabled => FeatureFlagsStrings.GPUI_ENABLED,
FeatureFlag.ChatTranslation => FeatureFlagsStrings.CHAT_TRANSLATION_ENABLED,
Expand Down
21 changes: 21 additions & 0 deletions Explorer/Assets/DCL/FeatureFlags/OfficialWalletsHelper.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
using CodeLess.Attributes;
using System.Collections.Generic;

namespace DCL.FeatureFlags
{
[Singleton]
public partial class OfficialWalletsHelper
{
private readonly HashSet<string> officialWallets = new ();

public OfficialWalletsHelper()
{
if (FeatureFlagsConfiguration.Instance.TryGetCsvPayload(FeatureFlagsStrings.OFFICIAL_WALLETS, FeatureFlagsStrings.WALLETS_VARIANT, out var csv) && csv is { Count: >= 1 })
foreach (string wallet in csv[0])
officialWallets.Add(wallet.ToLowerInvariant());
}

public bool IsOfficialWallet(string wallet) =>
officialWallets.Contains(wallet.ToLowerInvariant());
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
using SceneRunner.Debugging;
using Segment.Serialization;
using System;
using System.Collections.Generic;
using System.Threading;
using UnityEngine.UIElements;
using Utility;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
using SceneRuntime.Factory.JsSource;
using SceneRuntime.Factory.WebSceneSource;
using System;
using System.Collections.Generic;
using System.Threading;
using UnityEngine;
using UnityEngine.UIElements;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,6 @@ await LODContainer
IWebBrowser webBrowser = bootstrapContainer.WebBrowser;
ISystemClipboard clipboard = new UnityClipboard();
NameColorHelper.SetNameColors(dynamicSettings.UserNameColors);
NametagsData nametagsData = (await assetsProvisioner.ProvideMainAssetAsync(dynamicSettings.NametagsData, ct)).Value;

ChatSharedAreaEventBus chatSharedAreaEventBus = new ChatSharedAreaEventBus();

Expand Down Expand Up @@ -717,7 +716,7 @@ await MapRendererContainer
staticContainer.MainPlayerAvatarBaseProxy,
debugBuilder,
staticContainer.CacheCleaner,
nametagsData,
dynamicSettings.NametagsData,
defaultTexturesContainer.TextureArrayContainerFactory,
wearableCatalog,
userBlockingCacheProxy),
Expand Down Expand Up @@ -745,7 +744,7 @@ await MapRendererContainer
chatHistory,
clipboardManager,
entityParticipantTable,
nametagsData,
dynamicSettings.NametagsData,
mainUIView,
staticContainer.InputBlock,
globalWorld,
Expand Down Expand Up @@ -1017,7 +1016,7 @@ await MapRendererContainer
mainUIView.SidebarView.EnsureNotNull().InWorldCameraButton,
globalWorld,
debugBuilder,
nametagsData,
dynamicSettings.NametagsData,
profileRepositoryWrapper,
sharedSpaceManager,
identityCache,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
using System.Threading;
using DCL.FeatureFlags;
using Global.Versioning;
using System.Collections.Generic;
using UnityEngine.UIElements;
using Utility;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
using DCL.AssetsProvision;
using DCL.Audio;
using DCL.AuthenticationScreenFlow;
using DCL.AvatarRendering.AvatarShape;
using DCL.Browser;
using DCL.Browser.DecentralandUrls;
using DCL.DebugUtilities;
Expand Down Expand Up @@ -50,6 +51,8 @@
using DCL.Settings.ModuleControllers;
using DCL.Utility;
using DCL.Utility.Types;
using System.Collections.Generic;
using TMPro;
#if UNITY_EDITOR
#endif
using UnityEngine;
Expand Down Expand Up @@ -224,6 +227,8 @@ await bootstrap.InitializeFeatureFlagsAsync(bootstrapContainer.IdentityCache!.Id
bootstrap.ApplyFeatureFlagConfigs(FeatureFlagsConfiguration.Instance);
staticContainer.SceneLoadingLimit.SetEnabled(FeatureFlagsConfiguration.Instance.IsEnabled(FeatureFlagsStrings.SCENE_MEMORY_LIMIT));

OfficialWalletsHelper.Initialize(new OfficialWalletsHelper());

(dynamicWorldContainer, isLoaded) = await bootstrap.LoadDynamicWorldContainerAsync(
bootstrapContainer,
staticContainer!,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ public static class VisualElementsExtensions
public static void SetDisplayed(this VisualElement ve, bool displayed) =>
ve.style.display = displayed ? DisplayStyle.Flex : DisplayStyle.None;

public static bool IsDisplayed(this VisualElement ve) =>
ve.style.display == DisplayStyle.Flex;

public static void SetVisible(this VisualElement ve, bool visible) =>
ve.style.visibility = visible ? Visibility.Visible : Visibility.Hidden;

public static T InstantiateForElement<T>(this VisualTreeAsset asset) where T: VisualElement =>
asset.Instantiate().Q<T>();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ protected override void Update(float t)
}

foreach (UIDocument doc in UIDocumentTracker.ActiveDocuments)
doc.rootVisualElement.SetDisplayed(currentUIVisibilityState);
doc.rootVisualElement.SetVisible(currentUIVisibilityState);
}

private void ShowOrHideToast()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ public static bool IsUserAllowedToUseTheFeatureAsync(bool includeMarketplaceCred
if (!includeMarketplaceCredits)
return false;

FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.MARKETPLACE_CREDITS, FeatureFlagsStrings.MARKETPLACE_CREDITS_WALLETS_VARIANT, out string walletsForTestingMarketplaceCredits);
FeatureFlagsConfiguration.Instance.TryGetTextPayload(FeatureFlagsStrings.MARKETPLACE_CREDITS, FeatureFlagsStrings.WALLETS_VARIANT, out string walletsForTestingMarketplaceCredits);

return !string.IsNullOrEmpty(userId) && (walletsForTestingMarketplaceCredits == null || walletsForTestingMarketplaceCredits.Contains(userId, StringComparison.OrdinalIgnoreCase));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,10 @@ public DebugRoomsSystem(
IActivatableConnectiveRoom voiceChatRoom,
IReadOnlyEntityParticipantTable entityParticipantTable,
IRemoteMetadata remoteMetadata,
IDebugContainerBuilder debugBuilder,
IObjectPool<DebugRoomIndicatorView> roomIndicatorPool) : base(world)
IDebugContainerBuilder debugBuilder) : base(world)
{
this.roomsStatus = roomsStatus;
this.entityParticipantTable = entityParticipantTable;
this.roomIndicatorPool = roomIndicatorPool;

DebugWidgetBuilder? infoWidget = debugBuilder.TryAddWidget(IDebugContainerBuilder.Categories.ROOM_INFO);
enabled = infoWidget != null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,6 @@ namespace DCL.Multiplayer.Connections.Systems.RoomIndicator
{
public struct DebugRoomIndicatorComponent
{
public readonly DebugRoomIndicatorView View;

public RoomSource ConnectedTo;

public DebugRoomIndicatorComponent(DebugRoomIndicatorView view)
{
View = view;
ConnectedTo = RoomSource.NONE;
}
}
}

This file was deleted.

This file was deleted.

Loading
Loading