Changing to ShaderMaterial via gdscript

Godot Version

4.2 Stable


There is a drop down option in the inspector panel next to the material to convert StandardMaterial3D to ShaderMaterial is this possible via gdscript?

Trying to find the answer too.
Found that the conversion is down by using plugins named XXXConversionPlugin inherited from EditorResourceConversionPlugin (read in material_editor_plugin.h/.cpp)
Iā€™m not sure whether there is a way to call it from GDScript.
Here is the official doc of the class below.
EditorResourceConversionPlugin ā€” Godot Engine (stable) documentation in English

1 Like