Dreaming381 / Latios-Framework-Documentation

Documentation and articles for the Latios Framework for Unity's ECS
59 stars 10 forks source link

the audio file is not playing #5

Open jiangjiatao opened 9 months ago

jiangjiatao commented 9 months ago

I followed this documentation but the audio file is not playing

image

Dreaming381 commented 9 months ago

I have a few questions.

First, which Latios Framework version and Unity Editor version are you using? Second, can you please share screenshots of the inspector for both the Myri Audio Source and the Myri Audio Listener?

jiangjiatao commented 9 months ago

Is Bootstrap a must-have? I can't find the option in the menu。

image image image image image image

jiangjiatao commented 9 months ago

I need your help very much

Unity Editor version

image

Dreaming381 commented 9 months ago

First off, Myri only works correctly in Unity 2022.3.13f1 or newer. Versions prior to that rarely worked correctly with imported audio clips due to a bug on Unity's side.

Second, the bootstrap creation menu is not in the Component menu, but rather the Assets menu. The bootstrap is a hard requirement.

jiangjiatao commented 9 months ago

It can be used correctly, thank you

jiangjiatao commented 9 months ago

my Unity Editor version is 2022.3.10f1, are these errors caused by the unity version?

image image image

Dreaming381 commented 9 months ago

I do not believe those errors are related. Typically, Myri errors with the editor version will happen during subscene baking and cause Unity to crash.

jiangjiatao commented 9 months ago

There are related error reports

image

Dreaming381 commented 9 months ago

That's just a custom IRateManager that monitors for Latios Framework systems and performs extra operations. For other systems, it is just doing what ComponentSystemGroup normally does. You will see these show up in every callstack that the Latios Framework is installed in. The actual issues are in the invoked systems themselves. In this case, the issue is that your EntityCommandBuffer is trying to remove a component on an entity that does not have the component in the first place. Nothing in the Latios Framework even uses EntityCommandBufferSystem, so this is a bug in your code.

The Latios Framework has a special feature that you can enable in the bootstrap file via world.zeroToleranceForExceptions= true; This will cause the world to pause and not try to run any more systems once one of them throws an exception, hiding exceptions that were just side-effects of things being broken to start with.

jiangjiatao commented 9 months ago

The problem I'm encountering now is that if I don't add LatiosBakingBootstrap, there won't be any problems. But after adding LatiosBakingBootstrap, running unity and entering my game scene, the above errors will be reported. Can you give me some guidance? I just I started studying dots, but my proficiency is not high.

Dreaming381 commented 9 months ago

I'm sorry. I think I know what your issue might be.

From your screenshots, it appears you have Unity Physics installed. If you simply installed the Latios Framework and created the Standard - Injection Workflow bootstrap, you unfortunately created an incompatibility. Usually the Kinemation renderer is the first to catch this, but (assuming I am right about this) it appears that wasn't the case for you.

My guess is that you are missing the LATIOS_TRANSFORMS_UNITY scripting define. If you intend to use QVVS Transforms, you cannot use Unity Physics without modifying the package.