0 votes

I have created a plugin and there are some resources I'm trying to export which will be putting in a group

what I have tried (example):
in a_resource.gd

extends Resource

const A_resource = preload("res://a_resource.gd") 
# This is used for other things in my script

func _get_property_list() -> Array:
    return [
            hint_string="A_resource" # or "res://a_resource.gd"

in plugin.gd

extends EditorPlugin

const A_resource = preload("res://a_resource.gd") 

func _enter_tree():
    var none_texture = StreamTexture.new()
    add_custom_type('A_resource', 'Resource', A_resource, none_texture)

func _exit_tree():

It seems to be working, but actually, it's outputting an error and the resource will be showing up no matter what resource you are exporting.

Godot version 3.4.2.stable
in Engine by (79 points)
edited by

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.