Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release: 11-4-2024 #2705

Merged
merged 24 commits into from
Nov 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
cc2ff05
chore: UnloadStrategy abstract class (#2508)
dalkia Oct 24, 2024
2745511
fix: update audio for streams with no volume set (#2589)
davidejensen Oct 25, 2024
94ca2b4
fix: support resolutions for vertical monitor orientation (#2593)
lorenzo-ranciaffi Oct 25, 2024
278ba86
replace to -ea domain (#2583)
NickKhalow Oct 25, 2024
a7b1dd4
Fix: Fixed cursor sizes on Mac (#2604)
fcolarich Oct 25, 2024
79806f3
fix: emotes spam stuck (#2573)
lorux0 Oct 25, 2024
34fd8df
fixed mime header for video streams (#2545)
davidejensen Oct 28, 2024
8418d9d
Update bug_report.md (#2634)
anicalbano Oct 29, 2024
4520005
fix: tweens update with scene cycle (#2570)
fcolarich Oct 29, 2024
93a0df3
Added logic to hide UI (#2601)
fcolarich Oct 29, 2024
a003d59
chore: scene debug console app param + improve scene console toggling…
pravusjif Oct 29, 2024
d29bfc5
fix: sdk video player SEEK + VS_ERROR video event (#2563)
pravusjif Oct 30, 2024
070fddb
fix: attempt to remove build id (#2669)
m3taphysics Oct 31, 2024
c184dc8
Update build.py (#2681)
m3taphysics Oct 31, 2024
c2ec69e
fix: copy offline realm adapter value (#2613)
dalkia Oct 31, 2024
7d23fd3
chore: Add promise type to extension to get more data (#2671)
dalkia Oct 31, 2024
f425bfd
feat: support for zone terrain (#2648)
dalkia Nov 1, 2024
039cbb9
Update build.py
m3taphysics Nov 1, 2024
c8de7ae
Avoid allocating new strings every time we sign a web request (#2635)
AnsisMalins Nov 1, 2024
e928238
add scene restriction minimap badge (#2437)
lorenzo-ranciaffi Nov 1, 2024
1ece63b
style: badges minor fixes (#2678)
RominaMarchetti Nov 1, 2024
c3602c2
Feat: camera reel storage services (#2672)
popuz Nov 1, 2024
b858f2b
fix: disable scene restriction toast while invisible in order to unbl…
lorenzo-ranciaffi Nov 4, 2024
fead903
fix: fixed suppress error in satellite map chunk download (#2704)
davidejensen Nov 4, 2024
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
8 changes: 6 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ assignees: ''

---

### **Explorer Alpha build versions:**
### **Build version:**


### **Issue Description:**
Expand All @@ -20,14 +20,18 @@ assignees: ''
2.
3.

### **Expected behaviour:**
### **Expected behavior:**


### **Current behaviour:**


### **Repro Index:**
<!-- Starting on 0/10 attempts -->

#### **Evidence:**


#### **Additional Notes:**
<!-- If the test is made on Mac, specify if the chip is M1 or Intel -->

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
using CommunicationData.URLHelpers;
using Cysharp.Threading.Tasks;
using DCL.AvatarRendering.Loading.Components;
using DCL.Web3;
using Global.AppArgs;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;

namespace DCL.AvatarRendering.Emotes
{
public class ApplicationParamsEmoteProvider : IEmoteProvider
{
private readonly IAppArgs appArgs;
private readonly IEmoteProvider source;

public ApplicationParamsEmoteProvider(IAppArgs appArgs,
IEmoteProvider source)
{
this.appArgs = appArgs;
this.source = source;
}

public async UniTask<int> GetOwnedEmotesAsync(Web3Address userId, CancellationToken ct,
IEmoteProvider.OwnedEmotesRequestOptions requestOptions,
List<IEmote> output)
{
if (!appArgs.TryGetValue("self-preview-emotes", out string? emotesCsv))
return await source.GetOwnedEmotesAsync(userId, ct, requestOptions, output);

URN[] pointers = emotesCsv!.Split(',', StringSplitOptions.RemoveEmptyEntries)
.Select(s => new URN(s))
.ToArray();

await UniTask.WhenAll(GetEmotesAsync(pointers, BodyShape.MALE, ct, output),
GetEmotesAsync(pointers, BodyShape.FEMALE, ct, output));

return output.Count;
}

public UniTask GetEmotesAsync(IReadOnlyCollection<URN> emoteIds, BodyShape bodyShape, CancellationToken ct, List<IEmote> output) =>
source.GetEmotesAsync(emoteIds, bodyShape, ct, output);
}
}

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 @@ -18,17 +18,17 @@ namespace DCL.AvatarRendering.Wearables
{
public class ApplicationParametersWearablesProvider : IWearablesProvider
{
private readonly IAppArgs applicationParametersParser;
private readonly IAppArgs appArgs;
private readonly IWearablesProvider source;
private readonly World world;
private readonly string[] allWearableCategories = WearablesConstants.CATEGORIES_PRIORITY.ToArray();
private readonly List<IWearable> resultWearablesBuffer = new ();

public ApplicationParametersWearablesProvider(IAppArgs applicationParametersParser,
public ApplicationParametersWearablesProvider(IAppArgs appArgs,
IWearablesProvider source,
World world)
{
this.applicationParametersParser = applicationParametersParser;
this.appArgs = appArgs;
this.source = source;
this.world = world;
}
Expand All @@ -41,14 +41,18 @@ public ApplicationParametersWearablesProvider(IAppArgs applicationParametersPars
string? name = null,
List<IWearable>? results = null)
{
if (!applicationParametersParser.TryGetValue("self-preview-wearables", out string? wearablesCsv))
if (!appArgs.TryGetValue("self-preview-wearables", out string? wearablesCsv))
return await source.GetAsync(pageSize, pageNumber, ct, sortingField, orderBy, category, collectionType, name, results);

URN[] pointers = wearablesCsv!.Split(',', StringSplitOptions.RemoveEmptyEntries)
.Select(s => new URN(s)).ToArray();
.Select(s => new URN(s))
.ToArray();

IReadOnlyCollection<IWearable>? maleWearables = await RequestPointersAsync(pointers, BodyShape.MALE, ct);
IReadOnlyCollection<IWearable>? femaleWearables = await RequestPointersAsync(pointers, BodyShape.FEMALE, ct);
(IReadOnlyCollection<IWearable>? maleWearables, IReadOnlyCollection<IWearable>? femaleWearables) =
await UniTask.WhenAll(RequestPointersAsync(pointers, BodyShape.MALE, ct),
RequestPointersAsync(pointers, BodyShape.FEMALE, ct));

results ??= new List<IWearable>();

lock (resultWearablesBuffer)
{
Expand All @@ -61,7 +65,8 @@ public ApplicationParametersWearablesProvider(IAppArgs applicationParametersPars
resultWearablesBuffer.AddRange(femaleWearables);

int pageIndex = pageNumber - 1;
return (resultWearablesBuffer.Skip(pageIndex * pageSize).Take(pageSize).ToArray(), resultWearablesBuffer.Count);
results.AddRange(resultWearablesBuffer.Skip(pageIndex * pageSize).Take(pageSize));
return (results, resultWearablesBuffer.Count);
}
}

Expand All @@ -70,6 +75,7 @@ public ApplicationParametersWearablesProvider(IAppArgs applicationParametersPars
CancellationToken ct)
{
var promise = WearablePromise.Create(world,

// We pass all categories as force renderer to force the download of all of them
// Otherwise they will be skipped if any wearable is hiding the category
WearableComponentsUtils.CreateGetWearablesByPointersIntention(bodyShape, pointers, allWearableCategories),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ private void OnColorChange(Color newColor, string category)
previewAvatarModel.SkinColor = newColor;
break;
}

OnModelUpdated();
}

Expand Down Expand Up @@ -180,14 +181,18 @@ async UniTaskVoid EnsureEmoteAndPlayItAsync(CancellationToken ct)
{
URN urn = emote.GetUrn().Shorten();

// In case you want to preview an emote, it might happen that the asset bundles are not loaded
// By adding the emote we force to fetch them if missing
// Ensure assets are loaded for the emote
if (!previewAvatarModel.Emotes?.Contains(urn) ?? true)
{
previewAvatarModel.Emotes!.Add(urn);
await ShowLoadingSpinnerAndUpdateAvatarAsync(ct);
// Remove the emote so it stays original
previewAvatarModel.Emotes!.Remove(urn);

try { await ShowLoadingSpinnerAndUpdateAvatarAsync(ct); }
catch (OperationCanceledException) { }
finally
{
// Remove the emote so it stays original
previewAvatarModel.Emotes!.Remove(urn);
}
}

PlayEmote(urn);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,8 @@ public enum DecentralandUrl
AssetBundlesCDN,

Badges,

CameraReelUsers,
CameraReelImages
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,13 @@ private static string RawUrl(DecentralandUrl decentralandUrl) =>
DecentralandUrl.FeatureFlags => $"https://feature-flags.decentraland.{ENV}",
DecentralandUrl.Help => $"https://decentraland.{ENV}/help/",
DecentralandUrl.Market => $"https://market.decentraland.{ENV}",
// All ABs are in org
DecentralandUrl.AssetBundlesCDN => $"https://ab-cdn.decentraland.{ENV}",
DecentralandUrl.ArchipelagoStatus => $"https://archipelago-stats.decentraland.{ENV}/status",
DecentralandUrl.ArchipelagoStatus => $"https://archipelago-ea-stats.decentraland.{ENV}/status",
DecentralandUrl.GatekeeperStatus => $"https://comms-gatekeeper.decentraland.{ENV}/status",
DecentralandUrl.Genesis => $"https://realm-provider-ea.decentraland.{ENV}/main",
DecentralandUrl.Badges => $"https://badges.decentraland.{ENV}",
DecentralandUrl.CameraReelUsers => $"https://camera-reel-service.decentraland.{ENV}/api/users",
DecentralandUrl.CameraReelImages => $"https://camera-reel-service.decentraland.{ENV}/api/images",
_ => throw new ArgumentOutOfRangeException(nameof(decentralandUrl), decentralandUrl, null!)
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ public void Dispose()

public UniTask UpdateAvatarAsync(CharacterPreviewAvatarModel avatarModel, CancellationToken ct)
{
ct.ThrowIfCancellationRequested();

ref AvatarShapeComponent avatarShape = ref globalWorld.Get<AvatarShapeComponent>(characterPreviewEntity);

avatarShape.SkinColor = avatarModel.SkinColor;
Expand All @@ -87,25 +89,50 @@ public UniTask UpdateAvatarAsync(CharacterPreviewAvatarModel avatarModel, Cancel
PartitionComponent.TOP_PRIORITY
);

globalWorld.Create(EmotePromise.Create(globalWorld,
Entity emotePromiseEntity = globalWorld.Create(EmotePromise.Create(globalWorld,
EmoteComponentsUtils.CreateGetEmotesByPointersIntention(avatarShape.BodyShape,
avatarModel.Emotes ?? (IReadOnlyCollection<URN>)Array.Empty<URN>()),
PartitionComponent.TOP_PRIORITY));

EntityReference emotePromiseRef = globalWorld.Reference(emotePromiseEntity);

avatarShape.IsDirty = true;

return WaitForAvatarInstantiatedAsync(ct);
return WaitForAvatarInstantiatedAsync(emotePromiseRef, ct);
}

private async UniTask WaitForAvatarInstantiatedAsync(CancellationToken ct)
private async UniTask WaitForAvatarInstantiatedAsync(EntityReference emotePromiseEntity, CancellationToken ct)
{
while (!ct.IsCancellationRequested && globalWorld.Get<AvatarShapeComponent>(characterPreviewEntity).IsDirty)
World world = globalWorld;
Entity avatarEntity = characterPreviewEntity;

while (!IsAvatarLoaded() || !IsEmoteLoaded())
await UniTask.Yield(ct);

ct.ThrowIfCancellationRequested();

return;

bool IsAvatarLoaded()
{
return !world.Get<AvatarShapeComponent>(avatarEntity).IsDirty;
}

bool IsEmoteLoaded()
{
return !emotePromiseEntity.IsAlive(world)
|| world.Get<EmotePromise>(emotePromiseEntity).IsConsumed;
}
}

public void PlayEmote(string emoteId)
{
globalWorld.Add(characterPreviewEntity, new CharacterEmoteIntent { EmoteId = emoteId, TriggerSource = TriggerSource.PREVIEW});
var intent = new CharacterEmoteIntent { EmoteId = emoteId, TriggerSource = TriggerSource.PREVIEW };

if (globalWorld.Has<CharacterEmoteIntent>(characterPreviewEntity))
globalWorld.Set(characterPreviewEntity, intent);
else
globalWorld.Add(characterPreviewEntity, intent);
}

public void StopEmotes()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,18 @@ private void OnAnyCharacterPreviewHide(CharacterPreviewControllerBase characterP
protected void OnModelUpdated()
{
updateModelCancellationToken = updateModelCancellationToken.SafeRestart();
ShowLoadingSpinnerAndUpdateAvatarAsync(updateModelCancellationToken.Token).Forget();

UpdateModelAsync(updateModelCancellationToken.Token).Forget();
return;

async UniTaskVoid UpdateModelAsync(CancellationToken ct)
{
try
{
await ShowLoadingSpinnerAndUpdateAvatarAsync(ct);
}
catch (OperationCanceledException) { }
}
}

protected async UniTask ShowLoadingSpinnerAndUpdateAvatarAsync(CancellationToken ct)
Expand All @@ -232,7 +243,6 @@ protected async UniTask ShowLoadingSpinnerAndUpdateAvatarAsync(CancellationToken
DisableSpinner(spinner);
}


private void DisableSpinner(GameObject spinner)
{
spinner.SetActive(false);
Expand All @@ -250,11 +260,8 @@ private GameObject EnableSpinner()
return spinner;
}

private async UniTask UpdateAvatarAsync(CharacterPreviewAvatarModel model, CancellationToken ct)
{
try { await (previewController?.UpdateAvatarAsync(model, ct) ?? UniTask.CompletedTask); }
catch (OperationCanceledException) { }
}
private async UniTask UpdateAvatarAsync(CharacterPreviewAvatarModel model, CancellationToken ct) =>
await (previewController?.UpdateAvatarAsync(model, ct) ?? UniTask.CompletedTask);

protected void StopEmotes() =>
previewController?.StopEmotes();
Expand Down
3 changes: 3 additions & 0 deletions Explorer/Assets/DCL/InWorldCamera.meta

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

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
@@ -0,0 +1,5 @@
using System.Runtime.CompilerServices;

[assembly: InternalsVisibleTo("DCL.EditMode.Tests")]
[assembly: InternalsVisibleTo("DCL.PlayMode.Tests")]
[assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")] // for NSubstitute

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

Loading
Loading