Reply To: Some Errors on iL2CPP build

FlowCanvas Forums Support Some Errors on iL2CPP build Reply To: Some Errors on iL2CPP build

#2872
Gavalakis
Keymaster

Hello there,

When building for AOT platforms (like IL2CPP), you need to add all the types that you are using within the flowscript into the Preferred Types Editor and then generate the files (as you’ve already done). In your case, you need to add the type named “UnityEngine.SceneManagement.Scene” because it is a type that is used within your flowscript.

This information can be obtained by looking at the log wherever it says “Attempting to call method [….] for which no ahead of time (AOT) code was generated.” and then check the bold part as showcased bellow:

Attempting to call method ‘FlowCanvas.ValueOutput`1[[UnityEngine.SceneManagement.Scene, UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]::.ctor’ for which no ahead of time (AOT) code was generated.

The text in bold is the type that is missing from the Preferred Types and should be added before re-generatinng the AOT and XML files.

Please let me know if that works for you 🙂

Join us on Discord: https://discord.gg/97q2Rjh