Godot编辑器中添加DungeonRoomTemplate节点用于快速创建房间模板,完成房间门数据保存/读取操作
1 parent 1ec8e4e commit 2ac22a4931a7fd4c947b3ff53ee70776de58c6d2
@小李xl 小李xl authored on 19 Feb 2023
Showing 10 changed files
View
1
■■■■
DungeonShooting_Godot/addons/dungeonShooting_plugin/Map.svg 0 → 100644
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1676781886290" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2765" width="16" height="16" xmlns:xlink="http://www.w3.org/1999/xlink"><path d="M138.688 762.112l186.624 83.008V261.888L138.688 178.88v583.232z m524.736 66.048L400 959.168V960l-0.896-0.384-0.832 0.384-72.96-32.896v-0.32L64 810.688V64l296.64 131.84L624 65.28V64l1.28 0.64 0.832-0.448 41.6 19.2L960 213.376V960l-296.576-131.84zM624 148.608l-224 111.04v616.128l224-111.36V148.608z m74.688 613.504l186.624 83.008V261.888l-186.624-83.008v583.232z" fill="#1296db" p-id="2766"></path></svg>
View
38
DungeonShooting_Godot/addons/dungeonShooting_plugin/Map.svg.import 0 → 100644
[remap]
 
importer="texture"
type="CompressedTexture2D"
uid="uid://downmhbbm43yu"
path="res://.godot/imported/Map.svg-dcee5d8c5d80d0921a3de443b022f3d9.ctex"
metadata={
"vram_texture": false
}
 
[deps]
 
source_file="res://addons/dungeonShooting_plugin/Map.svg"
dest_files=["res://.godot/imported/Map.svg-dcee5d8c5d80d0921a3de443b022f3d9.ctex"]
 
[params]
 
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=false
editor/convert_colors_with_editor_theme=false
View
5
DungeonShooting_Godot/addons/dungeonShooting_plugin/Plugin.cs
_instance = this;
var script = GD.Load<Script>("res://src/framework/activity/ActivityObjectTemplate.cs");
var texture = GD.Load<Texture2D>("res://addons/dungeonShooting_plugin/ActivityObject.svg");
AddCustomType("ActivityObjectTemplate", "Node", script, texture);
 
var script2 = GD.Load<Script>("res://src/framework/map/DungeonRoomTemplate.cs");
var texture2 = GD.Load<Texture2D>("res://addons/dungeonShooting_plugin/Map.svg");
AddCustomType("DungeonRoomTemplate", "TileMap", script2, texture2);
dock = GD.Load<PackedScene>("res://addons/dungeonShooting_plugin/Automation.tscn").Instantiate<Control>();
AddControlToDock(DockSlot.LeftUr, dock);
}
 
public override void _ExitTree()
{
RemoveCustomType("ActivityObjectTemplate");
RemoveCustomType("DungeonRoomTemplate");
RemoveControlFromDocks(dock);
dock.Free();
}
 
View
DungeonShooting_Godot/resource/map/Room1.tscn
View
DungeonShooting_Godot/resource/map/Room2.tscn
View
DungeonShooting_Godot/resource/map/tiledata/TileMap.json 0 → 100644
View
DungeonShooting_Godot/resource/map/tiledata/TileMap2.json 0 → 100644
View
DungeonShooting_Godot/resource/theme/mainTheme.tres
View
DungeonShooting_Godot/src/framework/map/DoorAreaInfo.cs
View
DungeonShooting_Godot/src/framework/map/DungeonRoomTemplate.cs