From fd18ce3d5488606c17ba40bc4c8dfd096741d52c Mon Sep 17 00:00:00 2001 From: AnidemDex Date: Sat, 27 Nov 2021 12:16:04 -0500 Subject: [PATCH] Add choice inspector plugin. This will help modifying choices in the inspector. --- .../events/dialog/choice_inspector.gd | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 addons/textalog/events/dialog/choice_inspector.gd diff --git a/addons/textalog/events/dialog/choice_inspector.gd b/addons/textalog/events/dialog/choice_inspector.gd new file mode 100644 index 00000000..feee29fb --- /dev/null +++ b/addons/textalog/events/dialog/choice_inspector.gd @@ -0,0 +1,20 @@ +extends EditorInspectorPlugin + +const InspectorTools = preload("res://addons/textalog/core/inspector_tools.gd") + +var plugin_script:EditorPlugin +var editor_inspector:EditorInspector +var editor_gui:Control + +var ObjClass = load("res://addons/textalog/events/dialog/choice.gd") + +func can_handle(object: Object) -> bool: + return object is ObjClass + +func parse_category(object: Object, category: String) -> void: + if not editor_inspector.has_method("get_category_instance"): + return + + +func parse_property(object: Object, type: int, path: String, hint: int, hint_text: String, usage: int) -> bool: + return false