From e323bead2ecee69c13cd26895042917985532916 Mon Sep 17 00:00:00 2001 From: Nathan Lovato Date: Tue, 4 Feb 2020 21:50:54 -0600 Subject: [PATCH] Remake the 2d/platformer demo from scratch This Godot project is a complete rewrite of the official Platformer 2D demo. This is part of a proposal to improve and harmonize the official demo projects. We want to: - Teach good programming practices with Godot. - Bring demos to a higher quality standard. - Unify the code in the demos. See the [open issue](https://github.com/godotengine/godot-demo-projects/issues/390) for more information. This new demo showcases features from the original, and works with Godot 3.2. Co-authored-by: Johnny Goss --- 2d/platformer/Stage.tscn | 268 --------------- 2d/platformer/TileSet.tres | 243 ------------- 2d/platformer/TilesetEdit.tscn | 324 ------------------ .../art/background/cloud_1.png} | Bin .../art/background/cloud_1.png.import} | 6 +- .../art/background/cloud_2.png} | Bin .../assets/art/background/cloud_2.png.import | 34 ++ .../art/background/cloud_3.png} | Bin .../assets/art/background/cloud_3.png.import | 34 ++ .../art/background/distant_platforms_1.png | Bin 0 -> 5203 bytes .../background/distant_platforms_1.png.import | 34 ++ .../art/background/distant_platforms_2.png | Bin 0 -> 5779 bytes .../background/distant_platforms_2.png.import | 34 ++ .../art/background/sky.png} | Bin .../art/background/sky.png.import} | 6 +- 2d/platformer/{ => assets/art}/coin/coin.png | Bin .../{ => assets/art}/coin/coin.png.import | 6 +- .../{ => assets/art}/enemy/enemy.png | Bin .../{ => assets/art}/enemy/enemy.png.import | 6 +- .../assets/art/platforms/moving_platform.png | Bin 0 -> 1037 bytes .../art/platforms}/moving_platform.png.import | 6 +- .../art/platforms}/one_way_platform.png | Bin .../platforms}/one_way_platform.png.import | 6 +- .../art/player/bullet}/bullet.png | Bin .../art/player/bullet}/bullet.png.import | 6 +- .../{ => assets/art}/player/robot_demo.png | Bin .../art}/player/robot_demo.png.import | 6 +- .../assets/art/tileset/tiles_demo.png | Bin 0 -> 5167 bytes .../art/tileset}/tiles_demo.png.import | 6 +- 2d/platformer/assets/art/tileset/tileset.tres | 263 ++++++++++++++ .../art/ui/touch_button_fire.png} | Bin .../art/ui/touch_button_fire.png.import} | 6 +- .../art/ui/touch_button_jump.png} | Bin .../art/ui/touch_button_jump.png.import} | 6 +- .../art/ui/touch_button_left.png} | Bin .../art/ui/touch_button_left.png.import} | 6 +- .../art/ui/touch_button_right.png} | Bin .../art/ui/touch_button_right.png.import} | 6 +- .../{audio => assets/audio/music}/music.ogg | Bin .../assets/audio/music/music.ogg.import | 15 + .../audio/sfx/coin_pickup.wav} | Bin .../assets/audio/sfx/coin_pickup.wav.import | 21 ++ .../audio/sfx/explode.wav} | Bin .../audio/sfx/explode.wav.import} | 6 +- .../audio/sfx/hit.wav} | Bin .../audio/sfx/hit.wav.import} | 6 +- .../audio/sfx/jump.wav} | Bin .../audio/sfx/jump.wav.import} | 6 +- .../audio/sfx/shoot.wav} | Bin .../audio/sfx/shoot.wav.import} | 6 +- .../assets/theme/fonts/kenney_mini_square.ttf | Bin 0 -> 23996 bytes .../assets/theme/user_interface.tres | 82 +++++ 2d/platformer/audio/music.ogg.import | 15 - 2d/platformer/audio/sound_explode.wav.import | 21 -- 2d/platformer/background/scroll_bg_fg_1.png | Bin 5401 -> 0 bytes .../background/scroll_bg_fg_1.png.import | 34 -- 2d/platformer/background/scroll_bg_fg_2.png | Bin 6003 -> 0 bytes .../background/scroll_bg_fg_2.png.import | 34 -- 2d/platformer/coin/Coin.tscn | 140 -------- 2d/platformer/coin/coin.gd | 11 - 2d/platformer/enemy/enemy.gd | 50 --- 2d/platformer/platform/MovingPlatform.tscn | 16 - 2d/platformer/platform/OneWayPlatform.tscn | 17 - 2d/platformer/platform/moving_platform.gd | 17 - 2d/platformer/platform/moving_platform.png | Bin 1094 -> 0 bytes 2d/platformer/player/bullet.gd | 11 - 2d/platformer/player/osb_left.png.import | 34 -- 2d/platformer/player/osb_right.png.import | 34 -- 2d/platformer/player/player.gd | 97 ------ 2d/platformer/project.godot | 58 +++- 2d/platformer/src/Actors/Actor.gd | 18 + 2d/platformer/src/Actors/Enemy.gd | 78 +++++ .../{enemy => src/Actors}/Enemy.tscn | 183 ++++++---- 2d/platformer/src/Actors/Gun.gd | 24 ++ 2d/platformer/src/Actors/Player.gd | 96 ++++++ .../{player => src/Actors}/Player.tscn | 85 +++-- 2d/platformer/src/Level/Level.tscn | 275 +++++++++++++++ .../Level/ParallaxBackground.tscn} | 36 +- 2d/platformer/src/Main/Game.gd | 26 ++ 2d/platformer/src/Main/Game.tscn | 16 + 2d/platformer/src/Objects/Bullet.gd | 14 + .../{player => src/Objects}/Bullet.tscn | 30 +- 2d/platformer/src/Objects/Coin.gd | 15 + 2d/platformer/src/Objects/Coin.tscn | 161 +++++++++ 2d/platformer/src/Platforms/Platform.tscn | 21 ++ 2d/platformer/src/UserInterface/PauseMenu.gd | 26 ++ .../src/UserInterface/PauseMenu.tscn | 56 +++ 2d/platformer/tiles_demo.png | Bin 4057 -> 0 bytes 88 files changed, 1633 insertions(+), 1570 deletions(-) delete mode 100644 2d/platformer/Stage.tscn delete mode 100644 2d/platformer/TileSet.tres delete mode 100644 2d/platformer/TilesetEdit.tscn rename 2d/platformer/{background/scroll_bg_cloud_1.png => assets/art/background/cloud_1.png} (100%) rename 2d/platformer/{player/osb_jump.png.import => assets/art/background/cloud_1.png.import} (69%) rename 2d/platformer/{background/scroll_bg_cloud_2.png => assets/art/background/cloud_2.png} (100%) create mode 100644 2d/platformer/assets/art/background/cloud_2.png.import rename 2d/platformer/{background/scroll_bg_cloud_3.png => assets/art/background/cloud_3.png} (100%) create mode 100644 2d/platformer/assets/art/background/cloud_3.png.import create mode 100644 2d/platformer/assets/art/background/distant_platforms_1.png create mode 100644 2d/platformer/assets/art/background/distant_platforms_1.png.import create mode 100644 2d/platformer/assets/art/background/distant_platforms_2.png create mode 100644 2d/platformer/assets/art/background/distant_platforms_2.png.import rename 2d/platformer/{background/scroll_bg_sky.png => assets/art/background/sky.png} (100%) rename 2d/platformer/{player/osb_fire.png.import => assets/art/background/sky.png.import} (70%) rename 2d/platformer/{ => assets/art}/coin/coin.png (100%) rename 2d/platformer/{ => assets/art}/coin/coin.png.import (71%) rename 2d/platformer/{ => assets/art}/enemy/enemy.png (100%) rename 2d/platformer/{ => assets/art}/enemy/enemy.png.import (71%) create mode 100644 2d/platformer/assets/art/platforms/moving_platform.png rename 2d/platformer/{platform => assets/art/platforms}/moving_platform.png.import (67%) rename 2d/platformer/{platform => assets/art/platforms}/one_way_platform.png (100%) rename 2d/platformer/{platform => assets/art/platforms}/one_way_platform.png.import (66%) rename 2d/platformer/{player => assets/art/player/bullet}/bullet.png (100%) rename 2d/platformer/{player => assets/art/player/bullet}/bullet.png.import (70%) rename 2d/platformer/{ => assets/art}/player/robot_demo.png (100%) rename 2d/platformer/{ => assets/art}/player/robot_demo.png.import (68%) create mode 100644 2d/platformer/assets/art/tileset/tiles_demo.png rename 2d/platformer/{ => assets/art/tileset}/tiles_demo.png.import (68%) create mode 100644 2d/platformer/assets/art/tileset/tileset.tres rename 2d/platformer/{player/osb_fire.png => assets/art/ui/touch_button_fire.png} (100%) rename 2d/platformer/{background/scroll_bg_cloud_1.png.import => assets/art/ui/touch_button_fire.png.import} (67%) rename 2d/platformer/{player/osb_jump.png => assets/art/ui/touch_button_jump.png} (100%) rename 2d/platformer/{background/scroll_bg_cloud_2.png.import => assets/art/ui/touch_button_jump.png.import} (67%) rename 2d/platformer/{player/osb_left.png => assets/art/ui/touch_button_left.png} (100%) rename 2d/platformer/{background/scroll_bg_cloud_3.png.import => assets/art/ui/touch_button_left.png.import} (67%) rename 2d/platformer/{player/osb_right.png => assets/art/ui/touch_button_right.png} (100%) rename 2d/platformer/{background/scroll_bg_sky.png.import => assets/art/ui/touch_button_right.png.import} (66%) rename 2d/platformer/{audio => assets/audio/music}/music.ogg (100%) create mode 100644 2d/platformer/assets/audio/music/music.ogg.import rename 2d/platformer/{audio/sound_coin.wav => assets/audio/sfx/coin_pickup.wav} (100%) create mode 100644 2d/platformer/assets/audio/sfx/coin_pickup.wav.import rename 2d/platformer/{audio/sound_explode.wav => assets/audio/sfx/explode.wav} (100%) rename 2d/platformer/{audio/sound_shoot.wav.import => assets/audio/sfx/explode.wav.import} (51%) rename 2d/platformer/{audio/sound_hit.wav => assets/audio/sfx/hit.wav} (100%) rename 2d/platformer/{audio/sound_hit.wav.import => assets/audio/sfx/hit.wav.import} (51%) rename 2d/platformer/{audio/sound_jump.wav => assets/audio/sfx/jump.wav} (100%) rename 2d/platformer/{audio/sound_coin.wav.import => assets/audio/sfx/jump.wav.import} (51%) rename 2d/platformer/{audio/sound_shoot.wav => assets/audio/sfx/shoot.wav} (100%) rename 2d/platformer/{audio/sound_jump.wav.import => assets/audio/sfx/shoot.wav.import} (51%) create mode 100644 2d/platformer/assets/theme/fonts/kenney_mini_square.ttf create mode 100644 2d/platformer/assets/theme/user_interface.tres delete mode 100644 2d/platformer/audio/music.ogg.import delete mode 100644 2d/platformer/audio/sound_explode.wav.import delete mode 100644 2d/platformer/background/scroll_bg_fg_1.png delete mode 100644 2d/platformer/background/scroll_bg_fg_1.png.import delete mode 100644 2d/platformer/background/scroll_bg_fg_2.png delete mode 100644 2d/platformer/background/scroll_bg_fg_2.png.import delete mode 100644 2d/platformer/coin/Coin.tscn delete mode 100644 2d/platformer/coin/coin.gd delete mode 100644 2d/platformer/enemy/enemy.gd delete mode 100644 2d/platformer/platform/MovingPlatform.tscn delete mode 100644 2d/platformer/platform/OneWayPlatform.tscn delete mode 100644 2d/platformer/platform/moving_platform.gd delete mode 100644 2d/platformer/platform/moving_platform.png delete mode 100644 2d/platformer/player/bullet.gd delete mode 100644 2d/platformer/player/osb_left.png.import delete mode 100644 2d/platformer/player/osb_right.png.import delete mode 100644 2d/platformer/player/player.gd create mode 100644 2d/platformer/src/Actors/Actor.gd create mode 100644 2d/platformer/src/Actors/Enemy.gd rename 2d/platformer/{enemy => src/Actors}/Enemy.tscn (52%) create mode 100644 2d/platformer/src/Actors/Gun.gd create mode 100644 2d/platformer/src/Actors/Player.gd rename 2d/platformer/{player => src/Actors}/Player.tscn (74%) create mode 100644 2d/platformer/src/Level/Level.tscn rename 2d/platformer/{background/ParallaxBg.tscn => src/Level/ParallaxBackground.tscn} (54%) create mode 100644 2d/platformer/src/Main/Game.gd create mode 100644 2d/platformer/src/Main/Game.tscn create mode 100644 2d/platformer/src/Objects/Bullet.gd rename 2d/platformer/{player => src/Objects}/Bullet.tscn (74%) create mode 100644 2d/platformer/src/Objects/Coin.gd create mode 100644 2d/platformer/src/Objects/Coin.tscn create mode 100644 2d/platformer/src/Platforms/Platform.tscn create mode 100644 2d/platformer/src/UserInterface/PauseMenu.gd create mode 100644 2d/platformer/src/UserInterface/PauseMenu.tscn delete mode 100644 2d/platformer/tiles_demo.png diff --git a/2d/platformer/Stage.tscn b/2d/platformer/Stage.tscn deleted file mode 100644 index 5bef741656..0000000000 --- a/2d/platformer/Stage.tscn +++ /dev/null @@ -1,268 +0,0 @@ -[gd_scene load_steps=9 format=2] - -[ext_resource path="res://TileSet.tres" type="TileSet" id=1] -[ext_resource path="res://coin/Coin.tscn" type="PackedScene" id=2] -[ext_resource path="res://platform/MovingPlatform.tscn" type="PackedScene" id=3] -[ext_resource path="res://platform/OneWayPlatform.tscn" type="PackedScene" id=4] -[ext_resource path="res://enemy/Enemy.tscn" type="PackedScene" id=5] -[ext_resource path="res://background/ParallaxBg.tscn" type="PackedScene" id=6] -[ext_resource path="res://player/Player.tscn" type="PackedScene" id=7] -[ext_resource path="res://audio/music.ogg" type="AudioStream" id=8] - -[node name="Stage" type="Node"] - -[node name="TileMap" type="TileMap" parent="."] -tile_set = ExtResource( 1 ) -cell_quadrant_size = 8 -format = 1 -tile_data = PoolIntArray( 0, 2, 0, 65536, 2, 0, 131072, 2, 0, 196608, 2, 0, 196626, 9, 0, 262144, 2, 0, 262162, 8, 0, 327680, 2, 0, 327697, 536870921, 0, 327698, 7, 0, 393216, 2, 0, 393234, 7, 0, 393276, 536870914, 0, 393277, 536870922, 0, 393278, 536870922, 0, 393279, 536870922, 0, 393280, 536870922, 0, 393281, 536870922, 0, 393282, 536870922, 0, 393283, 536870922, 0, 393284, 536870922, 0, 393285, 536870922, 0, 458752, 2, 0, 458770, 8, 0, 458812, 536870914, 0, 458813, 536870922, 0, 458814, 536870922, 0, 458815, 536870922, 0, 458816, 536870922, 0, 458817, 536870922, 0, 458818, 536870922, 0, 458819, 536870922, 0, 458820, 536870922, 0, 458821, 536870922, 0, 524288, 4, 0, 524289, 1, 0, 524348, 536870914, 0, 524349, 536870922, 0, 524350, 536870922, 0, 524351, 536870922, 0, 524352, 536870922, 0, 524353, 536870922, 0, 524354, 536870922, 0, 524355, 536870922, 0, 524356, 536870922, 0, 524357, 536870922, 0, 589824, 10, 0, 589825, 13, 0, 589860, 536870914, 0, 589861, 10, 0, 589862, 10, 0, 589863, 10, 0, 589864, 10, 0, 589865, 10, 0, 589866, 10, 0, 589867, 10, 0, 589868, 10, 0, 589869, 2, 0, 589884, 536870914, 0, 589885, 536870922, 0, 589886, 536870922, 0, 589887, 536870922, 0, 589888, 536870922, 0, 589889, 536870922, 0, 589890, 536870922, 0, 589891, 536870922, 0, 589892, 536870922, 0, 589893, 536870922, 0, 655360, 2, 0, 655396, 536870914, 0, 655397, 10, 0, 655398, 10, 0, 655399, 10, 0, 655400, 10, 0, 655401, 10, 0, 655402, 10, 0, 655403, 10, 0, 655404, 10, 0, 655405, 2, 0, 655420, 536870914, 0, 655421, 536870922, 0, 655422, 536870922, 0, 655423, 536870922, 0, 655424, 536870922, 0, 655425, 536870922, 0, 655426, 536870922, 0, 655427, 536870922, 0, 655428, 536870922, 0, 655429, 536870922, 0, 720896, 2, 0, 720932, 536870914, 0, 720933, 10, 0, 720934, 10, 0, 720935, 10, 0, 720936, 10, 0, 720937, 10, 0, 720938, 10, 0, 720939, 10, 0, 720940, 10, 0, 720941, 2, 0, 720956, 536870914, 0, 720957, 536870922, 0, 720958, 536870922, 0, 720959, 536870922, 0, 720960, 536870922, 0, 720961, 536870922, 0, 720962, 536870922, 0, 720963, 536870922, 0, 720964, 536870922, 0, 720965, 536870922, 0, 786432, 2, 0, 786437, 9, 0, 786468, 536870914, 0, 786469, 10, 0, 786470, 10, 0, 786471, 10, 0, 786472, 10, 0, 786473, 10, 0, 786474, 10, 0, 786475, 10, 0, 786476, 10, 0, 786477, 2, 0, 786492, 536870914, 0, 786493, 536870922, 0, 786494, 536870922, 0, 786495, 536870922, 0, 786496, 536870922, 0, 786497, 536870922, 0, 786498, 536870922, 0, 786499, 536870922, 0, 786500, 536870922, 0, 786501, 536870922, 0, 851968, 2, 0, 851973, 7, 0, 852004, 536870914, 0, 852005, 10, 0, 852006, 10, 0, 852007, 10, 0, 852008, 10, 0, 852009, 10, 0, 852010, 10, 0, 852011, 10, 0, 852012, 10, 0, 852013, 2, 0, 852028, 536870914, 0, 852029, 536870922, 0, 852030, 536870922, 0, 852031, 536870922, 0, 852032, 536870922, 0, 852033, 536870922, 0, 852034, 536870922, 0, 852035, 536870922, 0, 852036, 536870922, 0, 852037, 536870922, 0, 917504, 2, 0, 917506, 9, 0, 917509, 7, 0, 917512, 536870921, 0, 917540, 536870914, 0, 917541, 10, 0, 917542, 10, 0, 917543, 10, 0, 917544, 10, 0, 917545, 10, 0, 917546, 10, 0, 917547, 10, 0, 917548, 10, 0, 917549, 2, 0, 917564, 536870914, 0, 917565, 536870922, 0, 917566, 536870922, 0, 917567, 536870922, 0, 917568, 536870922, 0, 917569, 536870922, 0, 917570, 536870922, 0, 917571, 536870922, 0, 917572, 536870922, 0, 917573, 536870922, 0, 983040, 2, 0, 983042, 7, 0, 983045, 7, 0, 983048, 536870920, 0, 983076, 536870914, 0, 983077, 10, 0, 983078, 10, 0, 983079, 10, 0, 983080, 10, 0, 983081, 10, 0, 983082, 10, 0, 983083, 10, 0, 983084, 10, 0, 983085, 2, 0, 983100, 536870914, 0, 983101, 536870922, 0, 983102, 536870922, 0, 983103, 536870922, 0, 983104, 536870922, 0, 983105, 536870922, 0, 983106, 536870922, 0, 983107, 536870922, 0, 983108, 536870922, 0, 983109, 536870922, 0, 1048576, 2, 0, 1048578, 8, 0, 1048581, 8, 0, 1048584, 536870919, 0, 1048612, 536870914, 0, 1048613, 10, 0, 1048614, 10, 0, 1048615, 10, 0, 1048616, 10, 0, 1048617, 10, 0, 1048618, 10, 0, 1048619, 10, 0, 1048620, 10, 0, 1048621, 2, 0, 1048636, 536870914, 0, 1048637, 536870922, 0, 1048638, 536870922, 0, 1048639, 536870922, 0, 1048640, 536870922, 0, 1048641, 536870922, 0, 1048642, 536870922, 0, 1048643, 536870922, 0, 1048644, 536870922, 0, 1048645, 536870922, 0, 1114112, 4, 0, 1114113, 0, 0, 1114114, 6, 0, 1114115, 0, 0, 1114116, 0, 0, 1114117, 6, 0, 1114118, 1, 0, 1114120, 536870919, 0, 1114127, 536870913, 0, 1114128, 0, 0, 1114129, 15, 0, 1114139, 536870927, 0, 1114140, 0, 0, 1114141, 536870912, 0, 1114142, 536870912, 0, 1114143, 536870912, 0, 1114144, 15, 0, 1114148, 536870925, 0, 1114149, 536870923, 0, 1114150, 536870923, 0, 1114151, 536870923, 0, 1114152, 536870923, 0, 1114153, 536870923, 0, 1114154, 536870923, 0, 1114155, 536870923, 0, 1114156, 536870923, 0, 1114157, 13, 0, 1114172, 536870914, 0, 1114173, 536870922, 0, 1114174, 536870922, 0, 1114175, 536870922, 0, 1114176, 536870922, 0, 1114177, 536870922, 0, 1114178, 536870922, 0, 1114179, 536870922, 0, 1114180, 536870922, 0, 1114181, 536870922, 0, 1179648, 10, 0, 1179649, 10, 0, 1179650, 10, 0, 1179651, 10, 0, 1179652, 10, 0, 1179653, 10, 0, 1179654, 2, 0, 1179656, 536870919, 0, 1179663, 536870914, 0, 1179664, 2, 0, 1179676, 536870914, 0, 1179677, 536870922, 0, 1179678, 536870922, 0, 1179679, 2, 0, 1179700, 536870913, 0, 1179701, 536870912, 0, 1179702, 536870912, 0, 1179703, 536870912, 0, 1179704, 536870912, 0, 1179705, 536870912, 0, 1179706, 536870912, 0, 1179707, 536870912, 0, 1179708, 536870916, 0, 1179709, 536870922, 0, 1179710, 536870922, 0, 1179711, 536870922, 0, 1179712, 536870922, 0, 1179713, 536870922, 0, 1179714, 536870922, 0, 1179715, 536870922, 0, 1179716, 536870922, 0, 1179717, 536870922, 0, 1245184, 10, 0, 1245185, 10, 0, 1245186, 10, 0, 1245187, 10, 0, 1245188, 10, 0, 1245189, 10, 0, 1245190, 4, 0, 1245191, 1, 0, 1245192, 536870919, 0, 1245199, 536870914, 0, 1245200, 2, 0, 1245212, 536870914, 0, 1245213, 536870922, 0, 1245214, 536870922, 0, 1245215, 2, 0, 1245236, 536870914, 0, 1245237, 536870922, 0, 1245238, 536870922, 0, 1245239, 536870922, 0, 1245240, 536870922, 0, 1245241, 536870922, 0, 1245242, 536870922, 0, 1245243, 536870922, 0, 1245244, 536870922, 0, 1245245, 536870922, 0, 1245246, 536870922, 0, 1245247, 536870922, 0, 1245248, 536870922, 0, 1245249, 536870922, 0, 1245250, 536870922, 0, 1245251, 536870922, 0, 1245252, 536870922, 0, 1245253, 536870922, 0, 1310720, 10, 0, 1310721, 10, 0, 1310722, 10, 0, 1310723, 10, 0, 1310724, 10, 0, 1310725, 10, 0, 1310726, 10, 0, 1310727, 4, 0, 1310728, 6, 0, 1310729, 1, 0, 1310735, 536870914, 0, 1310736, 2, 0, 1310748, 536870914, 0, 1310749, 536870922, 0, 1310750, 536870922, 0, 1310751, 2, 0, 1310772, 536870914, 0, 1310773, 536870922, 0, 1310774, 536870922, 0, 1310775, 536870922, 0, 1310776, 536870922, 0, 1310777, 536870922, 0, 1310778, 536870922, 0, 1310779, 536870922, 0, 1310780, 536870922, 0, 1310781, 536870922, 0, 1310782, 536870922, 0, 1310783, 536870922, 0, 1310784, 536870922, 0, 1310785, 536870922, 0, 1310786, 536870922, 0, 1310787, 536870922, 0, 1310788, 536870922, 0, 1310789, 536870922, 0, 1376256, 10, 0, 1376257, 10, 0, 1376258, 10, 0, 1376259, 10, 0, 1376260, 10, 0, 1376261, 10, 0, 1376262, 10, 0, 1376263, 10, 0, 1376264, 10, 0, 1376265, 4, 0, 1376266, 0, 0, 1376267, 0, 0, 1376268, 0, 0, 1376269, 0, 0, 1376270, 0, 0, 1376271, 536870916, 0, 1376272, 2, 0, 1376284, 536870914, 0, 1376285, 536870922, 0, 1376286, 536870922, 0, 1376287, 2, 0, 1376308, 536870914, 0, 1376309, 536870922, 0, 1376310, 536870922, 0, 1376311, 536870922, 0, 1376312, 536870922, 0, 1376313, 536870922, 0, 1376314, 536870922, 0, 1376315, 536870922, 0, 1376316, 536870922, 0, 1376317, 536870922, 0, 1376318, 536870922, 0, 1376319, 536870922, 0, 1376320, 536870922, 0, 1376321, 536870922, 0, 1376322, 536870922, 0, 1376323, 536870922, 0, 1376324, 536870922, 0, 1376325, 536870922, 0, 1441792, 10, 0, 1441793, 10, 0, 1441794, 10, 0, 1441795, 10, 0, 1441796, 10, 0, 1441797, 10, 0, 1441798, 10, 0, 1441799, 10, 0, 1441800, 10, 0, 1441801, 10, 0, 1441802, 10, 0, 1441803, 10, 0, 1441804, 10, 0, 1441805, 10, 0, 1441806, 10, 0, 1441807, 10, 0, 1441808, 2, 0, 1441820, 536870914, 0, 1441821, 536870922, 0, 1441822, 536870922, 0, 1441823, 2, 0, 1441844, 536870914, 0, 1441845, 536870922, 0, 1441846, 536870922, 0, 1441847, 536870922, 0, 1441848, 536870922, 0, 1441849, 536870922, 0, 1441850, 536870922, 0, 1441851, 536870922, 0, 1441852, 536870922, 0, 1441853, 536870922, 0, 1441854, 536870922, 0, 1441855, 536870922, 0, 1441856, 536870922, 0, 1441857, 536870922, 0, 1441858, 536870922, 0, 1441859, 536870922, 0, 1441860, 536870922, 0, 1441861, 536870922, 0, 1507328, 10, 0, 1507329, 10, 0, 1507330, 10, 0, 1507331, 10, 0, 1507332, 10, 0, 1507333, 10, 0, 1507334, 10, 0, 1507335, 10, 0, 1507336, 10, 0, 1507337, 10, 0, 1507338, 10, 0, 1507339, 10, 0, 1507340, 10, 0, 1507341, 10, 0, 1507342, 10, 0, 1507343, 10, 0, 1507344, 2, 0, 1507356, 536870914, 0, 1507357, 536870922, 0, 1507358, 536870922, 0, 1507359, 4, 0, 1507360, 0, 0, 1507361, 0, 0, 1507362, 0, 0, 1507363, 0, 0, 1507364, 0, 0, 1507365, 0, 0, 1507366, 12, 0, 1507380, 536870914, 0, 1507381, 536870922, 0, 1507382, 536870922, 0, 1507383, 536870922, 0, 1507384, 536870922, 0, 1507385, 536870922, 0, 1507386, 536870922, 0, 1507387, 536870922, 0, 1507388, 536870922, 0, 1507389, 536870922, 0, 1507390, 536870922, 0, 1507391, 536870922, 0, 1507392, 536870922, 0, 1507393, 536870922, 0, 1507394, 536870922, 0, 1507395, 536870922, 0, 1507396, 536870922, 0, 1507397, 536870922, 0, 1572864, 10, 0, 1572865, 10, 0, 1572866, 10, 0, 1572867, 10, 0, 1572868, 10, 0, 1572869, 10, 0, 1572870, 10, 0, 1572871, 10, 0, 1572872, 10, 0, 1572873, 10, 0, 1572874, 10, 0, 1572875, 10, 0, 1572876, 10, 0, 1572877, 10, 0, 1572878, 10, 0, 1572879, 10, 0, 1572880, 2, 0, 1572892, 536870914, 0, 1572893, 536870922, 0, 1572894, 536870922, 0, 1572895, 536870922, 0, 1572896, 536870922, 0, 1572897, 536870922, 0, 1572898, 536870922, 0, 1572899, 536870922, 0, 1572900, 536870922, 0, 1572901, 536870922, 0, 1572903, 12, 0, 1572916, 536870914, 0, 1572917, 536870922, 0, 1572918, 536870922, 0, 1572919, 536870922, 0, 1572920, 536870922, 0, 1572921, 536870922, 0, 1572922, 536870922, 0, 1572923, 536870922, 0, 1572924, 536870922, 0, 1572925, 536870922, 0, 1572926, 536870922, 0, 1572927, 536870922, 0, 1572928, 536870922, 0, 1572929, 536870922, 0, 1572930, 536870922, 0, 1572931, 536870922, 0, 1572932, 536870922, 0, 1572933, 536870922, 0, 1638400, 10, 0, 1638401, 10, 0, 1638402, 10, 0, 1638403, 10, 0, 1638404, 10, 0, 1638405, 10, 0, 1638406, 10, 0, 1638407, 10, 0, 1638408, 10, 0, 1638409, 10, 0, 1638410, 10, 0, 1638411, 10, 0, 1638412, 10, 0, 1638413, 10, 0, 1638414, 10, 0, 1638415, 10, 0, 1638416, 2, 0, 1638428, 536870914, 0, 1638429, 536870922, 0, 1638430, 536870922, 0, 1638431, 536870922, 0, 1638432, 536870922, 0, 1638433, 536870922, 0, 1638434, 536870922, 0, 1638435, 536870922, 0, 1638436, 536870922, 0, 1638437, 536870922, 0, 1638438, 536870922, 0, 1638440, 12, 0, 1638452, 536870914, 0, 1638453, 536870922, 0, 1638454, 536870922, 0, 1638455, 536870922, 0, 1638456, 536870922, 0, 1638457, 536870922, 0, 1638458, 536870922, 0, 1638459, 536870922, 0, 1638460, 536870922, 0, 1638461, 536870922, 0, 1638462, 536870922, 0, 1638463, 536870922, 0, 1638464, 536870922, 0, 1638465, 536870922, 0, 1638466, 536870922, 0, 1638467, 536870922, 0, 1638468, 536870922, 0, 1638469, 536870922, 0, 1703964, 536870914, 0, 1703965, 536870922, 0, 1703966, 536870922, 0, 1703967, 536870922, 0, 1703968, 536870922, 0, 1703969, 536870922, 0, 1703970, 536870922, 0, 1703971, 536870922, 0, 1703972, 536870922, 0, 1703973, 536870922, 0, 1703974, 536870922, 0, 1703975, 536870922, 0, 1703977, 12, 0, 1703988, 536870914, 0, 1703989, 536870922, 0, 1703990, 536870922, 0, 1703991, 536870922, 0, 1703992, 536870922, 0, 1703993, 536870922, 0, 1703994, 536870922, 0, 1703995, 536870922, 0, 1703996, 536870922, 0, 1703997, 536870922, 0, 1703998, 536870922, 0, 1703999, 536870922, 0, 1704000, 536870922, 0, 1704001, 536870922, 0, 1704002, 536870922, 0, 1704003, 536870922, 0, 1704004, 536870922, 0, 1704005, 536870922, 0, 1769500, 536870914, 0, 1769501, 536870922, 0, 1769502, 536870922, 0, 1769503, 536870922, 0, 1769504, 536870922, 0, 1769505, 536870922, 0, 1769506, 536870922, 0, 1769507, 536870922, 0, 1769508, 536870922, 0, 1769509, 536870922, 0, 1769510, 536870922, 0, 1769511, 536870922, 0, 1769512, 536870922, 0, 1769514, 12, 0, 1769524, 536870914, 0, 1769525, 536870922, 0, 1769526, 536870922, 0, 1769527, 536870922, 0, 1769528, 536870922, 0, 1769529, 536870922, 0, 1769530, 536870922, 0, 1769531, 536870922, 0, 1769532, 536870922, 0, 1769533, 536870922, 0, 1769534, 536870922, 0, 1769535, 536870922, 0, 1769536, 536870922, 0, 1769537, 536870922, 0, 1769538, 536870922, 0, 1769539, 536870922, 0, 1769540, 536870922, 0, 1769541, 536870922, 0, 1835036, 536870914, 0, 1835037, 536870922, 0, 1835038, 536870922, 0, 1835039, 536870922, 0, 1835040, 536870922, 0, 1835041, 536870922, 0, 1835042, 536870922, 0, 1835043, 536870922, 0, 1835044, 536870922, 0, 1835045, 536870922, 0, 1835046, 536870922, 0, 1835047, 536870922, 0, 1835048, 536870922, 0, 1835049, 536870922, 0, 1835051, 12, 0, 1835060, 536870914, 0, 1835061, 536870922, 0, 1835062, 536870922, 0, 1835063, 536870922, 0, 1835064, 536870922, 0, 1835065, 536870922, 0, 1835066, 536870922, 0, 1835067, 536870922, 0, 1835068, 536870922, 0, 1835069, 536870922, 0, 1835070, 536870922, 0, 1835071, 536870922, 0, 1835072, 536870922, 0, 1835073, 536870922, 0, 1835074, 536870922, 0, 1835075, 536870922, 0, 1835076, 536870922, 0, 1835077, 536870922, 0, 1900572, 536870914, 0, 1900573, 536870922, 0, 1900574, 536870922, 0, 1900575, 536870922, 0, 1900576, 536870922, 0, 1900577, 536870922, 0, 1900578, 536870922, 0, 1900579, 536870922, 0, 1900580, 536870922, 0, 1900581, 536870922, 0, 1900582, 536870922, 0, 1900583, 536870922, 0, 1900584, 536870922, 0, 1900585, 536870922, 0, 1900586, 536870922, 0, 1900588, 0, 0, 1900589, 0, 0, 1900590, 0, 0, 1900591, 0, 0, 1900592, 0, 0, 1900593, 0, 0, 1900594, 0, 0, 1900595, 0, 0, 1900596, 536870916, 0, 1900597, 536870922, 0, 1900598, 536870922, 0, 1900599, 536870922, 0, 1900600, 536870922, 0, 1900601, 536870922, 0, 1900602, 536870922, 0, 1900603, 536870922, 0, 1900604, 536870922, 0, 1900605, 536870922, 0, 1900606, 536870922, 0, 1900607, 536870922, 0, 1900608, 536870922, 0, 1900609, 536870922, 0, 1900610, 536870922, 0, 1900611, 536870922, 0, 1900612, 536870922, 0, 1900613, 536870922, 0, 1966108, 536870914, 0, 1966109, 536870922, 0, 1966110, 536870922, 0, 1966111, 536870922, 0, 1966112, 536870922, 0, 1966113, 536870922, 0, 1966114, 536870922, 0, 1966115, 536870922, 0, 1966116, 536870922, 0, 1966117, 536870922, 0, 1966118, 536870922, 0, 1966119, 536870922, 0, 1966120, 536870922, 0, 1966121, 536870922, 0, 1966122, 536870922, 0, 1966123, 536870922, 0, 1966124, 536870922, 0, 1966125, 536870922, 0, 1966126, 536870922, 0, 1966127, 536870922, 0, 1966128, 536870922, 0, 1966129, 536870922, 0, 1966130, 536870922, 0, 1966131, 536870922, 0, 1966132, 536870922, 0, 1966133, 536870922, 0, 1966134, 536870922, 0, 1966135, 536870922, 0, 1966136, 536870922, 0, 1966137, 536870922, 0, 1966138, 536870922, 0, 1966139, 536870922, 0, 1966140, 536870922, 0, 1966141, 536870922, 0, 1966142, 536870922, 0, 1966143, 536870922, 0, 1966144, 536870922, 0, 1966145, 536870922, 0, 1966146, 536870922, 0, 1966147, 536870922, 0, 1966148, 536870922, 0, 1966149, 536870922, 0, 2031644, 536870914, 0, 2031645, 536870922, 0, 2031646, 536870922, 0, 2031647, 536870922, 0, 2031648, 536870922, 0, 2031649, 536870922, 0, 2031650, 536870922, 0, 2031651, 536870922, 0, 2031652, 536870922, 0, 2031653, 536870922, 0, 2031654, 536870922, 0, 2031655, 536870922, 0, 2031656, 536870922, 0, 2031657, 536870922, 0, 2031658, 536870922, 0, 2031659, 536870922, 0, 2031660, 536870922, 0, 2031661, 536870922, 0, 2031662, 536870922, 0, 2031663, 536870922, 0, 2031664, 536870922, 0, 2031665, 536870922, 0, 2031666, 536870922, 0, 2031667, 536870922, 0, 2031668, 536870922, 0, 2031669, 536870922, 0, 2031670, 536870922, 0, 2031671, 536870922, 0, 2031672, 536870922, 0, 2031673, 536870922, 0, 2031674, 536870922, 0, 2031675, 536870922, 0, 2031676, 536870922, 0, 2031677, 536870922, 0, 2031678, 536870922, 0, 2031679, 536870922, 0, 2031680, 536870922, 0, 2031681, 536870922, 0, 2031682, 536870922, 0, 2031683, 536870922, 0, 2031684, 536870922, 0, 2031685, 536870922, 0, 2097180, 536870914, 0, 2097181, 536870922, 0, 2097182, 536870922, 0, 2097183, 536870922, 0, 2097184, 536870922, 0, 2097185, 536870922, 0, 2097186, 536870922, 0, 2097187, 536870922, 0, 2097188, 536870922, 0, 2097189, 536870922, 0, 2097190, 536870922, 0, 2097191, 536870922, 0, 2097192, 536870922, 0, 2097193, 536870922, 0, 2097194, 536870922, 0, 2097195, 536870922, 0, 2097196, 536870922, 0, 2097197, 536870922, 0, 2097198, 536870922, 0, 2097199, 536870922, 0, 2097200, 536870922, 0, 2097201, 536870922, 0, 2097202, 536870922, 0, 2097203, 536870922, 0, 2097204, 536870922, 0, 2097205, 536870922, 0, 2097206, 536870922, 0, 2097207, 536870922, 0, 2097208, 536870922, 0, 2097209, 536870922, 0, 2097210, 536870922, 0, 2097211, 536870922, 0, 2097212, 536870922, 0, 2097213, 536870922, 0, 2097214, 536870922, 0, 2097215, 536870922, 0, 2097216, 536870922, 0, 2097217, 536870922, 0, 2097218, 536870922, 0, 2097219, 536870922, 0, 2097220, 536870922, 0, 2097221, 536870922, 0, 2162716, 536870914, 0, 2162717, 536870922, 0, 2162718, 536870922, 0, 2162719, 536870922, 0, 2162720, 536870922, 0, 2162721, 536870922, 0, 2162722, 536870922, 0, 2162723, 536870922, 0, 2162724, 536870922, 0, 2162725, 536870922, 0, 2162726, 536870922, 0, 2162727, 536870922, 0, 2162728, 536870922, 0, 2162729, 536870922, 0, 2162730, 536870922, 0, 2162731, 536870922, 0, 2162732, 536870922, 0, 2162733, 536870922, 0, 2162734, 536870922, 0, 2162735, 536870922, 0, 2162736, 536870922, 0, 2162737, 536870922, 0, 2162738, 536870922, 0, 2162739, 536870922, 0, 2162740, 536870922, 0, 2162741, 536870922, 0, 2162742, 536870922, 0, 2162743, 536870922, 0, 2162744, 536870922, 0, 2162745, 536870922, 0, 2162746, 536870922, 0, 2162747, 536870922, 0, 2162748, 536870922, 0, 2162749, 536870922, 0, 2162750, 536870922, 0, 2162751, 536870922, 0, 2162752, 536870922, 0, 2162753, 536870922, 0, 2162754, 536870922, 0, 2162755, 536870922, 0, 2162756, 536870922, 0, 2162757, 536870922, 0, 2228252, 536870914, 0, 2228253, 536870922, 0, 2228254, 536870922, 0, 2228255, 536870922, 0, 2228256, 536870922, 0, 2228257, 536870922, 0, 2228258, 536870922, 0, 2228259, 536870922, 0, 2228260, 536870922, 0, 2228261, 536870922, 0, 2228262, 536870922, 0, 2228263, 536870922, 0, 2228264, 536870922, 0, 2228265, 536870922, 0, 2228266, 536870922, 0, 2228267, 536870922, 0, 2228268, 536870922, 0, 2228269, 536870922, 0, 2228270, 536870922, 0, 2228271, 536870922, 0, 2228272, 536870922, 0, 2228273, 536870922, 0, 2228274, 536870922, 0, 2228275, 536870922, 0, 2228276, 536870922, 0, 2228277, 536870922, 0, 2228278, 536870922, 0, 2228279, 536870922, 0, 2228280, 536870922, 0, 2228281, 536870922, 0, 2228282, 536870922, 0, 2228283, 536870922, 0, 2228284, 536870922, 0, 2228285, 536870922, 0, 2228286, 536870922, 0, 2228287, 536870922, 0, 2228288, 536870922, 0, 2228289, 536870922, 0, 2228290, 536870922, 0, 2228291, 536870922, 0, 2228292, 536870922, 0, 2228293, 536870922, 0, 2293788, 536870914, 0, 2293789, 536870922, 0, 2293790, 536870922, 0, 2293791, 536870922, 0, 2293792, 536870922, 0, 2293793, 536870922, 0, 2293794, 536870922, 0, 2293795, 536870922, 0, 2293796, 536870922, 0, 2293797, 536870922, 0, 2293798, 536870922, 0, 2293799, 536870922, 0, 2293800, 536870922, 0, 2293801, 536870922, 0, 2293802, 536870922, 0, 2293803, 536870922, 0, 2293804, 536870922, 0, 2293805, 536870922, 0, 2293806, 536870922, 0, 2293807, 536870922, 0, 2293808, 536870922, 0, 2293809, 536870922, 0, 2293810, 536870922, 0, 2293811, 536870922, 0, 2293812, 536870922, 0, 2293813, 536870922, 0, 2293814, 536870922, 0, 2293815, 536870922, 0, 2293816, 536870922, 0, 2293817, 536870922, 0, 2293818, 536870922, 0, 2293819, 536870922, 0, 2293820, 536870922, 0, 2293821, 536870922, 0, 2293822, 536870922, 0, 2293823, 536870922, 0, 2293824, 536870922, 0, 2293825, 536870922, 0, 2293826, 536870922, 0, 2293827, 536870922, 0, 2293828, 536870922, 0, 2293829, 536870922, 0, 2293830, 536870922, 0, 2359324, 536870914, 0, 2359325, 536870922, 0, 2359326, 536870922, 0, 2359327, 536870922, 0, 2359328, 536870922, 0, 2359329, 536870922, 0, 2359330, 536870922, 0, 2359331, 536870922, 0, 2359332, 536870922, 0, 2359333, 536870922, 0, 2359334, 536870922, 0, 2359335, 536870922, 0, 2359336, 536870922, 0, 2359337, 536870922, 0, 2359338, 536870922, 0, 2359339, 536870922, 0, 2359340, 536870922, 0, 2359341, 536870922, 0, 2359342, 536870922, 0, 2359343, 536870922, 0, 2359344, 536870922, 0, 2359345, 536870922, 0, 2359346, 536870922, 0, 2359347, 536870922, 0, 2359348, 536870922, 0, 2359349, 536870922, 0, 2359350, 536870922, 0, 2359351, 536870922, 0, 2359352, 536870922, 0, 2359353, 536870922, 0, 2359354, 536870922, 0, 2359355, 536870922, 0, 2359356, 536870922, 0, 2359357, 536870922, 0, 2359358, 536870922, 0, 2359359, 536870922, 0, 2359360, 536870922, 0, 2359361, 536870922, 0, 2359362, 536870922, 0, 2359363, 536870922, 0, 2359364, 536870922, 0, 2359365, 536870922, 0, 2359366, 536870922, 0, 2424860, 536870914, 0, 2424861, 536870922, 0, 2424862, 536870922, 0, 2424863, 536870922, 0, 2424864, 536870922, 0, 2424865, 536870922, 0, 2424866, 536870922, 0, 2424867, 536870922, 0, 2424868, 536870922, 0, 2424869, 536870922, 0, 2424870, 536870922, 0, 2424871, 536870922, 0, 2424872, 536870922, 0, 2424873, 536870922, 0, 2424874, 536870922, 0, 2424875, 536870922, 0, 2424876, 536870922, 0, 2424877, 536870922, 0, 2424878, 536870922, 0, 2424879, 536870922, 0, 2424880, 536870922, 0, 2424881, 536870922, 0, 2424882, 536870922, 0, 2424883, 536870922, 0, 2424884, 536870922, 0, 2424885, 536870922, 0, 2424886, 536870922, 0, 2424887, 536870922, 0, 2424888, 536870922, 0, 2424889, 536870922, 0, 2424890, 536870922, 0, 2424891, 536870922, 0, 2424892, 536870922, 0, 2424893, 536870922, 0, 2424894, 536870922, 0, 2424895, 536870922, 0, 2424896, 536870922, 0, 2424897, 536870922, 0, 2424898, 536870922, 0, 2424899, 536870922, 0, 2424900, 536870922, 0, 2424901, 536870922, 0, 2424902, 536870922, 0, 2490397, 536870922, 0, 2490398, 536870922, 0, 2490399, 536870922, 0, 2490400, 536870922, 0, 2490401, 536870922, 0, 2490402, 536870922, 0, 2490403, 536870922, 0, 2490404, 536870922, 0, 2490405, 536870922, 0, 2490406, 536870922, 0, 2490407, 536870922, 0, 2490408, 536870922, 0, 2490409, 536870922, 0, 2490410, 536870922, 0, 2490411, 536870922, 0, 2490412, 536870922, 0, 2490413, 536870922, 0, 2490414, 536870922, 0, 2490415, 536870922, 0, 2490416, 536870922, 0, 2490417, 536870922, 0, 2490418, 536870922, 0, 2490419, 536870922, 0, 2490420, 536870922, 0, 2490421, 536870922, 0, 2490422, 536870922, 0, 2490423, 536870922, 0, 2490424, 536870922, 0, 2490425, 536870922, 0, 2490426, 536870922, 0, 2490427, 536870922, 0, 2490428, 536870922, 0, 2490429, 536870922, 0, 2490430, 536870922, 0, 2490431, 536870922, 0, 2490432, 536870922, 0, 2490433, 536870922, 0, 2490434, 536870922, 0, 2490435, 536870922, 0, 2490436, 536870922, 0, 2490437, 536870922, 0, 2555933, 536870922, 0, 2555934, 536870922, 0, 2555935, 536870922, 0, 2555936, 536870922, 0, 2555937, 536870922, 0, 2555938, 536870922, 0, 2555939, 536870922, 0, 2555940, 536870922, 0, 2555941, 536870922, 0, 2555942, 536870922, 0, 2555943, 536870922, 0, 2555944, 536870922, 0, 2555945, 536870922, 0, 2555946, 536870922, 0, 2555947, 536870922, 0, 2555948, 536870922, 0, 2555949, 536870922, 0, 2555950, 536870922, 0, 2555951, 536870922, 0, 2555952, 536870922, 0, 2555953, 536870922, 0, 2555954, 536870922, 0, 2555955, 536870922, 0, 2555956, 536870922, 0, 2555957, 536870922, 0, 2555958, 536870922, 0, 2555959, 536870922, 0, 2555960, 536870922, 0, 2555961, 536870922, 0, 2555962, 536870922, 0, 2555963, 536870922, 0, 2555964, 536870922, 0, 2555965, 536870922, 0, 2555966, 536870922, 0, 2555967, 536870922, 0, 2555968, 536870922, 0, 2555969, 536870922, 0, 2555970, 536870922, 0, 2555971, 536870922, 0, 2555972, 536870922, 0, 2555973, 536870922, 0, 2621469, 536870922, 0, 2621470, 536870922, 0, 2621471, 536870922, 0, 2621472, 536870922, 0, 2621473, 536870922, 0, 2621474, 536870922, 0, 2621475, 536870922, 0, 2621476, 536870922, 0, 2621477, 536870922, 0, 2621478, 536870922, 0, 2621479, 536870922, 0, 2621480, 536870922, 0, 2621481, 536870922, 0, 2621482, 536870922, 0, 2621483, 536870922, 0, 2621484, 536870922, 0, 2621485, 536870922, 0, 2621486, 536870922, 0, 2621487, 536870922, 0, 2621488, 536870922, 0, 2621489, 536870922, 0, 2621490, 536870922, 0, 2621491, 536870922, 0, 2621492, 536870922, 0, 2621493, 536870922, 0, 2621494, 536870922, 0, 2621495, 536870922, 0, 2621496, 536870922, 0, 2621497, 536870922, 0, 2621498, 536870922, 0, 2621499, 536870922, 0, 2621500, 536870922, 0, 2621501, 536870922, 0, 2621502, 536870922, 0, 2621503, 536870922, 0, 2621504, 536870922, 0, 2621505, 536870922, 0, 2621506, 536870922, 0, 2621507, 536870922, 0, 2621508, 536870922, 0, 2687006, 536870922, 0, 2687007, 536870922, 0, 2687008, 536870922, 0, 2687009, 536870922, 0, 2687010, 536870922, 0, 2687011, 536870922, 0, 2687012, 536870922, 0, 2687013, 536870922, 0, 2687014, 536870922, 0, 2687015, 536870922, 0, 2687016, 536870922, 0, 2687017, 536870922, 0, 2687018, 536870922, 0, 2687019, 536870922, 0, 2687020, 536870922, 0, 2687021, 536870922, 0, 2687022, 536870922, 0, 2687023, 536870922, 0, 2687024, 536870922, 0, 2687025, 536870922, 0, 2687026, 536870922, 0, 2687027, 536870922, 0, 2687028, 536870922, 0, 2687029, 536870922, 0, 2687030, 536870922, 0, 2687031, 536870922, 0, 2687032, 536870922, 0, 2687033, 536870922, 0, 2687034, 536870922, 0, 2687035, 536870922, 0, 2687036, 536870922, 0, 2687037, 536870922, 0, 2687038, 536870922, 0, 2687039, 536870922, 0, 2687040, 536870922, 0, 2687041, 536870922, 0, 2687042, 536870922, 0, 2687043, 536870922, 0, 2687044, 536870922, 0, 2752543, 536870922, 0, 2752544, 536870922, 0, 2752545, 536870922, 0, 2752546, 536870922, 0, 2752547, 536870922, 0, 2752548, 536870922, 0, 2752549, 536870922, 0, 2752550, 536870922, 0, 2752551, 536870922, 0, 2752552, 536870922, 0, 2752553, 536870922, 0, 2752554, 536870922, 0, 2752555, 536870922, 0, 2752556, 536870922, 0, 2752557, 536870922, 0, 2752558, 536870922, 0, 2752559, 536870922, 0, 2752560, 536870922, 0, 2752561, 536870922, 0, 2752562, 536870922, 0, 2752563, 536870922, 0, 2752564, 536870922, 0, 2752565, 536870922, 0, 2752566, 536870922, 0, 2752567, 536870922, 0, 2752568, 536870922, 0, 2752569, 536870922, 0, 2752570, 536870922, 0, 2752571, 536870922, 0, 2752572, 536870922, 0, 2752573, 536870922, 0, 2752574, 536870922, 0, 2752575, 536870922, 0, 2752576, 536870922, 0, 2752577, 536870922, 0, 2752578, 536870922, 0, 2752579, 536870922, 0, 2818083, 536870922, 0, 2818084, 536870922, 0, 2818085, 536870922, 0, 2818086, 536870922, 0, 2818087, 536870922, 0, 2818088, 536870922, 0, 2818089, 536870922, 0, 2818090, 536870922, 0, 2818091, 536870922, 0, 2818092, 536870922, 0, 2818093, 536870922, 0, 2818094, 536870922, 0, 2818095, 536870922, 0, 2818096, 536870922, 0, 2818097, 536870922, 0, 2818098, 536870922, 0, 2818099, 536870922, 0, 2818100, 536870922, 0, 2818101, 536870922, 0, 2818102, 536870922, 0, 2818103, 536870922, 0, 2818104, 536870922, 0, 2818105, 536870922, 0, 2818106, 536870922, 0, 2818107, 536870922, 0, 2818108, 536870922, 0, 2818109, 536870922, 0, 2818110, 536870922, 0, 2818111, 536870922, 0, 2818112, 536870922, 0, 2818113, 536870922, 0 ) -__meta__ = { -"_edit_lock_": true -} - -[node name="Coins" type="Node" parent="."] - -[node name="Coin1" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 672, 1179 ) - -[node name="Coin2" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 704, 1179 ) - -[node name="Coin3" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 736, 1179 ) - -[node name="Coin4" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1120, 992 ) - -[node name="Coin5" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1152, 992 ) - -[node name="Coin6" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1184, 992 ) - -[node name="Coin7" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1216, 992 ) - -[node name="Coin8" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1248, 992 ) - -[node name="Coin9" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1568, 864 ) - -[node name="Coin10" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1632, 864 ) - -[node name="Coin11" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1169.44, 677.369 ) - -[node name="Coin12" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1233.44, 677.369 ) - -[node name="Coin13" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 924.453, 566.264 ) - -[node name="Coin14" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 988.453, 566.264 ) - -[node name="Coin15" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 983.872, 336.653 ) - -[node name="Coin16" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1047.87, 336.653 ) - -[node name="Coin17" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1111.87, 336.653 ) - -[node name="Coin18" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1111.87, 272.653 ) - -[node name="Coin19" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 1047.87, 272.653 ) - -[node name="Coin20" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 983.872, 272.653 ) - -[node name="Coin21" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3726.65, 1102.79 ) - -[node name="Coin22" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 89.5989, 481.217 ) - -[node name="Coin23" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3735.94, 1095.49 ) - -[node name="Coin24" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3743.9, 1084.22 ) - -[node name="Coin25" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3745.23, 1072.28 ) - -[node name="Coin26" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3733.95, 1063.65 ) - -[node name="Coin27" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 3725.99, 1072.94 ) - -[node name="Coin28" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 88.272, 448.71 ) - -[node name="Coin29" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 79.6476, 457.334 ) - -[node name="Coin30" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 82.9647, 468.612 ) - -[node name="Coin31" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2159.07, 1356.49 ) - -[node name="Coin32" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2223.07, 1356.49 ) - -[node name="Coin33" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2287.07, 1356.49 ) - -[node name="Coin34" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2287.07, 1292.49 ) - -[node name="Coin35" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2223.07, 1292.49 ) - -[node name="Coin36" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 2159.07, 1292.49 ) - -[node name="Coin37" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4172.75, 605.058 ) - -[node name="Coin38" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4236.75, 605.058 ) - -[node name="Coin39" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4300.75, 605.058 ) - -[node name="Coin40" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4300.75, 541.058 ) - -[node name="Coin41" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4236.75, 541.058 ) - -[node name="Coin42" parent="Coins" instance=ExtResource( 2 )] -position = Vector2( 4172.75, 541.058 ) - -[node name="Props" type="Node" parent="."] - -[node name="MovingPlatform" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 1451.86, 742.969 ) - -[node name="MovingPlatform2" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 719.199, 1123.81 ) -motion = Vector2( 100, 0 ) -cycle = 4.0 - -[node name="Still" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 1231.37, 1105.18 ) -rotation = -0.163314 - -[node name="Still1" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 1384.28, 1066.4 ) -rotation = -0.321902 - -[node name="Still2" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 1552.7, 1032.05 ) -rotation = -0.0826906 - -[node name="Still3" parent="Props" instance=ExtResource( 3 )] -position = Vector2( 1700.06, 1066.92 ) -rotation = 0.547997 - -[node name="OneWayPlatform1" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 967.609, 836.547 ) - -[node name="OneWayPlatform2" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1190.78, 754.282 ) - -[node name="OneWayPlatform3" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 953.762, 638.622 ) - -[node name="OneWayPlatform4" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1256.76, 638.622 ) - -[node name="OneWayPlatform5" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1039.29, 409.746 ) - -[node name="OneWayPlatform6" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1192.93, 520.298 ) - -[node name="OneWayPlatform7" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 2784.9, 1655.71 ) - -[node name="OneWayPlatform8" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 2976.23, 1555 ) - -[node name="OneWayPlatform9" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 3122.25, 1469.41 ) - -[node name="OneWayPlatform10" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 3200.29, 1353.6 ) - -[node name="OneWayPlatform11" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 3200.29, 1237.8 ) - -[node name="OneWayPlatform12" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1099.56, 940.804 ) - -[node name="OneWayPlatform13" parent="Props" instance=ExtResource( 4 )] -position = Vector2( 1339.63, 967.879 ) - -[node name="Player" parent="." instance=ExtResource( 7 )] -position = Vector2( 251.684, 1045.6 ) - -[node name="Enemies" type="Node" parent="."] - -[node name="Enemy1" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 734.693, 1064.22 ) - -[node name="Enemy2" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 707.665, 1225.05 ) - -[node name="Enemy3" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 1125.21, 1053.06 ) - -[node name="Enemy4" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 1292.11, 1059.24 ) - -[node name="Enemy5" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 968.927, 766.466 ) - -[node name="Enemy6" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 3080.34, 1807.61 ) - -[node name="Enemy7" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 1457.6, 688.741 ) - -[node name="Enemy8" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 1264.06, 571.713 ) - -[node name="Enemy9" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 3590.85, 1114.86 ) - -[node name="Enemy10" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 3546.2, 1356.19 ) - -[node name="Enemy11" parent="Enemies" instance=ExtResource( 5 )] -position = Vector2( 2215.3, 1429.39 ) - -[node name="ParallaxBg" parent="." instance=ExtResource( 6 )] - -[node name="Label" type="Label" parent="."] -margin_left = 12.0 -margin_top = -202.0 -margin_right = 358.0 -margin_bottom = -10.0 -size_flags_horizontal = 2 -size_flags_vertical = 0 -text = "This is a simple demo on how to make a platformer game with Godot.\"This version uses physics and the 2D physics engine for motion and collision.\"\"The demo also shows the benefits of using the scene system, where coins,\"enemies and the player are edited separatedly and instanced in the stage.\"\"To edit the base tiles for the tileset, open the tileset_edit.tscn file and follow \"instructions.\"" -autowrap = true - -[node name="Music" type="AudioStreamPlayer" parent="."] -stream = ExtResource( 8 ) -autoplay = true diff --git a/2d/platformer/TileSet.tres b/2d/platformer/TileSet.tres deleted file mode 100644 index 276213d12f..0000000000 --- a/2d/platformer/TileSet.tres +++ /dev/null @@ -1,243 +0,0 @@ -[gd_resource type="TileSet" load_steps=14 format=2] - -[ext_resource path="res://tiles_demo.png" type="Texture" id=1] - -[sub_resource type="ConvexPolygonShape2D" id=1] - -custom_solver_bias = 0.0 -points = PoolVector2Array( 32, -24, 32, 32, -32, 32, -32, -24 ) - -[sub_resource type="ConvexPolygonShape2D" id=2] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -24, 24, -24, 24, 32, -32, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=3] - -custom_solver_bias = 0.0 -points = PoolVector2Array( 32, -32, 32, 32, -32, 32, -32, -32 ) - -[sub_resource type="ConvexPolygonShape2D" id=4] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -56, 32, 8, 32, 64, -32, 64 ) - -[sub_resource type="ConvexPolygonShape2D" id=5] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -32, 24, -32, 24, 32, -32, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=6] - -custom_solver_bias = 0.0 -points = PoolVector2Array( 32, -24, 32, 24, -32, 24, -32, -24 ) - -[sub_resource type="ConvexPolygonShape2D" id=7] - -custom_solver_bias = 0.0 -points = PoolVector2Array( 24, -24, 24, 24, -32, 24, -32, -24 ) - -[sub_resource type="ConvexPolygonShape2D" id=8] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -32, 24, -32, 24, 32, -32, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=9] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -64, -32, -8, -32, -8, 32, -64, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=10] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -32, 24, -32, 32, -24, 32, 32, -32, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=11] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -24, 32, -24, 32, 32, -32, 32 ) - -[sub_resource type="ConvexPolygonShape2D" id=12] - -custom_solver_bias = 0.0 -points = PoolVector2Array( -32, -24, 32, -24, 32, 32, -32, 32 ) - -[resource] - -0/name = "floor" -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/occluder_offset = Vector2( 32, 32 ) -0/navigation_offset = Vector2( 32, 32 ) -0/shapes = [ { -"one_way": false, -"shape": SubResource( 1 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -1/name = "edge" -1/texture = ExtResource( 1 ) -1/tex_offset = Vector2( 0, 0 ) -1/modulate = Color( 1, 1, 1, 1 ) -1/region = Rect2( 64, 0, 64, 64 ) -1/occluder_offset = Vector2( 32, 32 ) -1/navigation_offset = Vector2( 32, 32 ) -1/shapes = [ { -"one_way": false, -"shape": SubResource( 2 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -2/name = "wall" -2/texture = ExtResource( 1 ) -2/tex_offset = Vector2( 0, 0 ) -2/modulate = Color( 1, 1, 1, 1 ) -2/region = Rect2( 64, 64, 64, 64 ) -2/occluder_offset = Vector2( 32, 32 ) -2/navigation_offset = Vector2( 32, 32 ) -2/shapes = [ { -"one_way": false, -"shape": SubResource( 8 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -3/name = "wall_deco" -3/texture = ExtResource( 1 ) -3/tex_offset = Vector2( 0, 0 ) -3/modulate = Color( 1, 1, 1, 1 ) -3/region = Rect2( 320, 128, 128, 64 ) -3/occluder_offset = Vector2( 64, 32 ) -3/navigation_offset = Vector2( 64, 32 ) -3/shapes = [ { -"one_way": false, -"shape": SubResource( 9 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 64, 32 ) -} ] -4/name = "corner" -4/texture = ExtResource( 1 ) -4/tex_offset = Vector2( 0, 0 ) -4/modulate = Color( 1, 1, 1, 1 ) -4/region = Rect2( 64, 128, 64, 64 ) -4/occluder_offset = Vector2( 32, 32 ) -4/navigation_offset = Vector2( 32, 32 ) -4/shapes = [ { -"one_way": false, -"shape": SubResource( 10 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -5/name = "flowers" -5/texture = ExtResource( 1 ) -5/tex_offset = Vector2( 0, 0 ) -5/modulate = Color( 1, 1, 1, 1 ) -5/region = Rect2( 192, 192, 64, 64 ) -5/occluder_offset = Vector2( 32, 32 ) -5/navigation_offset = Vector2( 32, 32 ) -5/shapes = [ { -"one_way": false, -"shape": SubResource( 11 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -6/name = "tree_base" -6/texture = ExtResource( 1 ) -6/tex_offset = Vector2( 0, 0 ) -6/modulate = Color( 1, 1, 1, 1 ) -6/region = Rect2( 256, 192, 64, 64 ) -6/occluder_offset = Vector2( 32, 32 ) -6/navigation_offset = Vector2( 32, 32 ) -6/shapes = [ { -"one_way": false, -"shape": SubResource( 12 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -7/name = "tree_mid" -7/texture = ExtResource( 1 ) -7/tex_offset = Vector2( 0, 0 ) -7/modulate = Color( 1, 1, 1, 1 ) -7/region = Rect2( 256, 128, 64, 64 ) -7/occluder_offset = Vector2( 32, 32 ) -7/navigation_offset = Vector2( 32, 32 ) -7/shapes = [ ] -8/name = "tree_mid 2" -8/texture = ExtResource( 1 ) -8/tex_offset = Vector2( 0, 0 ) -8/modulate = Color( 1, 1, 1, 1 ) -8/region = Rect2( 256, 64, 64, 64 ) -8/occluder_offset = Vector2( 32, 32 ) -8/navigation_offset = Vector2( 32, 32 ) -8/shapes = [ ] -9/name = "tree_top" -9/texture = ExtResource( 1 ) -9/tex_offset = Vector2( 0, 0 ) -9/modulate = Color( 1, 1, 1, 1 ) -9/region = Rect2( 256, 0, 64, 64 ) -9/occluder_offset = Vector2( 32, 32 ) -9/navigation_offset = Vector2( 32, 32 ) -9/shapes = [ ] -10/name = "solid" -10/texture = ExtResource( 1 ) -10/tex_offset = Vector2( 0, 0 ) -10/modulate = Color( 1, 1, 1, 1 ) -10/region = Rect2( 0, 64, 64, 64 ) -10/occluder_offset = Vector2( 32, 32 ) -10/navigation_offset = Vector2( 32, 32 ) -10/shapes = [ ] -11/name = "ceiling" -11/texture = ExtResource( 1 ) -11/tex_offset = Vector2( 0, 0 ) -11/modulate = Color( 1, 1, 1, 1 ) -11/region = Rect2( 384, 64, 64, 64 ) -11/occluder_offset = Vector2( 32, 32 ) -11/navigation_offset = Vector2( 32, 32 ) -11/shapes = [ { -"one_way": false, -"shape": SubResource( 3 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -12/name = "ramp" -12/texture = ExtResource( 1 ) -12/tex_offset = Vector2( 0, 0 ) -12/modulate = Color( 1, 1, 1, 1 ) -12/region = Rect2( 128, 128, 64, 128 ) -12/occluder_offset = Vector2( 32, 64 ) -12/navigation_offset = Vector2( 32, 64 ) -12/shapes = [ { -"one_way": false, -"shape": SubResource( 4 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 64 ) -} ] -13/name = "ceiling2wall" -13/texture = ExtResource( 1 ) -13/tex_offset = Vector2( 0, 0 ) -13/modulate = Color( 1, 1, 1, 1 ) -13/region = Rect2( 448, 64, 64, 64 ) -13/occluder_offset = Vector2( 32, 32 ) -13/navigation_offset = Vector2( 32, 32 ) -13/shapes = [ { -"one_way": false, -"shape": SubResource( 5 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -14/name = "platform_floor" -14/texture = ExtResource( 1 ) -14/tex_offset = Vector2( 0, 0 ) -14/modulate = Color( 1, 1, 1, 1 ) -14/region = Rect2( 128, 0, 64, 64 ) -14/occluder_offset = Vector2( 32, 32 ) -14/navigation_offset = Vector2( 32, 32 ) -14/shapes = [ { -"one_way": false, -"shape": SubResource( 6 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] -15/name = "platform_edge" -15/texture = ExtResource( 1 ) -15/tex_offset = Vector2( 0, 0 ) -15/modulate = Color( 1, 1, 1, 1 ) -15/region = Rect2( 192, 0, 64, 64 ) -15/occluder_offset = Vector2( 32, 32 ) -15/navigation_offset = Vector2( 32, 32 ) -15/shapes = [ { -"one_way": false, -"shape": SubResource( 7 ), -"shape_transform": Transform2D( 1, 0, 0, 1, 32, 32 ) -} ] - diff --git a/2d/platformer/TilesetEdit.tscn b/2d/platformer/TilesetEdit.tscn deleted file mode 100644 index 7b0153a364..0000000000 --- a/2d/platformer/TilesetEdit.tscn +++ /dev/null @@ -1,324 +0,0 @@ -[gd_scene load_steps=2 format=2] - -[ext_resource path="res://tiles_demo.png" type="Texture" id=1] - -[node name="Node" type="Node"] - -[node name="floor" type="Sprite" parent="."] - -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 0, 0, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="floor"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="floor/collision"] - -build_mode = 0 -polygon = PoolVector2Array( 32, -24, 32, 32, -32, 32, -32, -24 ) - -[node name="edge" type="Sprite" parent="."] - -position = Vector2( 64, 0 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 64, 0, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="edge"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="edge/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, -24, 24, -24, 24, 32, -32, 32 ) - -[node name="wall" type="Sprite" parent="."] - -position = Vector2( 64, 64 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 64, 64, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="wall"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="wall/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, -32, 24, -32, 24, 32, -32, 32 ) - -[node name="wall_deco" type="Sprite" parent="."] - -position = Vector2( 96, 128 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 320, 128, 128, 64 ) - -[node name="collision" type="StaticBody2D" parent="wall_deco"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="wall_deco/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -64, -32, -8, -32, -8, 32, -64, 32 ) - -[node name="corner" type="Sprite" parent="."] - -position = Vector2( 64, 192 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 64, 128, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="corner"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="corner/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, -32, 24, -32, 32, -24, 32, 32, -32, 32 ) - -[node name="flowers" type="Sprite" parent="."] - -position = Vector2( 128, 192 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 192, 192, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="flowers"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="flowers/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, 32, 32, 32, 32, -24, -32, -24 ) - -[node name="tree_base" type="Sprite" parent="."] - -position = Vector2( 192, 192 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 256, 192, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="tree_base"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="tree_base/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, 32, 32, 32, 32, -24, -32, -24 ) - -[node name="tree_mid" type="Sprite" parent="."] - -position = Vector2( 192, 128 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 256, 128, 64, 64 ) - -[node name="tree_mid 2" type="Sprite" parent="."] - -position = Vector2( 192, 64 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 256, 64, 64, 64 ) - -[node name="tree_top" type="Sprite" parent="."] - -position = Vector2( 192, 0 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 256, 0, 64, 64 ) - -[node name="solid" type="Sprite" parent="."] - -position = Vector2( 0, 64 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 0, 64, 64, 64 ) - -[node name="ceiling" type="Sprite" parent="."] - -position = Vector2( 0, 128 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 384, 64, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="ceiling"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="ceiling/collision"] - -build_mode = 0 -polygon = PoolVector2Array( 32, -32, 32, 32, -32, 32, -32, -32 ) - -[node name="ramp" type="Sprite" parent="."] - -position = Vector2( 256, 224 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 128, 128, 64, 128 ) - -[node name="collision" type="StaticBody2D" parent="ramp"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="ramp/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, -56, 32, 8, 32, 64, -32, 64 ) - -[node name="ceiling2wall" type="Sprite" parent="."] - -position = Vector2( 0, 192 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 448, 64, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="ceiling2wall"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="ceiling2wall/collision"] - -build_mode = 0 -polygon = PoolVector2Array( -32, -32, 24, -32, 24, 32, -32, 32 ) - -[node name="platform_floor" type="Sprite" parent="."] - -position = Vector2( 0, 256 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 128, 0, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="platform_floor"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="platform_floor/collision"] - -build_mode = 0 -polygon = PoolVector2Array( 32, -24, 32, 24, -32, 24, -32, -24 ) - -[node name="platform_edge" type="Sprite" parent="."] - -position = Vector2( 64, 256 ) -texture = ExtResource( 1 ) -region_enabled = true -region_rect = Rect2( 192, 0, 64, 64 ) - -[node name="collision" type="StaticBody2D" parent="platform_edge"] - -input_pickable = false -collision_layer = 1 -collision_mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="platform_edge/collision"] - -build_mode = 0 -polygon = PoolVector2Array( 24, -24, 24, 24, -32, 24, -32, -24 ) - -[node name="help" type="Label" parent="."] - -anchor_left = 0.0 -anchor_top = 0.0 -anchor_right = 0.0 -anchor_bottom = 0.0 -margin_left = 1.0 -margin_top = 331.0 -margin_right = 727.0 -margin_bottom = 422.0 -rect_pivot_offset = Vector2( 0, 0 ) -rect_clip_content = false -mouse_filter = 2 -size_flags_horizontal = 2 -size_flags_vertical = 0 -text = "This scene serves as a tool for editing the tileset. -Nodes (sprites) and their respective collisionsare edited here. - -To create a tileset from this, a \"TileSet\" resoucre must be created. Use the helper in: Scene -> Convert To -> TileSet. -This will save a tileset. Saving over it will merge your changes. - -Finally, the saved tileset resource (tileset.tres in this case), can be opened to be used into a TileMap node for editing a tile map." -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - - diff --git a/2d/platformer/background/scroll_bg_cloud_1.png b/2d/platformer/assets/art/background/cloud_1.png similarity index 100% rename from 2d/platformer/background/scroll_bg_cloud_1.png rename to 2d/platformer/assets/art/background/cloud_1.png diff --git a/2d/platformer/player/osb_jump.png.import b/2d/platformer/assets/art/background/cloud_1.png.import similarity index 69% rename from 2d/platformer/player/osb_jump.png.import rename to 2d/platformer/assets/art/background/cloud_1.png.import index 14db95e319..720169ee97 100644 --- a/2d/platformer/player/osb_jump.png.import +++ b/2d/platformer/assets/art/background/cloud_1.png.import @@ -2,15 +2,15 @@ importer="texture" type="StreamTexture" -path="res://.import/osb_jump.png-0d4d2b2d1a7d2c11e3e4fd800b8589ed.stex" +path="res://.import/cloud_1.png-03c0ad8be397b731df0dd38fa3c87727.stex" metadata={ "vram_texture": false } [deps] -source_file="res://player/osb_jump.png" -dest_files=[ "res://.import/osb_jump.png-0d4d2b2d1a7d2c11e3e4fd800b8589ed.stex" ] +source_file="res://assets/art/background/cloud_1.png" +dest_files=[ "res://.import/cloud_1.png-03c0ad8be397b731df0dd38fa3c87727.stex" ] [params] diff --git a/2d/platformer/background/scroll_bg_cloud_2.png b/2d/platformer/assets/art/background/cloud_2.png similarity index 100% rename from 2d/platformer/background/scroll_bg_cloud_2.png rename to 2d/platformer/assets/art/background/cloud_2.png diff --git a/2d/platformer/assets/art/background/cloud_2.png.import b/2d/platformer/assets/art/background/cloud_2.png.import new file mode 100644 index 0000000000..7fa52aad3e --- /dev/null +++ b/2d/platformer/assets/art/background/cloud_2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/cloud_2.png-4ddf8c5bceca4aa07a8bc86d7d788e02.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/art/background/cloud_2.png" +dest_files=[ "res://.import/cloud_2.png-4ddf8c5bceca4aa07a8bc86d7d788e02.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=false +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 +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/2d/platformer/background/scroll_bg_cloud_3.png b/2d/platformer/assets/art/background/cloud_3.png similarity index 100% rename from 2d/platformer/background/scroll_bg_cloud_3.png rename to 2d/platformer/assets/art/background/cloud_3.png diff --git a/2d/platformer/assets/art/background/cloud_3.png.import b/2d/platformer/assets/art/background/cloud_3.png.import new file mode 100644 index 0000000000..67c7f71c05 --- /dev/null +++ b/2d/platformer/assets/art/background/cloud_3.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/cloud_3.png-a1b7dc71aa84bea9cb4f78f585dcc65d.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/art/background/cloud_3.png" +dest_files=[ "res://.import/cloud_3.png-a1b7dc71aa84bea9cb4f78f585dcc65d.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=false +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 +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/2d/platformer/assets/art/background/distant_platforms_1.png b/2d/platformer/assets/art/background/distant_platforms_1.png new file mode 100644 index 0000000000000000000000000000000000000000..99821f356b51b81309f06a9212b6df201ee6a66a GIT binary patch literal 5203 zcmZ9O2|QH&_s8#8GFh@DNs6>s%94GX1v89oHfAx586$*H*(*#^rcpfALyO9irO48P zkR_3xq{tdsGTI1_Q1)bp$VeZB7M-g({gJ?H)Tob$bR&f>8)5~2#C002nXVo*c? z5CU%@08|jXC@f6NftU4%F)qOXAhvPkgaFsB%L9NwB;LUp4L&@9SI!SGxXjYVXpkK= z+;|DEF&Mid?mKg&aV&Ws&W`Nm9!SMAnN&Yll4p?j37RttYfGZw7zf+}85G|@uj6DK z-O<*GgrmDtd>t{)B)pqD`Je-a=!|!xlYAV(8?2if+1m;0#&q#@BYD}|5QvVhuFePS ztnp+5ok2ZFbfEcqgwmW3kioSpKdA?qAy_+S3f`UJ;!7g9x>LP<15+yg029v(D5 zKUM_B%8^F$AmJDkqPvHSuOBPS+RC0nV9>}cw51)H=oa909BpBXvaq$cCfcHL1bd2$ zlZQ9sh?Rvc2JJ{8cvxB3*ji)lY;Xhzs*|Iu71G*`;)S=Pl5q@s4Bp-b=i=l^babH- zS$GGs6V4T5<47Sg9qfoCke}*JaHP19JZ#YRaF_*&K=+^>f}108_9Pe#;o{7KnIS9@ zXiKEEjg`H%r5%;XG&hA?z)?0sBphXdK--`kFeoh6j%;cIL%^)8kQh^AbGW&s ziLt4iLsFx9ELD3G(y18dU|@shNfsMdtE(!LqlUTQ>4D0fr*is zE_g98GBhyRucvEhXlQB-*U{Z?Xk?5;p!e(Q>Fn1v0g+%<+WU31b@uD&fuW|_I$Byf z+D67^d_EuFGk9ZVPD6-TCjj}e+k52)%iad{X0W@k7yzWb!45b_^n8715!kCEC5#U? zzHo7Y@yG+p@^jXF{NPKq2uIqa)R3<&qbV;gX{96Z$^f4SD%?t zd_c}`H^HiZ&CNQ5W^qQ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hy5+;yRW^XG+2~Q)H1_Dzj%e6p~}?Hwr#CQtvSe!d0Ay^#SZ(LSgWHnl;aII15+J zJD-I=Ch58@vp>-eQ=GoEyx_ba-JoCO@@K)vJqkOTz&Jl;l@ep@esJFKig?km6JUym zow;zqS#YnGI$>&8qYFuPiDEw`ijx`R9+{48D2{F2cEW{g4#EIRd4g9ua?-+D#E-}G zFSsr?_31e_5;3+sp=;R_jQIz>>RMV>>Ry`}*0MKTzt!YEUpv(G`Bbe3 zcW)i?`KEC2W8Agd#T40*L-oe$@0Kgs)x-s*+dG3Ff45=tdA|sU!$S6w|DG#t7jzoA zbvgMEo}bzmZHO~c?_g>dKsMZoT)*>VwOBJ!nMCLadQ($lx=nZW?N0e3SRNIKYk{n6 z1pf;WNNAlHy7K7h<`0}`L_{st(-7#5Bi7{2`hfDZ)B(x}A1G5mju Crp2%T literal 0 HcmV?d00001 diff --git a/2d/platformer/assets/art/background/distant_platforms_2.png.import b/2d/platformer/assets/art/background/distant_platforms_2.png.import new file mode 100644 index 0000000000..73225a0e36 --- /dev/null +++ b/2d/platformer/assets/art/background/distant_platforms_2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/distant_platforms_2.png-ba010b30987da6d74062ce964ab450ef.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/art/background/distant_platforms_2.png" +dest_files=[ "res://.import/distant_platforms_2.png-ba010b30987da6d74062ce964ab450ef.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=false +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 +stream=false +size_limit=0 +detect_3d=false +svg/scale=1.0 diff --git a/2d/platformer/background/scroll_bg_sky.png b/2d/platformer/assets/art/background/sky.png similarity index 100% rename from 2d/platformer/background/scroll_bg_sky.png rename to 2d/platformer/assets/art/background/sky.png diff --git a/2d/platformer/player/osb_fire.png.import b/2d/platformer/assets/art/background/sky.png.import similarity index 70% rename from 2d/platformer/player/osb_fire.png.import rename to 2d/platformer/assets/art/background/sky.png.import index 8dc16ac3d9..535ab1c67c 100644 --- a/2d/platformer/player/osb_fire.png.import +++ b/2d/platformer/assets/art/background/sky.png.import @@ -2,15 +2,15 @@ importer="texture" type="StreamTexture" -path="res://.import/osb_fire.png-67a49910acd764fd7c67429af0ad5cb8.stex" +path="res://.import/sky.png-c175b712c46edc17f2b5fc55b9de3c49.stex" metadata={ "vram_texture": false } [deps] -source_file="res://player/osb_fire.png" -dest_files=[ "res://.import/osb_fire.png-67a49910acd764fd7c67429af0ad5cb8.stex" ] +source_file="res://assets/art/background/sky.png" +dest_files=[ "res://.import/sky.png-c175b712c46edc17f2b5fc55b9de3c49.stex" ] [params] diff --git a/2d/platformer/coin/coin.png b/2d/platformer/assets/art/coin/coin.png similarity index 100% rename from 2d/platformer/coin/coin.png rename to 2d/platformer/assets/art/coin/coin.png diff --git a/2d/platformer/coin/coin.png.import b/2d/platformer/assets/art/coin/coin.png.import similarity index 71% rename from 2d/platformer/coin/coin.png.import rename to 2d/platformer/assets/art/coin/coin.png.import index d63f0ad68a..6efc0524b2 100644 --- a/2d/platformer/coin/coin.png.import +++ b/2d/platformer/assets/art/coin/coin.png.import @@ -2,15 +2,15 @@ importer="texture" type="StreamTexture" -path="res://.import/coin.png-c9e5c2f51b2a10beb2d794afbbee004f.stex" +path="res://.import/coin.png-87689993f83db6056500d4fa153313d8.stex" metadata={ "vram_texture": false } [deps] -source_file="res://coin/coin.png" -dest_files=[ "res://.import/coin.png-c9e5c2f51b2a10beb2d794afbbee004f.stex" ] +source_file="res://assets/art/coin/coin.png" +dest_files=[ "res://.import/coin.png-87689993f83db6056500d4fa153313d8.stex" ] [params] diff --git a/2d/platformer/enemy/enemy.png b/2d/platformer/assets/art/enemy/enemy.png similarity index 100% rename from 2d/platformer/enemy/enemy.png rename to 2d/platformer/assets/art/enemy/enemy.png diff --git a/2d/platformer/enemy/enemy.png.import b/2d/platformer/assets/art/enemy/enemy.png.import similarity index 71% rename from 2d/platformer/enemy/enemy.png.import rename to 2d/platformer/assets/art/enemy/enemy.png.import index a7c3f0b96d..e8eb575f7d 100644 --- a/2d/platformer/enemy/enemy.png.import +++ b/2d/platformer/assets/art/enemy/enemy.png.import @@ -2,15 +2,15 @@ importer="texture" type="StreamTexture" -path="res://.import/enemy.png-1891d9038eeed672a2459bc4e7db5910.stex" +path="res://.import/enemy.png-c2f48b2558d3b68a547452306041a310.stex" metadata={ "vram_texture": false } [deps] -source_file="res://enemy/enemy.png" -dest_files=[ "res://.import/enemy.png-1891d9038eeed672a2459bc4e7db5910.stex" ] +source_file="res://assets/art/enemy/enemy.png" +dest_files=[ "res://.import/enemy.png-c2f48b2558d3b68a547452306041a310.stex" ] [params] diff --git a/2d/platformer/assets/art/platforms/moving_platform.png b/2d/platformer/assets/art/platforms/moving_platform.png new file mode 100644 index 0000000000000000000000000000000000000000..f3d7ce398f98c40191c9e378e8a2d6637f2c7f47 GIT binary patch literal 1037 zcmV+o1oHcdP)0i00001b5ch_0Itp) z=>Px#U{Fj{MF0Q*|NsA@QzR>!Mg94Q|Aq4Zh4LADFfz4KzG5o>h4TM}^1OxryoLX~ zh5!GB^8bbMyoLX~h5vy(6FM|PQ9oxfEjM6Ee`QQTKsHV`FD*?!UraqWK{z#CNkISq z|GGjj0{{R3AaqhrQvd+}0093Q009335D!fM3_3Io|NsC0{{a60{{R30|6&Cr8vpavj2Yo#&EzYMkruEKZdx3h+(Zx_JRMo3`D&plLRn z?G{!D*ntfT>+r)!9<&1R9s~%XZA0LOw_CFB?=iBdG_y^m7Do2dRxE@I@K!W4K)Px8 zLQ7=RIxHT){|MpdFWIM6${;gbXufIm3j67OTxgH1hldc>>$s-uqkYMSS<_rufZu;Y z`1|iu3DCA($4P~7Y^AH|y&QYW^IV>C_7J+R!Y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yX z1vTmrf4lH4a2`{=l^RyVPir9pMmW;vi;GHQwWPrD{rS)MUaqGq=CobiuB}Io3cH5* zY%$VaRImkpx_C4;RXPyvI5|*y{ZrwZXMgSeu?m-O18r>$!AnQRPEY3u?Ka#D`HV_@ z=?k$B*NXM$gI^SN>%XC&e;nWmdjD)!(#9I=j_^}?Iw#2zelG#=WrQ$;ml;s5{s&c4 Bw`BkT diff --git a/2d/platformer/background/scroll_bg_fg_1.png.import b/2d/platformer/background/scroll_bg_fg_1.png.import deleted file mode 100644 index 08be05e9b6..0000000000 --- a/2d/platformer/background/scroll_bg_fg_1.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="StreamTexture" -path="res://.import/scroll_bg_fg_1.png-20c90ebded5095c6863cdf6b1b82882d.stex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://background/scroll_bg_fg_1.png" -dest_files=[ "res://.import/scroll_bg_fg_1.png-20c90ebded5095c6863cdf6b1b82882d.stex" ] - -[params] - -compress/mode=0 -compress/lossy_quality=0.7 -compress/hdr_mode=0 -compress/bptc_ldr=0 -compress/normal_map=0 -flags/repeat=1 -flags/filter=false -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 -stream=false -size_limit=0 -detect_3d=false -svg/scale=1.0 diff --git a/2d/platformer/background/scroll_bg_fg_2.png b/2d/platformer/background/scroll_bg_fg_2.png deleted file mode 100644 index d1e7480f7b4b25ac3dc3acc26482632c8ac970da..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6003 zcmZ8j2RzjO|3B_<2q!7K(=sz6JI=o2xM7@eI3g=#6CG!iQo2&fPGlrol0=dyS&>B9 zoQ&*j{vWBn{r>lGkH>vJpV#~Sdan2D<0{rzpN)l&1q1@Ip^!Rw5C{whf#^U`FmNX{ zbyyd;h;r4|#-g;f;TL?o&bgj<0)c{3F5NnVtVakm*qJ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7u>&&)c>{R~eSFW67t=2PBvY{A$0FR$Bw zU{!eCej!zuVb??x@hyTY*k^qYzWqBDY(q--ao;oi_RssXAMcN;vu3Cb+OOD<%>3n_ z@n2R2{sX1KJPp_C_C5N=svzxIDA{)5Zsz@n;<_5+f0_)e52VkTI~?JSy*C4x*%&-s{an^LB{Ts5 DS3&P< diff --git a/2d/platformer/player/bullet.gd b/2d/platformer/player/bullet.gd deleted file mode 100644 index 49708fbc61..0000000000 --- a/2d/platformer/player/bullet.gd +++ /dev/null @@ -1,11 +0,0 @@ -extends RigidBody2D - -class_name Bullet - - -func _on_bullet_body_enter(body): - if body.has_method("hit_by_bullet"): - body.call("hit_by_bullet") - -func _on_Timer_timeout(): - ($Anim as AnimationPlayer).play("shutdown") diff --git a/2d/platformer/player/osb_left.png.import b/2d/platformer/player/osb_left.png.import deleted file mode 100644 index 02a50bd154..0000000000 --- a/2d/platformer/player/osb_left.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="StreamTexture" -path="res://.import/osb_left.png-95ec3a371455889d592aa8cae0a755bc.stex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://player/osb_left.png" -dest_files=[ "res://.import/osb_left.png-95ec3a371455889d592aa8cae0a755bc.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=false -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 -stream=false -size_limit=0 -detect_3d=false -svg/scale=1.0 diff --git a/2d/platformer/player/osb_right.png.import b/2d/platformer/player/osb_right.png.import deleted file mode 100644 index 35a3522ce1..0000000000 --- a/2d/platformer/player/osb_right.png.import +++ /dev/null @@ -1,34 +0,0 @@ -[remap] - -importer="texture" -type="StreamTexture" -path="res://.import/osb_right.png-db9bb4651315f3d42b87bd17a86cce76.stex" -metadata={ -"vram_texture": false -} - -[deps] - -source_file="res://player/osb_right.png" -dest_files=[ "res://.import/osb_right.png-db9bb4651315f3d42b87bd17a86cce76.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=false -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 -stream=false -size_limit=0 -detect_3d=false -svg/scale=1.0 diff --git a/2d/platformer/player/player.gd b/2d/platformer/player/player.gd deleted file mode 100644 index 681f6573a3..0000000000 --- a/2d/platformer/player/player.gd +++ /dev/null @@ -1,97 +0,0 @@ -extends KinematicBody2D - -class_name Player - - -const GRAVITY_VEC = Vector2(0, 900) -const FLOOR_NORMAL = Vector2(0, -1) -const SLOPE_SLIDE_STOP = 25.0 -const WALK_SPEED = 250 # pixels/sec -const JUMP_SPEED = 480 -const SIDING_CHANGE_SPEED = 10 -const BULLET_VELOCITY = 1000 -const SHOOT_TIME_SHOW_WEAPON = 0.2 - -var linear_vel = Vector2() -var shoot_time = 99999 # time since last shot - -var anim = "" - -# cache the sprite here for fast access (we will set scale to flip it often) -onready var sprite = $Sprite -# cache bullet for fast access -var Bullet = preload("res://player/Bullet.tscn") - - -func _physics_process(delta): - # Increment counters - shoot_time += delta - - ### MOVEMENT ### - - # Apply gravity - linear_vel += delta * GRAVITY_VEC - # Move and slide - linear_vel = move_and_slide(linear_vel, FLOOR_NORMAL, SLOPE_SLIDE_STOP) - # Detect if we are on floor - only works if called *after* move_and_slide - var on_floor = is_on_floor() - - ### CONTROL ### - - # Horizontal movement - var target_speed = 0 - if Input.is_action_pressed("move_left"): - target_speed -= 1 - if Input.is_action_pressed("move_right"): - target_speed += 1 - - target_speed *= WALK_SPEED - linear_vel.x = lerp(linear_vel.x, target_speed, 0.1) - - # Jumping - if on_floor and Input.is_action_just_pressed("jump"): - linear_vel.y = -JUMP_SPEED - ($SoundJump as AudioStreamPlayer2D).play() - - # Shooting - if Input.is_action_just_pressed("shoot"): - var bullet = Bullet.instance() - bullet.position = ($Sprite/BulletShoot as Position2D).global_position # use node for shoot position - bullet.linear_velocity = Vector2(sprite.scale.x * BULLET_VELOCITY, 0) - bullet.add_collision_exception_with(self) # don't want player to collide with bullet - get_parent().add_child(bullet) # don't want bullet to move with me, so add it as child of parent - ($SoundShoot as AudioStreamPlayer2D).play() - shoot_time = 0 - - ### ANIMATION ### - - var new_anim = "idle" - - if on_floor: - if linear_vel.x < -SIDING_CHANGE_SPEED: - sprite.scale.x = -1 - new_anim = "run" - - if linear_vel.x > SIDING_CHANGE_SPEED: - sprite.scale.x = 1 - new_anim = "run" - else: - # We want the character to immediately change facing side when the player - # tries to change direction, during air control. - # This allows for example the player to shoot quickly left then right. - if Input.is_action_pressed("move_left") and not Input.is_action_pressed("move_right"): - sprite.scale.x = -1 - if Input.is_action_pressed("move_right") and not Input.is_action_pressed("move_left"): - sprite.scale.x = 1 - - if linear_vel.y < 0: - new_anim = "jumping" - else: - new_anim = "falling" - - if shoot_time < SHOOT_TIME_SHOW_WEAPON: - new_anim += "_weapon" - - if new_anim != anim: - anim = new_anim - ($Anim as AnimationPlayer).play(anim) diff --git a/2d/platformer/project.godot b/2d/platformer/project.godot index bbd89f03da..9350ec7a4e 100644 --- a/2d/platformer/project.godot +++ b/2d/platformer/project.godot @@ -9,43 +9,49 @@ config_version=4 _global_script_classes=[ { +"base": "KinematicBody2D", +"class": "Actor", +"language": "GDScript", +"path": "res://src/Actors/Actor.gd" +}, { "base": "RigidBody2D", "class": "Bullet", "language": "GDScript", -"path": "res://player/bullet.gd" +"path": "res://src/Objects/Bullet.gd" }, { "base": "Area2D", "class": "Coin", "language": "GDScript", -"path": "res://coin/coin.gd" +"path": "res://src/Objects/Coin.gd" }, { -"base": "KinematicBody2D", +"base": "Actor", "class": "Enemy", "language": "GDScript", -"path": "res://enemy/enemy.gd" +"path": "res://src/Actors/Enemy.gd" }, { -"base": "Node2D", -"class": "MovingPlatform", +"base": "Position2D", +"class": "Gun", "language": "GDScript", -"path": "res://platform/moving_platform.gd" +"path": "res://src/Actors/Gun.gd" }, { -"base": "KinematicBody2D", +"base": "Actor", "class": "Player", "language": "GDScript", -"path": "res://player/player.gd" +"path": "res://src/Actors/Player.gd" } ] _global_script_class_icons={ +"Actor": "", "Bullet": "", "Coin": "", "Enemy": "", -"MovingPlatform": "", +"Gun": "", "Player": "" } [application] config/name="Platformer 2D" -run/main_scene="res://Stage.tscn" +run/main_scene="res://src/Main/Game.tscn" config/icon="res://icon.png" target_fps="60" @@ -61,8 +67,11 @@ gdscript/warnings/unsafe_call_argument=true window/size/width=800 window/size/height=480 +window/size/test_width=1600 +window/size/test_height=960 +window/dpi/allow_hidpi=true window/stretch/mode="2d" -window/stretch/aspect="keep_height" +window/stretch/aspect="expand" stretch/aspect="keep_height" stretch/mode="2d" @@ -80,18 +89,21 @@ jump={ "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":16777232,"unicode":0,"echo":false,"script":null) , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":0,"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":87,"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":16777231,"unicode":0,"echo":false,"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":65,"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":16777233,"unicode":0,"echo":false,"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":68,"unicode":0,"echo":false,"script":null) ] } shoot={ @@ -99,6 +111,7 @@ shoot={ "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":32,"unicode":0,"echo":false,"script":null) , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":2,"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":90,"unicode":0,"echo":false,"script":null) +, Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"button_mask":0,"position":Vector2( 0, 0 ),"global_position":Vector2( 0, 0 ),"factor":1.0,"button_index":1,"pressed":false,"doubleclick":false,"script":null) ] } spawn={ @@ -107,6 +120,25 @@ spawn={ , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":11,"pressure":0.0,"pressed":false,"script":null) ] } +toggle_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,"unicode":0,"echo":false,"script":null) + ] +} +toggle_pause={ +"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":16777217,"unicode":0,"echo":false,"script":null) +, Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":11,"pressure":0.0,"pressed":false,"script":null) + ] +} + +[layer_names] + +2d_physics/layer_1="player" +2d_physics/layer_2="enemies" +2d_physics/layer_3="coins" +2d_physics/layer_4="platforms" +2d_physics/layer_5="ground" [physics] @@ -124,9 +156,9 @@ mipmap_policy=1 quality/intended_usage/framebuffer_allocation=0 quality/intended_usage/framebuffer_allocation.mobile=1 +quality/2d/use_pixel_snap=true quality/filters/anisotropic_filter_level=2 quality/filters/use_nearest_mipmap_filter=true -quality/voxel_cone_tracing/high_quality=false quality/depth/hdr=false [texture_import] diff --git a/2d/platformer/src/Actors/Actor.gd b/2d/platformer/src/Actors/Actor.gd new file mode 100644 index 0000000000..980768f43a --- /dev/null +++ b/2d/platformer/src/Actors/Actor.gd @@ -0,0 +1,18 @@ +extends KinematicBody2D +class_name Actor + +# Both the Player and Enemy inherit this scene as they have shared behaviours such as +# speed and are affected by gravity. + + +export var speed = Vector2(400.0, 500.0) +export var gravity = 3500.0 + +const FLOOR_NORMAL = Vector2.UP + +var _velocity = Vector2.ZERO + +# _physics_process is called after the inherited _physics_process function. +# This allows the Player and Enemy scenes to be affected by gravity. +func _physics_process(delta): + _velocity.y += gravity * delta diff --git a/2d/platformer/src/Actors/Enemy.gd b/2d/platformer/src/Actors/Enemy.gd new file mode 100644 index 0000000000..6db70ac0aa --- /dev/null +++ b/2d/platformer/src/Actors/Enemy.gd @@ -0,0 +1,78 @@ +extends Actor +class_name Enemy + + +onready var platform_detector = $PlatformDetector +onready var floor_detector_left = $FloorDetectorLeft +onready var floor_detector_right = $FloorDetectorRight +onready var sprite = $Sprite +onready var animation_player = $AnimationPlayer + +enum State {WALKING, DEAD} + +var _state = State.WALKING + +# This function is called when the scene enters the scene tree. +# We can initialize variables here. +func _ready(): + _velocity.x = speed.x + +# Physics process is a built-in loop in Godot. +# If you define _physics_process on a node, Godot will call it every frame. + +# At a glance, you can see that the physics process loop: +# 1. Calculates the move velocity. +# 2. Moves the character. +# 3. Updates the sprite direction. +# 4. Updates the animation. + +# Splitting the physics process logic into functions not only makes it easier to read, it help to +# change or improve the code later on: +# - If you need to change a calculation, you can use Go To -> Function (Ctrl Alt F) to quickly +# jump to the corresponding function. +# - If you split the character into a state machine or more advanced pattern, you can easily move +# individual functions. +func _physics_process(_delta): + _velocity = calculate_move_velocity(_velocity) + + # We only update the y value of _velocity as we want to handle the horizontal movement ourselves. + _velocity.y = move_and_slide(_velocity, FLOOR_NORMAL).y + + # We flip the Sprite depending on which way the enemy is moving. + sprite.scale.x = 1 if _velocity.x > 0 else -1 + + var animation = get_new_animation() + if animation != animation_player.current_animation: + animation_player.play(animation) + + +func destroy(): + _state = State.DEAD + _velocity = Vector2.ZERO + + +# This function calculates a new velocity whenever you need it. +# If the enemy encounters a wall or an edge, the horizontal velocity is flipped. +func calculate_move_velocity( + linear_velocity + ): + var velocity = linear_velocity + + if not floor_detector_left.is_colliding(): + velocity.x = speed.x + elif not floor_detector_right.is_colliding(): + velocity.x = -speed.x + + if is_on_wall(): + velocity.x *= -1 + + return velocity + + +func get_new_animation(): + var animation_new = "" + if _state == State.WALKING: + animation_new = "walk" if abs(_velocity.x) > 0 else "idle" + else: + animation_new = "destroy" + return animation_new diff --git a/2d/platformer/enemy/Enemy.tscn b/2d/platformer/src/Actors/Enemy.tscn similarity index 52% rename from 2d/platformer/enemy/Enemy.tscn rename to 2d/platformer/src/Actors/Enemy.tscn index 501f08dce8..ae55902cf2 100644 --- a/2d/platformer/enemy/Enemy.tscn +++ b/2d/platformer/src/Actors/Enemy.tscn @@ -1,15 +1,16 @@ -[gd_scene load_steps=13 format=2] - -[ext_resource path="res://enemy/enemy.gd" type="Script" id=1] -[ext_resource path="res://enemy/enemy.png" type="Texture" id=2] -[ext_resource path="res://player/bullet.png" type="Texture" id=3] -[ext_resource path="res://audio/sound_hit.wav" type="AudioStream" id=4] -[ext_resource path="res://audio/sound_explode.wav" type="AudioStream" id=5] - -[sub_resource type="Animation" id=1] -resource_name = "explode" -length = 5.0 -step = 0.0 +[gd_scene load_steps=15 format=2] + +[ext_resource path="res://assets/art/player/bullet/bullet.png" type="Texture" id=1] +[ext_resource path="res://assets/audio/sfx/explode.wav" type="AudioStream" id=2] +[ext_resource path="res://assets/audio/sfx/hit.wav" type="AudioStream" id=3] +[ext_resource path="res://assets/art/enemy/enemy.png" type="Texture" id=4] +[ext_resource path="res://src/Actors/Enemy.gd" type="Script" id=5] + +[sub_resource type="CanvasItemMaterial" id=1] + +[sub_resource type="Animation" id=2] +resource_name = "destroy" +length = 1.5 tracks/0/type = "value" tracks/0/path = NodePath("Sprite:frame") tracks/0/interp = 1 @@ -20,7 +21,7 @@ tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 0, -"values": [ 0 ] +"values": [ 7 ] } tracks/1/type = "value" tracks/1/path = NodePath("Sprite:rotation_degrees") @@ -29,8 +30,8 @@ tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { -"times": PoolRealArray( 0, 3.2 ), -"transitions": PoolRealArray( 0.5, 1 ), +"times": PoolRealArray( 0, 0.8 ), +"transitions": PoolRealArray( 0.0796601, 1 ), "update": 0, "values": [ 0.0, 180.0 ] } @@ -41,10 +42,10 @@ tracks/2/loop_wrap = true tracks/2/imported = false tracks/2/enabled = true tracks/2/keys = { -"times": PoolRealArray( 2.6, 3.4 ), -"transitions": PoolRealArray( 1, 1 ), +"times": PoolRealArray( 0, 0.3, 0.9 ), +"transitions": PoolRealArray( 1, 1, 1 ), "update": 0, -"values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 0 ) ] +"values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 0 ) ] } tracks/3/type = "value" tracks/3/path = NodePath("Explosion:emitting") @@ -53,7 +54,7 @@ tracks/3/loop_wrap = true tracks/3/imported = false tracks/3/enabled = true tracks/3/keys = { -"times": PoolRealArray( 0, 2.8 ), +"times": PoolRealArray( 0, 0.8 ), "transitions": PoolRealArray( 1, 1 ), "update": 1, "values": [ false, true ] @@ -65,13 +66,13 @@ tracks/4/loop_wrap = true tracks/4/imported = false tracks/4/enabled = true tracks/4/keys = { -"times": PoolRealArray( 2.8, 3.4 ), +"times": PoolRealArray( 0.4, 0.8 ), "transitions": PoolRealArray( 1, 1 ), "update": 0, "values": [ 1.0, 4.0 ] } tracks/5/type = "value" -tracks/5/path = NodePath("SoundHit:playing") +tracks/5/path = NodePath("Hit:playing") tracks/5/interp = 1 tracks/5/loop_wrap = true tracks/5/imported = false @@ -83,13 +84,13 @@ tracks/5/keys = { "values": [ true ] } tracks/6/type = "value" -tracks/6/path = NodePath("SoundExplode:playing") +tracks/6/path = NodePath("Explode:playing") tracks/6/interp = 1 tracks/6/loop_wrap = true tracks/6/imported = false tracks/6/enabled = true tracks/6/keys = { -"times": PoolRealArray( 2.9 ), +"times": PoolRealArray( 0.6 ), "transitions": PoolRealArray( 1 ), "update": 1, "values": [ true ] @@ -101,15 +102,39 @@ tracks/7/loop_wrap = true tracks/7/imported = false tracks/7/enabled = true tracks/7/keys = { -"times": PoolRealArray( 4.2 ), +"times": PoolRealArray( 1.5 ), "transitions": PoolRealArray( 1 ), "values": [ { "args": [ ], "method": "queue_free" } ] } +tracks/8/type = "value" +tracks/8/path = NodePath(".:collision_layer") +tracks/8/interp = 1 +tracks/8/loop_wrap = true +tracks/8/imported = false +tracks/8/enabled = true +tracks/8/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ 0 ] +} +tracks/9/type = "value" +tracks/9/path = NodePath("Sprite:position") +tracks/9/interp = 1 +tracks/9/loop_wrap = true +tracks/9/imported = false +tracks/9/enabled = true +tracks/9/keys = { +"times": PoolRealArray( 0, 0.2, 0.4 ), +"transitions": PoolRealArray( 2.2974, 0.183011, 1 ), +"update": 0, +"values": [ Vector2( 0, 0 ), Vector2( 0, -32 ), Vector2( 0, 0 ) ] +} -[sub_resource type="Animation" id=2] +[sub_resource type="Animation" id=3] length = 6.75 loop = true step = 0.25 @@ -126,8 +151,7 @@ tracks/0/keys = { "values": [ 5, 6, 5, 6, 5, 6, 7, 6, 7, 5 ] } -[sub_resource type="Animation" id=3] -resource_name = "walk" +[sub_resource type="Animation" id=4] length = 1.25 loop = true step = 0.25 @@ -144,8 +168,6 @@ tracks/0/keys = { "values": [ 0, 1, 2, 3, 4, 0 ] } -[sub_resource type="CanvasItemMaterial" id=4] - [sub_resource type="CapsuleShape2D" id=5] radius = 13.4556 height = 14.2002 @@ -153,58 +175,73 @@ height = 14.2002 [sub_resource type="CanvasItemMaterial" id=6] blend_mode = 1 -[sub_resource type="ParticlesMaterial" id=7] +[sub_resource type="Gradient" id=7] +offsets = PoolRealArray( 0.562963, 1 ) +colors = PoolColorArray( 1, 1, 1, 1, 0, 0, 0, 1 ) + +[sub_resource type="GradientTexture" id=8] +gradient = SubResource( 7 ) +width = 256 + +[sub_resource type="ParticlesMaterial" id=9] +emission_shape = 1 +emission_sphere_radius = 8.0 flag_disable_z = true -gravity = Vector3( 0, 98, 0 ) +spread = 180.0 +gravity = Vector3( 0, 250, 0 ) +initial_velocity = 120.0 +initial_velocity_random = 0.5 orbit_velocity = 0.0 orbit_velocity_random = 0.0 +angle = 720.0 +angle_random = 1.0 +scale = 0.4 +scale_random = 1.0 +color_ramp = SubResource( 8 ) +hue_variation = 0.05 +hue_variation_random = 0.46 [node name="Enemy" type="KinematicBody2D"] -script = ExtResource( 1 ) +collision_layer = 2 +collision_mask = 24 +script = ExtResource( 5 ) +speed = Vector2( 150, 500 ) +gravity = 1800.0 -[node name="Enabler" type="VisibilityEnabler2D" parent="."] -position = Vector2( 16.2569, 11.0034 ) -scale = Vector2( 23.5056, 10.8629 ) -pause_particles = false +[node name="PlatformDetector" type="RayCast2D" parent="."] +position = Vector2( 0, 12 ) +enabled = true +cast_to = Vector2( 0, 8 ) +collision_mask = 8 -[node name="Anim" type="AnimationPlayer" parent="."] -anims/explode = SubResource( 1 ) -anims/idle = SubResource( 2 ) -anims/walk = SubResource( 3 ) +[node name="FloorDetectorLeft" type="RayCast2D" parent="."] +position = Vector2( -30, -8 ) +enabled = true +cast_to = Vector2( 0, 70 ) +collision_mask = 24 + +[node name="FloorDetectorRight" type="RayCast2D" parent="."] +position = Vector2( 31.16, -8 ) +enabled = true +cast_to = Vector2( 0, 70 ) +collision_mask = 24 [node name="Sprite" type="Sprite" parent="."] -material = SubResource( 4 ) -texture = ExtResource( 2 ) +material = SubResource( 1 ) +texture = ExtResource( 4 ) flip_h = true hframes = 8 +frame = 5 + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +anims/destroy = SubResource( 2 ) +anims/idle = SubResource( 3 ) +anims/walk = SubResource( 4 ) [node name="CollisionShape2D" type="CollisionShape2D" parent="."] -position = Vector2( -0.00525069, -0.727495 ) rotation = -1.5708 shape = SubResource( 5 ) -[node name="DetectFloorLeft" type="RayCast2D" parent="."] -position = Vector2( -33.2868, -9.34363 ) -enabled = true -cast_to = Vector2( 0, 45 ) - -[node name="DetectWallLeft" type="RayCast2D" parent="."] -position = Vector2( -12.1361, -0.739977 ) -rotation = 1.5708 -enabled = true -cast_to = Vector2( 0, 20 ) - -[node name="DetectWallRight" type="RayCast2D" parent="."] -position = Vector2( 3.2788, -0.381488 ) -rotation = -1.5708 -enabled = true -cast_to = Vector2( 0, 20 ) - -[node name="DetectFloorRight" type="RayCast2D" parent="."] -position = Vector2( 29.1987, -9.34363 ) -enabled = true -cast_to = Vector2( 0, 45 ) - [node name="Explosion" type="Particles2D" parent="."] self_modulate = Color( 1, 1, 1, 0.12 ) material = SubResource( 6 ) @@ -213,13 +250,13 @@ amount = 32 lifetime = 0.5 one_shot = true speed_scale = 1.2 -explosiveness = 0.1 -process_material = SubResource( 7 ) -texture = ExtResource( 3 ) - -[node name="SoundHit" type="AudioStreamPlayer2D" parent="."] -stream = ExtResource( 4 ) +explosiveness = 0.76 +draw_order = 215832976 +process_material = SubResource( 9 ) +texture = ExtResource( 1 ) -[node name="SoundExplode" type="AudioStreamPlayer2D" parent="."] -stream = ExtResource( 5 ) +[node name="Hit" type="AudioStreamPlayer2D" parent="."] +stream = ExtResource( 3 ) +[node name="Explode" type="AudioStreamPlayer2D" parent="."] +stream = ExtResource( 2 ) diff --git a/2d/platformer/src/Actors/Gun.gd b/2d/platformer/src/Actors/Gun.gd new file mode 100644 index 0000000000..588f289337 --- /dev/null +++ b/2d/platformer/src/Actors/Gun.gd @@ -0,0 +1,24 @@ +extends Position2D +class_name Gun +# Represents a weapon that spawns and shoots bullets. +# The Cooldown timer controls the cooldown duration between shots. + + +onready var sound_shoot = $Shoot +onready var timer = $Cooldown + +const Bullet = preload("res://src/Objects/Bullet.tscn") +const BULLET_VELOCITY = 1000.0 + + +func shoot(direction = 1): + if not timer.is_stopped(): + return false + var bullet = Bullet.instance() + bullet.global_position = global_position + bullet.linear_velocity = Vector2(direction * BULLET_VELOCITY, 0) + + bullet.set_as_toplevel(true) + add_child(bullet) + sound_shoot.play() + return true diff --git a/2d/platformer/src/Actors/Player.gd b/2d/platformer/src/Actors/Player.gd new file mode 100644 index 0000000000..0b39f6f614 --- /dev/null +++ b/2d/platformer/src/Actors/Player.gd @@ -0,0 +1,96 @@ +extends Actor +class_name Player + + +const FLOOR_DETECT_DISTANCE = 40.0 + +onready var platform_detector = $PlatformDetector +onready var sprite = $Sprite +onready var animation_player = $AnimationPlayer +onready var shoot_timer = $ShootAnimation +onready var gun = $Sprite/Gun + + +# Physics process is a built-in loop in Godot. +# If you define _physics_process on a node, Godot will call it every frame. + +# We use separate functions to calculate the direction and velocity to make this one easier to read. +# At a glance, you can see that the physics process loop: +# 1. Calculates the move direction. +# 2. Calculates the move velocity. +# 3. Moves the character. +# 4. Updates the sprite direction. +# 5. Shoots bullets. +# 6. Updates the animation. + +# # Splitting the physics process logic into functions not only makes it easier to read, it help to +# change or improve the code later on: +# - If you need to change a calculation, you can use Go To -> Function (Ctrl Alt F) to quickly +# jump to the corresponding function. +# - If you split the character into a state machine or more advanced pattern, you can easily move +# individual functions. +func _physics_process(_delta): + var direction = get_direction() + + var is_jump_interrupted = Input.is_action_just_released("jump") and _velocity.y < 0.0 + _velocity = calculate_move_velocity(_velocity, direction, speed, is_jump_interrupted) + + var snap_vector = Vector2.DOWN * FLOOR_DETECT_DISTANCE if direction.y == 0.0 else Vector2.ZERO + var is_on_platform = platform_detector.is_colliding() + _velocity = move_and_slide_with_snap( + _velocity, snap_vector, FLOOR_NORMAL, not is_on_platform, 4, 0.9, false + ) + + # When the character’s direction changes, we want to to scale the Sprite accordingly to flip it. + # This will make Robi face left or right depending on the direction you move. + if direction.x != 0: + sprite.scale.x = direction.x + + # We use the sprite's scale to store Robi’s look direction which allows us to shoot + # bullets forward. + # There are many situations like these where you can reuse existing properties instead of + # creating new variables. + var is_shooting = false + if Input.is_action_just_pressed("shoot"): + is_shooting = gun.shoot(sprite.scale.x) + + var animation = get_new_animation(is_shooting) + if animation != animation_player.current_animation and shoot_timer.is_stopped(): + if is_shooting: + shoot_timer.start() + animation_player.play(animation) + + +func get_direction(): + return Vector2( + Input.get_action_strength("move_right") - Input.get_action_strength("move_left"), + -Input.get_action_strength("jump") if is_on_floor() and Input.is_action_just_pressed("jump") else 0.0 + ) + + +# This function calculates a new velocity whenever you need it. +# It allows you to interrupt jumps. +func calculate_move_velocity( + linear_velocity, + direction, + speed, + is_jump_interrupted + ): + var velocity = linear_velocity + velocity.x = speed.x * direction.x + if direction.y != 0.0: + velocity.y = speed.y * direction.y + if is_jump_interrupted: + velocity.y = 0.0 + return velocity + + +func get_new_animation(is_shooting = false): + var animation_new = "" + if is_on_floor(): + animation_new = "run" if abs(_velocity.x) > 0.1 else "idle" + else: + animation_new = "falling" if _velocity.y > 0 else "jumping" + if is_shooting: + animation_new += "_weapon" + return animation_new diff --git a/2d/platformer/player/Player.tscn b/2d/platformer/src/Actors/Player.tscn similarity index 74% rename from 2d/platformer/player/Player.tscn rename to 2d/platformer/src/Actors/Player.tscn index aacabf256a..234d976dbd 100644 --- a/2d/platformer/player/Player.tscn +++ b/2d/platformer/src/Actors/Player.tscn @@ -1,13 +1,14 @@ -[gd_scene load_steps=20 format=2] +[gd_scene load_steps=21 format=2] -[ext_resource path="res://player/player.gd" type="Script" id=1] -[ext_resource path="res://player/robot_demo.png" type="Texture" id=2] -[ext_resource path="res://audio/sound_jump.wav" type="AudioStream" id=3] -[ext_resource path="res://audio/sound_shoot.wav" type="AudioStream" id=4] -[ext_resource path="res://player/osb_left.png" type="Texture" id=5] -[ext_resource path="res://player/osb_right.png" type="Texture" id=6] -[ext_resource path="res://player/osb_jump.png" type="Texture" id=7] -[ext_resource path="res://player/osb_fire.png" type="Texture" id=8] +[ext_resource path="res://src/Actors/Player.gd" type="Script" id=1] +[ext_resource path="res://assets/art/player/robot_demo.png" type="Texture" id=2] +[ext_resource path="res://assets/audio/sfx/jump.wav" type="AudioStream" id=3] +[ext_resource path="res://assets/audio/sfx/shoot.wav" type="AudioStream" id=4] +[ext_resource path="res://assets/art/ui/touch_button_left.png" type="Texture" id=5] +[ext_resource path="res://assets/art/ui/touch_button_right.png" type="Texture" id=6] +[ext_resource path="res://assets/art/ui/touch_button_jump.png" type="Texture" id=7] +[ext_resource path="res://assets/art/ui/touch_button_fire.png" type="Texture" id=8] +[ext_resource path="res://src/Actors/Gun.gd" type="Script" id=9] [sub_resource type="Animation" id=1] resource_name = "crouch" @@ -182,26 +183,47 @@ tracks/0/keys = { "values": [ 10, 11, 12, 13, 14, 5 ] } -[sub_resource type="CapsuleShape2D" id=11] -height = 44.4787 +[sub_resource type="RectangleShape2D" id=11] +extents = Vector2( 10, 27 ) [node name="Player" type="KinematicBody2D"] +collision_mask = 30 script = ExtResource( 1 ) +speed = Vector2( 300, 700 ) +gravity = 1800.0 + +[node name="ShootAnimation" type="Timer" parent="."] +process_mode = 0 +wait_time = 0.2 +one_shot = true + +[node name="PlatformDetector" type="RayCast2D" parent="."] +enabled = true +cast_to = Vector2( 0, 6 ) +collision_mask = 8 [node name="Sprite" type="Sprite" parent="."] +position = Vector2( 0, -28 ) texture = ExtResource( 2 ) vframes = 2 hframes = 16 -frame = 22 - -[node name="Smoke" type="Node2D" parent="Sprite"] -position = Vector2( 20.7312, 3.21187 ) -rotation = -1.45648 +frame = 16 -[node name="BulletShoot" type="Position2D" parent="Sprite"] +[node name="Gun" type="Position2D" parent="Sprite"] position = Vector2( 30.6589, 6.13176 ) +script = ExtResource( 9 ) + +[node name="Shoot" type="AudioStreamPlayer2D" parent="Sprite/Gun"] +position = Vector2( -30.6589, -6.13176 ) +stream = ExtResource( 4 ) -[node name="Anim" type="AnimationPlayer" parent="."] +[node name="Cooldown" type="Timer" parent="Sprite/Gun"] +process_mode = 0 +wait_time = 0.3 +one_shot = true + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +playback_speed = 2.6 anims/crouch = SubResource( 1 ) anims/falling = SubResource( 2 ) anims/falling_weapon = SubResource( 3 ) @@ -214,20 +236,17 @@ anims/run_weapon = SubResource( 9 ) anims/standing_weapon_ready = SubResource( 10 ) [node name="Camera" type="Camera2D" parent="."] +position = Vector2( 0, -28 ) current = true -limit_left = 0 -limit_top = 0 +process_mode = 0 [node name="CollisionShape2D" type="CollisionShape2D" parent="."] -position = Vector2( 0.291992, -0.835023 ) +position = Vector2( 0, -27 ) shape = SubResource( 11 ) -[node name="SoundJump" type="AudioStreamPlayer2D" parent="."] +[node name="Jump" type="AudioStreamPlayer2D" parent="."] stream = ExtResource( 3 ) -[node name="SoundShoot" type="AudioStreamPlayer2D" parent="."] -stream = ExtResource( 4 ) - [node name="UI" type="CanvasLayer" parent="."] layer = 0 @@ -247,23 +266,15 @@ passby_press = true action = "move_right" visibility_mode = 1 -[node name="BottomRightAnchor" type="Control" parent="UI"] -anchor_left = 1.0 -anchor_top = 1.0 -anchor_right = 1.0 -anchor_bottom = 1.0 -margin_left = -40.0 -margin_top = -40.0 - -[node name="Jump" type="TouchScreenButton" parent="UI/BottomRightAnchor"] -position = Vector2( -98.151, -83.768 ) +[node name="Jump" type="TouchScreenButton" parent="UI"] +position = Vector2( 666.224, 359.02 ) scale = Vector2( 1.49157, 1.46265 ) normal = ExtResource( 7 ) action = "jump" visibility_mode = 1 -[node name="Fire" type="TouchScreenButton" parent="UI/BottomRightAnchor"] -position = Vector2( -96.302, -180 ) +[node name="Fire" type="TouchScreenButton" parent="UI"] +position = Vector2( 668.073, 262.788 ) scale = Vector2( 1.49157, 1.46265 ) normal = ExtResource( 8 ) action = "shoot" diff --git a/2d/platformer/src/Level/Level.tscn b/2d/platformer/src/Level/Level.tscn new file mode 100644 index 0000000000..7d335e7fd3 --- /dev/null +++ b/2d/platformer/src/Level/Level.tscn @@ -0,0 +1,275 @@ +[gd_scene load_steps=11 format=2] + +[ext_resource path="res://assets/art/tileset/tileset.tres" type="TileSet" id=1] +[ext_resource path="res://src/Actors/Enemy.tscn" type="PackedScene" id=2] +[ext_resource path="res://src/Platforms/Platform.tscn" type="PackedScene" id=3] +[ext_resource path="res://src/Objects/Coin.tscn" type="PackedScene" id=4] +[ext_resource path="res://src/Actors/Player.tscn" type="PackedScene" id=5] +[ext_resource path="res://assets/art/platforms/moving_platform.png" type="Texture" id=6] +[ext_resource path="res://src/Level/ParallaxBackground.tscn" type="PackedScene" id=7] +[ext_resource path="res://assets/audio/music/music.ogg" type="AudioStream" id=8] + +[sub_resource type="Animation" id=1] +resource_name = "move" +length = 4.0 +loop = true +tracks/0/type = "value" +tracks/0/path = NodePath(".:position") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0, 2 ), +"transitions": PoolRealArray( 1, 1 ), +"update": 0, +"values": [ Vector2( 1414.49, 799.663 ), Vector2( 1131.8, 607.41 ) ] +} + +[sub_resource type="Animation" id=2] +length = 8.0 +loop = true +tracks/0/type = "value" +tracks/0/path = NodePath(".:position") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0, 4 ), +"transitions": PoolRealArray( 1, 1 ), +"update": 0, +"values": [ Vector2( -93.4945, 159.269 ), Vector2( -93.4945, 814.766 ) ] +} + +[node name="Level" type="Node2D"] +pause_mode = 1 + +[node name="TileMap" type="TileMap" parent="."] +tile_set = ExtResource( 1 ) +collision_layer = 16 +collision_mask = 0 +format = 1 +tile_data = PoolIntArray( -65546, 536870913, 0, -65545, 1, 0, -131044, 536870913, 0, -131043, 1, 0, -10, 536870915, 0, -9, 3, 0, -65508, 536870915, 0, -65507, 3, 0, 65526, 536870915, 0, 65527, 3, 0, 28, 536870915, 0, 29, 3, 0, 131062, 536870915, 0, 131063, 3, 0, 131069, 536870918, 0, 131070, 5, 0, 131071, 5, 0, 65536, 5, 0, 65537, 5, 0, 65538, 5, 0, 65539, 5, 0, 65540, 6, 0, 65564, 536870915, 0, 65565, 3, 0, 196598, 536870915, 0, 196599, 3, 0, 131080, 536870913, 0, 131081, 0, 0, 131082, 0, 0, 131083, 0, 0, 131084, 0, 0, 131085, 1, 0, 131100, 536870915, 0, 131101, 3, 0, 262134, 536870915, 0, 262135, 3, 0, 196616, 536870921, 0, 196617, 8, 0, 196618, 8, 0, 196619, 8, 0, 196620, 8, 0, 196621, 9, 0, 196626, 536870913, 0, 196627, 0, 0, 196628, 0, 0, 196629, 0, 0, 196630, 0, 0, 196631, 0, 0, 196632, 0, 0, 196633, 0, 0, 196634, 0, 0, 196635, 0, 0, 196636, 536870916, 0, 196637, 3, 0, 327670, 536870915, 0, 327671, 3, 0, 262149, 536870918, 0, 262150, 6, 0, 262162, 536870921, 0, 262163, 536870920, 0, 262164, 536870920, 0, 262165, 536870920, 0, 262166, 536870920, 0, 262167, 536870922, 0, 262168, 7, 0, 262169, 7, 0, 262170, 7, 0, 262171, 7, 0, 262172, 7, 0, 262173, 3, 0, 393206, 536870915, 0, 393207, 3, 0, 327682, 536870918, 0, 327683, 6, 0, 327703, 536870921, 0, 327704, 536870920, 0, 327705, 536870922, 0, 327706, 7, 0, 327707, 7, 0, 327708, 7, 0, 327709, 3, 0, 458742, 536870915, 0, 458743, 4, 0, 458744, 0, 0, 458745, 0, 0, 458746, 1, 0, 393241, 536870921, 0, 393242, 536870920, 0, 393243, 536870920, 0, 393244, 536870922, 0, 393245, 3, 0, 524278, 536870915, 0, 524279, 536870919, 0, 524280, 536870919, 0, 524281, 536870919, 0, 524282, 3, 0, 458754, 536870913, 0, 458755, 0, 0, 458756, 0, 0, 458757, 2, 0, 458764, 536870913, 0, 458765, 1, 0, 458780, 536870915, 0, 458781, 3, 0, 589814, 536870915, 0, 589815, 536870919, 0, 589816, 536870919, 0, 589817, 536870919, 0, 589818, 3, 0, 524290, 536870915, 0, 524291, 7, 0, 524292, 7, 0, 524294, 536870912, 0, 524295, 536870912, 0, 524296, 536870912, 0, 524297, 536870912, 0, 524298, 536870912, 0, 524299, 536870912, 0, 524300, 536870916, 0, 524301, 3, 0, 524316, 536870915, 0, 524317, 3, 0, 655350, 536870915, 0, 655351, 536870919, 0, 655352, 536870919, 0, 655353, 536870919, 0, 655354, 3, 0, 589826, 536870915, 0, 589827, 7, 0, 589828, 7, 0, 589829, 7, 0, 589830, 7, 0, 589831, 7, 0, 589832, 7, 0, 589833, 7, 0, 589834, 7, 0, 589835, 7, 0, 589836, 7, 0, 589837, 4, 0, 589838, 0, 0, 589839, 1, 0, 589852, 536870915, 0, 589853, 3, 0, 720886, 536870915, 0, 720887, 536870919, 0, 720888, 536870919, 0, 720889, 536870919, 0, 720890, 3, 0, 655362, 536870921, 0, 655363, 536870920, 0, 655364, 536870920, 0, 655365, 536870920, 0, 655366, 536870920, 0, 655367, 536870920, 0, 655368, 536870920, 0, 655369, 536870920, 0, 655370, 536870920, 0, 655371, 536870920, 0, 655372, 536870920, 0, 655373, 536870920, 0, 655374, 536870920, 0, 655375, 9, 0, 655388, 536870915, 0, 655389, 3, 0, 786422, 536870915, 0, 786423, 536870919, 0, 786424, 536870919, 0, 786425, 536870919, 0, 786426, 3, 0, 720924, 536870915, 0, 720925, 3, 0, 851958, 536870915, 0, 851959, 536870919, 0, 851960, 536870919, 0, 851961, 536870919, 0, 851962, 3, 0, 786456, 536870918, 0, 786457, 536870917, 0, 786458, 6, 0, 786460, 536870915, 0, 786461, 3, 0, 917494, 536870915, 0, 917495, 536870919, 0, 917496, 536870919, 0, 917497, 536870919, 0, 917498, 4, 0, 917499, 0, 0, 917500, 0, 0, 917501, 0, 0, 917502, 0, 0, 917503, 0, 0, 851968, 0, 0, 851969, 1, 0, 851996, 536870915, 0, 851997, 3, 0, 983030, 536870915, 0, 983031, 536870919, 0, 983032, 536870919, 0, 983033, 536870919, 0, 983034, 536870919, 0, 983035, 536870919, 0, 983036, 536870919, 0, 983037, 536870919, 0, 983038, 536870919, 0, 983039, 536870919, 0, 917504, 536870919, 0, 917505, 3, 0, 917526, 536870913, 0, 917527, 536870912, 0, 917528, 536870912, 0, 917529, 0, 0, 917530, 536870912, 0, 917531, 536870912, 0, 917532, 536870916, 0, 917533, 3, 0, 1048566, 536870915, 0, 1048567, 536870919, 0, 1048568, 536870919, 0, 1048569, 536870919, 0, 1048570, 536870919, 0, 1048571, 536870919, 0, 1048572, 536870919, 0, 1048573, 536870919, 0, 1048574, 536870919, 0, 1048575, 536870919, 0, 983040, 536870919, 0, 983041, 3, 0, 983057, 536870918, 0, 983058, 5, 0, 983059, 6, 0, 983062, 536870915, 0, 983063, 7, 0, 983064, 7, 0, 983065, 7, 0, 983066, 7, 0, 983067, 7, 0, 983068, 7, 0, 983069, 3, 0, 1114102, 536870915, 0, 1114103, 536870919, 0, 1114104, 536870919, 0, 1114105, 536870919, 0, 1114106, 536870919, 0, 1114107, 536870919, 0, 1114108, 536870919, 0, 1114109, 536870919, 0, 1114110, 536870919, 0, 1114111, 536870919, 0, 1048576, 536870919, 0, 1048577, 3, 0, 1048579, 536870926, 0, 1048598, 536870915, 0, 1048599, 7, 0, 1048600, 7, 0, 1048601, 7, 0, 1048602, 7, 0, 1048603, 7, 0, 1048604, 7, 0, 1048605, 3, 0, 1179638, 536870915, 0, 1179639, 536870919, 0, 1179640, 536870919, 0, 1179641, 536870919, 0, 1179642, 536870919, 0, 1179643, 536870919, 0, 1179644, 536870919, 0, 1179645, 536870919, 0, 1179646, 536870919, 0, 1179647, 536870919, 0, 1114112, 536870919, 0, 1114113, 4, 0, 1114114, 0, 0, 1114115, 536870925, 0, 1114116, 0, 0, 1114117, 2, 0, 1114123, 536870926, 0, 1114126, 536870918, 0, 1114127, 5, 0, 1114128, 6, 0, 1114133, 536870914, 0, 1114134, 536870916, 0, 1114135, 7, 0, 1114136, 7, 0, 1114137, 7, 0, 1114138, 7, 0, 1114139, 7, 0, 1114140, 7, 0, 1114141, 3, 0, 1245174, 536870915, 0, 1245175, 536870919, 0, 1245176, 536870919, 0, 1245177, 536870919, 0, 1245178, 536870919, 0, 1245179, 536870919, 0, 1245180, 536870919, 0, 1245181, 536870919, 0, 1245182, 536870919, 0, 1245183, 536870919, 0, 1179648, 536870919, 0, 1179649, 536870919, 0, 1179650, 536870919, 0, 1179651, 536870919, 0, 1179652, 536870922, 0, 1179654, 2, 0, 1179658, 536870913, 0, 1179659, 536870925, 0, 1179660, 1, 0, 1179668, 536870914, 0, 1179670, 7, 0, 1179671, 7, 0, 1179672, 7, 0, 1179673, 7, 0, 1179674, 7, 0, 1179675, 7, 0, 1179676, 7, 0, 1179677, 3, 0, 1310710, 536870915, 0, 1310711, 536870919, 0, 1310712, 536870919, 0, 1310713, 536870919, 0, 1310714, 536870919, 0, 1310715, 536870919, 0, 1310716, 536870919, 0, 1310717, 536870919, 0, 1310718, 536870919, 0, 1310719, 536870919, 0, 1245184, 536870919, 0, 1245185, 536870919, 0, 1245186, 536870919, 0, 1245187, 536870919, 0, 1245188, 536870919, 0, 1245189, 536870922, 0, 1245191, 2, 0, 1245194, 536870915, 0, 1245195, 7, 0, 1245196, 3, 0, 1245203, 536870914, 0, 1245205, 7, 0, 1245206, 7, 0, 1245207, 7, 0, 1245208, 7, 0, 1245209, 7, 0, 1245210, 7, 0, 1245211, 7, 0, 1245212, 7, 0, 1245213, 3, 0, 1376246, 536870915, 0, 1376247, 536870919, 0, 1376248, 536870919, 0, 1376249, 536870919, 0, 1376250, 536870919, 0, 1376251, 536870919, 0, 1376252, 536870919, 0, 1376253, 536870919, 0, 1376254, 536870919, 0, 1376255, 536870919, 0, 1310720, 536870919, 0, 1310721, 536870919, 0, 1310722, 536870919, 0, 1310723, 536870919, 0, 1310724, 536870919, 0, 1310725, 536870919, 0, 1310726, 536870922, 0, 1310728, 536870912, 0, 1310729, 536870912, 0, 1310730, 536870916, 0, 1310731, 7, 0, 1310732, 4, 0, 1310733, 0, 0, 1310734, 0, 0, 1310735, 0, 0, 1310736, 0, 0, 1310737, 0, 0, 1310738, 536870912, 0, 1310740, 7, 0, 1310741, 7, 0, 1310742, 7, 0, 1310743, 7, 0, 1310744, 7, 0, 1310745, 7, 0, 1310746, 7, 0, 1310747, 7, 0, 1310748, 7, 0, 1310749, 3, 0, 1441782, 536870921, 0, 1441783, 536870920, 0, 1441784, 536870920, 0, 1441785, 536870920, 0, 1441786, 536870920, 0, 1441787, 536870920, 0, 1441788, 536870920, 0, 1441789, 536870920, 0, 1441790, 536870920, 0, 1441791, 536870920, 0, 1376256, 536870920, 0, 1376257, 536870920, 0, 1376258, 536870920, 0, 1376259, 536870920, 0, 1376260, 536870920, 0, 1376261, 536870920, 0, 1376262, 536870920, 0, 1376263, 536870920, 0, 1376264, 536870920, 0, 1376265, 536870920, 0, 1376266, 536870920, 0, 1376267, 536870920, 0, 1376268, 536870920, 0, 1376269, 536870920, 0, 1376270, 536870920, 0, 1376271, 536870920, 0, 1376272, 536870920, 0, 1376273, 536870920, 0, 1376274, 536870920, 0, 1376275, 536870920, 0, 1376276, 536870920, 0, 1376277, 536870920, 0, 1376278, 536870920, 0, 1376279, 536870920, 0, 1376280, 536870920, 0, 1376281, 536870920, 0, 1376282, 536870920, 0, 1376283, 536870920, 0, 1376284, 8, 0, 1376285, 9, 0 ) + +[node name="Coins" type="Node" parent="."] + +[node name="CoinsArc" type="Node2D" parent="Coins"] +position = Vector2( 539.755, 1147.54 ) + +[node name="Coin" parent="Coins/CoinsArc" instance=ExtResource( 4 )] +position = Vector2( -29.4628, 59.9619 ) + +[node name="Coin2" parent="Coins/CoinsArc" instance=ExtResource( 4 )] +position = Vector2( 0.171143, 0.141846 ) + +[node name="Coin3" parent="Coins/CoinsArc" instance=ExtResource( 4 )] +position = Vector2( 62.5472, -35.7081 ) + +[node name="CoinsVertical" type="Node2D" parent="Coins"] +position = Vector2( 732.045, 1037.88 ) + +[node name="Coin" parent="Coins/CoinsVertical" instance=ExtResource( 4 )] +position = Vector2( -0.110291, 31.8701 ) + +[node name="Coin2" parent="Coins/CoinsVertical" instance=ExtResource( 4 )] +position = Vector2( -0.110291, -0.129883 ) + +[node name="Coin3" parent="Coins/CoinsVertical" instance=ExtResource( 4 )] +position = Vector2( -0.110291, -32.1299 ) + +[node name="CoinsVertical2" type="Node2D" parent="Coins"] +position = Vector2( 1018.11, -17.9731 ) + +[node name="Coin" parent="Coins/CoinsVertical2" instance=ExtResource( 4 )] +position = Vector2( -0.110291, 31.8701 ) + +[node name="Coin2" parent="Coins/CoinsVertical2" instance=ExtResource( 4 )] +position = Vector2( -0.110291, -0.129883 ) + +[node name="Coin3" parent="Coins/CoinsVertical2" instance=ExtResource( 4 )] +position = Vector2( -0.110291, -32.1299 ) + +[node name="CoinsSquare" type="Node2D" parent="Coins"] +position = Vector2( -429.669, 323.199 ) + +[node name="Coin" parent="Coins/CoinsSquare" instance=ExtResource( 4 )] +position = Vector2( -32, -32 ) + +[node name="Coin2" parent="Coins/CoinsSquare" instance=ExtResource( 4 )] +position = Vector2( 32, -32 ) + +[node name="Coin3" parent="Coins/CoinsSquare" instance=ExtResource( 4 )] +position = Vector2( -32, 32 ) + +[node name="Coin4" parent="Coins/CoinsSquare" instance=ExtResource( 4 )] +position = Vector2( 32, 32 ) + +[node name="CoinsSquare2" type="Node2D" parent="Coins"] +position = Vector2( 695.105, 66.9483 ) + +[node name="Coin" parent="Coins/CoinsSquare2" instance=ExtResource( 4 )] +position = Vector2( -32, -32 ) + +[node name="Coin2" parent="Coins/CoinsSquare2" instance=ExtResource( 4 )] +position = Vector2( 32, -32 ) + +[node name="Coin3" parent="Coins/CoinsSquare2" instance=ExtResource( 4 )] +position = Vector2( -32, 32 ) + +[node name="Coin4" parent="Coins/CoinsSquare2" instance=ExtResource( 4 )] +position = Vector2( 32, 32 ) + +[node name="CoinsSquare3" type="Node2D" parent="Coins"] +position = Vector2( 1353.17, 117.285 ) + +[node name="Coin" parent="Coins/CoinsSquare3" instance=ExtResource( 4 )] +position = Vector2( -32, -32 ) + +[node name="Coin2" parent="Coins/CoinsSquare3" instance=ExtResource( 4 )] +position = Vector2( 32, -32 ) + +[node name="Coin3" parent="Coins/CoinsSquare3" instance=ExtResource( 4 )] +position = Vector2( -32, 32 ) + +[node name="Coin4" parent="Coins/CoinsSquare3" instance=ExtResource( 4 )] +position = Vector2( 32, 32 ) + +[node name="CoinsSquare4" type="Node2D" parent="Coins"] +position = Vector2( 1592.58, 117.285 ) + +[node name="Coin" parent="Coins/CoinsSquare4" instance=ExtResource( 4 )] +position = Vector2( -32, -32 ) + +[node name="Coin2" parent="Coins/CoinsSquare4" instance=ExtResource( 4 )] +position = Vector2( 32, -32 ) + +[node name="Coin3" parent="Coins/CoinsSquare4" instance=ExtResource( 4 )] +position = Vector2( -32, 32 ) + +[node name="Coin4" parent="Coins/CoinsSquare4" instance=ExtResource( 4 )] +position = Vector2( 32, 32 ) + +[node name="CoinsHorizontal" type="Node2D" parent="Coins"] +position = Vector2( 73.2408, 805.983 ) + +[node name="Coin" parent="Coins/CoinsHorizontal" instance=ExtResource( 4 )] +position = Vector2( -32, 0 ) + +[node name="Coin2" parent="Coins/CoinsHorizontal" instance=ExtResource( 4 )] + +[node name="Coin3" parent="Coins/CoinsHorizontal" instance=ExtResource( 4 )] +position = Vector2( 32, 0 ) + +[node name="CoinsHorizontal2" type="Node2D" parent="Coins"] +position = Vector2( 1337.21, 863.089 ) + +[node name="Coin" parent="Coins/CoinsHorizontal2" instance=ExtResource( 4 )] +position = Vector2( -32, 0 ) + +[node name="Coin2" parent="Coins/CoinsHorizontal2" instance=ExtResource( 4 )] + +[node name="Coin3" parent="Coins/CoinsHorizontal2" instance=ExtResource( 4 )] +position = Vector2( 32, 0 ) + +[node name="CoinsHorizontal3" type="Node2D" parent="Coins"] +position = Vector2( 671.17, 311.745 ) + +[node name="Coin" parent="Coins/CoinsHorizontal3" instance=ExtResource( 4 )] +position = Vector2( -32, 0 ) + +[node name="Coin2" parent="Coins/CoinsHorizontal3" instance=ExtResource( 4 )] + +[node name="Coin3" parent="Coins/CoinsHorizontal3" instance=ExtResource( 4 )] +position = Vector2( 32, 0 ) + +[node name="CoinsHorizontal4" type="Node2D" parent="Coins"] +position = Vector2( -126.888, 41.1804 ) + +[node name="Coin" parent="Coins/CoinsHorizontal4" instance=ExtResource( 4 )] +position = Vector2( -32, 0 ) + +[node name="Coin2" parent="Coins/CoinsHorizontal4" instance=ExtResource( 4 )] + +[node name="Coin3" parent="Coins/CoinsHorizontal4" instance=ExtResource( 4 )] +position = Vector2( 32, 0 ) + +[node name="CoinsHorizontal5" type="Node2D" parent="Coins"] +position = Vector2( 255.215, 41.1804 ) + +[node name="Coin" parent="Coins/CoinsHorizontal5" instance=ExtResource( 4 )] +position = Vector2( -32, 0 ) + +[node name="Coin2" parent="Coins/CoinsHorizontal5" instance=ExtResource( 4 )] + +[node name="Coin3" parent="Coins/CoinsHorizontal5" instance=ExtResource( 4 )] +position = Vector2( 32, 0 ) + +[node name="Platforms" type="Node" parent="."] + +[node name="Platform" parent="Platforms" instance=ExtResource( 3 )] +position = Vector2( 1414.49, 799.663 ) + +[node name="AnimationPlayer" type="AnimationPlayer" parent="Platforms/Platform"] +autoplay = "move" +playback_process_mode = 0 +anims/move = SubResource( 1 ) + +[node name="Platform2" parent="Platforms" instance=ExtResource( 3 )] +position = Vector2( -93.4945, 700.054 ) + +[node name="AnimationPlayer" type="AnimationPlayer" parent="Platforms/Platform2"] +autoplay = "move" +playback_process_mode = 0 +anims/move = SubResource( 2 ) + +[node name="PlatformStatic" type="StaticBody2D" parent="Platforms"] +position = Vector2( 1139.87, 211.754 ) +rotation = 0.355618 +z_index = -1 +collision_layer = 16 +collision_mask = 0 + +[node name="Sprite2" type="Sprite" parent="Platforms/PlatformStatic"] +position = Vector2( -177.384, 21.0007 ) +rotation = -0.246293 +texture = ExtResource( 6 ) + +[node name="Sprite" type="Sprite" parent="Platforms/PlatformStatic"] +texture = ExtResource( 6 ) + +[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="Platforms/PlatformStatic"] +polygon = PoolVector2Array( -261.093, 20.4292, -94.1774, -21.2967, 16.1709, -14.2775, 20.3489, -3.02834, -93.7491, -8.65489, -257.264, 30.7409 ) + +[node name="Enemies" type="Node" parent="."] + +[node name="Enemy" parent="Enemies" instance=ExtResource( 2 )] +position = Vector2( 542.081, 491.279 ) + +[node name="Enemy2" parent="Enemies" instance=ExtResource( 2 )] +position = Vector2( 692.218, 97.1263 ) + +[node name="Enemy3" parent="Enemies" instance=ExtResource( 2 )] +position = Vector2( 1265.45, 157.109 ) + +[node name="Enemy4" parent="Enemies" instance=ExtResource( 2 )] +position = Vector2( 1657.03, 154.524 ) + +[node name="Player" parent="." instance=ExtResource( 5 )] +position = Vector2( 173.294, 1093.02 ) + +[node name="Camera" parent="Player" index="4"] +limit_left = -626 +limit_top = -780 +limit_right = 1905 +limit_bottom = 1384 +limit_smoothed = true +editor_draw_limits = true + +[node name="ParallaxBackground" parent="." instance=ExtResource( 7 )] + +[node name="Music" type="AudioStreamPlayer" parent="."] +stream = ExtResource( 8 ) +autoplay = true + +[editable path="Player"] diff --git a/2d/platformer/background/ParallaxBg.tscn b/2d/platformer/src/Level/ParallaxBackground.tscn similarity index 54% rename from 2d/platformer/background/ParallaxBg.tscn rename to 2d/platformer/src/Level/ParallaxBackground.tscn index 8d1c7256c2..ebfee2d0a3 100644 --- a/2d/platformer/background/ParallaxBg.tscn +++ b/2d/platformer/src/Level/ParallaxBackground.tscn @@ -1,20 +1,20 @@ [gd_scene load_steps=7 format=2] -[ext_resource path="res://background/scroll_bg_sky.png" type="Texture" id=1] -[ext_resource path="res://background/scroll_bg_cloud_1.png" type="Texture" id=2] -[ext_resource path="res://background/scroll_bg_cloud_2.png" type="Texture" id=3] -[ext_resource path="res://background/scroll_bg_cloud_3.png" type="Texture" id=4] -[ext_resource path="res://background/scroll_bg_fg_2.png" type="Texture" id=5] -[ext_resource path="res://background/scroll_bg_fg_1.png" type="Texture" id=6] +[ext_resource path="res://assets/art/background/sky.png" type="Texture" id=1] +[ext_resource path="res://assets/art/background/cloud_1.png" type="Texture" id=2] +[ext_resource path="res://assets/art/background/cloud_2.png" type="Texture" id=3] +[ext_resource path="res://assets/art/background/cloud_3.png" type="Texture" id=4] +[ext_resource path="res://assets/art/background/distant_platforms_2.png" type="Texture" id=5] +[ext_resource path="res://assets/art/background/distant_platforms_1.png" type="Texture" id=6] -[node name="ParallaxBg" type="ParallaxBackground"] +[node name="ParallaxBackground" type="ParallaxBackground"] scroll_base_scale = Vector2( 0.7, 0 ) [node name="Sky" type="ParallaxLayer" parent="."] motion_mirroring = Vector2( 800, 0 ) [node name="Sprite" type="Sprite" parent="Sky"] -scale = Vector2( 128, 0.94 ) +scale = Vector2( 32, 0.94 ) texture = ExtResource( 1 ) centered = false @@ -52,20 +52,24 @@ position = Vector2( 674, 70 ) texture = ExtResource( 4 ) centered = false -[node name="Mount2" type="ParallaxLayer" parent="."] +[node name="MountainsFar" type="ParallaxLayer" parent="."] motion_scale = Vector2( 0.2, 1 ) +motion_mirroring = Vector2( 800, 0 ) -[node name="Sprite" type="Sprite" parent="Mount2"] -position = Vector2( 0, 353 ) +[node name="Sprite" type="Sprite" parent="MountainsFar"] +position = Vector2( 0, 225 ) texture = ExtResource( 5 ) +centered = false region_enabled = true -region_rect = Rect2( 0, 0, 4096, 256 ) +region_rect = Rect2( 0, 0, 800, 256 ) -[node name="Mount1" type="ParallaxLayer" parent="."] +[node name="MountainsClose" type="ParallaxLayer" parent="."] motion_scale = Vector2( 0.4, 1 ) +motion_mirroring = Vector2( 800, 0 ) -[node name="Sprite" type="Sprite" parent="Mount1"] -position = Vector2( 0, 353 ) +[node name="Sprite" type="Sprite" parent="MountainsClose"] +position = Vector2( 0, 225 ) texture = ExtResource( 6 ) +centered = false region_enabled = true -region_rect = Rect2( 0, 0, 4096, 256 ) +region_rect = Rect2( 0, 0, 800, 256 ) diff --git a/2d/platformer/src/Main/Game.gd b/2d/platformer/src/Main/Game.gd new file mode 100644 index 0000000000..d1f301a086 --- /dev/null +++ b/2d/platformer/src/Main/Game.gd @@ -0,0 +1,26 @@ +# This class contains controls that should always be accessible, like pausing +# the game or toggling the window full-screen. +extends Node + + +# The "_" prefix is a convention to indicate that variables are private, +# that is to say, another node or script should not access them. +onready var _pause_menu = $InterfaceLayer/PauseMenu + + +func _input(event: InputEvent) -> void: + if event.is_action_pressed("toggle_fullscreen"): + OS.window_fullscreen = not OS.window_fullscreen + get_tree().set_input_as_handled() + # The GlobalControls node, in the Stage scene, is set to process even + # when the game is paused, so this code keeps running. + # To see that, select GlobalControls, and scroll down to the Pause category + # in the inspector. + elif event.is_action_pressed("toggle_pause"): + var tree = get_tree() + tree.paused = not tree.paused + if tree.paused: + _pause_menu.open() + else: + _pause_menu.close() + get_tree().set_input_as_handled() diff --git a/2d/platformer/src/Main/Game.tscn b/2d/platformer/src/Main/Game.tscn new file mode 100644 index 0000000000..e3157ca573 --- /dev/null +++ b/2d/platformer/src/Main/Game.tscn @@ -0,0 +1,16 @@ +[gd_scene load_steps=4 format=2] + +[ext_resource path="res://src/UserInterface/PauseMenu.tscn" type="PackedScene" id=1] +[ext_resource path="res://src/Main/Game.gd" type="Script" id=2] +[ext_resource path="res://src/Level/Level.tscn" type="PackedScene" id=3] + +[node name="Game" type="Node"] +pause_mode = 2 +script = ExtResource( 2 ) + +[node name="Level" parent="." instance=ExtResource( 3 )] + +[node name="InterfaceLayer" type="CanvasLayer" parent="."] +layer = 100 + +[node name="PauseMenu" parent="InterfaceLayer" instance=ExtResource( 1 )] diff --git a/2d/platformer/src/Objects/Bullet.gd b/2d/platformer/src/Objects/Bullet.gd new file mode 100644 index 0000000000..ad3cdd286f --- /dev/null +++ b/2d/platformer/src/Objects/Bullet.gd @@ -0,0 +1,14 @@ +extends RigidBody2D +class_name Bullet + + +onready var animation_player = $AnimationPlayer + + +func destroy(): + animation_player.play("destroy") + + +func _on_body_entered(body): + if body is Enemy: + body.destroy() diff --git a/2d/platformer/player/Bullet.tscn b/2d/platformer/src/Objects/Bullet.tscn similarity index 74% rename from 2d/platformer/player/Bullet.tscn rename to 2d/platformer/src/Objects/Bullet.tscn index 06413a6fa9..93a585f5ce 100644 --- a/2d/platformer/player/Bullet.tscn +++ b/2d/platformer/src/Objects/Bullet.tscn @@ -1,7 +1,7 @@ [gd_scene load_steps=9 format=2] -[ext_resource path="res://player/bullet.gd" type="Script" id=1] -[ext_resource path="res://player/bullet.png" type="Texture" id=2] +[ext_resource path="res://assets/art/player/bullet/bullet.png" type="Texture" id=1] +[ext_resource path="res://src/Objects/Bullet.gd" type="Script" id=2] [sub_resource type="CanvasItemMaterial" id=1] @@ -22,7 +22,8 @@ color = Color( 1, 1, 1, 0.705882 ) [sub_resource type="CircleShape2D" id=5] [sub_resource type="Animation" id=6] -length = 1.5 +resource_name = "destroy" +length = 0.3 tracks/0/type = "method" tracks/0/path = NodePath(".") tracks/0/interp = 1 @@ -30,7 +31,7 @@ tracks/0/loop_wrap = true tracks/0/imported = false tracks/0/enabled = true tracks/0/keys = { -"times": PoolRealArray( 1.31 ), +"times": PoolRealArray( 0.3 ), "transitions": PoolRealArray( 1 ), "values": [ { "args": [ ], @@ -44,7 +45,7 @@ tracks/1/loop_wrap = true tracks/1/imported = false tracks/1/enabled = true tracks/1/keys = { -"times": PoolRealArray( 0, 1 ), +"times": PoolRealArray( 0, 0.3 ), "transitions": PoolRealArray( 1, 1 ), "update": 0, "values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 0 ) ] @@ -56,7 +57,7 @@ tracks/2/loop_wrap = true tracks/2/imported = false tracks/2/enabled = true tracks/2/keys = { -"times": PoolRealArray( 0, 0.5 ), +"times": PoolRealArray( 0, 0.3 ), "transitions": PoolRealArray( 1, 1 ), "update": 0, "values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 0 ) ] @@ -64,10 +65,12 @@ tracks/2/keys = { [node name="Bullet" type="RigidBody2D"] material = SubResource( 1 ) +collision_layer = 0 +collision_mask = 26 continuous_cd = 2 contacts_reported = 1 contact_monitor = true -script = ExtResource( 1 ) +script = ExtResource( 2 ) [node name="Particles2D" type="Particles2D" parent="."] material = SubResource( 2 ) @@ -75,11 +78,11 @@ lifetime = 0.3 speed_scale = 3.0 local_coords = false process_material = SubResource( 3 ) -texture = ExtResource( 2 ) +texture = ExtResource( 1 ) [node name="Sprite" type="Sprite" parent="."] material = SubResource( 4 ) -texture = ExtResource( 2 ) +texture = ExtResource( 1 ) [node name="CollisionShape2D" type="CollisionShape2D" parent="."] shape = SubResource( 5 ) @@ -88,8 +91,7 @@ shape = SubResource( 5 ) one_shot = true autostart = true -[node name="Anim" type="AnimationPlayer" parent="."] -anims/shutdown = SubResource( 6 ) - -[connection signal="body_entered" from="." to="." method="_on_bullet_body_enter"] -[connection signal="timeout" from="Timer" to="." method="_on_Timer_timeout"] +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +anims/destroy = SubResource( 6 ) +[connection signal="body_entered" from="." to="." method="_on_body_entered"] +[connection signal="timeout" from="Timer" to="." method="destroy"] diff --git a/2d/platformer/src/Objects/Coin.gd b/2d/platformer/src/Objects/Coin.gd new file mode 100644 index 0000000000..4e2dc73a82 --- /dev/null +++ b/2d/platformer/src/Objects/Coin.gd @@ -0,0 +1,15 @@ +extends Area2D +class_name Coin +# Collectible that disappears when the player touches it. + +onready var animation_player = $AnimationPlayer + +# The Coins only detects collisions with the Player thanks to its collision mask. +# This prevents other characters such as enemies from picking up coins. + +# # When the player collides with a coin, the coin plays its 'picked' animation. +# The animation takes cares of making the coin disappear, but also deactivates its collisions +# and frees it from memory, saving us from writing more complex code. +# Click the AnimationPlayer node to see the animation timeline. +func _on_body_entered(_body): + animation_player.play("picked") diff --git a/2d/platformer/src/Objects/Coin.tscn b/2d/platformer/src/Objects/Coin.tscn new file mode 100644 index 0000000000..a240096e25 --- /dev/null +++ b/2d/platformer/src/Objects/Coin.tscn @@ -0,0 +1,161 @@ +[gd_scene load_steps=7 format=2] + +[ext_resource path="res://assets/art/coin/coin.png" type="Texture" id=2] +[ext_resource path="res://assets/audio/sfx/coin_pickup.wav" type="AudioStream" id=3] +[ext_resource path="res://src/Objects/Coin.gd" type="Script" id=4] + +[sub_resource type="Animation" id=1] +resource_name = "picked" +length = 1.5 +step = 0.25 +tracks/0/type = "value" +tracks/0/path = NodePath("Sprite:frame") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 0, +"values": [ 0 ] +} +tracks/1/type = "method" +tracks/1/path = NodePath(".") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 1 ), +"transitions": PoolRealArray( 1 ), +"values": [ { +"args": [ ], +"method": "queue_free" +} ] +} +tracks/2/type = "value" +tracks/2/path = NodePath("Sprite:self_modulate") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/keys = { +"times": PoolRealArray( 0.25, 1.25 ), +"transitions": PoolRealArray( 1, 1 ), +"update": 0, +"values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 0 ) ] +} +tracks/3/type = "value" +tracks/3/path = NodePath("Pickup:playing") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 2, +"values": [ true ] +} +tracks/4/type = "value" +tracks/4/path = NodePath(".:monitoring") +tracks/4/interp = 1 +tracks/4/loop_wrap = true +tracks/4/imported = false +tracks/4/enabled = true +tracks/4/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 1, +"values": [ false ] +} +tracks/5/type = "value" +tracks/5/path = NodePath("Sprite:position") +tracks/5/interp = 1 +tracks/5/loop_wrap = true +tracks/5/imported = false +tracks/5/enabled = true +tracks/5/keys = { +"times": PoolRealArray( 0, 1.5 ), +"transitions": PoolRealArray( 1, 1 ), +"update": 0, +"values": [ Vector2( 0, 0 ), Vector2( 0, -42 ) ] +} + +[sub_resource type="Animation" id=2] +length = 1.5 +loop = true +step = 0.25 +tracks/0/type = "value" +tracks/0/path = NodePath("Sprite:frame") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0, 0.25, 0.5, 0.75, 1, 1.25, 1.5 ), +"transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1 ), +"update": 1, +"values": [ 0, 1, 2, 3, 2, 1, 0 ] +} +tracks/1/type = "value" +tracks/1/path = NodePath("Sprite:position") +tracks/1/interp = 1 +tracks/1/loop_wrap = true +tracks/1/imported = false +tracks/1/enabled = true +tracks/1/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 2, +"values": [ Vector2( 0, 0 ) ] +} +tracks/2/type = "value" +tracks/2/path = NodePath("Sprite:self_modulate") +tracks/2/interp = 1 +tracks/2/loop_wrap = true +tracks/2/imported = false +tracks/2/enabled = true +tracks/2/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 2, +"values": [ Color( 1, 1, 1, 1 ) ] +} +tracks/3/type = "value" +tracks/3/path = NodePath(".:monitoring") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 2, +"values": [ true ] +} + +[sub_resource type="CircleShape2D" id=3] + +[node name="Coin" type="Area2D"] +monitorable = false +collision_layer = 0 +script = ExtResource( 4 ) + +[node name="Sprite" type="Sprite" parent="."] +texture = ExtResource( 2 ) +hframes = 4 + +[node name="AnimationPlayer" type="AnimationPlayer" parent="."] +autoplay = "spinning" +playback_speed = 1.5 +anims/picked = SubResource( 1 ) +anims/spinning = SubResource( 2 ) + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +shape = SubResource( 3 ) + +[node name="Pickup" type="AudioStreamPlayer2D" parent="."] +stream = ExtResource( 3 ) +[connection signal="body_entered" from="." to="." method="_on_body_entered"] diff --git a/2d/platformer/src/Platforms/Platform.tscn b/2d/platformer/src/Platforms/Platform.tscn new file mode 100644 index 0000000000..1564b262d9 --- /dev/null +++ b/2d/platformer/src/Platforms/Platform.tscn @@ -0,0 +1,21 @@ +[gd_scene load_steps=3 format=2] + +[ext_resource path="res://assets/art/platforms/moving_platform.png" type="Texture" id=2] + +[sub_resource type="RectangleShape2D" id=1] +extents = Vector2( 94, 12 ) + +[node name="Platform" type="KinematicBody2D"] +z_index = -1 +collision_layer = 8 +collision_mask = 0 +collision/safe_margin = 0.12 +motion/sync_to_physics = true + +[node name="Sprite" type="Sprite" parent="."] +texture = ExtResource( 2 ) + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +position = Vector2( 0, -8 ) +shape = SubResource( 1 ) +one_way_collision = true diff --git a/2d/platformer/src/UserInterface/PauseMenu.gd b/2d/platformer/src/UserInterface/PauseMenu.gd new file mode 100644 index 0000000000..95e869d695 --- /dev/null +++ b/2d/platformer/src/UserInterface/PauseMenu.gd @@ -0,0 +1,26 @@ +extends Control + + +onready var resume_button = $VBoxContainer/ResumeButton + + +func _ready(): + visible = false + + +func open(): + visible = true + resume_button.grab_focus() + + +func close(): + visible = false + + +func _on_ResumeButton_pressed() -> void: + get_tree().paused = false + visible = false + + +func _on_QuitButton_pressed() -> void: + get_tree().quit() diff --git a/2d/platformer/src/UserInterface/PauseMenu.tscn b/2d/platformer/src/UserInterface/PauseMenu.tscn new file mode 100644 index 0000000000..5db54b7e1e --- /dev/null +++ b/2d/platformer/src/UserInterface/PauseMenu.tscn @@ -0,0 +1,56 @@ +[gd_scene load_steps=3 format=2] + +[ext_resource path="res://assets/theme/user_interface.tres" type="Theme" id=1] +[ext_resource path="res://src/UserInterface/PauseMenu.gd" type="Script" id=2] + +[node name="PauseMenu" type="Control"] +pause_mode = 2 +anchor_right = 1.0 +anchor_bottom = 1.0 +theme = ExtResource( 1 ) +script = ExtResource( 2 ) +__meta__ = { +"_edit_use_anchors_": false +} + +[node name="ColorRect" type="ColorRect" parent="."] +anchor_right = 1.0 +anchor_bottom = 1.0 +color = Color( 0, 0, 0, 0.211765 ) + +[node name="VBoxContainer" type="VBoxContainer" parent="."] +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +margin_left = -87.0 +margin_top = -125.0 +margin_right = 87.0 +margin_bottom = 126.0 +alignment = 1 +__meta__ = { +"_edit_use_anchors_": false +} + +[node name="Label" type="Label" parent="VBoxContainer"] +margin_top = 71.0 +margin_right = 174.0 +margin_bottom = 91.0 +text = "Game Paused" +align = 1 + +[node name="ResumeButton" type="Button" parent="VBoxContainer"] +margin_top = 95.0 +margin_right = 174.0 +margin_bottom = 135.0 +rect_min_size = Vector2( 0, 40 ) +text = "Resume" + +[node name="QuitButton" type="Button" parent="VBoxContainer"] +margin_top = 139.0 +margin_right = 174.0 +margin_bottom = 179.0 +rect_min_size = Vector2( 0, 40 ) +text = "Quit" +[connection signal="pressed" from="VBoxContainer/ResumeButton" to="." method="_on_ResumeButton_pressed"] +[connection signal="pressed" from="VBoxContainer/QuitButton" to="." method="_on_QuitButton_pressed"] diff --git a/2d/platformer/tiles_demo.png b/2d/platformer/tiles_demo.png deleted file mode 100644 index a216b6899dc008d5a23a01e86e6a8f4a22e3ab12..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4057 zcmY*b2{e>zAAe@CWtp*5$TA^h$#jz~V}@kOzUEqHMy?xI*+NXiOhrSwp)7sbU0N(9 z*VT&2l1dj*Ay-I3D5f!%*}iw&bG~!FXXZWcbDrnF{{H{}@4Q)_?vAqCRJQ>DWSyPt zy#atjTNsc;KrfcNjUV)qigo(=Gyu|yq6Y?Ulqf@og`TdyM}$IQm5+{L@eyGLi@(7j zn7QvaHdi@|Z98rdX=lg?#Fs}pKg|$&;ZK~iRLB;4m5eXHj^SYFmlL?gNCPpXmR83%V99 z(HSW1e6W@CaTiDX{i9>*@c_s*INRI$CVyDGaV~lcD`Rhb%Paq8(x#AfXgqVLiEc$r zBRo`D6SLs7e>Xw>@w>UVS~V$U#Jd)yHa39;`aS3RJwy2@>M*wN%0J9w9ugZ9vS{&# z!QPLp^}7rA_eU(f^{RXwoHsb?m|;6cycDUFvaIsX%jLDZ`p-WR`Sti)w&!H9{W#f1Uamk~q;0U-C*xR~V6au5(vFrxTwc-?Cocv|AhbKRJTgM$ zJeusgxHpWoG{z?cQjXQ{<0d3j@Bw}A@l?nl|t zI^(v9p0%C9ILV^Zw_4L=gVi3{Dp#BlV!`xqfJ(Dxx`KY~s(qzjxO9eY6^F|us!Whh z(%36!Za?<>xDrK9JBKCo3qry3b!(%zG)!yz4jaAde8jtD%NHL1&~qOd z1+c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