Answer the question
In order to leave comments, you need to log in
How to make a method execute button in the editor?
My room is, first of all, an empty prefab into which I then stuff other prefabs and visually arrange them where necessary, I see that the room is visually ready as I need, I need to use a method that will distill it all into a text file, in txt information takes up much less space than the level prefab itself, but not the point, the question is - how to make a button in the editor so that after pressing it, the method that runs the method of processing into a file works?
So far, I only have the option to put a bool field and after changing it, the function worked as an option, but can I somehow do it with a button?
Answer the question
In order to leave comments, you need to log in
What's the problem?
Bind the UI button to the method and click at runtime - everything should work
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question