From f7a83cac6e51b9babf5b6dca9ee64504ee1217c7 Mon Sep 17 00:00:00 2001 From: Enzo Cranford Date: Tue, 1 Oct 2024 21:21:22 +0200 Subject: [PATCH] feat: change main menu & improve pixel art fidelity --- assets/sprites/cloud1.png | Bin 0 -> 626 bytes assets/sprites/cloud1.png.import | 34 +++ assets/sprites/cloud2.png | Bin 0 -> 526 bytes assets/sprites/cloud2.png.import | 34 +++ assets/sprites/cloud3.png | Bin 0 -> 601 bytes assets/sprites/cloud3.png.import | 34 +++ assets/sprites/play.png | Bin 0 -> 329 bytes assets/sprites/play.png.import | 34 +++ assets/sprites/quit.png | Bin 0 -> 329 bytes assets/sprites/quit.png.import | 34 +++ assets/sprites/title.png | Bin 0 -> 2704 bytes assets/sprites/title.png.import | 34 +++ project.godot | 8 +- resources/background_tileset.tres | 266 ++++++++++++++++++++ scenes/levels/level.tscn | 284 +-------------------- scenes/main.tscn | 24 +- scenes/main_menu.tscn | 402 ++++++------------------------ scenes/players/crosshair.tscn | 9 +- scenes/players/player.gd | 3 +- scenes/players/player.tscn | 5 +- scenes/zombie/zombie.tscn | 4 +- 21 files changed, 591 insertions(+), 618 deletions(-) create mode 100644 assets/sprites/cloud1.png create mode 100644 assets/sprites/cloud1.png.import create mode 100644 assets/sprites/cloud2.png create mode 100644 assets/sprites/cloud2.png.import create mode 100644 assets/sprites/cloud3.png create mode 100644 assets/sprites/cloud3.png.import create mode 100644 assets/sprites/play.png create mode 100644 assets/sprites/play.png.import create mode 100644 assets/sprites/quit.png create mode 100644 assets/sprites/quit.png.import create mode 100644 assets/sprites/title.png create mode 100644 assets/sprites/title.png.import create mode 100644 resources/background_tileset.tres diff --git a/assets/sprites/cloud1.png b/assets/sprites/cloud1.png new file mode 100644 index 0000000000000000000000000000000000000000..c90e05ded9e8f72c126aec1b022f18b48865db05 GIT binary patch literal 626 zcmV-&0*(ENP)Px%EJ;K`RCt{2n%#B6FbqZ|$|z-nvi|^OgEC4v=>v675dKRdOG^3fYYP&({*u^0 z1VX^x4fHZi)71JOX5P)`k%Vr%XZR)dCM9IETLehM|%)(72zR43vC$(%{O}`v=`A)^Uap9=QK!4pJhpE zTrN%jNkT6zDY!Hl(OP`wiFm~{NOI{wA{@vqMu>1i%20V~YF__-qln8=nbr3Q3{{7; zNEamn!yiX?A|PQL%*@S1K!6R^rzS|SqbLFrY{`m%1bd!DK!Ok0SvzyN-iSzuKpOl& zA{}HB z@n#Jf<4Cie-wvKc%>QU9<8r;3%lBAprJBVX^yk<2!Hz+M-QdYd}kBZ6dYn)oN-cv6Q~rYgX^3*A8jT z4qih@PhHE@OH__ET7%L)KIsv&rKVOAm-K-1r3#j*hlozBQxBZ@0p3O}!|1yWV*mgE M07*qoM6N<$f^zu}4gdfE literal 0 HcmV?d00001 diff --git a/assets/sprites/cloud1.png.import b/assets/sprites/cloud1.png.import new file mode 100644 index 0000000..6d3beb8 --- /dev/null +++ b/assets/sprites/cloud1.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://0ojjcq4b80fa" +path="res://.godot/imported/cloud1.png-a97dbe7d6b1051a1024f1aaf3c6bf014.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/sprites/cloud1.png" +dest_files=["res://.godot/imported/cloud1.png-a97dbe7d6b1051a1024f1aaf3c6bf014.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/sprites/cloud2.png b/assets/sprites/cloud2.png new file mode 100644 index 0000000000000000000000000000000000000000..f5ddfad5385246bd286a64cc22a1846cb767a08a GIT binary patch literal 526 zcmV+p0`dKcP)001)x1^@s6-#_(600001b5ch_0Itp) z=>Px$$Vo&&RA_rKFc3wr9hZ`Hkn~@G>A;j?5BZ74>t!YM*agMf^T}Z8a&!d- zz{%#c*F?**EYT3B({4FhFb|oM#OYm{S-28OoL;4wglZ8L=uwz@APrH0-h`=!(G(Tv zNtjv?3sC_s?5HQ}#cE(}auIb5?^7`9oI+?G|zdKXEYEonuv-c=GMB`izU2$DFGw4|&NB~iGr z=+kg?Q4(UaT+|cVu9YkowI&FA*@iAEjsJtsAe89L4>)nWSp~SP0?vSM!Cbsq1-PsN zTvi6t`~cvxif~yQgjNB6vgiTlN$~RXby>d~I%!;11l}rue4@GD?#uV*#{seWg5Hv- zD8QTb!q&a}Mb@Y{`e}ZwuAR3EU|&kFxBCJB*4uHKALeu9WRQ>~1w>hZoiH9!nnzP+ z$!#g`I!EFOJLU5Z11> QkN^Mx07*qoM6N<$f@$yVr~m)} literal 0 HcmV?d00001 diff --git a/assets/sprites/cloud2.png.import b/assets/sprites/cloud2.png.import new file mode 100644 index 0000000..c8a049b --- /dev/null +++ b/assets/sprites/cloud2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ccw0v328r7xn5" +path="res://.godot/imported/cloud2.png-151b43441b59cee1103798b0f2d26cc8.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/sprites/cloud2.png" +dest_files=["res://.godot/imported/cloud2.png-151b43441b59cee1103798b0f2d26cc8.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/sprites/cloud3.png b/assets/sprites/cloud3.png new file mode 100644 index 0000000000000000000000000000000000000000..3b61e7b58fba9be96ef651077ead30d92e999a05 GIT binary patch literal 601 zcmV-f0;c_mP)Px%6G=otRCt{2n_F%JAq++B=`5w$L9_n_G&^XP(rEHi)CmE@fH6*V&tG1Wb+}@T zQHX#kJi7piZQC~Kb7pp3e+qX6mn7$S75Q$8Y!w~jUHtUov_!{v6+gA8QL+ObrB5kn zwCEU5;>`=OmL2dSeVtu^H%7OjrmH?H-GQ7e%U0A(_-xsMy`&kfsEKedvIES_+BMZm z?-uS&=4?vhn}kEMj3oV#aEPuaC%sBIM7NQWzLb6h*}8}chwOghlxKxQwjO)w$t?x4 z$MKYK$R0yT`9s1XdpyN11?Zwa$N_nnnUQc~Al#UR2-}GzNVqW&ZVZGQ1L4L%xG@lJ z#N~P;qCer`1sD$!ZVZGQu-`$J)SEz`^J)E`hldwHpE$^i^daaY<@0F|hje}RJIIoH z6Vm(1Im~t`klxPTUHp7}dRTt{{65Uazdk>P750uuvWXH2kH3VZ*KxVts$6B;!8qwe zNPCWy=v=EU_TMS#L=YdyC0aVy6c0Q(>46&gm+S3q7OAvtln#+qC(M%cT3$tZ%X6#t zw0`JFuOZ&M^pUcO8vo000&U1^@s6h+bjC00001b5ch_0Itp) z=>Px$14%?dR9J=Gn86MMAqYgJ>Hq&Sz0|~P1xHZCzN@Q{5k^;HW-cH^MA~?7tG^)OoVxdI)<`rVq-SxJjR$Yjv!D2=2;%uDA>Uw(; zh%nvNF^K5r27sQFSF~Zv$y3oJ7JXTrjJ2g^=Z$ig#;3)K+}WM6q_wq}UC+vJ0W2lo zFI5`P@(L3nY#Om{Aca`j+D)SCSu4?m(7e&|n#s((({EE$){`s;%#-6{d0No&3hLpw bSU2$j8o8(?PfHdk00000NkvXXu0mjf(z=uA literal 0 HcmV?d00001 diff --git a/assets/sprites/play.png.import b/assets/sprites/play.png.import new file mode 100644 index 0000000..587b423 --- /dev/null +++ b/assets/sprites/play.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dw3f8gb3rk8ek" +path="res://.godot/imported/play.png-2124cd03a740eea8316d14d98d26b031.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/sprites/play.png" +dest_files=["res://.godot/imported/play.png-2124cd03a740eea8316d14d98d26b031.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/sprites/quit.png b/assets/sprites/quit.png new file mode 100644 index 0000000000000000000000000000000000000000..95e19aa6e924d0d8fa9789c2e57861f5ab7099fc GIT binary patch literal 329 zcmV-P0k-~$P)Px$14%?dR9J=WncWV1?94$r~zlDcqa9oT>sDI-k(2U}hg~InAQ9DNSGjck}yVh{=L`0dK#Er$eCL$L+ z61WFQZIzsaT!YmGncT7iR-onu&YVvy@l{^4c922~q|gE>v_J|ikOHpQfmZBJ{zF=R zr2k(n`j<6mb|AZ|f9YD~8{FPW&s=(YF3LvSst*D?2@Rt1`DYNGOm&f#Or)|%+fLG% bw{8zlG{vMpLw)JR00000NkvXXu0mjfW^9Uu literal 0 HcmV?d00001 diff --git a/assets/sprites/quit.png.import b/assets/sprites/quit.png.import new file mode 100644 index 0000000..e2b63e9 --- /dev/null +++ b/assets/sprites/quit.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cf66nknocxscm" +path="res://.godot/imported/quit.png-6b89bf52609c052e679e765f957e0601.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/sprites/quit.png" +dest_files=["res://.godot/imported/quit.png-6b89bf52609c052e679e765f957e0601.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/assets/sprites/title.png b/assets/sprites/title.png new file mode 100644 index 0000000000000000000000000000000000000000..11ed9098a695a05054145e986b87ac9c31b5fb24 GIT binary patch literal 2704 zcmV;B3UBp^P)Px_ZK%zDceju6e=q5!05IzIa%Z6fD*+2G9DJXpx6E zyp^S` z6*&ReIV<=2muQj4&U{n*&7~J&?Y(w1=7CMf9152|BNNCEC@R?Pc1vwbw`&@lQ1Kv} z#X04ADr5y)lHnDC>rBby}`rxdaRSh@rt z6d)=(SXKVB?mz?L4l1W;LnV)&wJFtJs9jVIg?U;qal75Lb;;`*7wy-GIuXrDZ35O@ zd_{Z12!8~YTw)PHmjwH#;yAs}FO^76$~-dC6n=C?(PT8GoPh~trmA-%&2JPZ<;Jj% zB>a(Ba*4-8ftX2uM$w4~2PeEOxM5#VYH+z+(7(Ok?}9y9c)+VJdF|JXY)*<|JkG!x z7et%Q4vIP+szKCP!~$)YJN&P&FZ6G(*DCsyWZfvLfD7&cd?{BVVMRsKXzY8GhyAaQOe0-pP`}z4P*pr18UteEn z`=CX#8Q%IuWrp3dwWBz^;R1fmHeF)#%Mel5Xvqpr?QJ8 zQ98Xsa82VWg+D{25&_JP)=NOK19dGvtxE@x`dV{T-q7k(!#nO0Pix|*;f6e z+N^v)`)O^=vYS%*ERxiv-IQ16*p+2$@90wQ7n@J-#p(sK#~0fG^gD8%-!n82{r%=v z_1i+1Y9w2fzwgBKiQ`=vb?lWwpJrISGH7v9!P#LMA8+ zdKaZ>+$9#e)CtdCdd51)L7dG|B|HX1T7Bv{FYBhK53rv z<38zFaaNuVT695iQsiA!&e}!cVK_kH`M^Xs>1zQ8r#sggTaXY8c6J?f%V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@WzSIo2l1JE@W_A_0)AuTm_e z@WLLEk(6;{c8v1O@*-t~D2!;cqB<#n?0p)iv#LZmLkN2$MpVWTS z0RM#X;H(l@!5?hBJqjBYg^jqwSOJ88EOkj}&5P}NU? void: var crosshair = crosshair_scene.instantiate() crosshair.number = number crosshair.name = "Crosshair" + str(number) - crosshair.position.y = randf_range(-100, 100) + crosshair.position.x = 350 + crosshair.position.y = randf_range(100, 350) crosshair.color = crosshair_color get_parent().add_child(crosshair) diff --git a/scenes/players/player.tscn b/scenes/players/player.tscn index db7c5b2..2584d24 100644 --- a/scenes/players/player.tscn +++ b/scenes/players/player.tscn @@ -6,11 +6,13 @@ [ext_resource type="SpriteFrames" uid="uid://baufp5u5muwll" path="res://resources/zombie_3_frames.tres" id="4_mstxp"] [sub_resource type="RectangleShape2D" id="RectangleShape2D_5wrs1"] -size = Vector2(58, 118) +size = Vector2(34, 68) [node name="Player" type="CharacterBody2D" groups=["players"]] z_index = 100 script = ExtResource("1_fff2d") +run_boost = 48.0 +speed = 32.0 sprite_frames = Array[SpriteFrames]([ExtResource("2_g323d"), ExtResource("3_vyhye"), ExtResource("4_mstxp")]) [node name="CollisionShape2D" type="CollisionShape2D" parent="."] @@ -18,7 +20,6 @@ shape = SubResource("RectangleShape2D_5wrs1") [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] position = Vector2(-3.8147e-06, -1.90735e-06) -scale = Vector2(1.8, 1.8) sprite_frames = ExtResource("2_g323d") animation = &"idle" autoplay = "idle" diff --git a/scenes/zombie/zombie.tscn b/scenes/zombie/zombie.tscn index ecc2c8f..517e268 100644 --- a/scenes/zombie/zombie.tscn +++ b/scenes/zombie/zombie.tscn @@ -6,10 +6,11 @@ [ext_resource type="SpriteFrames" uid="uid://baufp5u5muwll" path="res://resources/zombie_3_frames.tres" id="4_kcvoe"] [sub_resource type="RectangleShape2D" id="RectangleShape2D_6al3e"] -size = Vector2(58, 118) +size = Vector2(40, 64) [node name="Zombie" type="CharacterBody2D"] script = ExtResource("1_7wpk0") +speed = 32.0 sprite_frames = Array[SpriteFrames]([ExtResource("2_8m1jv"), ExtResource("3_rc68x"), ExtResource("4_kcvoe")]) metadata/_edit_group_ = true @@ -21,7 +22,6 @@ unique_name_in_owner = true autostart = true [node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."] -scale = Vector2(1.8, 1.8) sprite_frames = ExtResource("2_8m1jv") animation = &"idle" autoplay = "idle"