diff --git a/Assets/Materials/GoldGlow.tres b/Assets/Materials/GoldGlow.tres new file mode 100644 index 0000000..482eb03 --- /dev/null +++ b/Assets/Materials/GoldGlow.tres @@ -0,0 +1,9 @@ +[gd_resource type="StandardMaterial3D" format=3 uid="uid://c1evlkhnj37ky"] + +[resource] +transparency = 1 +blend_mode = 1 +albedo_color = Color(0.586682, 0.458813, 0.00383217, 1) +emission_enabled = true +emission = Color(0.774314, 0.602011, 0.0986466, 1) +emission_energy_multiplier = 5.0 diff --git a/Assets/Models/BowCursor.blend b/Assets/Models/BowCursor.blend new file mode 100644 index 0000000..8befc2e Binary files /dev/null and b/Assets/Models/BowCursor.blend differ diff --git a/Assets/Models/BowCursor.blend.import b/Assets/Models/BowCursor.blend.import new file mode 100644 index 0000000..f55be2d --- /dev/null +++ b/Assets/Models/BowCursor.blend.import @@ -0,0 +1,53 @@ +[remap] + +importer="scene" +importer_version=1 +type="PackedScene" +uid="uid://cbvijkdp1lqqw" +path="res://.godot/imported/BowCursor.blend-a70c23414219af23efa6df09ac2509cc.scn" + +[deps] + +source_file="res://Assets/Models/BowCursor.blend" +dest_files=["res://.godot/imported/BowCursor.blend-a70c23414219af23efa6df09ac2509cc.scn"] + +[params] + +nodes/root_type="" +nodes/root_name="" +nodes/apply_root_scale=true +nodes/root_scale=1.0 +nodes/import_as_skeleton_bones=false +nodes/use_node_type_suffixes=true +meshes/ensure_tangents=true +meshes/generate_lods=true +meshes/create_shadow_meshes=true +meshes/light_baking=1 +meshes/lightmap_texel_size=0.2 +meshes/force_disable_compression=false +skins/use_named_skins=true +animation/import=true +animation/fps=30 +animation/trimming=false +animation/remove_immutable_tracks=true +animation/import_rest_as_RESET=false +import_script/path="" +_subresources={} +blender/nodes/visible=0 +blender/nodes/active_collection_only=false +blender/nodes/punctual_lights=true +blender/nodes/cameras=true +blender/nodes/custom_properties=true +blender/nodes/modifiers=1 +blender/meshes/colors=false +blender/meshes/uvs=true +blender/meshes/normals=true +blender/meshes/export_geometry_nodes_instances=false +blender/meshes/tangents=true +blender/meshes/skins=2 +blender/meshes/export_bones_deforming_mesh_only=false +blender/materials/unpack_enabled=true +blender/materials/export_materials=1 +blender/animation/limit_playback=true +blender/animation/always_sample=true +blender/animation/group_tracks=true diff --git a/Assets/Models/BowCursor.blend1 b/Assets/Models/BowCursor.blend1 new file mode 100644 index 0000000..b36c3e0 Binary files /dev/null and b/Assets/Models/BowCursor.blend1 differ diff --git a/Assets/Models/SwordCursor.blend b/Assets/Models/SwordCursor.blend new file mode 100644 index 0000000..acbdf19 Binary files /dev/null and b/Assets/Models/SwordCursor.blend differ diff --git a/Assets/Models/SwordCursor.blend.import b/Assets/Models/SwordCursor.blend.import new file mode 100644 index 0000000..6d4062d --- /dev/null +++ b/Assets/Models/SwordCursor.blend.import @@ -0,0 +1,60 @@ +[remap] + +importer="scene" +importer_version=1 +type="PackedScene" +uid="uid://b4c4cu400yrgt" +path="res://.godot/imported/SwordCursor.blend-f9c7473568c1bc60c7978b764065f405.scn" + +[deps] + +source_file="res://Assets/Models/SwordCursor.blend" +dest_files=["res://.godot/imported/SwordCursor.blend-f9c7473568c1bc60c7978b764065f405.scn"] + +[params] + +nodes/root_type="" +nodes/root_name="" +nodes/apply_root_scale=true +nodes/root_scale=1.0 +nodes/import_as_skeleton_bones=false +nodes/use_node_type_suffixes=true +meshes/ensure_tangents=true +meshes/generate_lods=true +meshes/create_shadow_meshes=true +meshes/light_baking=1 +meshes/lightmap_texel_size=0.2 +meshes/force_disable_compression=false +skins/use_named_skins=true +animation/import=true +animation/fps=30 +animation/trimming=false +animation/remove_immutable_tracks=true +animation/import_rest_as_RESET=false +import_script/path="" +_subresources={ +"materials": { +"Sword": { +"use_external/enabled": true, +"use_external/path": "uid://c1evlkhnj37ky" +} +} +} +blender/nodes/visible=0 +blender/nodes/active_collection_only=false +blender/nodes/punctual_lights=true +blender/nodes/cameras=true +blender/nodes/custom_properties=true +blender/nodes/modifiers=1 +blender/meshes/colors=false +blender/meshes/uvs=true +blender/meshes/normals=true +blender/meshes/export_geometry_nodes_instances=false +blender/meshes/tangents=true +blender/meshes/skins=2 +blender/meshes/export_bones_deforming_mesh_only=false +blender/materials/unpack_enabled=true +blender/materials/export_materials=1 +blender/animation/limit_playback=true +blender/animation/always_sample=true +blender/animation/group_tracks=true diff --git a/Assets/Models/SwordCursor.blend1 b/Assets/Models/SwordCursor.blend1 new file mode 100644 index 0000000..66be922 Binary files /dev/null and b/Assets/Models/SwordCursor.blend1 differ diff --git a/Prefabs/PlayerCamera.tscn b/Prefabs/PlayerCamera.tscn index 6472698..58e9317 100644 --- a/Prefabs/PlayerCamera.tscn +++ b/Prefabs/PlayerCamera.tscn @@ -18,7 +18,7 @@ bg_color = Color(0.458824, 0, 0.145098, 1) bg_color = Color(0.457868, 0.677542, 0.145981, 1) [sub_resource type="BoxShape3D" id="BoxShape3D_8uhk6"] -size = Vector3(30, 1, 30) +size = Vector3(60, 1, 60) [node name="CameraFollow" type="Node3D"] script = ExtResource("1_ocbkm") diff --git a/Prefabs/goldcoin.tscn b/Prefabs/goldcoin.tscn index d116bff..ff67723 100644 --- a/Prefabs/goldcoin.tscn +++ b/Prefabs/goldcoin.tscn @@ -51,8 +51,8 @@ margin = 0.0 radius = 0.0860376 [node name="GOLDCOIN" type="RigidBody3D"] -collision_layer = 32 -collision_mask = 33 +collision_layer = 16 +collision_mask = 17 mass = 0.1 continuous_cd = true contact_monitor = true diff --git a/Prefabs/player.tscn b/Prefabs/player.tscn index 9b458aa..d12d1fa 100644 --- a/Prefabs/player.tscn +++ b/Prefabs/player.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=15 format=3 uid="uid://bacgd5lmvaxea"] +[gd_scene load_steps=17 format=3 uid="uid://bacgd5lmvaxea"] [ext_resource type="Script" uid="uid://bcgt64gerg8pv" path="res://Scripts/player.gd" id="1_5wxv7"] [ext_resource type="Material" uid="uid://b4rpp31c0dx2m" path="res://Assets/Materials/BasicMat.tres" id="1_y6xdh"] @@ -7,10 +7,15 @@ [ext_resource type="Script" uid="uid://wnisqyoyai2h" path="res://Scripts/player_on_floor.gd" id="4_hck1p"] [ext_resource type="Script" uid="uid://dhnl0penaqfkx" path="res://Scripts/player_dodge_roll.gd" id="5_hck1p"] [ext_resource type="PackedScene" uid="uid://b12w4ut17srje" path="res://Assets/Models/Character1.blend" id="7_juxdh"] +[ext_resource type="PackedScene" uid="uid://b4c4cu400yrgt" path="res://Assets/Models/SwordCursor.blend" id="8_4qbli"] [sub_resource type="BoxMesh" id="BoxMesh_5wxv7"] size = Vector3(0.945, 0.13, 0.135) +[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_08u7w"] +transparency = 1 +albedo_color = Color(1, 1, 1, 0) + [sub_resource type="CapsuleShape3D" id="CapsuleShape3D_y5hcb"] radius = 0.362 @@ -119,6 +124,10 @@ transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, -0. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.652269, 0.475497, -0.696594) mesh = SubResource("BoxMesh_5wxv7") skeleton = NodePath("../..") +surface_material_override/0 = SubResource("StandardMaterial3D_08u7w") + +[node name="SwordCursor" parent="Body/ShittySword" instance=ExtResource("8_4qbli")] +transform = Transform3D(0.644047, 0.760603, 0.0817732, -3.35396e-06, -0.106892, 0.994271, 0.764986, -0.640357, -0.068841, -0.0904393, 4.17233e-07, 0.438631) [node name="CollisionShape3D" type="CollisionShape3D" parent="."] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0) @@ -130,8 +139,8 @@ libraries = { } [node name="Area3D" type="Area3D" parent="."] -collision_layer = 32 -collision_mask = 32 +collision_layer = 16 +collision_mask = 16 [node name="CollisionShape3D" type="CollisionShape3D" parent="Area3D"] shape = SubResource("SphereShape3D_juxdh") diff --git a/Scenes/TestScene1.tscn b/Scenes/TestScene1.tscn index e3fa784..e7f58df 100644 --- a/Scenes/TestScene1.tscn +++ b/Scenes/TestScene1.tscn @@ -167,5 +167,6 @@ transform = Transform3D(0.0790682, 0, 0.996869, 0, 1, 0, -0.996869, 0, 0.0790682 [node name="CoinSpawner" parent="." instance=ExtResource("9_46b76")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 1.81324, 3.94453, 0.757049) -[node name="MOUSEDEBUG" parent="." instance=ExtResource("10_tadml")] +[node name="MOUSEDEBUG" parent="." node_paths=PackedStringArray("player") instance=ExtResource("10_tadml")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 2.21551, 0.500001, -0.339623) +player = NodePath("../Player") diff --git a/Scripts/mouseDebug.gd b/Scripts/mouseDebug.gd index f20edd3..f24612b 100644 --- a/Scripts/mouseDebug.gd +++ b/Scripts/mouseDebug.gd @@ -1,6 +1,9 @@ extends Node3D +@export var player : Player + func _process(delta: float) -> void: var mouse_pos = MousePos.get_mouse_world_position(00001000) if mouse_pos != null: - global_position = mouse_pos + global_position = Vector3(mouse_pos.x,.1,mouse_pos.z) + look_at(player.global_position, Vector3.UP) diff --git a/Scripts/player.gd b/Scripts/player.gd index fafbeec..c83754c 100644 --- a/Scripts/player.gd +++ b/Scripts/player.gd @@ -20,6 +20,9 @@ const STAMINA_REGEN_RATE = 10.0 const DODGE_STAMINA_COST = 30.0 const ATTACK_STAMINA_COST = 10.0 +func _ready() -> void: + Input.set_mouse_mode(Input.MOUSE_MODE_HIDDEN) + func _physics_process(delta: float) -> void: stamina_regen(delta) move_and_slide() diff --git a/mousedebug.tscn b/mousedebug.tscn index 1b73467..df0d01f 100644 --- a/mousedebug.tscn +++ b/mousedebug.tscn @@ -1,11 +1,10 @@ [gd_scene load_steps=3 format=3 uid="uid://jkl8odkxg2s2"] [ext_resource type="Script" uid="uid://cne68wmdyr4ld" path="res://Scripts/mouseDebug.gd" id="1_ehadm"] +[ext_resource type="PackedScene" uid="uid://b4c4cu400yrgt" path="res://Assets/Models/SwordCursor.blend" id="2_1bvqy"] -[sub_resource type="SphereMesh" id="SphereMesh_ehadm"] - -[node name="MOUSEDEBUG" type="Node3D"] +[node name="MouseCursor" type="Node3D"] script = ExtResource("1_ehadm") -[node name="MeshInstance3D" type="MeshInstance3D" parent="."] -mesh = SubResource("SphereMesh_ehadm") +[node name="SwordCursor" parent="." instance=ExtResource("2_1bvqy")] +transform = Transform3D(1, 0, 0, 0, -4.37114e-08, -1, 0, 1, -4.37114e-08, 0, 0, 0) diff --git a/project.godot b/project.godot index 5932085..c87e263 100644 --- a/project.godot +++ b/project.godot @@ -73,7 +73,8 @@ attack={ [layer_names] -3d_physics/layer_6="Objects" +3d_physics/layer_5="Objects" +3d_physics/layer_6="conflicts with MouseTable for some reason, leaving open for now" 3d_physics/layer_8="MouseTable" [rendering]