From 9c7e06215b0f223f8ebb66472647b195a90e19cb Mon Sep 17 00:00:00 2001 From: Relintai Date: Tue, 23 Aug 2022 15:54:28 +0200 Subject: [PATCH] Added a blog plugin's skeleton. --- game/addons/web_blog/classes/WebBlog.gd | 16 +++++ .../addons/web_blog/editor/WebBlogEditor.tscn | 5 ++ game/addons/web_blog/icons/icon_web_blog.svg | 68 +++++++++++++++++++ .../web_blog/icons/icon_web_blog.svg.import | 35 ++++++++++ game/addons/web_blog/plugin.cfg | 10 +++ game/addons/web_blog/plugin.gd | 27 ++++++++ 6 files changed, 161 insertions(+) create mode 100644 game/addons/web_blog/classes/WebBlog.gd create mode 100644 game/addons/web_blog/editor/WebBlogEditor.tscn create mode 100644 game/addons/web_blog/icons/icon_web_blog.svg create mode 100644 game/addons/web_blog/icons/icon_web_blog.svg.import create mode 100644 game/addons/web_blog/plugin.cfg create mode 100644 game/addons/web_blog/plugin.gd diff --git a/game/addons/web_blog/classes/WebBlog.gd b/game/addons/web_blog/classes/WebBlog.gd new file mode 100644 index 0000000..1eccaec --- /dev/null +++ b/game/addons/web_blog/classes/WebBlog.gd @@ -0,0 +1,16 @@ +extends Node + + +# Declare member variables here. Examples: +# var a = 2 +# var b = "text" + + +# Called when the node enters the scene tree for the first time. +func _ready(): + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +#func _process(delta): +# pass diff --git a/game/addons/web_blog/editor/WebBlogEditor.tscn b/game/addons/web_blog/editor/WebBlogEditor.tscn new file mode 100644 index 0000000..00a6290 --- /dev/null +++ b/game/addons/web_blog/editor/WebBlogEditor.tscn @@ -0,0 +1,5 @@ +[gd_scene format=2] + +[node name="Control" type="Control"] +anchor_right = 1.0 +anchor_bottom = 1.0 diff --git a/game/addons/web_blog/icons/icon_web_blog.svg b/game/addons/web_blog/icons/icon_web_blog.svg new file mode 100644 index 0000000..1c0db0d --- /dev/null +++ b/game/addons/web_blog/icons/icon_web_blog.svg @@ -0,0 +1,68 @@ + + + + + + + + + + + + + diff --git a/game/addons/web_blog/icons/icon_web_blog.svg.import b/game/addons/web_blog/icons/icon_web_blog.svg.import new file mode 100644 index 0000000..be51519 --- /dev/null +++ b/game/addons/web_blog/icons/icon_web_blog.svg.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/icon_web_blog.svg-717b51dbe8e2412ad01ab3d85a2cfea9.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/web_blog/icons/icon_web_blog.svg" +dest_files=[ "res://.import/icon_web_blog.svg-717b51dbe8e2412ad01ab3d85a2cfea9.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=true +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/game/addons/web_blog/plugin.cfg b/game/addons/web_blog/plugin.cfg new file mode 100644 index 0000000..9e8518f --- /dev/null +++ b/game/addons/web_blog/plugin.cfg @@ -0,0 +1,10 @@ +[plugin] + +name="WebBlog" +description="" +author="Relintai" +version="1.0" +script="plugin.gd" + + + diff --git a/game/addons/web_blog/plugin.gd b/game/addons/web_blog/plugin.gd new file mode 100644 index 0000000..1fb1afd --- /dev/null +++ b/game/addons/web_blog/plugin.gd @@ -0,0 +1,27 @@ +tool +extends EditorPlugin + +var blog_icon : Texture = null + +#func _ready(): +# gallery_icon = ResourceLoader.load("res://addons/web_gallery/icons/icon_gallery.svg", ) + +func enable_plugin() ->void: + pass + +func disable_plugin() ->void: + pass + +func get_plugin_name() -> String: + return "WebBlogEditorPlugin" + +#func handles(object: Object) -> bool: +# return false + +#func has_main_screen() -> bool: +# return false + +#func make_visible(visible: bool) -> void: +# pass + +