Search Unity

Bug (IN-33047) [1.0.0-pre.44] IL2CPP build not working

Discussion in 'Graphics for ECS' started by optimise, Feb 22, 2023.

  1. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    2,129
    When build IL2CPP runtime player build. Entity is not render properly and show nothing but Mono build is working fine.
     
  2. JussiKnuuttila

    JussiKnuuttila

    Unity Technologies

    Joined:
    Jun 7, 2019
    Posts:
    351
    Do you have error messages in the log? As a workaround, you can try whether setting "Managed Stripping Level" to "Disabled" in your Player settings helps, it has been known to help in some IL2CPP related issues.
     
  3. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    2,129
    The error message refers to Unity.Rendering.LODWorldReferencePoint component. And also sadly setting "Managed Stripping Level" to "Disabled" is not available at IL2CPP.

    ArgumentException: Cannot find TypeIndex for type hash 4459803065892484956. Check in the debug file ExportedTypes.log of your project Logs folder (<projectName>/Logs) the corresponding Component type name for the type hash 4459803065892484956. And ensure your runtime depends on all assemblies defining the Component types your data uses.
     
  4. JussiKnuuttila

    JussiKnuuttila

    Unity Technologies

    Joined:
    Jun 7, 2019
    Posts:
    351
    It's still worth trying to set it to the lowest allowed level to see if it helps.
     
  5. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    2,129
    Setting "Managed Stripping Level" to "Minimal" is still not working.
     
  6. JussiKnuuttila

    JussiKnuuttila

    Unity Technologies

    Joined:
    Jun 7, 2019
    Posts:
    351
    I can confirm that this is a known issue and that a fix is being worked on.
     
    Occuros and optimise like this.
  7. Occuros

    Occuros

    Joined:
    Sep 4, 2018
    Posts:
    300
    You might be able to work around it by creating a system which references it through the type manger (it worked for me with the culling system).
    Code (CSharp):
    1.  
    2.     public partial class PreventStrippingSystem : SystemBase
    3.     {
    4.         protected override void OnCreate()
    5.         {
    6.             base.OnCreate();
    7.             Debug.Log(
    8.                 $"Typemanager: {TypeManager.GetTypeInfo<Unity.Rendering.PerInstanceCullingTag>().StableTypeHash}");
    9.         }
    10.