Added Map; Added Spawners; Changed Decorations; Cleaned up Code and some Settings; Added Enemy
This commit is contained in:
parent
e82438139f
commit
e18beb6c4c
160 changed files with 4674 additions and 182 deletions
|
|
@ -2,12 +2,28 @@ extends Area2D
|
|||
|
||||
@export_range(10,1000) var value = 10
|
||||
@export_range(1,70) var weight = 1
|
||||
@onready var interactIcon = $InteractIcon
|
||||
|
||||
const heavy = 50
|
||||
|
||||
var player = null
|
||||
|
||||
func _ready() -> void:
|
||||
interactIcon.hide()
|
||||
|
||||
func _physics_process(delta: float) -> void:
|
||||
for i in get_overlapping_areas():
|
||||
if i.is_in_group("Player"):
|
||||
if isCarryied():
|
||||
interactIcon.hide()
|
||||
elif not isCarryied():
|
||||
interactIcon.show()
|
||||
|
||||
#if isCarryied():
|
||||
#interactIcon.hide()
|
||||
#elif not isCarryied():
|
||||
#interactIcon.show()
|
||||
|
||||
if player != null:
|
||||
global_position.y = move_toward(global_position.y, player.global_position.y, 3)
|
||||
global_position.x = move_toward(global_position.x, player.global_position.x, 3)
|
||||
|
|
@ -29,3 +45,14 @@ func getValue():
|
|||
|
||||
func isCarryied():
|
||||
return player != null
|
||||
|
||||
|
||||
#func _on_area_entered(area: Area2D) -> void:
|
||||
#if area.is_in_group("Player"):
|
||||
#interactIcon.show()
|
||||
#
|
||||
#
|
||||
#
|
||||
func _on_area_exited(area: Area2D) -> void:
|
||||
if area.is_in_group("Player"):
|
||||
interactIcon.hide()
|
||||
|
|
|
|||
|
|
@ -1,12 +1,35 @@
|
|||
[gd_scene load_steps=2 format=3 uid="uid://dxpd1pq7v6ing"]
|
||||
[gd_scene load_steps=5 format=3 uid="uid://dxpd1pq7v6ing"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/game/objects/object.gd" id="1_3y27f"]
|
||||
[ext_resource type="Texture2D" uid="uid://c4h5dodgulduy" path="res://Assets/Icons/Pickup.png" id="2_pqvu2"]
|
||||
|
||||
[sub_resource type="CanvasItemMaterial" id="CanvasItemMaterial_n7gny"]
|
||||
light_mode = 2
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_vvfu1"]
|
||||
radius = 8.0
|
||||
|
||||
[node name="Object" type="Area2D" groups=["Object"]]
|
||||
collision_layer = 4
|
||||
collision_mask = 8
|
||||
light_mask = 16
|
||||
visibility_layer = 16
|
||||
material = SubResource("CanvasItemMaterial_n7gny")
|
||||
collision_layer = 16
|
||||
collision_mask = 96
|
||||
script = ExtResource("1_3y27f")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
position = Vector2(0, -4)
|
||||
shape = SubResource("CircleShape2D_vvfu1")
|
||||
|
||||
[node name="AnimatedSprite2D" type="AnimatedSprite2D" parent="."]
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
use_parent_material = true
|
||||
position = Vector2(0, -4)
|
||||
|
||||
[node name="InteractIcon" type="Sprite2D" parent="."]
|
||||
z_index = 5
|
||||
position = Vector2(5.68434e-14, -16)
|
||||
scale = Vector2(0.625, 0.625)
|
||||
texture = ExtResource("2_pqvu2")
|
||||
|
||||
[connection signal="area_entered" from="." to="." method="_on_area_entered"]
|
||||
[connection signal="area_exited" from="." to="." method="_on_area_exited"]
|
||||
|
|
|
|||
17
scenes/game/objects/objects/computer.tscn
Normal file
17
scenes/game/objects/objects/computer.tscn
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://b6drcvlucpvxi"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_ahjmy"]
|
||||
[ext_resource type="Texture2D" uid="uid://d0bdyo2e6axq2" path="res://Assets/Objects/Computer.png" id="2_3c460"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_fkh3i"]
|
||||
radius = 8.0
|
||||
|
||||
[node name="Computer" instance=ExtResource("1_ahjmy")]
|
||||
value = 100
|
||||
weight = 40
|
||||
|
||||
[node name="CollisionShape2D" parent="." index="0"]
|
||||
shape = SubResource("CircleShape2D_fkh3i")
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
texture = ExtResource("2_3c460")
|
||||
10
scenes/game/objects/objects/controller.tscn
Normal file
10
scenes/game/objects/objects/controller.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://dvpc4jiifu08u"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_2gi3p"]
|
||||
[ext_resource type="Texture2D" uid="uid://4qj6kf6qfwhv" path="res://Assets/Objects/Controller.png" id="2_agabt"]
|
||||
|
||||
[node name="Controller" instance=ExtResource("1_2gi3p")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_agabt")
|
||||
10
scenes/game/objects/objects/food_tin_can.tscn
Normal file
10
scenes/game/objects/objects/food_tin_can.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://c2p2latnc2jof"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_5c6qq"]
|
||||
[ext_resource type="Texture2D" uid="uid://br853cx0laqjr" path="res://Assets/Objects/FoodTinCan.png" id="2_ywu5t"]
|
||||
|
||||
[node name="FoodTinCan" instance=ExtResource("1_5c6qq")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_ywu5t")
|
||||
12
scenes/game/objects/objects/game_console.tscn
Normal file
12
scenes/game/objects/objects/game_console.tscn
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://di0048xukocpa"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_uy3sa"]
|
||||
[ext_resource type="Texture2D" uid="uid://4dcme0lv0gs3" path="res://Assets/Objects/GameConsole.png" id="2_8xb0y"]
|
||||
|
||||
[node name="GameConsole" instance=ExtResource("1_uy3sa")]
|
||||
value = 60
|
||||
weight = 30
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_8xb0y")
|
||||
18
scenes/game/objects/objects/gold_bar.tscn
Normal file
18
scenes/game/objects/objects/gold_bar.tscn
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://cox2h4fjawq0t"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_iouty"]
|
||||
[ext_resource type="Texture2D" uid="uid://b5no68c7akp00" path="res://Assets/Objects/GoldBar.png" id="2_q4tnr"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_772ct"]
|
||||
radius = 8.0
|
||||
|
||||
[node name="GoldBar" instance=ExtResource("1_iouty")]
|
||||
value = 800
|
||||
weight = 50
|
||||
|
||||
[node name="CollisionShape2D" parent="." index="0"]
|
||||
shape = SubResource("CircleShape2D_772ct")
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -8)
|
||||
texture = ExtResource("2_q4tnr")
|
||||
10
scenes/game/objects/objects/hammer.tscn
Normal file
10
scenes/game/objects/objects/hammer.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://b7aqeqc4i4aw4"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_x0fak"]
|
||||
[ext_resource type="Texture2D" uid="uid://brbshxkillo2g" path="res://Assets/Objects/Hammer.png" id="2_1akxm"]
|
||||
|
||||
[node name="Hammer" instance=ExtResource("1_x0fak")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_1akxm")
|
||||
12
scenes/game/objects/objects/helmet.tscn
Normal file
12
scenes/game/objects/objects/helmet.tscn
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://5sajq051qfa7"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_ft6b2"]
|
||||
[ext_resource type="Texture2D" uid="uid://dycry3xe2kkuv" path="res://Assets/Objects/helmet.png" id="2_afdlx"]
|
||||
|
||||
[node name="Helmet" instance=ExtResource("1_ft6b2")]
|
||||
value = 55
|
||||
weight = 10
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_afdlx")
|
||||
18
scenes/game/objects/objects/monitor.tscn
Normal file
18
scenes/game/objects/objects/monitor.tscn
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
[gd_scene load_steps=4 format=3 uid="uid://b2o3rtatwhfgn"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_8hfxh"]
|
||||
[ext_resource type="Texture2D" uid="uid://deid7map2xc4g" path="res://Assets/Objects/Monitor.png" id="2_7s1fc"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_rhwnp"]
|
||||
radius = 8.0
|
||||
|
||||
[node name="Monitor" instance=ExtResource("1_8hfxh")]
|
||||
value = 50
|
||||
weight = 10
|
||||
|
||||
[node name="CollisionShape2D" parent="." index="0"]
|
||||
shape = SubResource("CircleShape2D_rhwnp")
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_7s1fc")
|
||||
5
scenes/game/objects/objects/mystery_box.tscn
Normal file
5
scenes/game/objects/objects/mystery_box.tscn
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
[gd_scene load_steps=2 format=3 uid="uid://bhpgpfub6mqe3"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_0a370"]
|
||||
|
||||
[node name="MysteryBox" instance=ExtResource("1_0a370")]
|
||||
10
scenes/game/objects/objects/mystery_briefcase.tscn
Normal file
10
scenes/game/objects/objects/mystery_briefcase.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://cchj2ofoy1po1"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_h8wmp"]
|
||||
[ext_resource type="Texture2D" uid="uid://ddaedsbebomx5" path="res://Assets/Objects/MysteryBriefcase.png" id="2_2j5i0"]
|
||||
|
||||
[node name="MysteryBriefcase" instance=ExtResource("1_h8wmp")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_2j5i0")
|
||||
10
scenes/game/objects/objects/mystery_liquid.tscn
Normal file
10
scenes/game/objects/objects/mystery_liquid.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://cabge4sd2hqci"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_nnm1b"]
|
||||
[ext_resource type="Texture2D" uid="uid://cyjlwsdf51v8b" path="res://Assets/Objects/MyteryLiquid.png" id="2_nkcej"]
|
||||
|
||||
[node name="MysteryLiquid" instance=ExtResource("1_nnm1b")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_nkcej")
|
||||
5
scenes/game/objects/objects/mystery_remote.tscn
Normal file
5
scenes/game/objects/objects/mystery_remote.tscn
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
[gd_scene load_steps=2 format=3 uid="uid://lmstim1w7qt5"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_hg782"]
|
||||
|
||||
[node name="MysteryRemote" instance=ExtResource("1_hg782")]
|
||||
10
scenes/game/objects/objects/screwdriver.tscn
Normal file
10
scenes/game/objects/objects/screwdriver.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://cqg6c8o7mrxdq"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_uny6r"]
|
||||
[ext_resource type="Texture2D" uid="uid://dq8lm6a4tyoss" path="res://Assets/Objects/Screwdriver.png" id="2_14dxu"]
|
||||
|
||||
[node name="Screwdriver" instance=ExtResource("1_uny6r")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_14dxu")
|
||||
10
scenes/game/objects/objects/soda_can.tscn
Normal file
10
scenes/game/objects/objects/soda_can.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://dtkbn42sua6bd"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_prdq3"]
|
||||
[ext_resource type="Texture2D" uid="uid://cxpy70verc74h" path="res://Assets/Objects/SodaCan.png" id="2_1yknj"]
|
||||
|
||||
[node name="SodaCan" instance=ExtResource("1_prdq3")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_1yknj")
|
||||
10
scenes/game/objects/objects/speaker.tscn
Normal file
10
scenes/game/objects/objects/speaker.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://bg0d4g8srx3ql"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_jlw2l"]
|
||||
[ext_resource type="Texture2D" uid="uid://bmlb8b00cro1f" path="res://Assets/Objects/Speaker.png" id="2_t3xrn"]
|
||||
|
||||
[node name="Speaker" instance=ExtResource("1_jlw2l")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_t3xrn")
|
||||
10
scenes/game/objects/objects/teddy_bear.tscn
Normal file
10
scenes/game/objects/objects/teddy_bear.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://2kdpile8qbj8"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_g3qoc"]
|
||||
[ext_resource type="Texture2D" uid="uid://bwl8v34qo8pif" path="res://Assets/Objects/TeddyBear.png" id="2_xa3pj"]
|
||||
|
||||
[node name="TeddyBear" instance=ExtResource("1_g3qoc")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_xa3pj")
|
||||
10
scenes/game/objects/objects/telephone.tscn
Normal file
10
scenes/game/objects/objects/telephone.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://0sivf5pahvkp"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_wpn0g"]
|
||||
[ext_resource type="Texture2D" uid="uid://cug6xc65ak64a" path="res://Assets/Objects/Telephone.png" id="2_1w0uo"]
|
||||
|
||||
[node name="Telephone" instance=ExtResource("1_wpn0g")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_1w0uo")
|
||||
10
scenes/game/objects/objects/toolbox.tscn
Normal file
10
scenes/game/objects/objects/toolbox.tscn
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://dep5yy0j8u34g"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_fk7ja"]
|
||||
[ext_resource type="Texture2D" uid="uid://bo803pp8gtg5y" path="res://Assets/Objects/Toolbox.png" id="2_co5u1"]
|
||||
|
||||
[node name="Toolbox" instance=ExtResource("1_fk7ja")]
|
||||
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_co5u1")
|
||||
|
|
@ -1,17 +1,17 @@
|
|||
[gd_scene load_steps=3 format=3 uid="uid://41ksceqosqq2"]
|
||||
[gd_scene load_steps=4 format=3 uid="uid://41ksceqosqq2"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://dxpd1pq7v6ing" path="res://scenes/game/objects/object.tscn" id="1_fkdlr"]
|
||||
[ext_resource type="Texture2D" uid="uid://cj70dguhwi83a" path="res://Assets/Objects/Vase.png" id="2_vxdei"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_pmiic"]
|
||||
radius = 12.0
|
||||
radius = 8.0
|
||||
|
||||
[node name="Vase" instance=ExtResource("1_fkdlr")]
|
||||
light_mask = 8
|
||||
visibility_layer = 8
|
||||
y_sort_enabled = true
|
||||
|
||||
[node name="CollisionShape2D" parent="." index="0"]
|
||||
shape = SubResource("CircleShape2D_pmiic")
|
||||
|
||||
[node name="AnimatedSprite2D" parent="." index="1"]
|
||||
animation = &""
|
||||
[node name="Sprite2D" parent="." index="1"]
|
||||
position = Vector2(0, -4)
|
||||
texture = ExtResource("2_vxdei")
|
||||
Loading…
Add table
Add a link
Reference in a new issue