I am new to Playcanvas and was wondering if it’s possible to run a script without pressing launch?
I am trying to generate entities in code (over 4000) without having to place them manually. But I do not want this to run every time I launch the game.
Even if I could copy from the hierarchy while running or even get the json data of the hierarchy while running could work and then I just import that.
Is there any new state regarding the possibility to run script inside Editor (without Launching) ?
I probably missed somthing but I do not understand the use of sliders in Editor UI when using customr script if I cannot run the script inside Editor. I’ve noticed I can use these sliders to change something that happens in Launch window, but then I can’t tune anything related to Editor.
My typical use case is : I’m trying to make a small editor script to enable artists to tune clearcoat values for material, as these parameters are not yet exposed in standard Editr UI. Is there any other way to achieve this ?
The sliders are more to bound the range of values you can give an attribute rather than directly affecting something in the Editor.
A Live Debugger (so you can see and editor the live game in the Editor (explore the hierarchy etc) and Editor API are pretty high on todo list. I can’t give a date just yet though.
It is possible to write Chrome Extensions or inject JS that work with the Editor now, but it’s not official and the hooks can change. @Leonidas has done this a few times with his custom tools.
Yes exactly, that returns an editor item which is an object responsible for serializing the entities. Right now as you correctly found out it doesn’t contain any references to clear coat mats, since this isn’t implemented in editor.
Accessing the entity on runtime is different, there you are running an instance of the Playcanvas engine (pc.App) which has been updated and it includes the clear coat material code.