vendredi 22 juillet 2022

How can I solve the problem of script blocking?

I want to give users the ability to customize the behavior of game objects, but I found that unity is actually a single threaded program. If the user writes a script with circular statements in the game object, the main thread of unity will block, just like the game is stuck. How to make the update function of object seem to be executed on a separate thread?

De facto execution order

The logical execution sequence I want to implement

Aucun commentaire:

Enregistrer un commentaire