diff --git a/.gitattributes b/.gitattributes
new file mode 100644
index 0000000..8ad74f7
--- /dev/null
+++ b/.gitattributes
@@ -0,0 +1,2 @@
+# Normalize EOL for all files that Git considers text files.
+* text=auto eol=lf
diff --git a/.github/workflows/godot-ci.yml b/.github/workflows/godot-ci.yml
deleted file mode 100644
index db367b7..0000000
--- a/.github/workflows/godot-ci.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-name: "godot-ci export"
-on: push
-
-env:
- GODOT_VERSION: mono-3.5.1
- EXPORT_NAME: RPG-Test
-
-jobs:
- export-windows:
- name: Windows Export
- runs-on: ubuntu-20.04
- container:
- image: barichello/godot-ci:mono-3.5.1
- steps:
- - name: Checkout
- uses: actions/checkout@v2
- with:
- lfs: true
- - name: Setup
- run: |
- mkdir -v -p ~/.local/share/godot/templates
- mv /root/.local/share/godot/templates/${GODOT_VERSION}.stable ~/.local/share/godot/templates/${GODOT_VERSION}.stable
- - name: Windows Build
- run: |
- mkdir -v -p build/windows
- cd $EXPORT_NAME
- godot -v --export "Windows Desktop" ../build/windows/$EXPORT_NAME.exe
- - name: Upload Artifact
- uses: actions/upload-artifact@v1
- with:
- name: windows
- path: build/windows
diff --git a/.gitignore b/.gitignore
index b82808f..fba49c1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,12 +1,4 @@
-
-# Godot-specific ignores
-.import/
-export.cfg
-export_presets.cfg
-
-# Mono-specific ignores
-.mono/
-data_*/
-
+# Godot 4+ specific ignores
+.godot/
#custom
.vs/
diff --git a/RPG Test gd4.csproj b/RPG Test gd4.csproj
new file mode 100644
index 0000000..870b6b9
--- /dev/null
+++ b/RPG Test gd4.csproj
@@ -0,0 +1,7 @@
+
+
+ net6.0
+ true
+ RPGTestgd4
+
+
\ No newline at end of file
diff --git a/RPG-Test.sln b/RPG Test gd4.sln
similarity index 51%
rename from RPG-Test.sln
rename to RPG Test gd4.sln
index f9c1d4d..3927e25 100644
--- a/RPG-Test.sln
+++ b/RPG Test gd4.sln
@@ -1,6 +1,6 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RPG-Test", "RPG-Test.csproj", "{03530658-9683-4AB8-AC24-354105EBCCDD}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RPG Test gd4", "RPG Test gd4.csproj", "{27424726-AFC3-4E97-8F36-EB38E4D2768D}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -9,11 +9,11 @@ Global
ExportRelease|Any CPU = ExportRelease|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {03530658-9683-4AB8-AC24-354105EBCCDD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {03530658-9683-4AB8-AC24-354105EBCCDD}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {03530658-9683-4AB8-AC24-354105EBCCDD}.ExportDebug|Any CPU.ActiveCfg = ExportDebug|Any CPU
- {03530658-9683-4AB8-AC24-354105EBCCDD}.ExportDebug|Any CPU.Build.0 = ExportDebug|Any CPU
- {03530658-9683-4AB8-AC24-354105EBCCDD}.ExportRelease|Any CPU.ActiveCfg = ExportRelease|Any CPU
- {03530658-9683-4AB8-AC24-354105EBCCDD}.ExportRelease|Any CPU.Build.0 = ExportRelease|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.ExportDebug|Any CPU.ActiveCfg = ExportDebug|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.ExportDebug|Any CPU.Build.0 = ExportDebug|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.ExportRelease|Any CPU.ActiveCfg = ExportRelease|Any CPU
+ {27424726-AFC3-4E97-8F36-EB38E4D2768D}.ExportRelease|Any CPU.Build.0 = ExportRelease|Any CPU
EndGlobalSection
EndGlobal
diff --git a/RPG-Test.csproj b/RPG-Test.csproj
deleted file mode 100644
index 33a08e3..0000000
--- a/RPG-Test.csproj
+++ /dev/null
@@ -1,6 +0,0 @@
-
-
- net472
- RPGTest
-
-
\ No newline at end of file
diff --git a/assets/textures/banana.png.import b/assets/textures/banana.png.import
deleted file mode 100644
index e858f4f..0000000
--- a/assets/textures/banana.png.import
+++ /dev/null
@@ -1,35 +0,0 @@
-[remap]
-
-importer="texture"
-type="StreamTexture"
-path="res://.import/banana.png-b266be96b0846753aedd2f84866d07bc.stex"
-metadata={
-"vram_texture": false
-}
-
-[deps]
-
-source_file="res://assets/textures/banana.png"
-dest_files=[ "res://.import/banana.png-b266be96b0846753aedd2f84866d07bc.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/assets/textures/cupcake.png.import b/assets/textures/cupcake.png.import
deleted file mode 100644
index 01c2bf9..0000000
--- a/assets/textures/cupcake.png.import
+++ /dev/null
@@ -1,35 +0,0 @@
-[remap]
-
-importer="texture"
-type="StreamTexture"
-path="res://.import/cupcake.png-93ee0951f9b3ff6300047d14826a099b.stex"
-metadata={
-"vram_texture": false
-}
-
-[deps]
-
-source_file="res://assets/textures/cupcake.png"
-dest_files=[ "res://.import/cupcake.png-93ee0951f9b3ff6300047d14826a099b.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/assets/textures/banana.png b/assets/textures/debug/banana.png
similarity index 100%
rename from assets/textures/banana.png
rename to assets/textures/debug/banana.png
diff --git a/assets/textures/debug/banana.png.import b/assets/textures/debug/banana.png.import
new file mode 100644
index 0000000..5e061d8
--- /dev/null
+++ b/assets/textures/debug/banana.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://ciidukjv5k6oa"
+path="res://.godot/imported/banana.png-50380ed0796f86b0b05039176725d8eb.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/debug/banana.png"
+dest_files=["res://.godot/imported/banana.png-50380ed0796f86b0b05039176725d8eb.ctex"]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/bptc_ldr=0
+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
diff --git a/assets/textures/cupcake.png b/assets/textures/debug/cupcake.png
similarity index 100%
rename from assets/textures/cupcake.png
rename to assets/textures/debug/cupcake.png
diff --git a/assets/textures/debug/cupcake.png.import b/assets/textures/debug/cupcake.png.import
new file mode 100644
index 0000000..56756b2
--- /dev/null
+++ b/assets/textures/debug/cupcake.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://p5ubildre2tg"
+path="res://.godot/imported/cupcake.png-e641a112586eeca5f723ee6aa32d7f28.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/debug/cupcake.png"
+dest_files=["res://.godot/imported/cupcake.png-e641a112586eeca5f723ee6aa32d7f28.ctex"]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/bptc_ldr=0
+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
diff --git a/assets/textures/debugitem_one64.png b/assets/textures/debug/debugitem_one64.png
similarity index 100%
rename from assets/textures/debugitem_one64.png
rename to assets/textures/debug/debugitem_one64.png
diff --git a/assets/textures/debug/debugitem_one64.png.import b/assets/textures/debug/debugitem_one64.png.import
new file mode 100644
index 0000000..cf5640a
--- /dev/null
+++ b/assets/textures/debug/debugitem_one64.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://diwxy1fl5m02y"
+path="res://.godot/imported/debugitem_one64.png-7941e59d1b01f784439647bcf9741e7c.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/debug/debugitem_one64.png"
+dest_files=["res://.godot/imported/debugitem_one64.png-7941e59d1b01f784439647bcf9741e7c.ctex"]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/bptc_ldr=0
+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
diff --git a/assets/textures/test_background_tileset.png b/assets/textures/debug/test_background_tileset.png
similarity index 100%
rename from assets/textures/test_background_tileset.png
rename to assets/textures/debug/test_background_tileset.png
diff --git a/assets/textures/debug/test_background_tileset.png.import b/assets/textures/debug/test_background_tileset.png.import
new file mode 100644
index 0000000..c1a91d7
--- /dev/null
+++ b/assets/textures/debug/test_background_tileset.png.import
@@ -0,0 +1,34 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://drlpbd1b7lthg"
+path="res://.godot/imported/test_background_tileset.png-a216d835e6ee8bee229573fc1a969d27.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://assets/textures/debug/test_background_tileset.png"
+dest_files=["res://.godot/imported/test_background_tileset.png-a216d835e6ee8bee229573fc1a969d27.ctex"]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/bptc_ldr=0
+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
diff --git a/assets/textures/debugitem_one64.png.import b/assets/textures/debugitem_one64.png.import
deleted file mode 100644
index 617ef45..0000000
--- a/assets/textures/debugitem_one64.png.import
+++ /dev/null
@@ -1,35 +0,0 @@
-[remap]
-
-importer="texture"
-type="StreamTexture"
-path="res://.import/debugitem_one64.png-1ec80dd262e8a6ed96484253d42fdc95.stex"
-metadata={
-"vram_texture": false
-}
-
-[deps]
-
-source_file="res://assets/textures/debugitem_one64.png"
-dest_files=[ "res://.import/debugitem_one64.png-1ec80dd262e8a6ed96484253d42fdc95.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/assets/textures/test_background_tileset.png.import b/assets/textures/test_background_tileset.png.import
deleted file mode 100644
index 4ae88c3..0000000
--- a/assets/textures/test_background_tileset.png.import
+++ /dev/null
@@ -1,35 +0,0 @@
-[remap]
-
-importer="texture"
-type="StreamTexture"
-path="res://.import/test_background_tileset.png-6a994978cefc6df9f5920903f59e7192.stex"
-metadata={
-"vram_texture": false
-}
-
-[deps]
-
-source_file="res://assets/textures/test_background_tileset.png"
-dest_files=[ "res://.import/test_background_tileset.png-6a994978cefc6df9f5920903f59e7192.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/default_env.tres b/default_env.tres
deleted file mode 100644
index 20207a4..0000000
--- a/default_env.tres
+++ /dev/null
@@ -1,7 +0,0 @@
-[gd_resource type="Environment" load_steps=2 format=2]
-
-[sub_resource type="ProceduralSky" id=1]
-
-[resource]
-background_mode = 2
-background_sky = SubResource( 1 )
diff --git a/icon.png b/icon.png
deleted file mode 100644
index c98fbb6..0000000
Binary files a/icon.png and /dev/null differ
diff --git a/icon.png.import b/icon.png.import
deleted file mode 100644
index a4c02e6..0000000
--- a/icon.png.import
+++ /dev/null
@@ -1,35 +0,0 @@
-[remap]
-
-importer="texture"
-type="StreamTexture"
-path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex"
-metadata={
-"vram_texture": false
-}
-
-[deps]
-
-source_file="res://icon.png"
-dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.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/icon.svg b/icon.svg
new file mode 100644
index 0000000..adc26df
--- /dev/null
+++ b/icon.svg
@@ -0,0 +1 @@
+
diff --git a/icon.svg.import b/icon.svg.import
new file mode 100644
index 0000000..237d253
--- /dev/null
+++ b/icon.svg.import
@@ -0,0 +1,37 @@
+[remap]
+
+importer="texture"
+type="CompressedTexture2D"
+uid="uid://c31svbjao0smt"
+path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"
+metadata={
+"vram_texture": false
+}
+
+[deps]
+
+source_file="res://icon.svg"
+dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"]
+
+[params]
+
+compress/mode=0
+compress/lossy_quality=0.7
+compress/hdr_compression=1
+compress/bptc_ldr=0
+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
diff --git a/project.godot b/project.godot
index 571297c..dcfe0a0 100644
--- a/project.godot
+++ b/project.godot
@@ -6,80 +6,42 @@
; [section] ; section goes between []
; param=value ; assign values to parameters
-config_version=4
+config_version=5
[application]
-config/name="RPG-Test"
-run/main_scene="res://scenes/maps/main.tscn"
-boot_splash/show_image=false
-boot_splash/bg_color=Color( 0.141176, 0.141176, 0.141176, 1 )
-config/icon="res://icon.png"
+config/name="RPG Test gd4"
+run/main_scene="res://scenes/main.tscn"
+config/features=PackedStringArray("4.0", "C#", "Forward Plus")
+config/icon="res://icon.svg"
-[display]
+[dotnet]
-window/size/height=640
-window/stretch/aspect="keep"
-
-[gui]
-
-common/drop_mouse_on_gui_input_disabled=true
+project/assembly_name="RPG Test gd4"
[input]
-fullscreen={
-"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777254,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
-, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":true,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777221,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
-}
move_left={
"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":65,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
+"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":65,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":-1.0,"script":null)
-, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":14,"pressure":0.0,"pressed":false,"script":null)
-, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777231,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
+]
}
move_right={
"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":68,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
+"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":68,"physical_keycode":0,"unicode":100,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":1.0,"script":null)
-, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":15,"pressure":0.0,"pressed":false,"script":null)
-, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777233,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
+]
}
move_up={
"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":87,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
+"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":87,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":-1.0,"script":null)
-, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":12,"pressure":0.0,"pressed":false,"script":null)
-, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777232,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
+]
}
move_down={
"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":83,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
+"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":83,"physical_keycode":0,"unicode":0,"echo":false,"script":null)
, Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":1.0,"script":null)
-, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":13,"pressure":0.0,"pressed":false,"script":null)
-, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777234,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
+]
}
-debug={
-"deadzone": 0.5,
-"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777246,"physical_scancode":0,"unicode":0,"echo":false,"script":null)
- ]
-}
-
-[mono]
-
-project/assembly_name="RPG-Test"
-
-[physics]
-
-common/enable_pause_aware_picking=true
-
-[rendering]
-
-2d/snapping/use_gpu_pixel_snap=true
-environment/default_environment="res://default_env.tres"
diff --git a/scenes/interactable_tiles/debug_tile_one.tscn b/scenes/interactable_tiles/debug_tile_one.tscn
deleted file mode 100644
index 1a6555c..0000000
--- a/scenes/interactable_tiles/debug_tile_one.tscn
+++ /dev/null
@@ -1,19 +0,0 @@
-[gd_scene load_steps=3 format=2]
-
-[ext_resource path="res://assets/textures/debugitem_one64.png" type="Texture" id=1]
-
-[sub_resource type="CircleShape2D" id=1]
-radius = 31.0
-
-[node name="debug_tile_one" type="Node2D"]
-
-[node name="RigidBody2D" type="RigidBody2D" parent="."]
-gravity_scale = 0.0
-
-[node name="Sprite" type="Sprite" parent="RigidBody2D"]
-texture = ExtResource( 1 )
-centered = false
-
-[node name="CollisionShape2D" type="CollisionShape2D" parent="RigidBody2D"]
-position = Vector2( 31, 34 )
-shape = SubResource( 1 )
diff --git a/scenes/main.tscn b/scenes/main.tscn
new file mode 100644
index 0000000..5199f62
--- /dev/null
+++ b/scenes/main.tscn
@@ -0,0 +1,10 @@
+[gd_scene load_steps=3 format=3 uid="uid://2867aayx0skw"]
+
+[ext_resource type="PackedScene" uid="uid://d4any5ht61f31" path="res://scenes/player.tscn" id="1_p5d84"]
+[ext_resource type="PackedScene" uid="uid://c2eoq4srb238n" path="res://scenes/worlds/first_world.tscn" id="2_x8nyb"]
+
+[node name="Main" type="Node2D"]
+
+[node name="first_world" parent="." instance=ExtResource("2_x8nyb")]
+
+[node name="player" parent="." instance=ExtResource("1_p5d84")]
diff --git a/scenes/maps/main.tscn b/scenes/maps/main.tscn
deleted file mode 100644
index d9e02e7..0000000
--- a/scenes/maps/main.tscn
+++ /dev/null
@@ -1,16 +0,0 @@
-[gd_scene load_steps=4 format=2]
-
-[ext_resource path="res://scenes/maps/tilemaps/world.tscn" type="PackedScene" id=1]
-[ext_resource path="res://scenes/player.tscn" type="PackedScene" id=2]
-[ext_resource path="res://src/main.cs" type="Script" id=3]
-
-[node name="Main" type="Node2D"]
-position = Vector2( 4, 0 )
-scale = Vector2( 1, 1.00619 )
-script = ExtResource( 3 )
-
-[node name="World" parent="." instance=ExtResource( 1 )]
-tile_data = PoolIntArray( -196612, 0, 0, -196611, 0, 1, -196610, 0, 1, -196609, 0, 1, -262144, 0, 1, -262143, 0, 1, -262142, 0, 1, -262141, 0, 2, -131076, 0, 65536, -131075, 0, 65537, -131074, 0, 131073, -131073, 0, 131073, -196608, 0, 131073, -196607, 0, 131073, -196606, 0, 65537, -196605, 0, 65538, -65540, 0, 65536, -65539, 0, 65538, -131070, 0, 65536, -131069, 0, 65538, -4, 0, 65536, -3, 0, 65537, -2, 0, 1, -1, 0, 1, -65536, 0, 1, -65535, 0, 1, -65534, 0, 65537, -65533, 0, 65538, 65532, 0, 65536, 65533, 0, 65537, 65534, 0, 65537, 65535, 0, 65537, 0, 0, 65537, 1, 0, 65537, 2, 0, 65537, 3, 0, 65538, 131068, 0, 65536, 131069, 0, 65537, 131070, 0, 65537, 131071, 0, 65537, 65536, 0, 65537, 65537, 0, 65537, 65538, 0, 65537, 65539, 0, 65538, 196604, 0, 131072, 196605, 0, 131073, 196606, 0, 131073, 196607, 0, 131073, 131072, 0, 131073, 131073, 0, 131073, 131074, 0, 131073, 131075, 0, 131074 )
-
-[node name="Player" parent="." instance=ExtResource( 2 )]
-speed = 600
diff --git a/scenes/maps/tilemaps/world.tscn b/scenes/maps/tilemaps/world.tscn
deleted file mode 100644
index 6b040f4..0000000
--- a/scenes/maps/tilemaps/world.tscn
+++ /dev/null
@@ -1,19 +0,0 @@
-[gd_scene load_steps=4 format=2]
-
-[ext_resource path="res://tilesets/Background.tres" type="TileSet" id=1]
-[ext_resource path="res://tilesets/foreground_test.tres" type="TileSet" id=2]
-[ext_resource path="res://src/tilemap_foreground.cs" type="Script" id=3]
-
-[node name="World" type="TileMap"]
-tile_set = ExtResource( 1 )
-cell_size = Vector2( 512, 512 )
-cell_quadrant_size = 128
-format = 1
-tile_data = PoolIntArray( -196612, 0, 0, -196611, 0, 1, -196610, 0, 1, -196609, 0, 1, -262144, 0, 1, -262143, 0, 1, -262142, 0, 1, -262141, 0, 2, -131076, 0, 65536, -131075, 0, 65537, -131074, 0, 131073, -131073, 0, 131073, -196608, 0, 131073, -196607, 0, 131073, -196606, 0, 65537, -196605, 0, 65538, -65540, 0, 65536, -65539, 0, 65538, -131070, 0, 65536, -131069, 0, 65538, -4, 0, 65536, -3, 0, 65537, -2, 0, 1, -1, 0, 1, -65536, 536870912, 1, -65535, 0, 1, -65534, 0, 65537, -65533, 0, 65538, 65532, 0, 65536, 65533, 0, 65537, 65534, 0, 65537, 65535, 0, 65537, 0, 0, 65537, 1, 0, 65537, 2, 0, 65537, 3, 0, 65538, 131068, 0, 65536, 131069, 0, 65537, 131070, 0, 65537, 131071, 0, 65537, 65536, 0, 65537, 65537, 0, 65537, 65538, 0, 65537, 65539, 0, 65538, 196604, 0, 131072, 196605, 0, 131073, 196606, 0, 131073, 196607, 0, 131073, 131072, 0, 131073, 131073, 0, 131073, 131074, 0, 131073, 131075, 0, 131074 )
-
-[node name="Foreground" type="TileMap" parent="."]
-tile_set = ExtResource( 2 )
-format = 1
-tile_data = PoolIntArray( -1900525, 1, 0, -1769494, 0, 0, -1769493, 0, 0, -1834990, 1, 0, -1834989, 1, 0, -1834986, 1, 0, -1834980, 1, 0, -1703959, 0, 0, -1703958, 0, 0, -1703957, 0, 0, -1703956, 0, 0, -1769454, 1, 0, -1769453, 1, 0, -1769452, 1, 0, -1769450, 1, 0, -1638426, 0, 0, -1638425, 0, 0, -1638424, 0, 0, -1638423, 0, 0, -1638420, 0, 0, -1703919, 1, 0, -1703918, 1, 0, -1703916, 1, 0, -1703915, 1, 0, -1703914, 1, 0, -1703909, 1, 0, -1572891, 0, 0, -1572890, 0, 0, -1572888, 0, 0, -1572884, 0, 0, -1638379, 1, 0, -1638373, 1, 0, -1507355, 0, 0, -1507349, 0, 0, -1507348, 0, 0, -1572843, 1, 0, -1572838, 1, 0, -1572837, 1, 0, -1441819, 0, 0, -1441814, 0, 0, -1441813, 0, 0, -1507302, 1, 0, -1376283, 0, 0, -1376282, 0, 0, -1376278, 0, 0, -1441789, 1, 0, -1441788, 1, 0, -1441787, 1, 0, -1441786, 1, 0, -1441785, 1, 0, -1441784, 1, 0, -1310746, 0, 0, -1310745, 0, 0, -1310743, 0, 0, -1310742, 0, 0, -1376251, 1, 0, -1376250, 1, 0, -1376249, 1, 0, -1245209, 0, 0, -1245208, 0, 0, -1245207, 0, 0, -1310715, 1, 0, -1310714, 1, 0, -1245179, 1, 0, -458775, 0, 0, -393239, 0, 0, -393235, 0, 0, -327708, 0, 0, -327707, 0, 0, -327700, 0, 0, -327699, 0, 0, -262168, 0, 0, -262167, 0, 0, -262165, 0, 0, -262164, 0, 0, -196633, 0, 0, -196632, 0, 0, -196631, 0, 0, -196615, 1, 0, -196614, 1, 0, -196611, 1, 0, -196610, 1, 0, -131097, 0, 0, -131096, 0, 0, -131095, 0, 0, -131094, 0, 0, -131079, 1, 0, -131078, 1, 0, -131075, 1, 0, -131074, 1, 0, -196595, 0, 0, -196586, 0, 0, -65561, 0, 0, -65560, 0, 0, -65559, 0, 0, -65558, 0, 0, -131059, 0, 0, -131056, 0, 0, -131055, 0, 0, -131050, 0, 0, -29, 0, 0, -28, 0, 0, -27, 0, 0, -20, 0, 0, -8, 1, 0, -1, 1, 0, -65524, 0, 0, -65520, 0, 0, 65507, 0, 0, 65511, 0, 0, 65516, 0, 0, 65517, 0, 0, 65528, 1, 0, 65529, 1, 0, 65534, 1, 0, 65535, 1, 0, 12, 0, 0, 13, 0, 0, 14, 0, 0, 15, 0, 0, 16, 0, 0, 21, 0, 0, 131047, 0, 0, 131048, 0, 0, 131053, 0, 0, 131065, 1, 0, 131066, 1, 0, 131067, 1, 0, 131068, 1, 0, 131069, 1, 0, 131070, 1, 0, 65547, 0, 0, 65548, 0, 0, 65550, 0, 0, 65551, 0, 0, 65557, 0, 0, 131083, 0, 0, 131085, 0, 0, 131092, 0, 0, 262141, 1, 0, 262142, 1, 0, 262143, 1, 0, 196608, 1, 0, 196609, 1, 0, 196610, 1, 0, 196627, 0, 0, 196628, 0, 0, 327676, 1, 0, 327677, 1, 0, 327678, 0, 0, 327679, 0, 0, 262144, 0, 0, 262145, 0, 0, 262146, 1, 0, 262147, 1, 0, 393193, 0, 0, 393194, 0, 0, 393212, 1, 0, 393213, 1, 0, 393214, 0, 0, 327680, 0, 0, 327681, 0, 0, 327682, 0, 0, 327683, 1, 0, 327684, 1, 0, 458729, 0, 0, 458730, 0, 0, 458734, 0, 0, 458735, 0, 0, 458736, 0, 0, 458749, 1, 0, 458750, 0, 0, 458751, 0, 0, 393216, 0, 0, 393217, 0, 0, 393218, 0, 0, 393220, 1, 0, 524265, 0, 0, 524266, 0, 0, 524269, 0, 0, 524270, 0, 0, 524271, 0, 0, 524272, 0, 0, 524273, 0, 0, 524285, 1, 0, 524286, 0, 0, 524287, 1, 0, 458752, 1, 0, 458753, 0, 0, 458754, 0, 0, 458756, 1, 0, 589805, 0, 0, 589806, 0, 0, 589807, 0, 0, 589808, 0, 0, 589809, 0, 0, 589821, 1, 0, 589822, 0, 0, 589823, 1, 0, 524288, 1, 0, 524289, 0, 0, 524292, 1, 0, 655342, 0, 0, 655343, 0, 0, 655344, 0, 0, 655357, 1, 0, 655358, 1, 0, 655359, 1, 0, 589824, 1, 0, 589825, 1, 0, 589827, 1, 0, 655360, 1, 0, 655361, 1, 0, 655362, 1, 0, 655363, 1, 0, 786408, 0, 0, 851943, 0, 0, 851944, 0, 0, 851951, 0, 0, 851952, 0, 0, 851962, 1, 0, 917478, 0, 0, 917479, 0, 0, 917480, 0, 0, 917486, 0, 0, 917487, 0, 0, 917488, 0, 0, 917500, 1, 0, 851983, 0, 0, 851984, 0, 0, 851985, 0, 0, 851986, 0, 0, 851987, 0, 0, 851988, 0, 0, 851989, 0, 0, 851990, 0, 0, 851991, 0, 0, 851992, 0, 0, 851993, 0, 0, 851994, 0, 0, 983015, 0, 0, 983016, 0, 0, 983017, 0, 0, 983018, 0, 0, 983019, 0, 0, 983020, 0, 0, 983021, 0, 0, 983022, 0, 0, 917518, 0, 0, 917521, 0, 0, 917522, 0, 0, 917524, 0, 0, 917525, 0, 0, 917527, 0, 0, 917528, 0, 0, 917530, 0, 0, 1048552, 0, 0, 1048553, 0, 0, 1048554, 0, 0, 1048555, 0, 0, 983047, 0, 0, 983048, 0, 0, 983049, 0, 0, 983050, 0, 0, 983051, 0, 0, 983052, 0, 0, 983053, 0, 0, 983054, 0, 0, 983055, 0, 0, 983056, 0, 0, 983057, 0, 0, 983058, 0, 0, 983060, 0, 0, 983061, 0, 0, 983063, 0, 0, 983064, 0, 0, 983065, 0, 0, 983066, 0, 0, 983067, 0, 0, 1048582, 0, 0, 1048583, 0, 0, 1048584, 0, 0, 1048585, 0, 0, 1048586, 0, 0, 1048587, 0, 0, 1048588, 0, 0, 1048590, 0, 0, 1048592, 0, 0, 1048593, 0, 0, 1048594, 0, 0, 1048599, 0, 0, 1048600, 0, 0, 1048601, 0, 0, 1048602, 0, 0, 1048603, 0, 0, 1114117, 0, 0, 1114118, 0, 0, 1114120, 0, 0, 1114121, 0, 0, 1114122, 0, 0, 1114123, 0, 0, 1114124, 0, 0, 1114126, 0, 0, 1114127, 0, 0, 1179656, 0, 0, 1179657, 0, 0, 1179658, 0, 0, 1179659, 0, 0, 1179660, 0, 0 )
-script = ExtResource( 3 )
-array2D = PoolIntArray( )
diff --git a/scenes/player.tscn b/scenes/player.tscn
index f7a70a5..5765519 100644
--- a/scenes/player.tscn
+++ b/scenes/player.tscn
@@ -1,28 +1,28 @@
-[gd_scene load_steps=5 format=2]
+[gd_scene load_steps=5 format=3 uid="uid://d4any5ht61f31"]
-[ext_resource path="res://assets/textures/banana.png" type="Texture" id=1]
-[ext_resource path="res://src/player.cs" type="Script" id=2]
+[ext_resource type="Script" path="res://src/player.cs" id="1_qehox"]
+[ext_resource type="Texture2D" uid="uid://ciidukjv5k6oa" path="res://assets/textures/debug/banana.png" id="2_1l1co"]
-[sub_resource type="SpriteFrames" id=1]
-animations = [ {
-"frames": [ ExtResource( 1 ) ],
+[sub_resource type="SpriteFrames" id="SpriteFrames_2x1cy"]
+animations = [{
+"frames": [ExtResource("2_1l1co")],
"loop": true,
-"name": "default",
+"name": &"default",
"speed": 5.0
-} ]
+}]
-[sub_resource type="RectangleShape2D" id=2]
-extents = Vector2( 19, 29 )
+[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_38v5o"]
+radius = 21.0
+height = 66.0
-[node name="Player" type="KinematicBody2D"]
-script = ExtResource( 2 )
+[node name="player" type="CharacterBody2D"]
+script = ExtResource("1_qehox")
-[node name="AnimatedSprite" type="AnimatedSprite" parent="."]
-frames = SubResource( 1 )
+[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
+frames = SubResource("SpriteFrames_2x1cy")
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
-position = Vector2( 0, 2 )
-shape = SubResource( 2 )
+shape = SubResource("CapsuleShape2D_38v5o")
[node name="Camera2D" type="Camera2D" parent="."]
current = true
diff --git a/scenes/tiles/first_debug_tile.tscn b/scenes/tiles/first_debug_tile.tscn
new file mode 100644
index 0000000..92d7572
--- /dev/null
+++ b/scenes/tiles/first_debug_tile.tscn
@@ -0,0 +1,16 @@
+[gd_scene load_steps=3 format=3 uid="uid://dk7fqaw2b3w1k"]
+
+[ext_resource type="Texture2D" uid="uid://diwxy1fl5m02y" path="res://assets/textures/debug/debugitem_one64.png" id="1_2m632"]
+
+[sub_resource type="CircleShape2D" id="CircleShape2D_2d5dy"]
+radius = 30.8058
+
+[node name="first_debug_tile" type="RigidBody2D"]
+gravity_scale = 0.0
+
+[node name="Sprite2D" type="Sprite2D" parent="."]
+texture = ExtResource("1_2m632")
+
+[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
+position = Vector2(-1, 4)
+shape = SubResource("CircleShape2D_2d5dy")
diff --git a/scenes/worlds/first_world.tscn b/scenes/worlds/first_world.tscn
new file mode 100644
index 0000000..248baf2
--- /dev/null
+++ b/scenes/worlds/first_world.tscn
@@ -0,0 +1,18 @@
+[gd_scene load_steps=3 format=3 uid="uid://c2eoq4srb238n"]
+
+[ext_resource type="TileSet" uid="uid://bduttqwwbt6lq" path="res://tiilesets/main_background.tres" id="1_71wsi"]
+[ext_resource type="TileSet" uid="uid://txl24cadn8t4" path="res://tiilesets/main_foreground.tres" id="2_v3ju2"]
+
+[node name="first_world" type="Node2D"]
+
+[node name="background" type="TileMap" parent="."]
+tile_set = ExtResource("1_71wsi")
+format = 2
+layer_0/tile_data = PackedInt32Array(-65535, 65536, 1, -131071, 65536, 0, -65536, 65536, 1, -131072, 65536, 0, -1, 65536, 1, -65537, 65536, 0, 3, 131072, 2, -65533, 131072, 1, -131069, 131072, 0, 2, 65536, 2, -65534, 65536, 1, -131070, 65536, 0, 1, 65536, 2, 0, 65536, 2, 65535, 65536, 2, 65534, 0, 2, -2, 0, 1, -65538, 0, 0)
+
+[node name="foreground" type="TileMap" parent="."]
+tile_set = ExtResource("2_v3ju2")
+cell_quadrant_size = 64
+format = 2
+layer_0/z_index = 1
+layer_0/tile_data = PackedInt32Array(65535, 0, 0, 0, 0, 0, 1, 0, 0, 65534, 0, 0, 65533, 0, 0, -3, 0, 0, -2, 0, 0, -1, 0, 0, -65536, 0, 0, -65535, 0, 0)
diff --git a/src/main.cs b/src/main.cs
deleted file mode 100644
index ae51455..0000000
--- a/src/main.cs
+++ /dev/null
@@ -1,19 +0,0 @@
-using Godot;
-using System;
-
-public class main : Node2D
-{
-
- public override void _Ready()
- {
-
- }
-
- public override void _Process(float delta)
- {
- if (Input.IsActionJustReleased("fullscreen"))
- {
- OS.WindowFullscreen = !OS.WindowFullscreen;
- }
- }
-}
diff --git a/src/player.cs b/src/player.cs
index eb071c8..184b22e 100644
--- a/src/player.cs
+++ b/src/player.cs
@@ -1,45 +1,26 @@
using Godot;
using System;
-
-public class player : KinematicBody2D
+public partial class player : CharacterBody2D
{
- [Export]
- public int speed = 400;
+ [Export]
+ public int speed = 400;
+ // Called when the node enters the scene tree for the first time.
+ public override void _Ready()
+ {
- public override void _PhysicsProcess(float delta)
- {
+ }
+
+ // Called every frame. 'delta' is the elapsed time since the previous frame.
+ public override void _PhysicsProcess(double delta)
+ {
MoveAndCollide(new Vector2
(
- Input.GetActionStrength("move_right")
- - Input.GetActionStrength("move_left"),
- Input.GetActionStrength("move_down")
+ Input.GetActionStrength("move_right")
+ - Input.GetActionStrength("move_left"),
+ Input.GetActionStrength("move_down")
- Input.GetActionStrength("move_up")
- ).LimitLength(1)
- * speed * delta
+ ).LimitLength(1)
+ * speed * (float)delta
);
}
-
- public override void _Process(float delta)
- {
- //debug the grid
- int currentCellID = 1;
- var tilemap = GetNode("/root/Main/World/Foreground");
- Vector2 coordinates = tilemap.WorldToMap(Position);
- if (Input.IsActionJustReleased("debug"))
- {
- GD.Print("All Number 1 tiles: " + tilemap.GetUsedCellsById(1));
- GD.Print("Player coordinate: " + coordinates);
- }
- if (Input.IsKeyPressed((int)KeyList.F1))
- {
- tilemap.SetCell((int)coordinates.x, (int)coordinates.y, -1);
- }
- if (Input.IsKeyPressed((int)KeyList.F2))
- {
- if(tilemap.GetCell((int)coordinates.x, (int)coordinates.y) == -1)
- {
- tilemap.SetCell((int)coordinates.x, (int)coordinates.y, currentCellID); //place offset coordinates += offset = build coordinates
- }
- }
- }
}
diff --git a/src/tilemap_foreground.cs b/src/tilemap_foreground.cs
deleted file mode 100644
index 686faa7..0000000
--- a/src/tilemap_foreground.cs
+++ /dev/null
@@ -1,27 +0,0 @@
-using Godot;
-using System;
-using System.Linq;
-
-public class tilemap_foreground : TileMap
-{
- public override void _Process(float delta)
- {
- ReplaceStaticTiles(1, "debug_tile_one");
- }
-
- public void ReplaceStaticTiles(int CellID, string sceneName)
- {
- Vector2[] allCells = GetUsedCellsById(CellID).OfType().ToArray();
- for(int i = 0; i < allCells.Length; i++)
- {
- GD.Print(allCells[i]);
- SetCell((int)allCells[i].x, (int)allCells[i].y, -1);
- var scene = GD.Load("res://scenes/interactable_tiles/" + sceneName + ".tscn");
- var instance = scene.Instance();
- AddChild(instance);
- var node = GetNode(instance.GetPath());
- node.Position = allCells[i] * CellSize; //node has to be Node2D and can't be centered
- GD.Print(node);
- }
- }
-}
diff --git a/tiilesets/main_background.tres b/tiilesets/main_background.tres
new file mode 100644
index 0000000..6601476
--- /dev/null
+++ b/tiilesets/main_background.tres
@@ -0,0 +1,81 @@
+[gd_resource type="TileSet" load_steps=3 format=3 uid="uid://bduttqwwbt6lq"]
+
+[ext_resource type="Texture2D" uid="uid://drlpbd1b7lthg" path="res://assets/textures/debug/test_background_tileset.png" id="1_l8p16"]
+
+[sub_resource type="TileSetAtlasSource" id="TileSetAtlasSource_mfja2"]
+texture = ExtResource("1_l8p16")
+texture_region_size = Vector2i(512, 512)
+0:0/0 = 0
+0:0/0/terrain_set = 0
+0:0/0/terrain = 0
+0:0/0/terrains_peering_bit/right_side = 0
+0:0/0/terrains_peering_bit/bottom_right_corner = 0
+0:0/0/terrains_peering_bit/bottom_side = 0
+1:0/0 = 0
+1:0/0/terrain_set = 0
+1:0/0/terrain = 0
+1:0/0/terrains_peering_bit/right_side = 0
+1:0/0/terrains_peering_bit/bottom_right_corner = 0
+1:0/0/terrains_peering_bit/bottom_side = 0
+1:0/0/terrains_peering_bit/bottom_left_corner = 0
+1:0/0/terrains_peering_bit/left_side = 0
+2:0/0 = 0
+2:0/0/terrain_set = 0
+2:0/0/terrain = 0
+2:0/0/terrains_peering_bit/bottom_side = 0
+2:0/0/terrains_peering_bit/bottom_left_corner = 0
+2:0/0/terrains_peering_bit/left_side = 0
+0:1/0 = 0
+0:1/0/terrain_set = 0
+0:1/0/terrain = 0
+0:1/0/terrains_peering_bit/right_side = 0
+0:1/0/terrains_peering_bit/bottom_right_corner = 0
+0:1/0/terrains_peering_bit/bottom_side = 0
+0:1/0/terrains_peering_bit/top_side = 0
+0:1/0/terrains_peering_bit/top_right_corner = 0
+1:1/0 = 0
+1:1/0/terrain_set = 0
+1:1/0/terrain = 0
+1:1/0/terrains_peering_bit/right_side = 0
+1:1/0/terrains_peering_bit/bottom_right_corner = 0
+1:1/0/terrains_peering_bit/bottom_side = 0
+1:1/0/terrains_peering_bit/bottom_left_corner = 0
+1:1/0/terrains_peering_bit/left_side = 0
+1:1/0/terrains_peering_bit/top_left_corner = 0
+1:1/0/terrains_peering_bit/top_side = 0
+1:1/0/terrains_peering_bit/top_right_corner = 0
+2:1/0 = 0
+2:1/0/terrain_set = 0
+2:1/0/terrain = 0
+2:1/0/terrains_peering_bit/bottom_side = 0
+2:1/0/terrains_peering_bit/bottom_left_corner = 0
+2:1/0/terrains_peering_bit/left_side = 0
+2:1/0/terrains_peering_bit/top_left_corner = 0
+2:1/0/terrains_peering_bit/top_side = 0
+0:2/0 = 0
+0:2/0/terrain_set = 0
+0:2/0/terrain = 0
+0:2/0/terrains_peering_bit/right_side = 0
+0:2/0/terrains_peering_bit/top_side = 0
+0:2/0/terrains_peering_bit/top_right_corner = 0
+1:2/0 = 0
+1:2/0/terrain_set = 0
+1:2/0/terrain = 0
+1:2/0/terrains_peering_bit/right_side = 0
+1:2/0/terrains_peering_bit/left_side = 0
+1:2/0/terrains_peering_bit/top_left_corner = 0
+1:2/0/terrains_peering_bit/top_side = 0
+1:2/0/terrains_peering_bit/top_right_corner = 0
+2:2/0 = 0
+2:2/0/terrain_set = 0
+2:2/0/terrain = 0
+2:2/0/terrains_peering_bit/left_side = 0
+2:2/0/terrains_peering_bit/top_left_corner = 0
+2:2/0/terrains_peering_bit/top_side = 0
+
+[resource]
+tile_size = Vector2i(512, 512)
+terrain_set_0/mode = 0
+terrain_set_0/terrain_0/name = "Grass"
+terrain_set_0/terrain_0/color = Color(0, 0.509804, 0, 1)
+sources/0 = SubResource("TileSetAtlasSource_mfja2")
diff --git a/tiilesets/main_foreground.tres b/tiilesets/main_foreground.tres
new file mode 100644
index 0000000..1ef0b41
--- /dev/null
+++ b/tiilesets/main_foreground.tres
@@ -0,0 +1,11 @@
+[gd_resource type="TileSet" load_steps=3 format=3 uid="uid://txl24cadn8t4"]
+
+[ext_resource type="PackedScene" uid="uid://dk7fqaw2b3w1k" path="res://scenes/tiles/first_debug_tile.tscn" id="1_uxmn6"]
+
+[sub_resource type="TileSetScenesCollectionSource" id="TileSetScenesCollectionSource_h5u31"]
+resource_name = "test"
+scenes/0/scene = ExtResource("1_uxmn6")
+
+[resource]
+tile_size = Vector2i(64, 64)
+sources/0 = SubResource("TileSetScenesCollectionSource_h5u31")
diff --git a/tilesets/background.tres b/tilesets/background.tres
deleted file mode 100644
index 9c446cf..0000000
--- a/tilesets/background.tres
+++ /dev/null
@@ -1,137 +0,0 @@
-[gd_resource type="TileSet" load_steps=14 format=2]
-
-[ext_resource path="res://assets/textures/test_background_tileset.png" type="Texture" id=1]
-
-[sub_resource type="ConvexPolygonShape2D" id=1]
-points = PoolVector2Array( 512, 512, 448, 512, 448, 0, 512, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=3]
-points = PoolVector2Array( 512, 64, 0, 64, 0, 0, 512, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=4]
-points = PoolVector2Array( 512, 64, 0, 64, 0, 0, 512, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=6]
-points = PoolVector2Array( 0, 0, 64, 0, 64, 512, 0, 512 )
-
-[sub_resource type="ConvexPolygonShape2D" id=7]
-points = PoolVector2Array( 64, 512, 0, 512, 0, 0, 64, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=8]
-points = PoolVector2Array( 512, 512, 0, 512, 0, 448, 512, 448 )
-
-[sub_resource type="ConvexPolygonShape2D" id=10]
-points = PoolVector2Array( 0, 448, 512, 448, 512, 512, 0, 512 )
-
-[sub_resource type="ConvexPolygonShape2D" id=12]
-points = PoolVector2Array( 512, 512, 0, 512, 0, 448, 512, 448 )
-
-[sub_resource type="ConvexPolygonShape2D" id=13]
-points = PoolVector2Array( 512, 512, 448, 512, 448, 64, 512, 64 )
-
-[sub_resource type="ConvexPolygonShape2D" id=14]
-points = PoolVector2Array( 512, 64, 64, 64, 64, 0, 512, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=15]
-points = PoolVector2Array( 64, 448, 0, 448, 0, 0, 64, 0 )
-
-[sub_resource type="ConvexPolygonShape2D" id=16]
-points = PoolVector2Array( 512, 448, 448, 448, 448, 0, 512, 0 )
-
-[resource]
-0/name = "test_background_tileset.png 0"
-0/texture = ExtResource( 1 )
-0/tex_offset = Vector2( 0, 0 )
-0/modulate = Color( 1, 1, 1, 1 )
-0/region = Rect2( 0, 0, 1536, 1536 )
-0/tile_mode = 1
-0/autotile/bitmask_mode = 0
-0/autotile/bitmask_flags = [ Vector2( 0, 0 ), 256, Vector2( 0, 1 ), 260, Vector2( 0, 2 ), 4, Vector2( 1, 0 ), 320, Vector2( 1, 1 ), 325, Vector2( 1, 2 ), 5, Vector2( 2, 0 ), 64, Vector2( 2, 1 ), 65, Vector2( 2, 2 ), 1 ]
-0/autotile/icon_coordinate = Vector2( 1, 1 )
-0/autotile/tile_size = Vector2( 512, 512 )
-0/autotile/spacing = 0
-0/autotile/occluder_map = [ ]
-0/autotile/navpoly_map = [ ]
-0/autotile/priority_map = [ Vector3( 0, 0, 9 ), Vector3( 0, 1, 6 ), Vector3( 0, 2, 3 ), Vector3( 1, 0, 8 ), Vector3( 1, 1, 5 ), Vector3( 1, 2, 2 ), Vector3( 2, 0, 7 ), Vector3( 2, 1, 4 ) ]
-0/autotile/z_index_map = [ ]
-0/occluder_offset = Vector2( 0, 0 )
-0/navigation_offset = Vector2( 0, 0 )
-0/shape_offset = Vector2( 0, 0 )
-0/shape_transform = Transform2D( 1, 0, 0, 1, 0, 0 )
-0/shape = SubResource( 1 )
-0/shape_one_way = false
-0/shape_one_way_margin = 1.0
-0/shapes = [ {
-"autotile_coord": Vector2( 2, 1 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 1 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 2, 0 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 3 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 1, 0 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 4 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 0, 0 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 6 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 0, 1 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 7 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 1, 2 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 8 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 0, 2 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 10 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 2, 2 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 12 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 2, 0 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 13 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 0, 0 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 14 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 0, 2 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 15 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-}, {
-"autotile_coord": Vector2( 2, 2 ),
-"one_way": false,
-"one_way_margin": 1.0,
-"shape": SubResource( 16 ),
-"shape_transform": Transform2D( 1, 0, 0, 1, 0, 0 )
-} ]
-0/z_index = 0
diff --git a/tilesets/foreground_test.tres b/tilesets/foreground_test.tres
deleted file mode 100644
index a4c3a30..0000000
--- a/tilesets/foreground_test.tres
+++ /dev/null
@@ -1,54 +0,0 @@
-[gd_resource type="TileSet" load_steps=7 format=2]
-
-[ext_resource path="res://assets/textures/cupcake.png" type="Texture" id=1]
-[ext_resource path="res://assets/textures/debugitem_one64.png" type="Texture" id=2]
-
-[sub_resource type="NavigationPolygon" id=1]
-vertices = PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 )
-polygons = [ PoolIntArray( 0, 1, 2, 3 ) ]
-outlines = [ PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 ) ]
-
-[sub_resource type="OccluderPolygon2D" id=2]
-polygon = PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 )
-
-[sub_resource type="NavigationPolygon" id=6]
-vertices = PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 )
-polygons = [ PoolIntArray( 0, 1, 2, 3 ) ]
-outlines = [ PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 ) ]
-
-[sub_resource type="OccluderPolygon2D" id=7]
-polygon = PoolVector2Array( 0, 0, 64, 0, 64, 64, 0, 64 )
-
-[resource]
-0/name = "cupcake.png 0"
-0/texture = ExtResource( 1 )
-0/tex_offset = Vector2( 0, 0 )
-0/modulate = Color( 1, 1, 1, 1 )
-0/region = Rect2( 0, 0, 64, 64 )
-0/tile_mode = 0
-0/occluder_offset = Vector2( 0, 0 )
-0/occluder = SubResource( 2 )
-0/navigation_offset = Vector2( 0, 0 )
-0/navigation = SubResource( 1 )
-0/shape_offset = Vector2( 0, 0 )
-0/shape_transform = Transform2D( 1, 0, 0, 1, 0, 0 )
-0/shape_one_way = false
-0/shape_one_way_margin = 0.0
-0/shapes = [ ]
-0/z_index = 0
-1/name = "debugitem_one64.png 1"
-1/texture = ExtResource( 2 )
-1/tex_offset = Vector2( 0, 0 )
-1/modulate = Color( 1, 1, 1, 1 )
-1/region = Rect2( 0, 0, 64, 64 )
-1/tile_mode = 0
-1/occluder_offset = Vector2( 0, 0 )
-1/occluder = SubResource( 7 )
-1/navigation_offset = Vector2( 0, 0 )
-1/navigation = SubResource( 6 )
-1/shape_offset = Vector2( 0, 0 )
-1/shape_transform = Transform2D( 1, 0, 0, 1, 0, 0 )
-1/shape_one_way = false
-1/shape_one_way_margin = 0.0
-1/shapes = [ ]
-1/z_index = 0