I’m trying to access a script method from the editor.
The Terrain Generation script works great, but I don’t want to do it at runtime. Instead I want to run the generation once within the editor.
It it possible to access the instance of the
Terrain object from the editor?
I know I can access the component data with a call like
editor.call('entities:selectedFirst').apiEntity.get('components.script.scripts.terrain'), but I’m not wanting to manipulate the editor attributes directly. This doesn’t appear to be an instance of
This topic doesn’t seem to cover accessing the script in the editor as
entity.script isn’t set.
Thanks for any help.