diff --git a/README.md b/README.md index 2943547..88f159e 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ - [x] shift click items to move to other inventory? - [x] automatically fill recipie book - [x] block taking from recipe book item slots -- [ ] trash slot +- [x] trash slot - [ ] endings - [ ] 0 power mrowww - [ ] 1-19 mew @@ -20,26 +20,29 @@ - [ ] 40-59 winning more - [ ] 60+ winning most - [ ] soundtrack - kane working on something -- [ ] credit/replace images - square images that fit in the item slot box -- [ ] Disk drives scavenge to disks of varying rarity worth $$$ +- [x] credit/replace images - square images that fit in the item slot box +- [x] Disk drives scavenge to disks of varying rarity worth $$$ + - [x] scavenge rolls can produce nothing? Submission day: Jan 19th 8AM ## Bugs / Fixes - [x] Add Sarantis to playtesters list -- [ ] Volume slider for music +- [x] Volume slider for music - [x] Change GPU rarity border to epic -- [ ] Refresh sell (and botnet) button when changes to next day -- [ ] Improve tooltips - sell value, botnet value, scavengable?, flavour text +- [x] Refresh sell (and botnet) button when changes to next day +- [x] Improve tooltips - sell value, botnet value, scavengable?, flavour text - [x] Make location buttons static / icons - 3 buttons - [-] Leaving ewaste prevent item loss - "are you sure?" -- [ ] Improve visibility of book tabs -- [ ] Prominent shift+click -- [ ] make all images square to fix hitbox +- [x] Improve visibility of book tabs +- [x] Prominent shift+click +- [x] make all images square to fix hitbox - [x] block buying if inventory full - [x] reduce days by 1 - [x] better border between recipes - [x] disable loot button if no time +- [x] show percentage chances for scavenging +- [x] trash slto # Maintain motivation by setting milestones and showing progress when you reach them! 1. [x] Gettign a random assortment of loot from the ewaste bin @@ -68,6 +71,9 @@ Submission day: Jan 19th 8AM ## Attribution ### Icons -https://www.flaticon.com/free-icon/home_25694?term=home&page=1&position=2&origin=tag&related_id=25694 -https://www.flaticon.com/free-icon/renovation_2825738?term=workshop&page=1&position=90&origin=search&related_id=2825738 -https://www.flaticon.com/free-icon/bin_484611?term=bin&page=1&position=4&origin=search&related_id=484611 +https://www.flaticon.com/free-icon/home_25694 +https://www.flaticon.com/free-icon/renovation_2825738 +https://www.flaticon.com/free-icon/bin_484611 +https://www.flaticon.com/free-icon/volume-up_6996058 + +Glyphs - https://kenney.nl/assets/input-prompts diff --git a/assets/glyphs/keyboard_shift.png b/assets/glyphs/keyboard_shift.png new file mode 100644 index 0000000..f21512f Binary files /dev/null and b/assets/glyphs/keyboard_shift.png differ diff --git a/assets/glyphs/keyboard_shift.png.import b/assets/glyphs/keyboard_shift.png.import new file mode 100644 index 0000000..0cab9f1 --- /dev/null +++ b/assets/glyphs/keyboard_shift.png.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://of71gurkt2v2" +path="res://.godot/imported/keyboard_shift.png-0a139a10d27334aef5c06be45cbc3a54.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/glyphs/keyboard_shift.png" +dest_files=["res://.godot/imported/keyboard_shift.png-0a139a10d27334aef5c06be45cbc3a54.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/assets/glyphs/mouse_left.png b/assets/glyphs/mouse_left.png new file mode 100644 index 0000000..d458955 Binary files /dev/null and b/assets/glyphs/mouse_left.png differ diff --git a/assets/glyphs/mouse_left.png.import b/assets/glyphs/mouse_left.png.import new file mode 100644 index 0000000..9187320 --- /dev/null +++ b/assets/glyphs/mouse_left.png.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b6pddnr3aascg" +path="res://.godot/imported/mouse_left.png-6b71001ac374d6a552903181011068e4.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/glyphs/mouse_left.png" +dest_files=["res://.godot/imported/mouse_left.png-6b71001ac374d6a552903181011068e4.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/assets/icons/volume-up.png b/assets/icons/volume-up.png new file mode 100644 index 0000000..87f3d1b Binary files /dev/null and b/assets/icons/volume-up.png differ diff --git a/assets/icons/volume-up.png.import b/assets/icons/volume-up.png.import new file mode 100644 index 0000000..b5cc486 --- /dev/null +++ b/assets/icons/volume-up.png.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://6es1rrxgg6xs" +path="res://.godot/imported/volume-up.png-853891013bae5a8a8ebdb9284765eae9.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/icons/volume-up.png" +dest_files=["res://.godot/imported/volume-up.png-853891013bae5a8a8ebdb9284765eae9.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/assets/item images/battery.webp b/assets/item images/battery.webp index b06289d..2fc9e2b 100644 Binary files a/assets/item images/battery.webp and b/assets/item images/battery.webp differ diff --git a/assets/item images/big psu.png b/assets/item images/big psu.png index 56ad9b8..0d5eb1c 100644 Binary files a/assets/item images/big psu.png and b/assets/item images/big psu.png differ diff --git a/assets/item images/disc.png b/assets/item images/disc.png new file mode 100644 index 0000000..22666b9 Binary files /dev/null and b/assets/item images/disc.png differ diff --git a/assets/item images/disc.png.import b/assets/item images/disc.png.import new file mode 100644 index 0000000..04829bf --- /dev/null +++ b/assets/item images/disc.png.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dnrvduigm7ouj" +path="res://.godot/imported/disc.png-80f91e7caa24b2f858cd07e61a0ccc61.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://assets/item images/disc.png" +dest_files=["res://.godot/imported/disc.png-80f91e7caa24b2f858cd07e61a0ccc61.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/assets/item images/hdd.png b/assets/item images/hdd.png index 6532602..9a04c37 100644 Binary files a/assets/item images/hdd.png and b/assets/item images/hdd.png differ diff --git a/assets/item images/laptop.png b/assets/item images/laptop.png index 32ab80f..0752a6a 100644 Binary files a/assets/item images/laptop.png and b/assets/item images/laptop.png differ diff --git a/assets/item images/small psu.png b/assets/item images/small psu.png index 9b1478b..1b39c5e 100644 Binary files a/assets/item images/small psu.png and b/assets/item images/small psu.png differ diff --git a/crafting/crafts/pastic_block_craft.tres b/crafting/crafts/pastic_block_craft.tres deleted file mode 100644 index 7d738e5..0000000 --- a/crafting/crafts/pastic_block_craft.tres +++ /dev/null @@ -1,12 +0,0 @@ -[gd_resource type="Resource" script_class="CraftRecipe" load_steps=5 format=3 uid="uid://betkb8vbukp8g"] - -[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="1_ex3qq"] -[ext_resource type="Resource" uid="uid://cnr1k8seffsxb" path="res://items/plastic.tres" id="2_ex3qq"] -[ext_resource type="Resource" uid="uid://u5u51q8erbkf" path="res://items/plastic_block.tres" id="3_1qpj1"] -[ext_resource type="Script" uid="uid://b4iu5xrdf0evs" path="res://crafting/craft_recipe.gd" id="4_hrlxw"] - -[resource] -script = ExtResource("4_hrlxw") -ingredients = Array[ExtResource("1_ex3qq")]([ExtResource("2_ex3qq"), ExtResource("2_ex3qq"), ExtResource("2_ex3qq"), ExtResource("2_ex3qq"), ExtResource("2_ex3qq"), ExtResource("2_ex3qq"), null, null, null]) -output = ExtResource("3_1qpj1") -metadata/_custom_type_script = "uid://b4iu5xrdf0evs" diff --git a/crafting/crafts/ups_craft.tres b/crafting/crafts/ups_craft.tres new file mode 100644 index 0000000..d454067 --- /dev/null +++ b/crafting/crafts/ups_craft.tres @@ -0,0 +1,12 @@ +[gd_resource type="Resource" script_class="CraftRecipe" load_steps=5 format=3 uid="uid://betkb8vbukp8g"] + +[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="1_73sjm"] +[ext_resource type="Resource" uid="uid://b2tfv3l6feulr" path="res://items/battery.tres" id="2_ddta5"] +[ext_resource type="Resource" uid="uid://etplpx8i2jf1" path="res://items/ups_item.tres" id="3_cnltt"] +[ext_resource type="Script" uid="uid://b4iu5xrdf0evs" path="res://crafting/craft_recipe.gd" id="4_mwyny"] + +[resource] +script = ExtResource("4_mwyny") +ingredients = Array[ExtResource("1_73sjm")]([ExtResource("2_ddta5"), ExtResource("2_ddta5"), ExtResource("2_ddta5"), ExtResource("2_ddta5"), null, null, null, null, null]) +output = ExtResource("3_cnltt") +metadata/_custom_type_script = "uid://b4iu5xrdf0evs" diff --git a/crafting/recipe book/recipe_card.gd b/crafting/recipe book/recipe_card.gd index 720def4..9c9166b 100644 --- a/crafting/recipe book/recipe_card.gd +++ b/crafting/recipe book/recipe_card.gd @@ -25,8 +25,8 @@ func show_recipe(recipe : CraftRecipe): ingredient_slots[x].update_ui() ingredient_slots[x].block_taking = true output_slot.item = recipe.output - if (PlayerInventory.power_values.has(recipe.output)): - output_slot.extra_data = "Botnet Power: " + str(PlayerInventory.power_values.get(recipe.output)) + #if (PlayerInventory.power_values.has(recipe.output)): + #output_slot.extra_data = "Botnet Power: " + str(PlayerInventory.power_values.get(recipe.output)) output_slot.update_ui() output_slot.block_taking = true diff --git a/crafting/recipe book/scavengeBook.gd b/crafting/recipe book/scavengeBook.gd index b0a599e..a408925 100644 --- a/crafting/recipe book/scavengeBook.gd +++ b/crafting/recipe book/scavengeBook.gd @@ -19,8 +19,18 @@ func scavs_ready(): new_slot.item = scav.input new_slot.block_taking = true var scav_preview : String = str(scav.rolls) + " Rolls" + + var total_chance : int = 0 for loot in scav.loot_pool: - scav_preview += "\n" + loot.item.item_name + " : " + str(loot.chance) + " Chance" + total_chance += loot.chance + var uncounted_chance = total_chance + + for loot in scav.loot_pool: + if loot.item: + scav_preview += "\n" + loot.item.item_name + ": " + str((int((loot.chance/float(total_chance))*10000))/100) + "%" + uncounted_chance -= loot.chance + if uncounted_chance > 0: + scav_preview += "\nNothing: " + str((int((uncounted_chance/float(total_chance))*10000))/100) + "%" new_slot.extra_data = scav_preview grid.add_child(new_slot) pass diff --git a/crafting/scavenges/dvd_drive_scav.tres b/crafting/scavenges/dvd_drive_scav.tres new file mode 100644 index 0000000..ded014a --- /dev/null +++ b/crafting/scavenges/dvd_drive_scav.tres @@ -0,0 +1,24 @@ +[gd_resource type="Resource" script_class="ScavengeRecipe" load_steps=7 format=3 uid="uid://bagxi34ry0g1b"] + +[ext_resource type="Resource" uid="uid://d14wjbxictxb" path="res://items/dvd_drive.tres" id="1_54aqd"] +[ext_resource type="Script" uid="uid://oa5rlx6ttwuj" path="res://crafting/rollableLoot.gd" id="2_8d3so"] +[ext_resource type="Resource" uid="uid://cbgv58ylt2wnc" path="res://items/disc_item.tres" id="3_54aqd"] +[ext_resource type="Script" uid="uid://boqr1fowaqmt0" path="res://crafting/scavenge_recipe.gd" id="5_n3vaw"] + +[sub_resource type="Resource" id="Resource_uytxf"] +script = ExtResource("2_8d3so") +item = ExtResource("3_54aqd") +chance = 1 +metadata/_custom_type_script = "uid://oa5rlx6ttwuj" + +[sub_resource type="Resource" id="Resource_8d3so"] +script = ExtResource("2_8d3so") +chance = 9 +metadata/_custom_type_script = "uid://oa5rlx6ttwuj" + +[resource] +script = ExtResource("5_n3vaw") +input = ExtResource("1_54aqd") +rolls = 1 +loot_pool = Array[ExtResource("2_8d3so")]([SubResource("Resource_uytxf"), SubResource("Resource_8d3so")]) +metadata/_custom_type_script = "uid://boqr1fowaqmt0" diff --git a/credits/credit_slot.gd b/credits/credit_slot.gd new file mode 100644 index 0000000..0cd46c1 --- /dev/null +++ b/credits/credit_slot.gd @@ -0,0 +1,22 @@ +extends ItemSlot + +@export var link : String = "" + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + super() + block_taking = true + if link != "": + label.text = "🌐" + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_gui_input(event: InputEvent) -> void: + if event.is_pressed() and link != "": + OS.shell_open(link) + #print("slot clicked") diff --git a/credits/credit_slot.gd.uid b/credits/credit_slot.gd.uid new file mode 100644 index 0000000..c2b64db --- /dev/null +++ b/credits/credit_slot.gd.uid @@ -0,0 +1 @@ +uid://kvxou0qjrhmc diff --git a/credits/credit_slot.tscn b/credits/credit_slot.tscn new file mode 100644 index 0000000..634b8bf --- /dev/null +++ b/credits/credit_slot.tscn @@ -0,0 +1,50 @@ +[gd_scene load_steps=5 format=3 uid="uid://bicj8f61mhigk"] + +[ext_resource type="StyleBox" uid="uid://hgjmkwj0dbqr" path="res://inv_system/item_panels/default.tres" id="1_lpte7"] +[ext_resource type="Script" uid="uid://kvxou0qjrhmc" path="res://credits/credit_slot.gd" id="2_katch"] +[ext_resource type="Texture2D" uid="uid://b7jp850fqpa0j" path="res://icon.svg" id="3_0u6ut"] + +[sub_resource type="LabelSettings" id="LabelSettings_ab1u2"] +outline_size = 5 +outline_color = Color(0, 0, 0, 1) + +[node name="CreditSlot" type="Panel" node_paths=PackedStringArray("icon", "label")] +custom_minimum_size = Vector2(50, 50) +theme_override_styles/panel = ExtResource("1_lpte7") +script = ExtResource("2_katch") +icon = NodePath("Icon") +label = NodePath("Icon/Label") + +[node name="Icon" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.1 +anchor_top = 0.1 +anchor_right = 0.8 +anchor_bottom = 0.9 +offset_right = 5.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("3_0u6ut") +expand_mode = 3 + +[node name="Label" type="Label" parent="Icon"] +layout_mode = 1 +anchors_preset = 7 +anchor_left = 0.5 +anchor_top = 1.0 +anchor_right = 0.5 +anchor_bottom = 1.0 +offset_left = -31.0 +offset_top = -14.599998 +offset_right = 30.999998 +offset_bottom = 8.400002 +grow_horizontal = 2 +grow_vertical = 0 +text = "meow" +label_settings = SubResource("LabelSettings_ab1u2") +horizontal_alignment = 2 + +[connection signal="gui_input" from="." to="." method="_on_gui_input"] +[connection signal="mouse_entered" from="." to="." method="_on_mouse_entered"] +[connection signal="mouse_exited" from="." to="." method="_on_mouse_exited"] diff --git a/credits/people/kane.webp b/credits/people/kane.webp new file mode 100644 index 0000000..ec4ca94 Binary files /dev/null and b/credits/people/kane.webp differ diff --git a/credits/people/kane.webp.import b/credits/people/kane.webp.import new file mode 100644 index 0000000..971863b --- /dev/null +++ b/credits/people/kane.webp.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://drbc57qdmvl3w" +path="res://.godot/imported/kane.webp-0b456414bf6aeedf9f20cf2f98ce855a.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://credits/people/kane.webp" +dest_files=["res://.godot/imported/kane.webp-0b456414bf6aeedf9f20cf2f98ce855a.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/credits/people/maxie.webp b/credits/people/maxie.webp new file mode 100644 index 0000000..e4bb6a5 Binary files /dev/null and b/credits/people/maxie.webp differ diff --git a/credits/people/maxie.webp.import b/credits/people/maxie.webp.import new file mode 100644 index 0000000..c93366b --- /dev/null +++ b/credits/people/maxie.webp.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ofdvybdxtcgb" +path="res://.godot/imported/maxie.webp-f5844598a9c59def0c4f8304c5a42a3f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://credits/people/maxie.webp" +dest_files=["res://.godot/imported/maxie.webp-f5844598a9c59def0c4f8304c5a42a3f.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/credits/people/spantle.webp b/credits/people/spantle.webp new file mode 100644 index 0000000..e0db7da Binary files /dev/null and b/credits/people/spantle.webp differ diff --git a/credits/people/spantle.webp.import b/credits/people/spantle.webp.import new file mode 100644 index 0000000..26b4d68 --- /dev/null +++ b/credits/people/spantle.webp.import @@ -0,0 +1,40 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bu3t30sqi3t8t" +path="res://.godot/imported/spantle.webp-4f4fbd0b1fd312c9a9eca32e9eed909f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://credits/people/spantle.webp" +dest_files=["res://.godot/imported/spantle.webp-4f4fbd0b1fd312c9a9eca32e9eed909f.ctex"] + +[params] + +compress/mode=0 +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=false +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=1 diff --git a/default_bus_layout.tres b/default_bus_layout.tres new file mode 100644 index 0000000..ff1616d --- /dev/null +++ b/default_bus_layout.tres @@ -0,0 +1,9 @@ +[gd_resource type="AudioBusLayout" format=3 uid="uid://qkklhisa6at6"] + +[resource] +bus/1/name = &"Soundtrack" +bus/1/solo = false +bus/1/mute = false +bus/1/bypass_fx = false +bus/1/volume_db = 0.0 +bus/1/send = &"Master" diff --git a/inv_system/botnet/botnet_panel.gd b/inv_system/botnet/botnet_panel.gd index ed5ea95..ae45abf 100644 --- a/inv_system/botnet/botnet_panel.gd +++ b/inv_system/botnet/botnet_panel.gd @@ -26,9 +26,9 @@ func _notification(what: int) -> void: func check_server(): if slots[0].item: - if PlayerInventory.power_values.has(slots[0].item): + if slots[0].item.botnet_power > 0: install_button.disabled = false - power_predict.text = "[color=green][wave]Device Power: " + str(PlayerInventory.power_values.get(slots[0].item)) + power_predict.text = "[color=green][wave]Device Power: " + str(slots[0].item.botnet_power) else: install_button.disabled = true power_predict.text = "[pulse]Insert a device to predict power" @@ -39,7 +39,7 @@ func check_server(): func _on_button_pressed() -> void: - PlayerInventory.botnet_servers += PlayerInventory.power_values.get(slots[0].item) + PlayerInventory.botnet_servers += slots[0].item.botnet_power PlayerInventory.botnet.append(slots[0].item) install_button.disabled = true power_predict.text = "[pulse]Insert a device to predict power" diff --git a/inv_system/item_data.gd b/inv_system/item_data.gd index c031e5e..cdc9601 100644 --- a/inv_system/item_data.gd +++ b/inv_system/item_data.gd @@ -7,4 +7,6 @@ class_name ItemData @export var custom_panel_style : StyleBox @export var bin_chance : int = 5 @export var buy_value : int = 10 +@export var botnet_power : int = 0 @export var can_buy : bool = false +@export var description : String = "" diff --git a/inv_system/item_slot.gd b/inv_system/item_slot.gd index f4eace5..77eea5c 100644 --- a/inv_system/item_slot.gd +++ b/inv_system/item_slot.gd @@ -62,7 +62,7 @@ func _drop_data(at_position: Vector2, data: Variant) -> void: func _on_mouse_entered() -> void: #print("im real?") if item: - Tooltip.show_tip(item.item_name, extra_data) + Tooltip.show_tip(item, extra_data) MouseTweaks.hovered_slot = self pass # Replace with function body. diff --git a/inv_system/player_inventory.gd b/inv_system/player_inventory.gd index a94428f..8bf317d 100644 --- a/inv_system/player_inventory.gd +++ b/inv_system/player_inventory.gd @@ -6,7 +6,7 @@ extends Node @export var money_label : Label @export var botnet_servers : int = 0 @export var botnet : Array[ItemData] = [] -@export var power_values : Dictionary[ItemData,int] +#@export var power_values : Dictionary[ItemData,int] # Called when the node enters the scene tree for the first time. func _ready() -> void: diff --git a/inv_system/player_inventory.tscn b/inv_system/player_inventory.tscn index c6b05d4..ee2ad70 100644 --- a/inv_system/player_inventory.tscn +++ b/inv_system/player_inventory.tscn @@ -1,16 +1,65 @@ -[gd_scene load_steps=15 format=3 uid="uid://bkhg56q71vsjv"] +[gd_scene load_steps=16 format=3 uid="uid://bkhg56q71vsjv"] [ext_resource type="Script" uid="uid://jxkjnscuxcyi" path="res://inv_system/player_inventory.gd" id="1_vk2kx"] [ext_resource type="Script" uid="uid://c6oycdae5wvjf" path="res://inv_system/inventory.gd" id="2_hk4hx"] -[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="2_l456l"] [ext_resource type="PackedScene" uid="uid://dgqs20xf7l8c" path="res://inv_system/item_slot.tscn" id="3_8qgtd"] -[ext_resource type="Resource" uid="uid://be540abaa08ox" path="res://items/server.tres" id="3_77dmv"] [ext_resource type="Script" uid="uid://chxgum3v3d1o7" path="res://crafting/recipe book/recipie_book.gd" id="4_bdgfq"] -[ext_resource type="Resource" uid="uid://b3uytlkfvj67f" path="res://items/gaming_computer.tres" id="4_txpda"] [ext_resource type="Script" uid="uid://drm5jfhadys7l" path="res://crafting/recipe book/scavengeBook.gd" id="5_bdgfq"] -[ext_resource type="Resource" uid="uid://8vw85c1qrypm" path="res://items/computer.tres" id="5_klg10"] -[ext_resource type="Resource" uid="uid://bvcquf4e43r6r" path="res://items/laptop.tres" id="6_xr7r7"] -[ext_resource type="Resource" uid="uid://3afonee3dw7" path="res://items/nas_item.tres" id="7_g2557"] +[ext_resource type="Texture2D" uid="uid://of71gurkt2v2" path="res://assets/glyphs/keyboard_shift.png" id="12_txpda"] +[ext_resource type="Texture2D" uid="uid://b6pddnr3aascg" path="res://assets/glyphs/mouse_left.png" id="13_klg10"] + +[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_txpda"] +content_margin_left = 10.0 +content_margin_top = 4.0 +content_margin_right = 10.0 +content_margin_bottom = 4.0 +bg_color = Color(0.1, 0.1, 0.1, 0.6) +border_color = Color(1, 1, 0, 0.7490196) +corner_radius_top_left = 15 +corner_radius_top_right = 15 +corner_detail = 5 + +[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_klg10"] +content_margin_left = 10.0 +content_margin_top = 4.0 +content_margin_right = 10.0 +content_margin_bottom = 4.0 +bg_color = Color(0.46963727, 0.46963727, 0.46963727, 0.6) +border_width_left = 2 +border_width_top = 2 +border_width_right = 2 +border_color = Color(1, 1, 0, 0.7490196) +corner_radius_top_left = 15 +corner_radius_top_right = 15 +corner_detail = 5 + +[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_xr7r7"] +content_margin_left = 10.0 +content_margin_top = 4.0 +content_margin_right = 10.0 +content_margin_bottom = 4.0 +bg_color = Color(0.1, 0.1, 0.1, 0.6) +border_width_left = 2 +border_width_top = 2 +border_width_right = 2 +border_color = Color(1, 1, 0, 0.7490196) +corner_radius_top_left = 15 +corner_radius_top_right = 15 +corner_detail = 5 + +[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_g2557"] +content_margin_left = 10.0 +content_margin_top = 4.0 +content_margin_right = 10.0 +content_margin_bottom = 4.0 +bg_color = Color(0.6, 0.6, 0.6, 0) +border_width_left = 2 +border_width_top = 2 +border_width_right = 2 +border_color = Color(1, 1, 0, 0.7490196) +corner_radius_top_left = 15 +corner_radius_top_right = 15 +corner_detail = 5 [sub_resource type="StyleBoxFlat" id="StyleBoxFlat_icm48"] content_margin_left = 0.0 @@ -40,6 +89,9 @@ corner_detail = 5 font_size = 24 font_color = Color(1, 0.7490196, 0, 1) +[sub_resource type="LabelSettings" id="LabelSettings_xr7r7"] +font_size = 24 + [node name="PlayerInventory" type="Control" node_paths=PackedStringArray("inventory_panel", "button", "money_label")] z_index = 2 layout_mode = 3 @@ -53,13 +105,6 @@ script = ExtResource("1_vk2kx") inventory_panel = NodePath("Inventory") button = NodePath("Button") money_label = NodePath("PanelContainer/Label") -power_values = Dictionary[ExtResource("2_l456l"), int]({ -ExtResource("3_77dmv"): 10, -ExtResource("4_txpda"): 4, -ExtResource("5_klg10"): 2, -ExtResource("6_xr7r7"): 3, -ExtResource("7_g2557"): 2 -}) [node name="Button" type="Button" parent="."] visible = false @@ -208,27 +253,33 @@ offset_left = 1.0 offset_top = 126.0 offset_right = 237.0 offset_bottom = 603.0 +theme_override_colors/font_selected_color = Color(0.9490196, 0.9490196, 0, 1) +theme_override_colors/font_unselected_color = Color(0.99637884, 0.99637896, 0.99637896, 1) +theme_override_styles/tab_unselected = SubResource("StyleBoxFlat_txpda") +theme_override_styles/tab_hovered = SubResource("StyleBoxFlat_klg10") +theme_override_styles/tab_selected = SubResource("StyleBoxFlat_xr7r7") +theme_override_styles/tab_focus = SubResource("StyleBoxFlat_g2557") current_tab = 0 -[node name="Recipie Book" type="PanelContainer" parent="TabContainer" node_paths=PackedStringArray("vbox")] +[node name="Recipe Book" type="PanelContainer" parent="TabContainer" node_paths=PackedStringArray("vbox")] layout_mode = 2 theme_override_styles/panel = SubResource("StyleBoxFlat_icm48") script = ExtResource("4_bdgfq") vbox = NodePath("MarginContainer/ScrollContainer/VBoxContainer") metadata/_tab_index = 0 -[node name="MarginContainer" type="MarginContainer" parent="TabContainer/Recipie Book"] +[node name="MarginContainer" type="MarginContainer" parent="TabContainer/Recipe Book"] layout_mode = 2 theme_override_constants/margin_left = 5 theme_override_constants/margin_top = 5 theme_override_constants/margin_right = 5 theme_override_constants/margin_bottom = 5 -[node name="ScrollContainer" type="ScrollContainer" parent="TabContainer/Recipie Book/MarginContainer"] +[node name="ScrollContainer" type="ScrollContainer" parent="TabContainer/Recipe Book/MarginContainer"] layout_mode = 2 horizontal_scroll_mode = 0 -[node name="VBoxContainer" type="VBoxContainer" parent="TabContainer/Recipie Book/MarginContainer/ScrollContainer"] +[node name="VBoxContainer" type="VBoxContainer" parent="TabContainer/Recipe Book/MarginContainer/ScrollContainer"] layout_mode = 2 size_flags_horizontal = 3 size_flags_vertical = 3 @@ -276,4 +327,38 @@ text = "Money: $0" label_settings = SubResource("LabelSettings_bdgfq") horizontal_alignment = 1 +[node name="PanelContainer2" type="PanelContainer" parent="."] +layout_mode = 0 +offset_left = 250.0 +offset_top = 575.0 +offset_right = 507.0 +offset_bottom = 617.0 + +[node name="HBoxContainer" type="HBoxContainer" parent="PanelContainer2"] +layout_mode = 2 +theme_override_constants/separation = 0 +alignment = 1 + +[node name="Label" type="Label" parent="PanelContainer2/HBoxContainer"] +layout_mode = 2 +text = "Quick Move:" +label_settings = SubResource("LabelSettings_xr7r7") +horizontal_alignment = 1 + +[node name="TextureRect" type="TextureRect" parent="PanelContainer2/HBoxContainer"] +layout_mode = 2 +texture = ExtResource("12_txpda") +expand_mode = 3 + +[node name="Label2" type="Label" parent="PanelContainer2/HBoxContainer"] +layout_mode = 2 +text = "+" +label_settings = SubResource("LabelSettings_xr7r7") +horizontal_alignment = 1 + +[node name="TextureRect2" type="TextureRect" parent="PanelContainer2/HBoxContainer"] +layout_mode = 2 +texture = ExtResource("13_klg10") +expand_mode = 3 + [connection signal="pressed" from="Button" to="." method="_on_button_pressed"] diff --git a/inv_system/sell_panel.gd b/inv_system/sell_panel.gd index c935e86..230a5f0 100644 --- a/inv_system/sell_panel.gd +++ b/inv_system/sell_panel.gd @@ -7,6 +7,7 @@ extends Inventory func _ready() -> void: super() calculate_sell_value() + Clock.new_day.connect(calculate_sell_value) pass # Replace with function body. diff --git a/inv_system/trash_slot.gd b/inv_system/trash_slot.gd new file mode 100644 index 0000000..ca8dd8f --- /dev/null +++ b/inv_system/trash_slot.gd @@ -0,0 +1,17 @@ +extends PanelContainer + +@export var slot : ItemSlot + +# 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 + + +func _on_button_pressed() -> void: + slot.item = null + slot.update_ui() diff --git a/inv_system/trash_slot.gd.uid b/inv_system/trash_slot.gd.uid new file mode 100644 index 0000000..41c4bec --- /dev/null +++ b/inv_system/trash_slot.gd.uid @@ -0,0 +1 @@ +uid://dm7x3etlucffq diff --git a/items/computer.tres b/items/computer.tres index b543504..f6accf6 100644 --- a/items/computer.tres +++ b/items/computer.tres @@ -11,4 +11,5 @@ icon = ExtResource("1_e0dbh") custom_panel_style = ExtResource("1_x7wm3") bin_chance = 0 buy_value = 500 +botnet_power = 2 metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/disc_item.tres b/items/disc_item.tres new file mode 100644 index 0000000..c9feb9d --- /dev/null +++ b/items/disc_item.tres @@ -0,0 +1,14 @@ +[gd_resource type="Resource" script_class="ItemData" load_steps=4 format=3 uid="uid://cbgv58ylt2wnc"] + +[ext_resource type="StyleBox" uid="uid://c563rid4b4fho" path="res://inv_system/item_panels/epic.tres" id="1_lhfs3"] +[ext_resource type="Texture2D" uid="uid://dnrvduigm7ouj" path="res://assets/item images/disc.png" id="2_v2wmo"] +[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="3_k0y7x"] + +[resource] +script = ExtResource("3_k0y7x") +item_name = "Data Disc" +icon = ExtResource("2_v2wmo") +custom_panel_style = ExtResource("1_lhfs3") +bin_chance = 0 +buy_value = 600 +metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/gaming_computer.tres b/items/gaming_computer.tres index a28d46d..df48ab7 100644 --- a/items/gaming_computer.tres +++ b/items/gaming_computer.tres @@ -11,4 +11,5 @@ icon = ExtResource("2_a2am6") custom_panel_style = ExtResource("1_j1gmi") bin_chance = 0 buy_value = 1500 +botnet_power = 4 metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/laptop.tres b/items/laptop.tres index 0c1e8cf..46aabbb 100644 --- a/items/laptop.tres +++ b/items/laptop.tres @@ -11,4 +11,5 @@ icon = ExtResource("2_xyf87") custom_panel_style = ExtResource("1_xyf87") bin_chance = 0 buy_value = 850 +botnet_power = 3 metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/nas_item.tres b/items/nas_item.tres index 80ceb85..8cf1926 100644 --- a/items/nas_item.tres +++ b/items/nas_item.tres @@ -11,4 +11,5 @@ icon = ExtResource("2_wtpx3") custom_panel_style = ExtResource("1_wtpx3") bin_chance = 0 buy_value = 600 +botnet_power = 2 metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/server.tres b/items/server.tres index 035aae7..0702d87 100644 --- a/items/server.tres +++ b/items/server.tres @@ -11,4 +11,5 @@ icon = ExtResource("2_5q0ct") custom_panel_style = ExtResource("1_70din") bin_chance = 0 buy_value = 2000 +botnet_power = 10 metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/items/ups_item.tres b/items/ups_item.tres new file mode 100644 index 0000000..a767740 --- /dev/null +++ b/items/ups_item.tres @@ -0,0 +1,14 @@ +[gd_resource type="Resource" script_class="ItemData" load_steps=4 format=3 uid="uid://etplpx8i2jf1"] + +[ext_resource type="StyleBox" uid="uid://dcnrpkhjhp4tk" path="res://inv_system/item_panels/rare.tres" id="1_pugmu"] +[ext_resource type="Texture2D" uid="uid://k5r6iukify6r" path="res://assets/item images/UPS.png" id="2_pugmu"] +[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="3_d6fvv"] + +[resource] +script = ExtResource("3_d6fvv") +item_name = "Uninterruptible power supply" +icon = ExtResource("2_pugmu") +custom_panel_style = ExtResource("1_pugmu") +bin_chance = 0 +buy_value = 400 +metadata/_custom_type_script = "uid://dccraom7a7e8d" diff --git a/music/Godot Wild Jam #89 Demo.flac b/music/Godot Wild Jam #89 Demo.flac new file mode 100644 index 0000000..f791919 Binary files /dev/null and b/music/Godot Wild Jam #89 Demo.flac differ diff --git a/music/Godot Wild Jam 89 Demo.ogg b/music/Godot Wild Jam 89 Demo.ogg new file mode 100644 index 0000000..cfd66c9 Binary files /dev/null and b/music/Godot Wild Jam 89 Demo.ogg differ diff --git a/music/Godot Wild Jam 89 Demo.ogg.import b/music/Godot Wild Jam 89 Demo.ogg.import new file mode 100644 index 0000000..14fddbe --- /dev/null +++ b/music/Godot Wild Jam 89 Demo.ogg.import @@ -0,0 +1,19 @@ +[remap] + +importer="oggvorbisstr" +type="AudioStreamOggVorbis" +uid="uid://r5u2un1fds6m" +path="res://.godot/imported/Godot Wild Jam 89 Demo.ogg-9dcd0225c3667337807a990bcf2bd61f.oggvorbisstr" + +[deps] + +source_file="res://music/Godot Wild Jam 89 Demo.ogg" +dest_files=["res://.godot/imported/Godot Wild Jam 89 Demo.ogg-9dcd0225c3667337807a990bcf2bd61f.oggvorbisstr"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/music/music_panel.gd b/music/music_panel.gd new file mode 100644 index 0000000..d5b502e --- /dev/null +++ b/music/music_panel.gd @@ -0,0 +1,22 @@ +extends Control + +@export var ambient_player : AudioStreamPlayer + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + _on_h_slider_value_changed(0.5) + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_h_slider_value_changed(value: float) -> void: + #var new_db = linear_to_db(value) + AudioServer.set_bus_volume_linear(1, value) + + +func _on_audio_stream_player_finished() -> void: + ambient_player.play() diff --git a/music/music_panel.gd.uid b/music/music_panel.gd.uid new file mode 100644 index 0000000..63cb474 --- /dev/null +++ b/music/music_panel.gd.uid @@ -0,0 +1 @@ +uid://bjieium3xew23 diff --git a/music/music_panel.tscn b/music/music_panel.tscn new file mode 100644 index 0000000..92651e7 --- /dev/null +++ b/music/music_panel.tscn @@ -0,0 +1,60 @@ +[gd_scene load_steps=4 format=3 uid="uid://dossu7drwmunk"] + +[ext_resource type="Texture2D" uid="uid://6es1rrxgg6xs" path="res://assets/icons/volume-up.png" id="1_8ia4e"] +[ext_resource type="Script" uid="uid://bjieium3xew23" path="res://music/music_panel.gd" id="1_52dcn"] +[ext_resource type="AudioStream" uid="uid://r5u2un1fds6m" path="res://music/Godot Wild Jam 89 Demo.ogg" id="3_yx23q"] + +[node name="MusicPanel" type="Control" node_paths=PackedStringArray("ambient_player")] +z_index = 4 +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +script = ExtResource("1_52dcn") +ambient_player = NodePath("AudioStreamPlayer") + +[node name="PanelContainer" type="PanelContainer" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -40.0 +offset_bottom = 40.0 +grow_horizontal = 0 +mouse_filter = 2 + +[node name="HBoxContainer" type="HBoxContainer" parent="PanelContainer"] +layout_mode = 2 + +[node name="TextureRect" type="TextureRect" parent="PanelContainer/HBoxContainer"] +layout_mode = 2 +texture = ExtResource("1_8ia4e") +expand_mode = 3 + +[node name="VBoxContainer" type="VBoxContainer" parent="PanelContainer/HBoxContainer"] +layout_mode = 2 +theme_override_constants/separation = -2 +alignment = 1 + +[node name="Label" type="Label" parent="PanelContainer/HBoxContainer/VBoxContainer"] +layout_mode = 2 +text = "Soundtrack" + +[node name="HSlider" type="HSlider" parent="PanelContainer/HBoxContainer/VBoxContainer"] +custom_minimum_size = Vector2(150, 0) +layout_mode = 2 +size_flags_vertical = 4 +max_value = 1.0 +step = 0.0 +value = 0.5 + +[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."] +stream = ExtResource("3_yx23q") +autoplay = true +bus = &"Soundtrack" + +[connection signal="value_changed" from="PanelContainer/HBoxContainer/VBoxContainer/HSlider" to="." method="_on_h_slider_value_changed"] +[connection signal="finished" from="AudioStreamPlayer" to="." method="_on_audio_stream_player_finished"] diff --git a/project.godot b/project.godot index ef3cee4..7682eb0 100644 --- a/project.godot +++ b/project.godot @@ -23,6 +23,7 @@ Clock="*res://time_system/clock.tscn" MouseTweaks="*res://mouseTweaks.gd" RecipeManager="*res://crafting/recipeManager.gd" Locations="*res://scenes/manager/locations panel.tscn" +MusicPanel="*res://music/music_panel.tscn" [display] diff --git a/scenes/credits.tscn b/scenes/credits.tscn new file mode 100644 index 0000000..0548032 --- /dev/null +++ b/scenes/credits.tscn @@ -0,0 +1,184 @@ +[gd_scene load_steps=14 format=3 uid="uid://cix7xfnu1305i"] + +[ext_resource type="Script" uid="uid://4c4k3o0jnmdk" path="res://scenes/menu.gd" id="1_2ckv8"] +[ext_resource type="Texture2D" uid="uid://b1rs6epjar6mj" path="res://assets/menu.png" id="2_0ctdu"] +[ext_resource type="Texture2D" uid="uid://drbc57qdmvl3w" path="res://credits/people/kane.webp" id="5_ih6pn"] +[ext_resource type="StyleBox" uid="uid://coy6kyoackibc" path="res://inv_system/item_panels/legendary.tres" id="5_ooihk"] +[ext_resource type="Script" uid="uid://dccraom7a7e8d" path="res://inv_system/item_data.gd" id="6_7lgdl"] +[ext_resource type="StyleBox" uid="uid://c563rid4b4fho" path="res://inv_system/item_panels/epic.tres" id="7_ih6pn"] +[ext_resource type="Texture2D" uid="uid://ofdvybdxtcgb" path="res://credits/people/maxie.webp" id="8_7lgdl"] +[ext_resource type="Texture2D" uid="uid://bu3t30sqi3t8t" path="res://credits/people/spantle.webp" id="9_c6kru"] +[ext_resource type="PackedScene" uid="uid://bicj8f61mhigk" path="res://credits/credit_slot.tscn" id="9_ih6pn"] + +[sub_resource type="Resource" id="Resource_7lgdl"] +script = ExtResource("6_7lgdl") +item_name = "Unlimited_Gaming (Kane)" +icon = ExtResource("5_ih6pn") +custom_panel_style = ExtResource("5_ooihk") +metadata/_custom_type_script = "uid://dccraom7a7e8d" + +[sub_resource type="Resource" id="Resource_qbfqv"] +script = ExtResource("6_7lgdl") +item_name = "Maxie" +icon = ExtResource("8_7lgdl") +custom_panel_style = ExtResource("7_ih6pn") +metadata/_custom_type_script = "uid://dccraom7a7e8d" + +[sub_resource type="Resource" id="Resource_x5q3x"] +script = ExtResource("6_7lgdl") +item_name = "Unlimited_Gaming (Kane)" +icon = ExtResource("5_ih6pn") +custom_panel_style = ExtResource("7_ih6pn") +metadata/_custom_type_script = "uid://dccraom7a7e8d" + +[sub_resource type="Resource" id="Resource_nmdnh"] +script = ExtResource("6_7lgdl") +item_name = "Spantle" +icon = ExtResource("9_c6kru") +custom_panel_style = ExtResource("7_ih6pn") +metadata/_custom_type_script = "uid://dccraom7a7e8d" + +[node name="Credits" type="Control"] +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +script = ExtResource("1_2ckv8") + +[node name="TextureRect" type="TextureRect" parent="."] +z_index = -3 +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +texture = ExtResource("2_0ctdu") +expand_mode = 3 + +[node name="MarginContainer" type="MarginContainer" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +mouse_filter = 2 +theme_override_constants/margin_left = 250 +theme_override_constants/margin_top = 100 +theme_override_constants/margin_right = 250 +theme_override_constants/margin_bottom = 100 + +[node name="PanelContainer" type="PanelContainer" parent="MarginContainer"] +layout_mode = 2 + +[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/PanelContainer"] +layout_mode = 2 +theme_override_constants/margin_left = 5 +theme_override_constants/margin_top = 5 +theme_override_constants/margin_right = 5 +theme_override_constants/margin_bottom = 5 + +[node name="VBoxContainer" type="VBoxContainer" parent="MarginContainer/PanelContainer/MarginContainer"] +layout_mode = 2 +alignment = 1 + +[node name="RichTextLabel" type="RichTextLabel" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer"] +layout_mode = 2 +bbcode_enabled = true +text = "[center][font_size=50][wave]Credits" +fit_content = true + +[node name="RichTextLabel2" type="RichTextLabel" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer"] +layout_mode = 2 +bbcode_enabled = true +text = "[wave][color=orchid][center]Programming and Game Design by Tabby" +fit_content = true + +[node name="Label" type="Label" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer"] +layout_mode = 2 +text = "Hover to see details, Click to visit website 🌐" +horizontal_alignment = 1 +autowrap_mode = 2 + +[node name="HSeparator" type="HSeparator" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer"] +layout_mode = 2 + +[node name="ScrollContainer" type="ScrollContainer" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer"] +layout_mode = 2 +size_flags_vertical = 3 + +[node name="VBoxContainer" type="VBoxContainer" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer"] +layout_mode = 2 +size_flags_horizontal = 3 +size_flags_vertical = 3 + +[node name="Label2" type="Label" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer"] +layout_mode = 2 +text = "Ambient Soundtrack" +horizontal_alignment = 1 + +[node name="HFlowContainer" type="HFlowContainer" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer"] +layout_mode = 2 +theme_override_constants/h_separation = 8 +theme_override_constants/v_separation = 8 +alignment = 1 + +[node name="Kane" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer/HFlowContainer" instance=ExtResource("9_ih6pn")] +layout_mode = 2 +item = SubResource("Resource_7lgdl") + +[node name="Label3" type="Label" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer"] +layout_mode = 2 +text = "Playtesters" +horizontal_alignment = 1 + +[node name="HFlowContainer2" type="HFlowContainer" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer"] +layout_mode = 2 +theme_override_constants/h_separation = 8 +theme_override_constants/v_separation = 8 +alignment = 1 + +[node name="Maxie" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer/HFlowContainer2" instance=ExtResource("9_ih6pn")] +layout_mode = 2 +item = SubResource("Resource_qbfqv") + +[node name="Kane2" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer/HFlowContainer2" instance=ExtResource("9_ih6pn")] +layout_mode = 2 +item = SubResource("Resource_x5q3x") + +[node name="Sarantis" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer/HFlowContainer2" instance=ExtResource("9_ih6pn")] +layout_mode = 2 +item = SubResource("Resource_nmdnh") + +[node name="other" type="RichTextLabel" parent="MarginContainer/PanelContainer/MarginContainer/VBoxContainer/ScrollContainer/VBoxContainer"] +layout_mode = 2 +bbcode_enabled = true +text = "[center]Icons[/center][ul] +[url=https://www.flaticon.com/free-icon/bin_484611]Bin Icon by Freepik[/url] +[url=https://www.flaticon.com/free-icon/renovation_2825738]Rennovation Icon by Freepik[/url] +[url=https://www.flaticon.com/free-icon/home_25694]Home Icon by Dave Gandy[/url] +[url=https://www.flaticon.com/free-icon/home_25694]Volume Icon by Bharat Icons[/url] +[/ul][center]Items[/center][ul] +[url=https://www.umart.com.au/product/corsair-cx750-series-750w-80-bronze-non-modular-atx-power-supply-cp-9020279-au-77539]Large Power Supply[/url] +[url=https://sanmarcoscomputers.com/laptop-screen-repair/]Broken Laptop[/url] +[url=https://www.pngfind.com/mpng/JimhR_computer-server-workstation-hosting-cpu-clipart-hd-png/]Computer[/url] +[url=https://underwater.com.au/shop/nitecore-nl2153hp-5300mah-rechargeable-21700-battery.html]Battery[/url] +[url=https://www.amazon.com.au/81Y6404-IBM-Internal-DVD-Writer/dp/B005NO0RWY]DVD Drive[/url] +[url=https://geekd.dk/products/starter-gaming-2]Gaming Computer[/url] +[url=https://www.pcgamer.com/evgas-geforce-gtx-1070-ti-ftw-ultra-silent-card-is-on-sale-for-dollar510/]GPU[/url] +[url=https://www.australiandatarecovery.com.au/data-recovery-services/hdd-data-recovery]HDD[/url] +[url=https://www.dell.com/en-au/shop/cty/pdp/spd/latitude-14-5440-laptop]Laptop[/url] +[url=https://mobilehq.com.au/2-power-laptop-battery-hp-ht03xl-11-55v-3400mah]Laptop Battery[/url] +[url=https://www.qnap.com/en-au/product/ts-932px/specs/hardware]NAS[/url] +[url=https://www.ebay.com.au/itm/324153980853]RAM[/url] +[url=https://www.hiclipart.com/free-transparent-background-png-clipart-lbqwa]Server[/url] +[url=https://www.advantech.com/emt/products/atx-power-supply/sub_2d9aae24-dfb2-4741-bec5-62dca5bc9cd3]Small Power Supply[/url] +[url=https://www.ebay.com.au/itm/394942125788]SSD[/url] +[url=https://www.fingers.co.in/computer-peripherals/power-protection-ups/fr--1250lcd]UPS[/url] +[url=https://simple.wikipedia.org/wiki/Compact_disc]Disc[/url]" +fit_content = true diff --git a/scenes/ewaste.tscn b/scenes/ewaste.tscn index 97af554..fe257bd 100644 --- a/scenes/ewaste.tscn +++ b/scenes/ewaste.tscn @@ -35,7 +35,7 @@ layout_mode = 0 offset_left = 751.0 offset_top = 376.0 offset_right = 1027.0 -offset_bottom = 576.0 +offset_bottom = 630.0 script = ExtResource("1_6uqi0") inventory_name = "E-waste Recycling Bin" type = "Loot" @@ -97,7 +97,7 @@ layout_mode = 2 [node name="HSeparator" type="HSeparator" parent="BinPanel/MarginContainer/VBoxContainer"] layout_mode = 2 -theme_override_constants/separation = 14 +theme_override_constants/separation = 69 [node name="Delete" type="Button" parent="BinPanel/MarginContainer/VBoxContainer"] modulate = Color(1, 0, 0, 1) diff --git a/scenes/manager/locations panel.tscn b/scenes/manager/locations panel.tscn index 3215595..148618e 100644 --- a/scenes/manager/locations panel.tscn +++ b/scenes/manager/locations panel.tscn @@ -68,7 +68,7 @@ theme_override_styles/panel = ExtResource("5_qjxm7") [node name="Label" type="Label" parent="Move blocker"] layout_mode = 2 -text = "Cannot move" +text = "Cannot travel" horizontal_alignment = 1 autowrap_mode = 2 diff --git a/scenes/menu.tscn b/scenes/menu.tscn index 512e43c..9f99652 100644 --- a/scenes/menu.tscn +++ b/scenes/menu.tscn @@ -3,7 +3,7 @@ [ext_resource type="Script" uid="uid://4c4k3o0jnmdk" path="res://scenes/menu.gd" id="1_vjb58"] [ext_resource type="Texture2D" uid="uid://b1rs6epjar6mj" path="res://assets/menu.png" id="2_con2f"] -[node name="Ending" type="Control"] +[node name="Menu" type="Control"] layout_mode = 3 anchors_preset = 15 anchor_right = 1.0 @@ -32,6 +32,7 @@ anchor_right = 1.0 anchor_bottom = 1.0 grow_horizontal = 2 grow_vertical = 2 +mouse_filter = 2 theme_override_constants/margin_left = 250 theme_override_constants/margin_top = 100 theme_override_constants/margin_right = 250 diff --git a/scenes/workshop.tscn b/scenes/workshop.tscn index b630130..6a3ada9 100644 --- a/scenes/workshop.tscn +++ b/scenes/workshop.tscn @@ -1,8 +1,10 @@ -[gd_scene load_steps=4 format=3 uid="uid://dbxymsdyvbe2p"] +[gd_scene load_steps=6 format=3 uid="uid://dbxymsdyvbe2p"] [ext_resource type="Texture2D" uid="uid://dhyryjblax7sj" path="res://assets/workshop.png" id="1_d7fqo"] [ext_resource type="Script" uid="uid://bla0gy2tlqwe1" path="res://scenes/workshop.gd" id="1_g1tdj"] [ext_resource type="PackedScene" uid="uid://f06ym5ujhdsc" path="res://inv_system/crafting_panel.tscn" id="2_wwo6w"] +[ext_resource type="Script" uid="uid://dm7x3etlucffq" path="res://inv_system/trash_slot.gd" id="4_0t7iv"] +[ext_resource type="PackedScene" uid="uid://dgqs20xf7l8c" path="res://inv_system/item_slot.tscn" id="4_4103c"] [node name="Workshop" type="Control" node_paths=PackedStringArray("ewaste_button", "computer_button", "crafting_inv")] layout_mode = 3 @@ -60,5 +62,42 @@ offset_top = 189.0 offset_right = 1039.0 offset_bottom = 444.0 +[node name="TrashSlot" type="PanelContainer" parent="." node_paths=PackedStringArray("slot")] +modulate = Color(1, 0.31965953, 0.2533799, 1) +layout_mode = 0 +offset_left = 893.0 +offset_top = 486.0 +offset_right = 1026.0 +offset_bottom = 573.0 +script = ExtResource("4_0t7iv") +slot = NodePath("MarginContainer/VBoxContainer/HBoxContainer/ItemSlot") + +[node name="MarginContainer" type="MarginContainer" parent="TrashSlot"] +layout_mode = 2 +theme_override_constants/margin_left = 5 +theme_override_constants/margin_top = 5 +theme_override_constants/margin_right = 5 +theme_override_constants/margin_bottom = 5 + +[node name="VBoxContainer" type="VBoxContainer" parent="TrashSlot/MarginContainer"] +layout_mode = 2 + +[node name="Label" type="Label" parent="TrashSlot/MarginContainer/VBoxContainer"] +layout_mode = 2 +text = "Trash Slot" +horizontal_alignment = 1 + +[node name="HBoxContainer" type="HBoxContainer" parent="TrashSlot/MarginContainer/VBoxContainer"] +layout_mode = 2 + +[node name="ItemSlot" parent="TrashSlot/MarginContainer/VBoxContainer/HBoxContainer" instance=ExtResource("4_4103c")] +layout_mode = 2 + +[node name="Button" type="Button" parent="TrashSlot/MarginContainer/VBoxContainer/HBoxContainer"] +layout_mode = 2 +size_flags_vertical = 4 +text = "Destroy" + [connection signal="pressed" from="GotoEwaste" to="." method="_on_goto_ewaste_pressed"] [connection signal="pressed" from="GotoComputer" to="." method="_on_goto_computer_pressed"] +[connection signal="pressed" from="TrashSlot/MarginContainer/VBoxContainer/HBoxContainer/Button" to="TrashSlot" method="_on_button_pressed"] diff --git a/time_system/clock.gd b/time_system/clock.gd index da20885..de61f74 100644 --- a/time_system/clock.gd +++ b/time_system/clock.gd @@ -8,6 +8,8 @@ var starting_time : int = 200 @export var days_text : Label @export var next_button : Button +signal new_day + # Called when the node enters the scene tree for the first time. func _ready() -> void: pass # Replace with function body. @@ -35,6 +37,7 @@ func _on_next_day_pressed() -> void: if days_left >= 1: days_left -= 1 time_left = 200 + new_day.emit() else: get_tree().change_scene_to_file("res://scenes/ending.tscn") PlayerInventory.hide() diff --git a/tooltip.gd b/tooltip.gd index 791eb6b..01e843c 100644 --- a/tooltip.gd +++ b/tooltip.gd @@ -1,6 +1,6 @@ extends PanelContainer -@export var tooltip_label : Label +@export var tooltip_label : RichTextLabel @export var exdata_box : VBoxContainer @export var exdata_label : Label @@ -14,8 +14,10 @@ func _ready() -> void: func _process(delta: float) -> void: global_position = get_global_mouse_position() + Vector2(12,-6) -func show_tip(text : String, extra : String = ""): - tooltip_label.text = text +func show_tip(item : ItemData, extra : String = ""): + tooltip_label.text = item.item_name + "\nSell Value: $"+str(floori(item.buy_value/float(2))) + if item.botnet_power > 0: + tooltip_label.text += "\n[color=orchid]Botnet Power: " + str(item.botnet_power) +"[/color]" if extra != "": exdata_box.show() exdata_label.text = extra diff --git a/tooltip.tscn b/tooltip.tscn index 4eba57a..ac92c7c 100644 --- a/tooltip.tscn +++ b/tooltip.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=4 format=3 uid="uid://sb2wq874p37j"] +[gd_scene load_steps=3 format=3 uid="uid://sb2wq874p37j"] [ext_resource type="Script" uid="uid://cbta38dhunndc" path="res://tooltip.gd" id="1_gwequ"] @@ -17,14 +17,12 @@ corner_radius_top_right = 3 corner_radius_bottom_right = 3 corner_radius_bottom_left = 3 -[sub_resource type="LabelSettings" id="LabelSettings_oxk8h"] - [node name="Tooltip" type="PanelContainer" node_paths=PackedStringArray("tooltip_label", "exdata_box", "exdata_label")] z_index = 3 offset_right = 95.0 offset_bottom = 31.0 -size_flags_horizontal = 0 -size_flags_vertical = 0 +size_flags_horizontal = 2 +size_flags_vertical = 2 mouse_filter = 2 theme_override_styles/panel = SubResource("StyleBoxFlat_gwequ") script = ExtResource("1_gwequ") @@ -34,14 +32,15 @@ exdata_label = NodePath("VBoxContainer/Extradata/Label") [node name="VBoxContainer" type="VBoxContainer" parent="."] layout_mode = 2 -size_flags_horizontal = 0 -size_flags_vertical = 0 -[node name="Label" type="Label" parent="VBoxContainer"] +[node name="Label" type="RichTextLabel" parent="VBoxContainer"] layout_mode = 2 -size_flags_vertical = 6 +size_flags_vertical = 3 +bbcode_enabled = true text = "Item Name" -label_settings = SubResource("LabelSettings_oxk8h") +fit_content = true +scroll_active = false +autowrap_mode = 0 [node name="Extradata" type="VBoxContainer" parent="VBoxContainer"] visible = false