Skip to content

Commit

Permalink
Bugfixes
Browse files Browse the repository at this point in the history
Flashlight:
- Fixed animation that was somehow overwritten by the wieldable health extension potion.

Wieldabele Consumable:
- Saved out animation of the health extension potion.
- Some minor code cleanup.

Dynamic Input Icon:
- changed updating icon call to be deferred to avoid issues for input icons that exist before the options cfg gets loaded in the tree.
  • Loading branch information
Phazorknight committed Nov 12, 2024
1 parent 1f960d7 commit ff75ff0
Show file tree
Hide file tree
Showing 10 changed files with 97 additions and 320 deletions.
10 changes: 4 additions & 6 deletions addons/cogito/Components/DynamicInputIcon.gd
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ func update_device(_device, _device_index):
if _is_steam_deck():
device = "steam_deck"

update_input_icon()
update_input_icon.call_deferred() #Calling this deferred as there's been Input Icons that exist before the cfg is loaded.


func update_input_icon():
Expand Down Expand Up @@ -99,16 +99,14 @@ func update_icon_kbm(): # Sets the bound action to keyboard and mouse icon
set_texture(keyboard_icons)

var keyboard_input = InputHelper.get_keyboard_input_for_action(action_name)
print("Dynamic Input Icon: update_icon_kbm: keyboard_input for action ", action_name, " = ", keyboard_input)
if keyboard_input is InputEventKey:
print("Dynamic Input Icon: update_icon_kbm: Keycode string for action ", action_name, " is ", OS.get_keycode_string(keyboard_input.keycode) )
frame = keycode_to_frame_index(OS.get_keycode_string(keyboard_input.keycode))
elif keyboard_input is InputEventMouseButton:
if keyboard_input.get_button_index() == 2:
if keyboard_input.get_button_index() == MOUSE_BUTTON_RIGHT:
frame = keycode_to_frame_index("Mouse Right")
if keyboard_input.get_button_index() == 1:
if keyboard_input.get_button_index() == MOUSE_BUTTON_LEFT:
frame = keycode_to_frame_index("Mouse Left")
if keyboard_input.get_button_index() == 3:
if keyboard_input.get_button_index() == MOUSE_BUTTON_MIDDLE:
frame = keycode_to_frame_index("Mouse Middle")

else:
Expand Down
8 changes: 4 additions & 4 deletions addons/cogito/DemoScenes/COGITO_3_Lobby.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ volumetric_fog_temporal_reprojection_amount = 0.85
density = 0.04
albedo = Color(0.694118, 0.694118, 0.694118, 1)

[sub_resource type="Resource" id="Resource_rrue1"]
[sub_resource type="Resource" id="Resource_kkhbp"]
resource_local_to_scene = true
script = ExtResource("4_0kggm")
grid = true
Expand Down Expand Up @@ -2425,7 +2425,7 @@ shadow_mesh = SubResource("ArrayMesh_3ecdw")
[sub_resource type="ConcavePolygonShape3D" id="ConcavePolygonShape3D_upcaa"]
data = PackedVector3Array(0.6928, 0.0903, -1.6, 0, 0.0903, -1.2, 0.6128, 0.0903, -0.88, 0.6128, 0.0903, -0.88, 0.7728, 0.0903, -0.88, 0.6928, 0.0903, -1.6, 0.7728, 0.0903, -0.88, 1.3856, 0.0903, -1.2, 0.6928, 0.0903, -1.6, 0.7728, 0.0903, -0.88, 0.7728, 0.0903, -0.72, 1.3856, 0.0903, -1.2, 0.6128, 0.0903, -0.72, 0.6128, 0.0903, -0.88, 0, 0.0903, -1.2, 0.6928, 0.0903, 0, 0.6128, 0.0903, -0.72, 0, 0.0903, -1.2, 0.6928, 0.0903, 0, 0.7728, 0.0903, -0.72, 0.6128, 0.0903, -0.72, 0, 0.0903, -0.4, 0.6928, 0.0903, 0, 0, 0.0903, -1.2, 0, 0.0903, -1.2, 0, 0.0903, -0.8, 0, 0.0903, -0.4, 0.6928, 0.0903, 0, 1.3856, 0.0903, -0.4, 0.7728, 0.0903, -0.72, 1.3856, 0.0903, -0.4, 1.3856, 0.0903, -1.2, 0.7728, 0.0903, -0.72, 1.3856, 0.0903, -0.4, 1.3856, 0.0903, -0.8, 1.3856, 0.0903, -1.2, 0.6928, 0.1935, 0, 0, 0.1935, -0.4, 0, 0.1935, -1.2, 0, 0.1935, -1.2, 0.6928, 0.1935, -1.6, 0.6928, 0.1935, 0, 0.6928, 0.1935, -1.6, 1.3856, 0.1935, -0.4, 0.6928, 0.1935, 0, 0.6928, 0.1935, -1.6, 1.3856, 0.1935, -1.2, 1.3856, 0.1935, -0.4, 0.6928, 0.1935, -1.6, 0.6928, 0.0903, -1.6, 1.3856, 0.0903, -1.2, 1.3856, 0.0903, -1.2, 1.3856, 0.1935, -1.2, 0.6928, 0.1935, -1.6, 1.3856, 0.0903, -0.8, 1.3856, 0.0903, -0.4, 1.3856, 0.1935, -0.4, 1.3856, 0.1935, -0.4, 1.3856, 0.1935, -1.2, 1.3856, 0.0903, -0.8, 1.3856, 0.1935, -1.2, 1.3856, 0.0903, -1.2, 1.3856, 0.0903, -0.8, 1.3856, 0.1935, -0.4, 1.3856, 0.0903, -0.4, 0.6928, 0.0903, 0, 0.6928, 0.0903, 0, 0.6928, 0.1935, 0, 1.3856, 0.1935, -0.4, 0.6928, 0.1935, 0, 0.6928, 0.0903, 0, 0, 0.0903, -0.4, 0, 0.0903, -0.4, 0, 0.1935, -0.4, 0.6928, 0.1935, 0, 0, 0.1935, -1.2, 0, 0.1935, -0.4, 0, 0.0903, -0.4, 0, 0.0903, -0.4, 0, 0.0903, -0.8, 0, 0.1935, -1.2, 0, 0.0903, -0.8, 0, 0.0903, -1.2, 0, 0.1935, -1.2, 0, 0.1935, -1.2, 0, 0.0903, -1.2, 0.6928, 0.0903, -1.6, 0.6928, 0.0903, -1.6, 0.6928, 0.1935, -1.6, 0, 0.1935, -1.2, 0.7728, 0.0903, -0.72, 0.7728, -0.4, -0.72, 0.6128, -0.4, -0.72, 0.6128, -0.4, -0.72, 0.6128, 0.0903, -0.72, 0.7728, 0.0903, -0.72, 0.6128, 0.0903, -0.88, 0.6128, 0.0903, -0.72, 0.6128, -0.4, -0.72, 0.6128, -0.4, -0.72, 0.6128, -0.4, -0.88, 0.6128, 0.0903, -0.88, 0.6128, 0.0903, -0.88, 0.6128, -0.4, -0.88, 0.7728, -0.4, -0.88, 0.7728, -0.4, -0.88, 0.7728, 0.0903, -0.88, 0.6128, 0.0903, -0.88, 0.7728, -0.4, -0.88, 0.7728, -0.4, -0.72, 0.7728, 0.0903, -0.72, 0.7728, 0.0903, -0.72, 0.7728, 0.0903, -0.88, 0.7728, -0.4, -0.88, 0.8128, -0.4, -0.68, 0.8128, -0.44, -0.68, 0.5728, -0.44, -0.68, 0.5728, -0.44, -0.68, 0.5728, -0.4, -0.68, 0.8128, -0.4, -0.68, 0.5728, -0.4, -0.92, 0.5728, -0.4, -0.68, 0.5728, -0.44, -0.68, 0.5728, -0.44, -0.68, 0.5728, -0.44, -0.92, 0.5728, -0.4, -0.92, 0.8128, -0.44, -0.92, 0.8128, -0.44, -0.68, 0.8128, -0.4, -0.68, 0.8128, -0.4, -0.68, 0.8128, -0.4, -0.92, 0.8128, -0.44, -0.92, 0.5728, -0.4, -0.68, 0.5728, -0.4, -0.92, 0.6128, -0.4, -0.72, 0.6128, -0.4, -0.72, 0.8128, -0.4, -0.68, 0.5728, -0.4, -0.68, 0.6128, -0.4, -0.72, 0.7728, -0.4, -0.72, 0.8128, -0.4, -0.68, 0.7728, -0.4, -0.72, 0.7728, -0.4, -0.88, 0.8128, -0.4, -0.68, 0.6128, -0.4, -0.88, 0.6128, -0.4, -0.72, 0.5728, -0.4, -0.92, 0.5728, -0.4, -0.92, 0.8128, -0.4, -0.92, 0.6128, -0.4, -0.88, 0.8128, -0.4, -0.92, 0.7728, -0.4, -0.88, 0.6128, -0.4, -0.88, 0.8128, -0.4, -0.92, 0.8128, -0.4, -0.68, 0.7728, -0.4, -0.88, 0.4928, -0.44, -1, 0.4928, -0.44, -0.6, 0.4928, -0.5, -0.6, 0.4928, -0.5, -0.6, 0.4928, -0.5, -1, 0.4928, -0.44, -1, 0.4928, -0.44, -1, 0.4928, -0.5, -1, 0.8928, -0.5, -1, 0.8928, -0.5, -1, 0.8928, -0.44, -1, 0.4928, -0.44, -1, 0.8928, -0.44, -0.6, 0.8928, -0.5, -0.6, 0.4928, -0.5, -0.6, 0.4928, -0.5, -0.6, 0.4928, -0.44, -0.6, 0.8928, -0.44, -0.6, 0.8928, -0.5, -1, 0.8928, -0.5, -0.6, 0.8928, -0.44, -0.6, 0.8928, -0.44, -0.6, 0.8928, -0.44, -1, 0.8928, -0.5, -1, 0.4928, -0.44, -0.6, 0.4928, -0.44, -1, 0.5728, -0.44, -0.68, 0.5728, -0.44, -0.68, 0.8928, -0.44, -0.6, 0.4928, -0.44, -0.6, 0.5728, -0.44, -0.68, 0.8128, -0.44, -0.68, 0.8928, -0.44, -0.6, 0.8128, -0.44, -0.68, 0.8128, -0.44, -0.92, 0.8928, -0.44, -0.6, 0.5728, -0.44, -0.92, 0.5728, -0.44, -0.68, 0.4928, -0.44, -1, 0.4928, -0.44, -1, 0.8928, -0.44, -1, 0.5728, -0.44, -0.92, 0.8928, -0.44, -1, 0.8128, -0.44, -0.92, 0.5728, -0.44, -0.92, 0.8928, -0.44, -1, 0.8928, -0.44, -0.6, 0.8128, -0.44, -0.92, 0.9128, -0.54, -1.02, 0.4728, -0.54, -1.02, 0.4728, -0.54, -0.58, 0.4728, -0.54, -0.58, 0.9128, -0.54, -0.58, 0.9128, -0.54, -1.02, 0.4928, -0.5, -1, 0.4728, -0.54, -1.02, 0.9128, -0.54, -1.02, 0.9128, -0.54, -1.02, 0.8928, -0.5, -1, 0.4928, -0.5, -1, 0.9128, -0.54, -1.02, 0.9128, -0.54, -0.58, 0.8928, -0.5, -0.6, 0.8928, -0.5, -0.6, 0.8928, -0.5, -1, 0.9128, -0.54, -1.02, 0.8928, -0.5, -0.6, 0.9128, -0.54, -0.58, 0.4728, -0.54, -0.58, 0.4728, -0.54, -0.58, 0.4928, -0.5, -0.6, 0.8928, -0.5, -0.6, 0.4928, -0.5, -0.6, 0.4728, -0.54, -0.58, 0.4728, -0.54, -1.02, 0.4728, -0.54, -1.02, 0.4928, -0.5, -1, 0.4928, -0.5, -0.6, 0.5728, -0.4, -0.92, 0.5728, -0.44, -0.92, 0.8128, -0.44, -0.92, 0.8128, -0.44, -0.92, 0.8128, -0.4, -0.92, 0.5728, -0.4, -0.92)

[sub_resource type="Resource" id="Resource_wc1fr"]
[sub_resource type="Resource" id="Resource_wlk4n"]
resource_local_to_scene = true
script = ExtResource("4_0kggm")
grid = true
Expand Down Expand Up @@ -3167,7 +3167,7 @@ material = SubResource("FogMaterial_4avjx")

[node name="Player" parent="." instance=ExtResource("3_mgle8")]
transform = Transform3D(-1, 0, 7.45058e-07, 0, 1, 0, -7.45058e-07, 0, -1, 3.03073, 0.905039, -17.9321)
inventory_data = SubResource("Resource_rrue1")
inventory_data = SubResource("Resource_kkhbp")
step_height_camera_lerp = 1.5

[node name="QUESTS" type="Node3D" parent="."]
Expand Down Expand Up @@ -6991,7 +6991,7 @@ shape = SubResource("ConcavePolygonShape3D_upcaa")

[node name="kitchenFridgeContainer2" parent="BREAK_ROOM" instance=ExtResource("57_fdyfl")]
transform = Transform3D(-1, 0, -1.50996e-07, 0, 1, 0, 1.50996e-07, 0, -1, 3.65301, -4.84288e-08, 6.17191)
inventory_data = SubResource("Resource_wc1fr")
inventory_data = SubResource("Resource_wlk4n")

[node name="kitchenMicrowave" parent="BREAK_ROOM" instance=ExtResource("43_rl17a")]
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 1.98491, 0.84, 6.39503)
Expand Down
4 changes: 2 additions & 2 deletions addons/cogito/DemoScenes/COGITO_4_Laboratory.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ volumetric_fog_ambient_inject = 0.1
volumetric_fog_sky_affect = 0.1
volumetric_fog_temporal_reprojection_amount = 0.85

[sub_resource type="Resource" id="Resource_gtshc"]
[sub_resource type="Resource" id="Resource_3rqrv"]
resource_local_to_scene = true
script = ExtResource("4_hlewe")
grid = true
Expand Down Expand Up @@ -899,7 +899,7 @@ environment = SubResource("Environment_obnk3")
[node name="Player" parent="." instance=ExtResource("2_7qwrr")]
transform = Transform3D(-4.37114e-08, 0, 1, 0, 1, 0, -1, 0, -4.37114e-08, 5.13854, 0.8, -5.43073)
inventory_data = SubResource("Resource_gtshc")
inventory_data = SubResource("Resource_3rqrv")
[node name="CONNECTOR_TO_LOBBY" type="Node3D" parent="."]
Expand Down
2 changes: 0 additions & 2 deletions addons/cogito/EasyMenus/Scripts/pause_menu_controller.gd
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,6 @@ func open_pause_menu():
#Stops game and shows pause menu
get_tree().paused = true
label_active_slot.text = "Current Slot: " + CogitoSceneManager._active_slot
#save_button.text = "Save Slot " + CogitoSceneManager._active_slot
#load_button.text = "Load Slot " + CogitoSceneManager._active_slot
temp_screenshot = grab_temp_screenshot()
show()
game_menu.show()
Expand Down
Loading

0 comments on commit ff75ff0

Please sign in to comment.