Compare commits

..

2 commits

11 changed files with 369 additions and 15 deletions

View file

@ -15,6 +15,10 @@ run/main_scene="uid://bxdnehietcpkj"
config/features=PackedStringArray("4.6", "Mobile") config/features=PackedStringArray("4.6", "Mobile")
config/icon="res://icon.svg" config/icon="res://icon.svg"
[autoload]
Global="*uid://4hvgybxt05qj"
[editor_plugins] [editor_plugins]
enabled=PackedStringArray("res://addons/godot_super-wakatime/plugin.cfg") enabled=PackedStringArray("res://addons/godot_super-wakatime/plugin.cfg")

View file

@ -1,11 +1,13 @@
[gd_scene format=3 uid="uid://bxdnehietcpkj"] [gd_scene format=3 uid="uid://bxdnehietcpkj"]
[ext_resource type="Script" uid="uid://dhfun46prq3uk" path="res://scripts/game.gd" id="1_gee14"]
[ext_resource type="Script" uid="uid://crf3d7dpjvlsl" path="res://scripts/player_camera.gd" id="1_lnu2h"] [ext_resource type="Script" uid="uid://crf3d7dpjvlsl" path="res://scripts/player_camera.gd" id="1_lnu2h"]
[ext_resource type="Script" uid="uid://66iq60cxqomg" path="res://scripts/player.gd" id="1_yqjtg"] [ext_resource type="Script" uid="uid://66iq60cxqomg" path="res://scripts/player.gd" id="1_yqjtg"]
[ext_resource type="Texture2D" uid="uid://dp3jbqmr5toth" path="res://textures/character-body.png" id="3_p57ef"] [ext_resource type="Texture2D" uid="uid://dp3jbqmr5toth" path="res://textures/character-body.png" id="3_p57ef"]
[ext_resource type="Texture2D" uid="uid://b6krbvbco0jt6" path="res://textures/shadow.png" id="4_lbhrr"] [ext_resource type="Texture2D" uid="uid://b6krbvbco0jt6" path="res://textures/shadow.png" id="4_lbhrr"]
[ext_resource type="Texture2D" uid="uid://3ptkafoafq14" path="res://textures/character-leg.png" id="4_u5sy4"] [ext_resource type="Texture2D" uid="uid://3ptkafoafq14" path="res://textures/character-leg.png" id="4_u5sy4"]
[ext_resource type="PackedScene" uid="uid://b0kty7juk7rfo" path="res://models/stalagmite.gltf" id="5_iywne"] [ext_resource type="PackedScene" uid="uid://b0kty7juk7rfo" path="res://models/stalagmite.gltf" id="5_iywne"]
[ext_resource type="Texture2D" uid="uid://rgxhw23471ut" path="res://textures/character-arm.png" id="5_u5sy4"]
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_lbhrr"] [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_lbhrr"]
albedo_color = Color(0.61, 0.28791997, 0.17079999, 1) albedo_color = Color(0.61, 0.28791997, 0.17079999, 1)
@ -88,6 +90,54 @@ tracks/5/keys = {
"update": 0, "update": 0,
"values": [Vector3(0, 0, 0)] "values": [Vector3(0, 0, 0)]
} }
tracks/6/type = "value"
tracks/6/imported = false
tracks/6/enabled = true
tracks/6/path = NodePath("Body/ArmPivot/FrontArm:rotation")
tracks/6/interp = 1
tracks/6/loop_wrap = true
tracks/6/keys = {
"times": PackedFloat32Array(),
"transitions": PackedFloat32Array(),
"update": 0,
"values": []
}
tracks/7/type = "value"
tracks/7/imported = false
tracks/7/enabled = true
tracks/7/path = NodePath("Body/ArmPivot/FrontArm:position")
tracks/7/interp = 1
tracks/7/loop_wrap = true
tracks/7/keys = {
"times": PackedFloat32Array(),
"transitions": PackedFloat32Array(),
"update": 0,
"values": []
}
tracks/8/type = "value"
tracks/8/imported = false
tracks/8/enabled = true
tracks/8/path = NodePath("Body/ArmPivot/BackArm:rotation")
tracks/8/interp = 1
tracks/8/loop_wrap = true
tracks/8/keys = {
"times": PackedFloat32Array(),
"transitions": PackedFloat32Array(),
"update": 0,
"values": []
}
tracks/9/type = "value"
tracks/9/imported = false
tracks/9/enabled = true
tracks/9/path = NodePath("Body/ArmPivot/BackArm:position")
tracks/9/interp = 1
tracks/9/loop_wrap = true
tracks/9/keys = {
"times": PackedFloat32Array(),
"transitions": PackedFloat32Array(),
"update": 0,
"values": []
}
[sub_resource type="Animation" id="Animation_u5sy4"] [sub_resource type="Animation" id="Animation_u5sy4"]
resource_name = "fall" resource_name = "fall"
@ -165,6 +215,30 @@ tracks/5/keys = {
"update": 0, "update": 0,
"values": [Vector3(0, 0, 0)] "values": [Vector3(0, 0, 0)]
} }
tracks/6/type = "value"
tracks/6/imported = false
tracks/6/enabled = true
tracks/6/path = NodePath("Body/ArmPivot/FrontArm:rotation")
tracks/6/interp = 1
tracks/6/loop_wrap = true
tracks/6/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 1.134464)]
}
tracks/7/type = "value"
tracks/7/imported = false
tracks/7/enabled = true
tracks/7/path = NodePath("Body/ArmPivot/BackArm:rotation")
tracks/7/interp = 1
tracks/7/loop_wrap = true
tracks/7/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, -1.134464)]
}
[sub_resource type="Animation" id="Animation_p57ef"] [sub_resource type="Animation" id="Animation_p57ef"]
resource_name = "jump" resource_name = "jump"
@ -241,6 +315,131 @@ tracks/5/keys = {
"update": 0, "update": 0,
"values": [Vector3(0, 0, 0), Vector3(0, 0, 0.06981317), Vector3(0, 0, 0)] "values": [Vector3(0, 0, 0), Vector3(0, 0, 0.06981317), Vector3(0, 0, 0)]
} }
tracks/6/type = "value"
tracks/6/imported = false
tracks/6/enabled = true
tracks/6/path = NodePath("Body/ArmPivot/FrontArm:rotation")
tracks/6/interp = 1
tracks/6/loop_wrap = true
tracks/6/keys = {
"times": PackedFloat32Array(0, 0.06666667, 0.18),
"transitions": PackedFloat32Array(1, 1, 1),
"update": 0,
"values": [Vector3(0, 0, 0.08726646), Vector3(0, 0, 0.61086524), Vector3(0, 0, 0.5235988)]
}
tracks/7/type = "value"
tracks/7/imported = false
tracks/7/enabled = true
tracks/7/path = NodePath("Body/ArmPivot/BackArm:rotation")
tracks/7/interp = 1
tracks/7/loop_wrap = true
tracks/7/keys = {
"times": PackedFloat32Array(0, 0.06666667, 0.18),
"transitions": PackedFloat32Array(1, 1, 1),
"update": 0,
"values": [Vector3(0, 0, -0.08726646), Vector3(0, 0, -0.61086524), Vector3(0, 0, -0.5235988)]
}
[sub_resource type="Animation" id="Animation_vtaks"]
resource_name = "leap"
length = 0.2
loop_mode = 1
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Body/FrontLeg:position")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0.045, -0.09000015, 0)]
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("Body/FrontLeg:rotation")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 0.10471976)]
}
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Body/BackLeg:position")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(-0.044999994, -0.09000015, 0)]
}
tracks/3/type = "value"
tracks/3/imported = false
tracks/3/enabled = true
tracks/3/path = NodePath("Body/BackLeg:rotation")
tracks/3/interp = 1
tracks/3/loop_wrap = true
tracks/3/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 0.10471976)]
}
tracks/4/type = "value"
tracks/4/imported = false
tracks/4/enabled = true
tracks/4/path = NodePath("Body:position")
tracks/4/interp = 1
tracks/4/loop_wrap = true
tracks/4/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 0)]
}
tracks/5/type = "value"
tracks/5/imported = false
tracks/5/enabled = true
tracks/5/path = NodePath("Body:rotation")
tracks/5/interp = 1
tracks/5/loop_wrap = true
tracks/5/keys = {
"times": PackedFloat32Array(0.0033333339),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 0)]
}
tracks/6/type = "value"
tracks/6/imported = false
tracks/6/enabled = true
tracks/6/path = NodePath("Body/ArmPivot/FrontArm:rotation")
tracks/6/interp = 1
tracks/6/loop_wrap = true
tracks/6/keys = {
"times": PackedFloat32Array(0.033333335),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, 0.5235988)]
}
tracks/7/type = "value"
tracks/7/imported = false
tracks/7/enabled = true
tracks/7/path = NodePath("Body/ArmPivot/BackArm:rotation")
tracks/7/interp = 1
tracks/7/loop_wrap = true
tracks/7/keys = {
"times": PackedFloat32Array(0.033333335),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(0, 0, -0.5235988)]
}
[sub_resource type="Animation" id="Animation_0tnpc"] [sub_resource type="Animation" id="Animation_0tnpc"]
resource_name = "move" resource_name = "move"
@ -269,15 +468,55 @@ tracks/1/keys = {
"update": 0, "update": 0,
"values": [Vector3(0, 0, 0.34906584), Vector3(0, 0, -0.34906584), Vector3(0, 0, 0.34906584)] "values": [Vector3(0, 0, 0.34906584), Vector3(0, 0, -0.34906584), Vector3(0, 0, 0.34906584)]
} }
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Body/ArmPivot/FrontArm:rotation")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0, 0.5, 1),
"transitions": PackedFloat32Array(1, 1, 1),
"update": 0,
"values": [Vector3(0, 0, -0.17453292), Vector3(0, 0, 0.17453292), Vector3(0, 0, -0.17453292)]
}
tracks/3/type = "value"
tracks/3/imported = false
tracks/3/enabled = true
tracks/3/path = NodePath("Body/ArmPivot/BackArm:rotation")
tracks/3/interp = 1
tracks/3/loop_wrap = true
tracks/3/keys = {
"times": PackedFloat32Array(0, 0.5, 1),
"transitions": PackedFloat32Array(1, 1, 1),
"update": 0,
"values": [Vector3(0, 0, 0.17453292), Vector3(0, 0, -0.17453292), Vector3(0, 0, 0.17453292)]
}
tracks/4/type = "value"
tracks/4/imported = false
tracks/4/enabled = true
tracks/4/path = NodePath("Body:position")
tracks/4/interp = 1
tracks/4/loop_wrap = true
tracks/4/keys = {
"times": PackedFloat32Array(),
"transitions": PackedFloat32Array(),
"update": 0,
"values": []
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_vtaks"] [sub_resource type="AnimationLibrary" id="AnimationLibrary_vtaks"]
_data = { _data = {
&"RESET": SubResource("Animation_gee14"), &"RESET": SubResource("Animation_gee14"),
&"fall": SubResource("Animation_u5sy4"), &"fall": SubResource("Animation_u5sy4"),
&"jump": SubResource("Animation_p57ef"), &"jump": SubResource("Animation_p57ef"),
&"leap": SubResource("Animation_vtaks"),
&"move": SubResource("Animation_0tnpc") &"move": SubResource("Animation_0tnpc")
} }
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_vtaks"]
animation = &"leap"
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_p57ef"] [sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_p57ef"]
animation = &"jump" animation = &"jump"
@ -288,6 +527,8 @@ animation = &"fall"
[sub_resource type="AnimationNodeOneShot" id="AnimationNodeOneShot_u5sy4"] [sub_resource type="AnimationNodeOneShot" id="AnimationNodeOneShot_u5sy4"]
[sub_resource type="AnimationNodeBlend2" id="AnimationNodeBlend2_kvpfn"]
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_gee14"] [sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_gee14"]
animation = &"move" animation = &"move"
@ -299,10 +540,10 @@ animation = &"RESET"
[sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_p57ef"] [sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_p57ef"]
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_kvpfn"] [sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_kvpfn"]
graph_offset = Vector2(-299.60645, 18.418121) graph_offset = Vector2(-228.28757, 27.085762)
nodes/output/position = Vector2(1020, 160) nodes/output/position = Vector2(1140, 140)
nodes/jump/node = SubResource("AnimationNodeOneShot_u5sy4") nodes/jump/node = SubResource("AnimationNodeOneShot_u5sy4")
nodes/jump/position = Vector2(680, 140) nodes/jump/position = Vector2(860, 140)
nodes/reset/node = SubResource("AnimationNodeAnimation_0tnpc") nodes/reset/node = SubResource("AnimationNodeAnimation_0tnpc")
nodes/reset/position = Vector2(60, 20) nodes/reset/position = Vector2(60, 20)
nodes/move/node = SubResource("AnimationNodeAnimation_gee14") nodes/move/node = SubResource("AnimationNodeAnimation_gee14")
@ -310,20 +551,25 @@ nodes/move/position = Vector2(-80, 220)
nodes/walk/node = SubResource("AnimationNodeBlend2_vtaks") nodes/walk/node = SubResource("AnimationNodeBlend2_vtaks")
nodes/walk/position = Vector2(240, 80) nodes/walk/position = Vector2(240, 80)
nodes/Animation/node = SubResource("AnimationNodeAnimation_p57ef") nodes/Animation/node = SubResource("AnimationNodeAnimation_p57ef")
nodes/Animation/position = Vector2(480, 360) nodes/Animation/position = Vector2(680, 420)
nodes/walk_speed/node = SubResource("AnimationNodeTimeScale_p57ef") nodes/walk_speed/node = SubResource("AnimationNodeTimeScale_p57ef")
nodes/walk_speed/position = Vector2(80, 220) nodes/walk_speed/position = Vector2(80, 220)
nodes/fall/node = SubResource("AnimationNodeBlend2_gee14") nodes/fall/node = SubResource("AnimationNodeBlend2_gee14")
nodes/fall/position = Vector2(480, 100) nodes/fall/position = Vector2(480, 100)
nodes/fall_anim/node = SubResource("AnimationNodeAnimation_u5sy4") nodes/fall_anim/node = SubResource("AnimationNodeAnimation_u5sy4")
nodes/fall_anim/position = Vector2(260, 400) nodes/fall_anim/position = Vector2(260, 400)
node_connections = [&"output", 0, &"jump", &"jump", 0, &"fall", &"jump", 1, &"Animation", &"walk", 0, &"reset", &"walk", 1, &"walk_speed", &"walk_speed", 0, &"move", &"fall", 0, &"walk", &"fall", 1, &"fall_anim"] "nodes/Animation 2/node" = SubResource("AnimationNodeAnimation_vtaks")
"nodes/Animation 2/position" = Vector2(480, 420)
nodes/leap/node = SubResource("AnimationNodeBlend2_kvpfn")
nodes/leap/position = Vector2(670.4032, 137.15503)
node_connections = [&"output", 0, &"jump", &"jump", 0, &"leap", &"jump", 1, &"Animation", &"walk", 0, &"reset", &"walk", 1, &"walk_speed", &"walk_speed", 0, &"move", &"fall", 0, &"walk", &"fall", 1, &"fall_anim", &"leap", 0, &"fall", &"leap", 1, &"Animation 2"]
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_yqjtg"] [sub_resource type="CapsuleShape3D" id="CapsuleShape3D_yqjtg"]
radius = 0.25 radius = 0.25
height = 1.0 height = 1.0
[node name="Game" type="Node3D" unique_id=1358608749] [node name="Game" type="Node3D" unique_id=1358608749]
script = ExtResource("1_gee14")
[node name="CSGBox3D" type="CSGBox3D" parent="." unique_id=1781956012] [node name="CSGBox3D" type="CSGBox3D" parent="." unique_id=1781956012]
use_collision = true use_collision = true
@ -364,6 +610,25 @@ pixel_size = 0.03
texture_filter = 0 texture_filter = 0
texture = ExtResource("4_u5sy4") texture = ExtResource("4_u5sy4")
[node name="ArmPivot" type="Node3D" parent="Player/DreamerBody/Body" unique_id=101320487]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.1500001, 0)
[node name="FrontArm" type="Sprite3D" parent="Player/DreamerBody/Body/ArmPivot" unique_id=1454211664]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.089999996, 0, 0)
offset = Vector2(0, -6)
pixel_size = 0.03
texture_filter = 0
render_priority = 6
texture = ExtResource("5_u5sy4")
[node name="BackArm" type="Sprite3D" parent="Player/DreamerBody/Body/ArmPivot" unique_id=1463191879]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.089999996, 0, 0)
offset = Vector2(0, -6)
pixel_size = 0.03
texture_filter = 0
render_priority = -1
texture = ExtResource("5_u5sy4")
[node name="Animations" type="AnimationPlayer" parent="Player/DreamerBody" unique_id=708762765] [node name="Animations" type="AnimationPlayer" parent="Player/DreamerBody" unique_id=708762765]
libraries/ = SubResource("AnimationLibrary_vtaks") libraries/ = SubResource("AnimationLibrary_vtaks")
@ -376,6 +641,7 @@ parameters/jump/request = 0
parameters/walk/blend_amount = 0.0 parameters/walk/blend_amount = 0.0
parameters/walk_speed/scale = 3.1400000000000006 parameters/walk_speed/scale = 3.1400000000000006
parameters/fall/blend_amount = 0.0 parameters/fall/blend_amount = 0.0
parameters/leap/blend_amount = 0.0
[node name="Shadow" type="Sprite3D" parent="Player" unique_id=495232250] [node name="Shadow" type="Sprite3D" parent="Player" unique_id=495232250]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -2, 0) transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -2, 0)

11
scripts/game.gd Normal file
View file

@ -0,0 +1,11 @@
extends Node3D
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
pass

1
scripts/game.gd.uid Normal file
View file

@ -0,0 +1 @@
uid://dhfun46prq3uk

5
scripts/global.gd Normal file
View file

@ -0,0 +1,5 @@
extends Node
const weapons = {
}

1
scripts/global.gd.uid Normal file
View file

@ -0,0 +1 @@
uid://4hvgybxt05qj

View file

@ -4,23 +4,41 @@ const SPEED = 2.5
const JUMP_VELOCITY = 4.5 const JUMP_VELOCITY = 4.5
var walk_animation_time = 0 var walk_animation_time = 0
var face_rotation = null
var face_left = false
@onready var game = get_parent() @onready var game = get_parent()
@onready var camera = game.get_node("PlayerCamera")
func _ready() -> void: func _ready() -> void:
$DreamerBody.look_at(game.get_node("PlayerCamera").global_position) $DreamerBody.look_at(game.get_node("PlayerCamera").global_position)
$DreamerBody.rotation.x = 0 $DreamerBody.rotation.x = 0
face_rotation = $DreamerBody.rotation.y
func _physics_process(delta: float) -> void: func _physics_process(delta: float) -> void:
if not is_on_floor(): if not is_on_floor():
velocity += get_gravity() * delta velocity += get_gravity() * delta
var viewport_size = (get_viewport().get_visible_rect().size / 2.0)
if face_left:
$DreamerBody.rotation.y = face_rotation + deg_to_rad(180)
else:
$DreamerBody.rotation.y = face_rotation
#$DreamerBody/Body/ArmPivot.rotation.z = viewport_size.angle_to_point(get_viewport().get_mouse_position())
if Input.is_action_pressed("jump") and is_on_floor(): if Input.is_action_pressed("jump") and is_on_floor():
velocity.y = JUMP_VELOCITY velocity.y = JUMP_VELOCITY
$DreamerBody/Animator.set("parameters/jump/request", AnimationNodeOneShot.ONE_SHOT_REQUEST_FIRE) $DreamerBody/Animator.set("parameters/jump/request", AnimationNodeOneShot.ONE_SHOT_REQUEST_FIRE)
var input_dir := Input.get_vector("move_left", "move_right", "move_up", "move_down") var input_dir := Input.get_vector("move_left", "move_right", "move_up", "move_down")
var direction := (transform.basis * Vector3(input_dir.y + input_dir.x, 0, input_dir.y - input_dir.x)).normalized() if input_dir.x > 0:
face_left = false
if input_dir.x < 0:
face_left = true
var direction = (camera.transform.basis * Vector3(input_dir.x, 0, input_dir.y)).normalized()
if direction: if direction:
velocity.x = direction.x * SPEED velocity.x = direction.x * SPEED
velocity.z = direction.z * SPEED velocity.z = direction.z * SPEED
@ -36,7 +54,7 @@ func _physics_process(delta: float) -> void:
if direction and is_on_floor(): if direction and is_on_floor():
walk_animation_time += delta * 25 walk_animation_time += delta * 25
$DreamerBody.position.y = sin(walk_animation_time + 1) / 8 $DreamerBody.position.y = sin(walk_animation_time + 1) / 16
$DreamerBody.rotation.z = sin(walk_animation_time / 2) / 16 $DreamerBody.rotation.z = sin(walk_animation_time / 2) / 16
else: else:
walk_animation_time = 0 walk_animation_time = 0
@ -47,8 +65,14 @@ func _physics_process(delta: float) -> void:
if is_on_floor(): if is_on_floor():
$DreamerBody/Animator.set("parameters/fall/blend_amount", 0) $DreamerBody/Animator.set("parameters/fall/blend_amount", 0)
$DreamerBody/Animator.set("parameters/leap/blend_amount", 0)
else: else:
$DreamerBody/Animator.set("parameters/fall/blend_amount", 1) if velocity.y < 0:
$DreamerBody/Animator.set("parameters/fall/blend_amount", 1)
$DreamerBody/Animator.set("parameters/leap/blend_amount", 0)
else:
$DreamerBody/Animator.set("parameters/fall/blend_amount", 0)
$DreamerBody/Animator.set("parameters/leap/blend_amount", 1)
move_and_slide() move_and_slide()

BIN
textures/character-arm.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 108 B

View file

@ -0,0 +1,41 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://rgxhw23471ut"
path.s3tc="res://.godot/imported/character-arm.png-887bc51ad4f0b012b30145a175363600.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
[deps]
source_file="res://textures/character-arm.png"
dest_files=["res://.godot/imported/character-arm.png-887bc51ad4f0b012b30145a175363600.s3tc.ctex"]
[params]
compress/mode=2
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=true
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
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=0

Binary file not shown.

Before

Width:  |  Height:  |  Size: 103 B

After

Width:  |  Height:  |  Size: 100 B

View file

@ -3,19 +3,20 @@
importer="texture" importer="texture"
type="CompressedTexture2D" type="CompressedTexture2D"
uid="uid://btqaj6yslgvax" uid="uid://btqaj6yslgvax"
path="res://.godot/imported/example-character-hand.png-363b3285c631aacb16602f2b09024d62.ctex" path.s3tc="res://.godot/imported/example-character-hand.png-363b3285c631aacb16602f2b09024d62.s3tc.ctex"
metadata={ metadata={
"vram_texture": false "imported_formats": ["s3tc_bptc"],
"vram_texture": true
} }
[deps] [deps]
source_file="res://textures/example-character-hand.png" source_file="res://textures/example-character-hand.png"
dest_files=["res://.godot/imported/example-character-hand.png-363b3285c631aacb16602f2b09024d62.ctex"] dest_files=["res://.godot/imported/example-character-hand.png-363b3285c631aacb16602f2b09024d62.s3tc.ctex"]
[params] [params]
compress/mode=0 compress/mode=2
compress/high_quality=false compress/high_quality=false
compress/lossy_quality=0.7 compress/lossy_quality=0.7
compress/uastc_level=0 compress/uastc_level=0
@ -23,7 +24,7 @@ compress/rdo_quality_loss=0.0
compress/hdr_compression=1 compress/hdr_compression=1
compress/normal_map=0 compress/normal_map=0
compress/channel_pack=0 compress/channel_pack=0
mipmaps/generate=false mipmaps/generate=true
mipmaps/limit=-1 mipmaps/limit=-1
roughness/mode=0 roughness/mode=0
roughness/src_normal="" roughness/src_normal=""
@ -37,4 +38,4 @@ process/normal_map_invert_y=false
process/hdr_as_srgb=false 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=0