Compare commits

...
4 Commits
Author SHA1 Message Date
sam 2315add8ec Merge pull request 'Player Movment' (#2) from sam's_puzzle_expirement into main
Reviewed-on: #2
Reviewed-by: matt <matt@mattstone.io>
2026-10-02 20:44:24 -05:00
sam 978fb7aded Player Movment
implented edited hollow night movement and set up player/test_scene.
2026-10-02 19:46:07 -06:00
sam 1eccb9bc67 Merge pull request 'Adding Title' (#1) from title_scene into main
Reviewed-on: #1
Reviewed-by: matt <matt@mattstone.io>
2026-10-02 19:24:34 -05:00
sam 55dc6719da Adding Title
Adding in title screen and staging the button for plumbing later.
2026-10-02 18:25:55 -06:00
12 changed files with 145 additions and 45 deletions

No files matched your search

+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://xlg0kyp0jhet"
path="res://.godot/imported/coin.png-c8309bf0f8fb5f3a7d1e96a4eb3f02ce.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/coin.png"
dest_files=["res://.godot/imported/coin.png-c8309bf0f8fb5f3a7d1e96a4eb3f02ce.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://coer7bk56ksye"
path="res://.godot/imported/fruit.png-3735163b668af10c2b35b52cba81b68a.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/fruit.png"
dest_files=["res://.godot/imported/fruit.png-3735163b668af10c2b35b52cba81b68a.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://bt61g6xdrepd"
path="res://.godot/imported/knight.png-7c67c83d34932624952797d9e971a644.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/knight.png"
dest_files=["res://.godot/imported/knight.png-7c67c83d34932624952797d9e971a644.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://b7cc0lt1g041f"
path="res://.godot/imported/platforms.png-3869606db457611ed4193d705dc364e4.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/platforms.png"
dest_files=["res://.godot/imported/platforms.png-3869606db457611ed4193d705dc364e4.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://bfp7d2c8w5d5j"
path="res://.godot/imported/slime_green.png-f6349164bf3a0f5189bb927b97af9c58.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/slime_green.png"
dest_files=["res://.godot/imported/slime_green.png-f6349164bf3a0f5189bb927b97af9c58.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://cjx7y6aru1j2v"
path="res://.godot/imported/slime_purple.png-26dc5ddef235ce6a400e78e0d532b050.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/slime_purple.png"
dest_files=["res://.godot/imported/slime_purple.png-26dc5ddef235ce6a400e78e0d532b050.ctex"]
[params]
+1 -5
View File
@@ -3,15 +3,11 @@
importer="texture"
type="CompressedTexture2D"
uid="uid://bdtdnto04r82s"
path="res://.godot/imported/world_tileset.png-61a32465f33c3d9d3bfecb75b6485009.ctex"
metadata={
"vram_texture": false
}
valid=false
[deps]
source_file="res://assets/sprites/world_tileset.png"
dest_files=["res://.godot/imported/world_tileset.png-61a32465f33c3d9d3bfecb75b6485009.ctex"]
[params]
+54
View File
@@ -11,6 +11,7 @@ config_version=5
[application]
config/name="wgj26"
run/main_scene="uid://btktv5aqpafau"
config/features=PackedStringArray("4.7", "Forward Plus")
config/icon="res://icon.svg"
@@ -19,6 +20,59 @@ config/icon="res://icon.svg"
window/stretch/mode="canvas_items"
window/stretch/aspect="expand"
[input]
left={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":65,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
right={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":68,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
jump={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":32,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
dash={
"deadzone": 0.2,
"events": [null, Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194325,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
up={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":87,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
down={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":83,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
roll={
"deadzone": 0.2,
"events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":0,"position":Vector2(0, 0),"global_position":Vector2(0, 0),"factor":1.0,"button_index":2,"canceled":false,"pressed":false,"double_click":false,"script":null)
]
}
latch={
"deadzone": 0.2,
"events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":0,"position":Vector2(0, 0),"global_position":Vector2(0, 0),"factor":1.0,"button_index":1,"canceled":false,"pressed":false,"double_click":false,"script":null)
]
}
twirl={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":4194329,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
run={
"deadzone": 0.2,
"events": [Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":16,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"pressed":false,"keycode":0,"physical_keycode":69,"key_label":0,"unicode":0,"location":0,"echo":false,"script":null)
]
}
[physics]
3d/physics_engine="Jolt Physics"
+20
View File
@@ -0,0 +1,20 @@
[gd_scene format=3 uid="uid://cmtdq6tedv1mm"]
[ext_resource type="Script" uid="uid://2ig5okof0vaa" path="res://scripts/UltimatePlatformerController.gd" id="1_3vyb7"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_d2by0"]
size = Vector2(111, 105)
[node name="player" type="CharacterBody2D" unique_id=1596338883]
collision_mask = 2
script = ExtResource("1_3vyb7")
[node name="ColorRect" type="ColorRect" parent="." unique_id=42689460]
offset_right = 111.0
offset_bottom = 105.0
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="." unique_id=440932344]
[node name="CollisionShape2D" type="CollisionShape2D" parent="." unique_id=1496788104]
position = Vector2(55.5, 52.5)
shape = SubResource("RectangleShape2D_d2by0")
+26
View File
@@ -0,0 +1,26 @@
[gd_scene format=3 uid="uid://d1xirc54wud0s"]
[ext_resource type="PackedScene" uid="uid://cmtdq6tedv1mm" path="res://scenes/player.tscn" id="1_g7g4h"]
[ext_resource type="Script" uid="uid://87oh2y0i2muf" path="res://scenes/rigid_body_2d.gd" id="2_nd71p"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_aqe1g"]
size = Vector2(1116.25, 73)
[node name="test_scene" type="Node2D" unique_id=1970054744]
[node name="ColorRect" type="ColorRect" parent="." unique_id=1255479846]
offset_left = 2.0
offset_top = 530.0
offset_right = 1121.0
offset_bottom = 606.0
[node name="player" parent="." unique_id=1596338883 instance=ExtResource("1_g7g4h")]
position = Vector2(64, 386)
[node name="floor" type="StaticBody2D" parent="." unique_id=866269158]
collision_layer = 2
script = ExtResource("2_nd71p")
[node name="CollisionShape2D" type="CollisionShape2D" parent="floor" unique_id=1146724072]
position = Vector2(561.125, 569)
shape = SubResource("RectangleShape2D_aqe1g")
+28
View File
@@ -1,5 +1,7 @@
[gd_scene format=3 uid="uid://btktv5aqpafau"]
[ext_resource type="FontFile" uid="uid://dkytywan8eapf" path="res://assets/fonts/PixelOperator8.ttf" id="1_4ignj"]
[node name="Title" type="Control" unique_id=715100706]
layout_mode = 3
anchors_preset = 15
@@ -7,3 +9,29 @@ anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
[node name="ColorRect" type="ColorRect" parent="." unique_id=1504521213]
layout_mode = 0
offset_right = 1152.0
offset_bottom = 648.0
color = Color(0, 0, 0, 1)
[node name="Label" type="Label" parent="." unique_id=1433094765]
layout_mode = 0
offset_left = 107.0
offset_top = 50.0
offset_right = 1013.0
offset_bottom = 301.0
theme_override_fonts/font = ExtResource("1_4ignj")
theme_override_font_sizes/font_size = 250
text = "title"
[node name="Button" type="Button" parent="." unique_id=963162220]
layout_mode = 0
offset_left = 149.0
offset_top = 375.0
offset_right = 982.0
offset_bottom = 583.0
theme_override_fonts/font = ExtResource("1_4ignj")
theme_override_font_sizes/font_size = 150
text = "start"
+10 -10
View File
@@ -10,15 +10,15 @@ class_name PlatformerController2D
#2. Animations are very primitive. To make full use of your custom art, you may want to slightly change the code for the animations
@export_category("Necesary Child Nodes")
@export var PlayerSprite: AnimatedSprite2D
@export var PlayerCollider: CollisionShape2D
@onready var PlayerSprite = $AnimatedSprite2D
@onready var PlayerCollider = $CollisionShape2D
#INFO HORIZONTAL MOVEMENT
@export_category("L/R Movement")
##The max speed your player will move
@export_range(50, 500) var maxSpeed: float = 200.0
@export_range(50, 500) var maxSpeed: float = 500
##How fast your player will reach max speed from rest (in seconds)
@export_range(0, 4) var timeToReachMaxSpeed: float = 0.2
@export_range(0, 4) var timeToReachMaxSpeed: float = 0
##How fast your player will reach zero speed from max speed (in seconds)
@export_range(0, 4) var timeToReachZeroSpeed: float = 0.2
##If true, player will instantly move and switch directions. Overrides the "timeToReach" variables, setting them to 0.
@@ -29,15 +29,15 @@ class_name PlatformerController2D
#INFO JUMPING
@export_category("Jumping and Gravity")
##The peak height of your player's jump
@export_range(0, 20) var jumpHeight: float = 2.0
@export_range(0, 20) var jumpHeight: float = 4
##How many jumps your character can do before needing to touch the ground again. Giving more than 1 jump disables jump buffering and coyote time.
@export_range(0, 4) var jumps: int = 1
@export_range(0, 4) var jumps: int = 2
##The strength at which your character will be pulled to the ground.
@export_range(0, 100) var gravityScale: float = 20.0
@export_range(0, 100) var gravityScale: float = 30
##The fastest your player can fall
@export_range(0, 1000) var terminalVelocity: float = 500.0
@export_range(0, 1000) var terminalVelocity: float = 700
##Your player will move this amount faster when falling providing a less floaty jump curve.
@export_range(0.5, 3) var descendingGravityFactor: float = 1.3
@export_range(0.5, 3) var descendingGravityFactor: float = 2
##Enabling this toggle makes it so that when the player releases the jump key while still ascending, their vertical velocity will cut by the height cut, providing variable jump height.
@export var shortHopAkaVariableJumpHeight: bool = true
##How much the jump height is cut by.
@@ -159,7 +159,7 @@ var wasLatched
var crouching
var groundPounding
var anim
var anim = PlayerSprite
var col
var animScaleLock : Vector2