Skip to content

Commit

Permalink
added rifle
Browse files Browse the repository at this point in the history
  • Loading branch information
Matvey Sivachinski authored and Matvey Sivachinski committed Feb 5, 2024
1 parent 108cb3a commit 0e27737
Show file tree
Hide file tree
Showing 8 changed files with 71 additions and 5 deletions.
13 changes: 13 additions & 0 deletions addons/pronto/behaviors/CollisionBehavior.gd
Original file line number Diff line number Diff line change
Expand Up @@ -110,3 +110,16 @@ func _on_area_2d_body_entered(body):
#var timer = get_parent().get_parent().get_parent().find_child("Timer")
#timer.set_one_shot(true)
#timer.start(3)


func _on_rifle_body_entered(body):
var player2 = get_tree().get_nodes_in_group("player")[1]
player2.timeCapsule = true
get_tree().get_nodes_in_group("rifle")[0].queue_free()

#var labels = get_tree().get_nodes_in_group("label")
#for label in labels:
#label.show()
#await get_tree().create_timer(3).timeout
#for label in labels:
#label.hide()
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://k6c8bjj1vta0"
path="res://.godot/imported/alienRifle.png-4b7d10c9a7cc5b32df1b3a375d490a1c.ctex"
metadata={
"vram_texture": false
}

[deps]

source_file="res://prototypes/game-shadows-of-surveillance/assets/alienRifle.png"
dest_files=["res://.godot/imported/alienRifle.png-4b7d10c9a7cc5b32df1b3a375d490a1c.ctex"]

[params]

compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
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/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
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[ext_resource type="Script" path="res://prototypes/game-shadows-of-surveillance/scripts/player2.gd" id="1_dxuki"]
[ext_resource type="Texture2D" uid="uid://dx884i5e2o8ql" path="res://prototypes/game-shadows-of-surveillance/characters/Pink Man/Idle (32x32).png" id="2_3wlyp"]
[ext_resource type="Script" path="res://prototypes/game-shadows-of-surveillance/characters/PlatformerControllerPlayer2.gd" id="3_kwpqc"]
[ext_resource type="Texture2D" uid="uid://ca3jyudumrgbl" path="res://LightSprite.png" id="4_u5jrv"]
[ext_resource type="Texture2D" uid="uid://ch6w3mr4w7ueu" path="res://LightSprite.png" id="4_u5jrv"]
[ext_resource type="Script" path="res://addons/pronto/behaviors/HealthBarBehavior.gd" id="5_oymb4"]
[ext_resource type="Script" path="res://addons/pronto/helpers/ConnectionScript.gd" id="6_82em1"]
[ext_resource type="Script" path="res://addons/pronto/helpers/Connection.gd" id="7_dkbr3"]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
"description": "You are a brilliant scientist who just discovered time travel. Unfortunately, during your first test, something goes wrong and your mind is split into two parts, one part travels to the future and one is stuck in the present. \nIn this coop split screen game, your goal is to somehow recombine the two parts of your mind. But be careful: In the future, some things have changed...",
"time": "2024-02-05",
"title": "Shadows of Surveillance"
}
}
22 changes: 21 additions & 1 deletion prototypes/game-shadows-of-surveillance/levels/level.tscn
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[gd_scene load_steps=8 format=3 uid="uid://dyvtu758xr2so"]
[gd_scene load_steps=10 format=3 uid="uid://dyvtu758xr2so"]

[ext_resource type="Texture2D" uid="uid://bhjxc5s34c3cu" path="res://prototypes/game-shadows-of-surveillance/assets/10.png" id="1_elldh"]
[ext_resource type="Script" path="res://prototypes/game-shadows-of-surveillance/scripts/LightSwitch.gd" id="2_4klox"]
Expand All @@ -7,6 +7,10 @@
[ext_resource type="PackedScene" uid="uid://c5c24526dtufn" path="res://prototypes/game-shadows-of-surveillance/characters/player1.tscn" id="3_x2hlg"]
[ext_resource type="Texture2D" uid="uid://dn87bxukebfvu" path="res://icon.svg" id="4_rqfal"]
[ext_resource type="Script" path="res://addons/pronto/behaviors/CollisionBehavior.gd" id="6_i4obq"]
[ext_resource type="Texture2D" uid="uid://k6c8bjj1vta0" path="res://prototypes/game-shadows-of-surveillance/assets/alienRifle.png" id="8_rsrys"]

[sub_resource type="RectangleShape2D" id="RectangleShape2D_whbw0"]
size = Vector2(11, 29)

[node name="Level" type="Node2D"]

Expand Down Expand Up @@ -39,9 +43,25 @@ position = Vector2(1.74846e-05, -200)
script = ExtResource("6_i4obq")
limit_to_group = "button"

[node name="rifleBehavior" type="Node2D" parent="Player1"]
position = Vector2(141.421, -141.421)
script = ExtResource("6_i4obq")

[node name="TileMap" type="TileMap" parent="."]
tile_set = ExtResource("3_r5ys7")
format = 2
layer_0/tile_data = PackedInt32Array(2424834, 524288, 6, 2424835, 589824, 6, 2424836, 589824, 6, 2424837, 589824, 6, 2424838, 589824, 6, 2424839, 589824, 6, 2424840, 589824, 6, 2424841, 589824, 6, 2424842, 589824, 6, 2424843, 589824, 6, 2424844, 589824, 6, 2424845, 589824, 6, 2424846, 589824, 6, 2424847, 589824, 6, 2424848, 589824, 6, 2424849, 589824, 6, 2490370, 524288, 7, 2555906, 524288, 7, 2621442, 524288, 7, 2490371, 589824, 7, 2555907, 589824, 7, 2621443, 589824, 7, 2621444, 589824, 7, 2621445, 589824, 7, 2621446, 589824, 7, 2621447, 589824, 7, 2621448, 589824, 7, 2621449, 589824, 7, 2621450, 589824, 7, 2621451, 589824, 7, 2621452, 589824, 7, 2621453, 589824, 7, 2621454, 589824, 7, 2621455, 589824, 7, 2621456, 589824, 7, 2621457, 589824, 7, 2621458, 589824, 7, 2555922, 589824, 7, 2490386, 589824, 7, 2490385, 589824, 7, 2490384, 589824, 7, 2490383, 589824, 7, 2490382, 589824, 7, 2490381, 589824, 7, 2490380, 589824, 7, 2490379, 589824, 7, 2490378, 589824, 7, 2490377, 589824, 7, 2490376, 589824, 7, 2490375, 589824, 7, 2490374, 589824, 7, 2490373, 589824, 7, 2490372, 589824, 7, 2555908, 589824, 7, 2555909, 589824, 7, 2555910, 589824, 7, 2555911, 589824, 7, 2555912, 589824, 7, 2555913, 589824, 7, 2555914, 589824, 7, 2555915, 589824, 7, 2555916, 589824, 7, 2555917, 589824, 7, 2555918, 589824, 7, 2555919, 589824, 7, 2555920, 589824, 7, 2555921, 589824, 7, 2424850, 589824, 6, 2490387, 655360, 7, 2424851, 655360, 6, 2555923, 655360, 7, 2621459, 655360, 7, 2228250, 589824, 6, 2228251, 589824, 6, 2228252, 589824, 6, 2228253, 589824, 6, 2228254, 589824, 6, 2228255, 589824, 6, 2228256, 589824, 6, 2228257, 589824, 6, 2228258, 589824, 6, 2228259, 589824, 6, 2228260, 589824, 6, 2228261, 589824, 6, 2228262, 589824, 6, 2228263, 589824, 6, 2228264, 589824, 6, 2228249, 524288, 6, 2293785, 524288, 7, 2359321, 524288, 7, 2424857, 524288, 7, 2490393, 524288, 7, 2555929, 524288, 7, 2621465, 524288, 7, 2293786, 589824, 7, 2359322, 589824, 7, 2424858, 589824, 7, 2490394, 589824, 7, 2555930, 589824, 7, 2621466, 589824, 7, 2293787, 589824, 7, 2293788, 589824, 7, 2293789, 589824, 7, 2293790, 589824, 7, 2293791, 589824, 7, 2293792, 589824, 7, 2293793, 589824, 7, 2293794, 589824, 7, 2293795, 589824, 7, 2293796, 589824, 7, 2293797, 589824, 7, 2293798, 589824, 7, 2293799, 589824, 7, 2293800, 589824, 7, 2359336, 589824, 7, 2424872, 589824, 7, 2490408, 589824, 7, 2555944, 589824, 7, 2621480, 589824, 7, 2621479, 589824, 7, 2621478, 589824, 7, 2621477, 589824, 7, 2621476, 589824, 7, 2621475, 589824, 7, 2621474, 589824, 7, 2621473, 589824, 7, 2621472, 589824, 7, 2621471, 589824, 7, 2621470, 589824, 7, 2621469, 589824, 7, 2621468, 589824, 7, 2621467, 589824, 7, 2555931, 589824, 7, 2490396, 589824, 7, 2424859, 589824, 7, 2490395, 589824, 7, 2359323, 589824, 7, 2424860, 589824, 7, 2555933, 589824, 7, 2490397, 589824, 7, 2424861, 589824, 7, 2359325, 589824, 7, 2359324, 589824, 7, 2555932, 589824, 7, 2359327, 589824, 7, 2424863, 589824, 7, 2490399, 589824, 7, 2555935, 589824, 7, 2555934, 589824, 7, 2490398, 589824, 7, 2424862, 589824, 7, 2359326, 589824, 7, 2359328, 589824, 7, 2424864, 589824, 7, 2490400, 589824, 7, 2555936, 589824, 7, 2490401, 589824, 7, 2424865, 589824, 7, 2359329, 589824, 7, 2555937, 589824, 7, 2555938, 589824, 7, 2490402, 589824, 7, 2424866, 589824, 7, 2359330, 589824, 7, 2490403, 589824, 7, 2424867, 589824, 7, 2359331, 589824, 7, 2555939, 589824, 7, 2555940, 589824, 7, 2490404, 589824, 7, 2424868, 589824, 7, 2359332, 589824, 7, 2555941, 589824, 7, 2490405, 589824, 7, 2424869, 589824, 7, 2359333, 589824, 7, 2555942, 589824, 7, 2490406, 589824, 7, 2424870, 589824, 7, 2359334, 589824, 7, 2555943, 589824, 7, 2490407, 589824, 7, 2424871, 589824, 7, 2359335, 589824, 7, 2228265, 655360, 6, 2293801, 655360, 7, 2359337, 655360, 7, 2424873, 655360, 7, 2490409, 655360, 7, 2555945, 655360, 7, 2621481, 655360, 7, 2686978, 524288, 8, 2686995, 655360, 8, 2686979, 589824, 8, 2686980, 589824, 8, 2686981, 589824, 8, 2686982, 589824, 8, 2686983, 589824, 8, 2686984, 589824, 8, 2686985, 589824, 8, 2686986, 589824, 8, 2686987, 589824, 8, 2686988, 589824, 8, 2686989, 589824, 8, 2686990, 589824, 8, 2686991, 589824, 8, 2686992, 589824, 8, 2686993, 589824, 8, 2686994, 589824, 8, 2687001, 524288, 8, 2687002, 589824, 8, 2687003, 589824, 8, 2687004, 589824, 8, 2687005, 589824, 8, 2687006, 589824, 8, 2687007, 589824, 8, 2687008, 589824, 8, 2687009, 589824, 8, 2687010, 589824, 8, 2687011, 589824, 8, 2687012, 589824, 8, 2687013, 589824, 8, 2687014, 589824, 8, 2687015, 589824, 8, 2687016, 589824, 8, 2687017, 655360, 8)

[node name="Rifle" type="Area2D" parent="." groups=["rifle"]]
position = Vector2(614, 525)
rotation = 1.56983

[node name="Sprite2D" type="Sprite2D" parent="Rifle"]
texture = ExtResource("8_rsrys")

[node name="CollisionShape2D" type="CollisionShape2D" parent="Rifle"]
position = Vector2(1.5, -0.5)
shape = SubResource("RectangleShape2D_whbw0")

[connection signal="body_entered" from="LightSwitch" to="Player1/LightSwitchBehavior" method="_on_area_2d_body_entered"]
[connection signal="body_entered" from="Rifle" to="Player1/rifleBehavior" method="_on_rifle_body_entered"]
3 changes: 1 addition & 2 deletions prototypes/game-shadows-of-surveillance/levels/level2.tscn
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[gd_scene load_steps=6 format=3 uid="uid://nrfvxvrpbboq"]

[ext_resource type="Texture2D" uid="uid://ej3g6agmjf0x" path="res://prototypes/game-shadows-of-surveillance/assets/6.png" id="1_j6sv0"]
[ext_resource type="PackedScene" path="res://Tilemap.tscn" id="2_llo4g"]
[ext_resource type="PackedScene" uid="uid://4j52c4ucysq5" path="res://Tilemap.tscn" id="2_llo4g"]
[ext_resource type="TileSet" uid="uid://dp12gfueqor5q" path="res://tileset.tres" id="3_ko4tt"]
[ext_resource type="PackedScene" uid="uid://ds24wbrnr7tta" path="res://prototypes/game-shadows-of-surveillance/characters/drone.tscn" id="4_m1bym"]
[ext_resource type="PackedScene" uid="uid://dxp4mlvvs0g2" path="res://prototypes/game-shadows-of-surveillance/characters/player2.tscn" id="5_a7n2h"]
Expand All @@ -13,7 +13,6 @@ position = Vector2(578, 319)
scale = Vector2(3.5, 3.5)
texture = ExtResource("1_j6sv0")

[node name="CanvasModulate" type="CanvasModulate" parent="6" groups=["dark"]]
[node name="Background_2" type="Sprite2D" parent="Background"]
position = Vector2(576, 0)
texture = ExtResource("1_j6sv0")
Expand Down
Binary file modified prototypes/game-shadows-of-surveillance/levels/thumbnail.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 0e27737

Please sign in to comment.