PEW PEWPEPWPEPEWEP

This commit is contained in:
Victor Turgeon 2023-01-14 17:14:55 -05:00
parent a80feca89b
commit b31f0be98a
28 changed files with 116 additions and 45 deletions

View File

@ -1,3 +1,7 @@
Sprite2D
Line2D
RayCast2D
Camera2D
TileMap TileMap
CollisionShape2D CollisionShape2D
AnimatedSprite2D AnimatedSprite2D

View File

@ -8,7 +8,7 @@ dock_split_2=0
dock_split_3=0 dock_split_3=0
dock_hsplit_1=0 dock_hsplit_1=0
dock_hsplit_2=309 dock_hsplit_2=309
dock_hsplit_3=-216 dock_hsplit_3=-266
dock_hsplit_4=0 dock_hsplit_4=0
dock_3="Scene,Import" dock_3="Scene,Import"
dock_4="FileSystem" dock_4="FileSystem"
@ -16,7 +16,7 @@ dock_5="Inspector,Node,History"
[EditorNode] [EditorNode]
open_scenes=["res://test_level001.tscn"] open_scenes=["res://test_level001.tscn", "res://Player/player.tscn", "res://Player/Weapons/basic_weapon.tscn", "res://Player/Projectiles/basic_projectile.tscn"]
[ScriptEditor] [ScriptEditor]

View File

@ -1,13 +1,21 @@
0b7126e0c6e86d3ec295a72f5aa6e0bd 0b7126e0c6e86d3ec295a72f5aa6e0bd
::res://::1673728399 ::res://::1673734432
icon.svg::CompressedTexture2D::4918904308290865421::1673712834::1673713013::1::::<><>:: icon.svg::CompressedTexture2D::4918904308290865421::1673712834::1673713013::1::::<><>::
placeholder.png::CompressedTexture2D::4828848561319431753::1673716304::1673716317::1::::<><>:: placeholder.png::CompressedTexture2D::4828848561319431753::1673716304::1673716317::1::::<><>::
README.md::TextFile::-1::1673712834::0::1::::<><>:: README.md::TextFile::-1::1673712834::0::1::::<><>::
test_level001.tscn::PackedScene::278447013021769396::1673727256::0::1::::<><>::uid://b62h0w8gjm6tj test_level001.tscn::PackedScene::278447013021769396::1673733616::0::1::::<><>::uid://b62h0w8gjm6tj<>uid://brxelntunb27r
::res://Levels/::1673726687 ::res://Levels/::1673726687
level.tscn::PackedScene::4739050375457527030::1673726687::0::1::::<><>:: level.tscn::PackedScene::4739050375457527030::1673726687::0::1::::<><>::
::res://Player/::1673727256 ::res://Player/::1673733741
player.gd::GDScript::-1::1673726441::0::1::::<>CharacterBody2D<>:: player.gd::GDScript::-1::1673732770::0::1::::<>CharacterBody2D<>::
player.tscn::PackedScene::4618483906406103163::1673727256::0::1::::<><>::res://Player/player.gd<>uid://ca2eovotfh6v2 player.tscn::PackedScene::4618483906406103163::1673733616::0::1::::<><>::res://Player/player.gd<>uid://wkeakqjvu3gg
::res://TileSets/::1673728399 ::res://Player/Projectiles/::1673734122
basic_projectile.tscn::PackedScene::5856608848916302392::1673734122::0::1::::<><>::
::res://Player/Weapons/::1673734078
basic_weapon.tscn::PackedScene::5655575360493827386::1673734078::0::1::::<><>::
::res://Sprites/::1673734432
dingo_jam_mc_front_64.png::CompressedTexture2D::1565041755936548690::1673732299::1673732300::1::::<><>::
pew.png::CompressedTexture2D::7577871081029115281::1673734362::1673734427::1::::<><>::
projectile.png::CompressedTexture2D::13383739614235193::1673734403::1673734432::1::::<><>::
::res://TileSets/::1673728405
Tiles Set GameJam.png::CompressedTexture2D::3627374938668034389::1673728399::1673728405::1::::<><>:: Tiles Set GameJam.png::CompressedTexture2D::3627374938668034389::1673728399::1673728405::1::::<><>::

View File

@ -1,2 +1,4 @@
res://Player/player.tscn
res://test_level001.tscn res://test_level001.tscn
res://Player/player.tscn
res://Player/player.gd
res://Player/Weapons/basic_weapon.tscn

View File

@ -8,7 +8,7 @@ Anim={
"grid_snap_active": false, "grid_snap_active": false,
"grid_step": Vector2(8, 8), "grid_step": Vector2(8, 8),
"grid_visibility": 1, "grid_visibility": 1,
"ofs": Vector2(-695, -333), "ofs": Vector2(-964.97, -535.65),
"primary_grid_steps": 8, "primary_grid_steps": 8,
"show_edit_locks": true, "show_edit_locks": true,
"show_guides": true, "show_guides": true,
@ -32,7 +32,7 @@ Anim={
"snap_rotation_step": 0.261799, "snap_rotation_step": 0.261799,
"snap_scale": false, "snap_scale": false,
"snap_scale_step": 0.1, "snap_scale_step": 0.1,
"zoom": 1.0 "zoom": 0.529732
} }
3D={ 3D={
"fov": 70.01, "fov": 70.01,

View File

@ -1,5 +1,5 @@
[folding] [folding]
node_unfolds=[NodePath("AnimatedSprite2D"), PackedStringArray("Animation", "frames"), NodePath("CollisionShape2D"), PackedStringArray("shape")] node_unfolds=[NodePath("AnimatedSprite2D"), PackedStringArray("Animation", "frames"), NodePath("CollisionShape2D"), PackedStringArray("shape"), NodePath("RayCast2D"), PackedStringArray("Visibility"), NodePath("RayCast2D/Line2D"), PackedStringArray("points")]
resource_unfolds=["res://Player/player.tscn::SpriteFrames_mqbrd", PackedStringArray("Resource"), "res://Player/player.tscn::RectangleShape2D_ng5bv", PackedStringArray()] resource_unfolds=["res://Player/player.tscn::SpriteFrames_mqbrd", PackedStringArray("Resource"), "res://Player/player.tscn::RectangleShape2D_ng5bv", PackedStringArray()]
nodes_folded=[] nodes_folded=[]

View File

@ -1,6 +1,6 @@
[editor_metadata] [editor_metadata]
executable_path="/usr/bin/godot4" executable_path="C:/Godot_v4.0-beta12_mono_win64/Godot_v4.0-beta12_mono_win64/Godot_v4.0-beta12_mono_win64.exe"
tile_source_sort=0 tile_source_sort=0
[debug_options] [debug_options]
@ -10,7 +10,7 @@ run_reload_scripts=true
[recent_files] [recent_files]
scenes=["res://test_level001.tscn", "res://Player/player.tscn", "res://player.tscn"] scenes=["res://Player/player.tscn", "res://test_level001.tscn", "res://player.tscn"]
scripts=["Vector2", "CharacterBody2D", "res://player.gd"] scripts=["Vector2", "CharacterBody2D", "res://player.gd"]
[script_setup] [script_setup]
@ -20,3 +20,7 @@ last_selected_language="GDScript"
[dialog_bounds] [dialog_bounds]
project_settings=Rect2(510, 238, 900, 700) project_settings=Rect2(510, 238, 900, 700)
[color_picker]
recent_presets=PackedColorArray(0.158472, 0.158472, 0.158472, 1, 1, 0.156863, 0.156863, 1, 0.890153, 0, 0.0748197, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 1, 1, 0, 0, 0.670588, 1, 0, 0, 0.392157)

View File

@ -3,11 +3,11 @@
state={ state={
"bookmarks": PackedInt32Array(), "bookmarks": PackedInt32Array(),
"breakpoints": PackedInt32Array(), "breakpoints": PackedInt32Array(),
"column": 30, "column": 17,
"folded_lines": [], "folded_lines": [],
"h_scroll_position": 0, "h_scroll_position": 0,
"row": 2, "row": 15,
"scroll_position": 0.0, "scroll_position": 6.0,
"selection": false, "selection": false,
"syntax_highlighter": "GDScript" "syntax_highlighter": "GDScript"
} }

View File

@ -8,7 +8,7 @@ Anim={
"grid_snap_active": false, "grid_snap_active": false,
"grid_step": Vector2(8, 8), "grid_step": Vector2(8, 8),
"grid_visibility": 1, "grid_visibility": 1,
"ofs": Vector2(-49.3436, -18.2981), "ofs": Vector2(-7.60516, -14.8748),
"primary_grid_steps": 8, "primary_grid_steps": 8,
"show_edit_locks": true, "show_edit_locks": true,
"show_guides": true, "show_guides": true,
@ -32,7 +32,7 @@ Anim={
"snap_rotation_step": 0.261799, "snap_rotation_step": 0.261799,
"snap_scale": false, "snap_scale": false,
"snap_scale_step": 0.1, "snap_scale_step": 0.1,
"zoom": 2.11893 "zoom": 1.41421
} }
3D={ 3D={
"fov": 70.01, "fov": 70.01,

Binary file not shown.

View File

@ -1,4 +1,4 @@
<Project Sdk="Godot.NET.Sdk/4.0.0-beta"> <Project Sdk="Godot.NET.Sdk/4.0.0-beta.12">
<PropertyGroup> <PropertyGroup>
<TargetFramework>net6.0</TargetFramework> <TargetFramework>net6.0</TargetFramework>
<EnableDynamicLoading>true</EnableDynamicLoading> <EnableDynamicLoading>true</EnableDynamicLoading>

View File

@ -0,0 +1,7 @@
<Project Sdk="Godot.NET.Sdk/4.0.0-beta">
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<EnableDynamicLoading>true</EnableDynamicLoading>
<RootNamespace>GameJamVanier</RootNamespace>
</PropertyGroup>
</Project>

View File

@ -0,0 +1,3 @@
[gd_scene format=3 uid="uid://cpo8qy3y0fuui"]
[node name="basic_projectile" type="Node2D"]

View File

@ -0,0 +1,5 @@
[gd_scene format=3 uid="uid://cmtuq84761y0i"]
[node name="basic_weapon" type="Node2D"]
[node name="Sprite2D" type="Sprite2D" parent="."]

View File

@ -4,11 +4,16 @@ extends CharacterBody2D
@export var ACCELERATION = 2000.0; @export var ACCELERATION = 2000.0;
@export var FRICTION = 3000.0; @export var FRICTION = 3000.0;
@onready var raycast = $RayCast2D;
func _physics_process(delta): func _physics_process(delta):
var input_vector = get_input_vector(); var input_vector = get_input_vector();
apply_movement(input_vector, delta); apply_movement(input_vector, delta);
apply_friction(input_vector, delta); apply_friction(input_vector, delta);
move_and_slide(); move_and_slide();
var look_vec = get_global_mouse_position() - global_position;
raycast.rotation = atan2(look_vec.y,look_vec.x);
func get_input_vector(): func get_input_vector():
var input_vector = Vector2.ZERO; var input_vector = Vector2.ZERO;

View File

@ -1,13 +1,13 @@
[gd_scene load_steps=5 format=3 uid="uid://b62h0w8gjm6tj"] [gd_scene load_steps=5 format=3 uid="uid://b62h0w8gjm6tj"]
[ext_resource type="Script" path="res://Player/player.gd" id="1_mbyc2"] [ext_resource type="Script" path="res://Player/player.gd" id="1_mbyc2"]
[ext_resource type="Texture2D" uid="uid://ca2eovotfh6v2" path="res://placeholder.png" id="2_26hmp"] [ext_resource type="Texture2D" uid="uid://wkeakqjvu3gg" path="res://Sprites/dingo_jam_mc_front_64.png" id="2_ae25p"]
[sub_resource type="SpriteFrames" id="SpriteFrames_mqbrd"] [sub_resource type="SpriteFrames" id="SpriteFrames_mqbrd"]
animations = [{ animations = [{
"frames": [{ "frames": [{
"duration": 1.0, "duration": 1.0,
"texture": ExtResource("2_26hmp") "texture": ExtResource("2_ae25p")
}], }],
"loop": true, "loop": true,
"name": &"default", "name": &"default",
@ -25,3 +25,14 @@ frames = SubResource("SpriteFrames_mqbrd")
[node name="CollisionShape2D" type="CollisionShape2D" parent="."] [node name="CollisionShape2D" type="CollisionShape2D" parent="."]
shape = SubResource("RectangleShape2D_ng5bv") shape = SubResource("RectangleShape2D_ng5bv")
[node name="Camera2D" type="Camera2D" parent="."]
current = true
[node name="RayCast2D" type="RayCast2D" parent="."]
target_position = Vector2(2000, 0)
[node name="Line2D" type="Line2D" parent="RayCast2D"]
points = PackedVector2Array(0, 0, 2000, 0)
width = 5.0
default_color = Color(1, 0, 0, 0.392157)

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@ -2,16 +2,16 @@
importer="texture" importer="texture"
type="CompressedTexture2D" type="CompressedTexture2D"
uid="uid://ccc0vunx1coaf" uid="uid://wkeakqjvu3gg"
path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex" path="res://.godot/imported/dingo_jam_mc_front_64.png-601093cfabf1ebe5f72150684b2fcd7e.ctex"
metadata={ metadata={
"vram_texture": false "vram_texture": false
} }
[deps] [deps]
source_file="res://icon.svg" source_file="res://Sprites/dingo_jam_mc_front_64.png"
dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"] dest_files=["res://.godot/imported/dingo_jam_mc_front_64.png-601093cfabf1ebe5f72150684b2fcd7e.ctex"]
[params] [params]
@ -32,6 +32,3 @@ process/hdr_as_srgb=false
process/hdr_clamp_exposure=false process/hdr_clamp_exposure=false
process/size_limit=0 process/size_limit=0
detect_3d/compress_to=1 detect_3d/compress_to=1
svg/scale=1.0
editor/scale_with_editor_scale=false
editor/convert_colors_with_editor_theme=false

BIN
Sprites/pew.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 158 B

View File

@ -2,16 +2,16 @@
importer="texture" importer="texture"
type="CompressedTexture2D" type="CompressedTexture2D"
uid="uid://ca2eovotfh6v2" uid="uid://df71outtqfcu0"
path="res://.godot/imported/placeholder.png-ef21141e6f7fef7ccb4b638348400c3b.ctex" path="res://.godot/imported/pew.png-3aab10d741cd8f2cd98a8407fc89f0cc.ctex"
metadata={ metadata={
"vram_texture": false "vram_texture": false
} }
[deps] [deps]
source_file="res://placeholder.png" source_file="res://Sprites/pew.png"
dest_files=["res://.godot/imported/placeholder.png-ef21141e6f7fef7ccb4b638348400c3b.ctex"] dest_files=["res://.godot/imported/pew.png-3aab10d741cd8f2cd98a8407fc89f0cc.ctex"]
[params] [params]

BIN
Sprites/projectile.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 125 B

View File

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://gqotbni355f"
path="res://.godot/imported/projectile.png-eff5302beb46bc9a9106ccfb67813440.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://Sprites/projectile.png"
dest_files=["res://.godot/imported/projectile.png-eff5302beb46bc9a9106ccfb67813440.ctex"]
[params]
compress/mode=0
compress/lossy_quality=0.7
compress/hdr_compression=1
compress/bptc_ldr=0
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

View File

@ -1 +0,0 @@
<svg height="128" width="128" xmlns="http://www.w3.org/2000/svg"><g transform="translate(32 32)"><path d="m-16-32c-8.86 0-16 7.13-16 15.99v95.98c0 8.86 7.13 15.99 16 15.99h96c8.86 0 16-7.13 16-15.99v-95.98c0-8.85-7.14-15.99-16-15.99z" fill="#363d52"/><path d="m-16-32c-8.86 0-16 7.13-16 15.99v95.98c0 8.86 7.13 15.99 16 15.99h96c8.86 0 16-7.13 16-15.99v-95.98c0-8.85-7.14-15.99-16-15.99zm0 4h96c6.64 0 12 5.35 12 11.99v95.98c0 6.64-5.35 11.99-12 11.99h-96c-6.64 0-12-5.35-12-11.99v-95.98c0-6.64 5.36-11.99 12-11.99z" fill-opacity=".4"/></g><g stroke-width="9.92746" transform="matrix(.10073078 0 0 .10073078 12.425923 2.256365)"><path d="m0 0s-.325 1.994-.515 1.976l-36.182-3.491c-2.879-.278-5.115-2.574-5.317-5.459l-.994-14.247-27.992-1.997-1.904 12.912c-.424 2.872-2.932 5.037-5.835 5.037h-38.188c-2.902 0-5.41-2.165-5.834-5.037l-1.905-12.912-27.992 1.997-.994 14.247c-.202 2.886-2.438 5.182-5.317 5.46l-36.2 3.49c-.187.018-.324-1.978-.511-1.978l-.049-7.83 30.658-4.944 1.004-14.374c.203-2.91 2.551-5.263 5.463-5.472l38.551-2.75c.146-.01.29-.016.434-.016 2.897 0 5.401 2.166 5.825 5.038l1.959 13.286h28.005l1.959-13.286c.423-2.871 2.93-5.037 5.831-5.037.142 0 .284.005.423.015l38.556 2.75c2.911.209 5.26 2.562 5.463 5.472l1.003 14.374 30.645 4.966z" fill="#fff" transform="matrix(4.162611 0 0 -4.162611 919.24059 771.67186)"/><path d="m0 0v-47.514-6.035-5.492c.108-.001.216-.005.323-.015l36.196-3.49c1.896-.183 3.382-1.709 3.514-3.609l1.116-15.978 31.574-2.253 2.175 14.747c.282 1.912 1.922 3.329 3.856 3.329h38.188c1.933 0 3.573-1.417 3.855-3.329l2.175-14.747 31.575 2.253 1.115 15.978c.133 1.9 1.618 3.425 3.514 3.609l36.182 3.49c.107.01.214.014.322.015v4.711l.015.005v54.325c5.09692 6.4164715 9.92323 13.494208 13.621 19.449-5.651 9.62-12.575 18.217-19.976 26.182-6.864-3.455-13.531-7.369-19.828-11.534-3.151 3.132-6.7 5.694-10.186 8.372-3.425 2.751-7.285 4.768-10.946 7.118 1.09 8.117 1.629 16.108 1.846 24.448-9.446 4.754-19.519 7.906-29.708 10.17-4.068-6.837-7.788-14.241-11.028-21.479-3.842.642-7.702.88-11.567.926v.006c-.027 0-.052-.006-.075-.006-.024 0-.049.006-.073.006v-.006c-3.872-.046-7.729-.284-11.572-.926-3.238 7.238-6.956 14.642-11.03 21.479-10.184-2.264-20.258-5.416-29.703-10.17.216-8.34.755-16.331 1.848-24.448-3.668-2.35-7.523-4.367-10.949-7.118-3.481-2.678-7.036-5.24-10.188-8.372-6.297 4.165-12.962 8.079-19.828 11.534-7.401-7.965-14.321-16.562-19.974-26.182 4.4426579-6.973692 9.2079702-13.9828876 13.621-19.449z" fill="#478cbf" transform="matrix(4.162611 0 0 -4.162611 104.69892 525.90697)"/><path d="m0 0-1.121-16.063c-.135-1.936-1.675-3.477-3.611-3.616l-38.555-2.751c-.094-.007-.188-.01-.281-.01-1.916 0-3.569 1.406-3.852 3.33l-2.211 14.994h-31.459l-2.211-14.994c-.297-2.018-2.101-3.469-4.133-3.32l-38.555 2.751c-1.936.139-3.476 1.68-3.611 3.616l-1.121 16.063-32.547 3.138c.015-3.498.06-7.33.06-8.093 0-34.374 43.605-50.896 97.781-51.086h.066.067c54.176.19 97.766 16.712 97.766 51.086 0 .777.047 4.593.063 8.093z" fill="#478cbf" transform="matrix(4.162611 0 0 -4.162611 784.07144 817.24284)"/><path d="m0 0c0-12.052-9.765-21.815-21.813-21.815-12.042 0-21.81 9.763-21.81 21.815 0 12.044 9.768 21.802 21.81 21.802 12.048 0 21.813-9.758 21.813-21.802" fill="#fff" transform="matrix(4.162611 0 0 -4.162611 389.21484 625.67104)"/><path d="m0 0c0-7.994-6.479-14.473-14.479-14.473-7.996 0-14.479 6.479-14.479 14.473s6.483 14.479 14.479 14.479c8 0 14.479-6.485 14.479-14.479" fill="#414042" transform="matrix(4.162611 0 0 -4.162611 367.36686 631.05679)"/><path d="m0 0c-3.878 0-7.021 2.858-7.021 6.381v20.081c0 3.52 3.143 6.381 7.021 6.381s7.028-2.861 7.028-6.381v-20.081c0-3.523-3.15-6.381-7.028-6.381" fill="#fff" transform="matrix(4.162611 0 0 -4.162611 511.99336 724.73954)"/><path d="m0 0c0-12.052 9.765-21.815 21.815-21.815 12.041 0 21.808 9.763 21.808 21.815 0 12.044-9.767 21.802-21.808 21.802-12.05 0-21.815-9.758-21.815-21.802" fill="#fff" transform="matrix(4.162611 0 0 -4.162611 634.78706 625.67104)"/><path d="m0 0c0-7.994 6.477-14.473 14.471-14.473 8.002 0 14.479 6.479 14.479 14.473s-6.477 14.479-14.479 14.479c-7.994 0-14.471-6.485-14.471-14.479" fill="#414042" transform="matrix(4.162611 0 0 -4.162611 656.64056 631.05679)"/></g></svg>

Before

Width:  |  Height:  |  Size: 4.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 475 B

View File

@ -20,6 +20,8 @@ config/icon="res://icon.svg"
window/size/viewport_width=1920 window/size/viewport_width=1920
window/size/viewport_height=1080 window/size/viewport_height=1080
window/size/mode=3 window/size/mode=3
window/size/resizable=false
window/stretch/mode="viewport"
[dotnet] [dotnet]

File diff suppressed because one or more lines are too long