Added locked barriers and a new ghost enemy

This commit is contained in:
VoidTwo committed 2021-12-04 18:23:05 -06:00
1 parent fcea3cee03
commit 9101bf2f65
21 files changed
+472 -41

No files matched your search

+23
View File
@@ -0,0 +1,23 @@
extends StaticBody2D
export var alignment: String = 'V'
func _ready() -> void:
if not alignment in ['V', 'H']:
print('Silver Barrier rotation needs to be "V" or "H"')
elif alignment == 'H':
rotation_degrees = 90
return
func _on_unlock_body_entered(body: Node) -> void:
if not 'player' in body.get_groups():
return
if body.has_item('Silver Key'):
body.remove_item('Silver Key')
$Sprite.animation = 'open'
$Collision.set_deferred('disabled', true)
$Unlock.set_deferred('monitoring', false)
return
+51
View File
@@ -0,0 +1,51 @@
[gd_scene load_steps=7 format=2]
[ext_resource path="res://Sprites/Levels/Interactables/Silver_Barrier_Open.png" type="Texture" id=1]
[ext_resource path="res://Sprites/Levels/Interactables/Silver_Barrier_Closed.png" type="Texture" id=2]
[ext_resource path="res://Levels/Interactables/Silver Barrier.gd" type="Script" id=3]
[sub_resource type="SpriteFrames" id=1]
animations = [ {
"frames": [ ExtResource( 1 ) ],
"loop": true,
"name": "open",
"speed": 5.0
}, {
"frames": [ ExtResource( 2 ) ],
"loop": true,
"name": "closed",
"speed": 5.0
} ]
[sub_resource type="RectangleShape2D" id=2]
extents = Vector2( 6, 8 )
[sub_resource type="RectangleShape2D" id=3]
extents = Vector2( 12, 10 )
[node name="Silver Barrier" type="StaticBody2D"]
collision_mask = 0
script = ExtResource( 3 )
[node name="Sprite" type="AnimatedSprite" parent="."]
light_mask = 8
frames = SubResource( 1 )
animation = "closed"
[node name="Collision" type="CollisionShape2D" parent="."]
light_mask = 0
shape = SubResource( 2 )
[node name="Unlock" type="Area2D" parent="."]
light_mask = 0
collision_layer = 0
collision_mask = 2
input_pickable = false
monitorable = false
[node name="CollisionShape2D" type="CollisionShape2D" parent="Unlock"]
visible = false
light_mask = 0
shape = SubResource( 3 )
[connection signal="body_entered" from="Unlock" to="." method="_on_unlock_body_entered"]
+30 -9
View File
@@ -1,4 +1,4 @@
[gd_scene load_steps=12 format=2]
[gd_scene load_steps=14 format=2]
[ext_resource path="res://Player/Player.tscn" type="PackedScene" id=1]
[ext_resource path="res://Levels/Level 5.gd" type="Script" id=2]
@@ -8,20 +8,25 @@
[ext_resource path="res://Music/Level_5.mp3" type="AudioStream" id=6]
[ext_resource path="res://GUI/Pause Screen.tscn" type="PackedScene" id=7]
[ext_resource path="res://Resources/Level_5_Walls_Tileset.tres" type="TileSet" id=8]
[ext_resource path="res://Enemies/Glowing Ghost.tscn" type="PackedScene" id=9]
[ext_resource path="res://Enemies/Chasing Glowing Ghost.tscn" type="PackedScene" id=9]
[ext_resource path="res://Levels/Traps/Spawn Trap.tscn" type="PackedScene" id=10]
[ext_resource path="res://Levels/Interactables/Silver Key Pickup.tscn" type="PackedScene" id=11]
[ext_resource path="res://Levels/Interactables/Silver Barrier.tscn" type="PackedScene" id=12]
[ext_resource path="res://Enemies/Creepy Glowing Ghost.tscn" type="PackedScene" id=13]
[node name="Void Level" type="Node2D"]
script = ExtResource( 2 )
[node name="CanvasModulate" type="CanvasModulate" parent="."]
[node name="Darkness" type="CanvasModulate" parent="."]
color = Color( 0, 0, 0, 1 )
[node name="Floor" type="TileMap" parent="."]
self_modulate = Color( 0.627451, 0.627451, 0.627451, 1 )
tile_set = ExtResource( 4 )
cell_size = Vector2( 16, 16 )
collision_layer = 0
collision_mask = 0
occluder_light_mask = 0
format = 1
tile_data = PoolIntArray( -393225, 0, 0, -393224, 0, 1, -393223, 0, 1, -393222, 0, 1, -393221, 0, 1, -393220, 0, 1, -393219, 0, 1, -393218, 0, 1, -393217, 0, 1, -458752, 0, 1, -458751, 0, 1, -458750, 0, 1, -458749, 0, 1, -458748, 0, 1, -458747, 0, 1, -458746, 0, 1, -458745, 0, 1, -458744, 0, 1, -458743, 0, 1, -458742, 0, 1, -458741, 0, 1, -458740, 0, 1, -458739, 0, 1, -458738, 0, 1, -458737, 0, 1, -458736, 0, 1, -458735, 0, 1, -458734, 0, 1, -458733, 0, 1, -458732, 0, 1, -458731, 0, 1, -458730, 0, 1, -458729, 0, 1, -458728, 0, 1, -458727, 0, 1, -458726, 0, 1, -458725, 0, 1, -458724, 0, 1, -458723, 0, 1, -458722, 0, 1, -458721, 0, 1, -458720, 0, 1, -458719, 0, 1, -458718, 0, 1, -458717, 0, 1, -458716, 0, 2, -327689, 0, 65536, -327688, 0, 65537, -327687, 0, 65537, -327686, 0, 65537, -327685, 0, 65537, -327684, 0, 65537, -327683, 0, 65537, -327682, 0, 65537, -327681, 0, 65537, -393216, 0, 65537, -393215, 0, 65537, -393214, 0, 65537, -393213, 0, 65537, -393212, 0, 65537, -393211, 0, 65537, -393210, 0, 65537, -393209, 0, 65537, -393208, 0, 65537, -393207, 0, 65537, -393206, 0, 65537, -393205, 0, 65537, -393204, 0, 65537, -393203, 0, 65537, -393202, 0, 65537, -393201, 0, 65537, -393200, 0, 65537, -393199, 0, 65537, -393198, 0, 65537, -393197, 0, 65537, -393196, 0, 65537, -393195, 0, 65537, -393194, 0, 65537, -393193, 0, 65537, -393192, 0, 65537, -393191, 0, 65537, -393190, 0, 65537, -393189, 0, 65537, -393188, 0, 65537, -393187, 0, 65537, -393186, 0, 65537, -393185, 0, 65537, -393184, 0, 65537, -393183, 0, 65537, -393182, 0, 65537, -393181, 0, 65537, -393180, 0, 65538, -262153, 0, 65536, -262152, 0, 65537, -262151, 0, 65537, -262150, 0, 65537, -262149, 0, 65537, -262148, 0, 65537, -262147, 0, 65537, -262146, 0, 65537, -262145, 0, 65537, -327680, 0, 65537, -327679, 0, 65537, -327678, 0, 65537, -327677, 0, 65537, -327676, 0, 65537, -327675, 0, 65537, -327674, 0, 65537, -327673, 0, 65537, -327672, 0, 65537, -327671, 0, 65537, -327670, 0, 65537, -327669, 0, 65537, -327668, 0, 65537, -327667, 0, 65537, -327666, 0, 65537, -327665, 0, 65537, -327664, 0, 65537, -327663, 0, 65537, -327662, 0, 65537, -327661, 0, 65537, -327660, 0, 65537, -327659, 0, 65537, -327658, 0, 65537, -327657, 0, 65537, -327656, 0, 65537, -327655, 0, 65537, -327654, 0, 65537, -327653, 0, 65537, -327652, 0, 65537, -327651, 0, 65537, -327650, 0, 65537, -327649, 0, 65537, -327648, 0, 65537, -327647, 0, 65537, -327646, 0, 65537, -327645, 0, 65537, -327644, 0, 65538, -196617, 0, 65536, -196616, 0, 65537, -196615, 0, 65537, -196614, 0, 65537, -196613, 0, 65537, -196612, 0, 65537, -196611, 0, 65537, -196610, 0, 65537, -196609, 0, 65537, -262144, 0, 65537, -262143, 0, 65537, -262142, 0, 65537, -262141, 0, 65537, -262140, 0, 65537, -262139, 0, 65537, -262138, 0, 65537, -262137, 0, 65537, -262136, 0, 65537, -262135, 0, 65537, -262134, 0, 65537, -262133, 0, 65537, -262132, 0, 65537, -262131, 0, 65537, -262130, 0, 65537, -262129, 0, 65537, -262128, 0, 65537, -262127, 0, 65537, -262126, 0, 65537, -262125, 0, 65537, -262124, 0, 65537, -262123, 0, 65537, -262122, 0, 65537, -262121, 0, 65537, -262120, 0, 65537, -262119, 0, 65537, -262118, 0, 65537, -262117, 0, 65537, -262116, 0, 65537, -262115, 0, 65537, -262114, 0, 65537, -262113, 0, 65537, -262112, 0, 65537, -262111, 0, 65537, -262110, 0, 65537, -262109, 0, 65537, -262108, 0, 65538, -131081, 0, 65536, -131080, 0, 65537, -131079, 0, 65537, -131078, 0, 65537, -131077, 0, 65537, -131076, 0, 65537, -131075, 0, 65537, -131074, 0, 65537, -131073, 0, 65537, -196608, 0, 65537, -196607, 0, 65537, -196606, 0, 65537, -196605, 0, 65537, -196604, 0, 65537, -196603, 0, 65537, -196602, 0, 65537, -196601, 0, 65537, -196600, 0, 65537, -196599, 0, 65537, -196598, 0, 65537, -196597, 0, 65537, -196596, 0, 65537, -196595, 0, 65537, -196594, 0, 65537, -196593, 0, 65537, -196592, 0, 65537, -196591, 0, 65537, -196590, 0, 65537, -196589, 0, 65537, -196588, 0, 65537, -196587, 0, 65537, -196586, 0, 65537, -196585, 0, 65537, -196584, 0, 65537, -196583, 0, 65537, -196582, 0, 65537, -196581, 0, 65537, -196580, 0, 65537, -196579, 0, 65537, -196578, 0, 65537, -196577, 0, 65537, -196576, 0, 65537, -196575, 0, 65537, -196574, 0, 65537, -196573, 0, 65537, -196572, 0, 65538, -65545, 0, 65536, -65544, 0, 65537, -65543, 0, 65537, -65542, 0, 65537, -65541, 0, 65537, -65540, 0, 65537, -65539, 0, 65537, -65538, 0, 65537, -65537, 0, 65537, -131072, 0, 65537, -131071, 0, 65537, -131070, 0, 65537, -131069, 0, 65537, -131068, 0, 65537, -131067, 0, 65537, -131066, 0, 65537, -131065, 0, 65537, -131064, 0, 65537, -131063, 0, 65537, -131062, 0, 65537, -131061, 0, 65537, -131060, 0, 65537, -131059, 0, 65537, -131058, 0, 65537, -131057, 0, 65537, -131056, 0, 65537, -131055, 0, 65537, -131054, 0, 65537, -131053, 0, 65537, -131052, 0, 65537, -131051, 0, 65537, -131050, 0, 65537, -131049, 0, 65537, -131048, 0, 65537, -131047, 0, 65537, -131046, 0, 65537, -131045, 0, 65537, -131044, 0, 65537, -131043, 0, 65537, -131042, 0, 65537, -131041, 0, 65537, -131040, 0, 65537Line truncated
@@ -29,43 +34,59 @@ tile_data = PoolIntArray( -393225, 0, 0, -393224, 0, 1, -393223, 0, 1, -393222,
light_mask = 8
tile_set = ExtResource( 8 )
cell_size = Vector2( 16, 16 )
collision_mask = 0
format = 1
tile_data = PoolIntArray( -196589, 0, 0, -196588, 0, 1, -196587, 0, 1, -196586, 0, 1, -196585, 0, 1, -196584, 0, 1, -196583, 0, 2, -131055, 0, 0, -131054, 0, 1, -131053, 0, 131078, -131052, 0, 65541, -131051, 0, 131073, -131050, 0, 131073, -131049, 0, 131073, -131048, 0, 65542, -131047, 0, 65538, -65524, 0, 0, -65523, 0, 1, -65522, 0, 1, -65521, 0, 1, -65520, 0, 1, -65519, 0, 65545, -65518, 0, 131073, -65517, 0, 131073, -65516, 0, 131074, -65512, 0, 65536, -65511, 0, 65538, 12, 0, 65536, 13, 0, 65541, 14, 0, 131073, 15, 0, 131073, 16, 0, 131073, 17, 0, 131074, 24, 0, 65536, 25, 0, 65538, 65548, 0, 65536, 65549, 0, 65538, 65560, 0, 65536, 65561, 0, 65538, 131078, 0, 0, 131079, 0, 1, 131080, 0, 1, 131081, 0, 1, 131082, 0, 1, 131083, 0, 1, 131084, 0, 131078, 131085, 0, 65538, 131089, 0, 3, 131096, 0, 65536, 131097, 0, 65538, 196614, 0, 65536, 196615, 0, 65541, 196616, 0, 131073, 196617, 0, 131073, 196618, 0, 131073, 196619, 0, 131073, 196620, 0, 65542, 196621, 0, 65538, 196625, 0, 65539, 196632, 0, 65536, 196633, 0, 65538, 262150, 0, 65536, 262151, 0, 65538, 262156, 0, 65536, 262157, 0, 65538, 262161, 0, 65539, 262163, 0, 0, 262164, 0, 2, 262167, 0, 0, 262168, 0, 131078, 262169, 0, 65538, 327686, 0, 65536, 327687, 0, 65538, 327692, 0, 65536, 327693, 0, 65538, 327696, 0, 4, 327697, 0, 196615, 327699, 0, 131072, 327700, 0, 65543, 327703, 0, 65536, 327704, 0, 65541, 327705, 0, 131074, 393222, 0, 65536, 393223, 0, 65538, 393228, 0, 65536, 393229, 0, 131077, 393230, 0, 5, 393231, 0, 196609, 393232, 0, 196615, 393236, 0, 131075, 393239, 0, 65536, 393240, 0, 65538, 458758, 0, 131072, 458759, 0, 131074, 458761, 0, 0, 458762, 0, 2, 458764, 0, 131072, 458765, 0, 131073, 458766, 0, 131074, 458774, 0, 0, 458775, 0, 131078, 458776, 0, 65538, 524297, 0, 65536, 524298, 0, 65538, 524309, 0, 0, 524310, 0, 131078, 524311, 0, 65541, 524312, 0, 131074, 589833, 0, 65536, 589834, 0, 131077, 589835, 0, 1, 589836, 0, 1, 589837, 0, 1, 589838, 0, 1, 589839, 0, 1, 589840, 0, 1, 589841, 0, 1, 589842, 0, 1, 589843, 0, 1, 589844, 0, 1, 589845, 0, 131078, 589846, 0, 65541, 589847, 0, 131074, 655369, 0, 131072, 655370, 0, 131073, 655371, 0, 131073, 655372, 0, 131073, 655373, 0, 131073, 655374, 0, 131073, 655375, 0, 131073, 655376, 0, 131073, 655377, 0, 131073, 655378, 0, 131073, 655379, 0, 131073, 655380, 0, 131073, 655381, 0, 131073, 655382, 0, 131074 )
tile_data = PoolIntArray( -196589, 0, 0, -196588, 0, 1, -196587, 0, 1, -196586, 0, 1, -196585, 0, 1, -196584, 0, 1, -196583, 0, 2, -131055, 0, 0, -131054, 0, 1, -131053, 0, 131078, -131052, 0, 65541, -131051, 0, 131073, -131050, 0, 131073, -131049, 0, 131073, -131048, 0, 65542, -131047, 0, 65538, -65524, 0, 0, -65523, 0, 1, -65522, 0, 1, -65521, 0, 1, -65520, 0, 1, -65519, 0, 65545, -65518, 0, 131073, -65517, 0, 131073, -65516, 0, 131074, -65512, 0, 65536, -65511, 0, 65538, 12, 0, 65536, 13, 0, 65541, 14, 0, 131073, 15, 0, 131073, 16, 0, 131073, 17, 0, 131074, 24, 0, 65536, 25, 0, 65538, 65548, 0, 65536, 65549, 0, 65538, 65560, 0, 65536, 65561, 0, 65538, 131078, 0, 0, 131079, 0, 1, 131080, 0, 1, 131081, 0, 1, 131082, 0, 1, 131083, 0, 1, 131084, 0, 131078, 131085, 0, 65538, 131089, 0, 3, 131096, 0, 65536, 131097, 0, 65538, 196614, 0, 65536, 196615, 0, 65541, 196616, 0, 131073, 196617, 0, 131073, 196618, 0, 131073, 196619, 0, 131073, 196620, 0, 65542, 196621, 0, 65538, 196625, 0, 65539, 196632, 0, 65536, 196633, 0, 65538, 262150, 0, 65536, 262151, 0, 65538, 262156, 0, 65536, 262157, 0, 65538, 262161, 0, 65539, 262163, 0, 0, 262164, 0, 2, 262167, 0, 0, 262168, 0, 131078, 262169, 0, 65538, 327686, 0, 65536, 327687, 0, 65538, 327692, 0, 65536, 327693, 0, 65538, 327696, 0, 4, 327697, 0, 196615, 327699, 0, 131072, 327700, 0, 65543, 327703, 0, 65536, 327704, 0, 65541, 327705, 0, 131074, 393222, 0, 65536, 393223, 0, 65538, 393228, 0, 65536, 393229, 0, 131077, 393230, 0, 5, 393231, 0, 196609, 393232, 0, 196615, 393236, 0, 131075, 393239, 0, 65536, 393240, 0, 65538, 458755, 0, 0, 458756, 0, 2, 458758, 0, 65536, 458759, 0, 65538, 458761, 0, 0, 458762, 0, 2, 458764, 0, 131072, 458765, 0, 131073, 458766, 0, 131074, 458774, 0, 0, 458775, 0, 131078, 458776, 0, 65538, 524291, 0, 65536, 524292, 0, 65538, 524294, 0, 65536, 524295, 0, 65538, 524297, 0, 65536, 524298, 0, 65538, 524309, 0, 0, 524310, 0, 131078, 524311, 0, 65541, 524312, 0, 131074, 589827, 0, 65536, 589828, 0, 65538, 589830, 0, 131072, 589831, 0, 131074, 589833, 0, 65536, 589834, 0, 131077, 589835, 0, 1, 589836, 0, 1, 589837, 0, 1, 589838, 0, 1, 589839, 0, 1, 589840, 0, 1, 589841, 0, 1, 589842, 0, 1, 589843, 0, 1, 589844, 0, 1, 589845, 0, 131078, 589846, 0, 65541, 589847, 0, 131074, 655363, 0, 65536, 655364, 0, 65538, 655369, 0, 65536, 655370, 0, 65541, 655371, 0, 131073, 655372, 0, 131073, 655373, 0, 131073, 655374, 0, 131073, 655375, 0, 131073, 655376, 0, 131073, 655377, 0, 131073, 655378, 0, 131073, 655379, 0, 131073, 655380, 0, 131073, 655381, 0, 131073, 655382, 0, 131074, 720899, 0, 65536, 720900, 0, 65538, 720905, 0, 65536, 720906, 0, 65538, 786435, 0, 65536, 786436, 0, 65538, 786441, 0, 65536, 786442, 0, 65538, 851971, 0, 65536, 851972, 0, 65538, 851977, 0, 65536, 851978, 0, 65538, 917507, 0, 65536, 917508, 0, 65538, 917513, 0, 65536, 917514, 0, 65538, 983043, 0, 65536, 983044, 0, 131077, 983045, 0, 1, 983046, 0, 1, 983047, 0, 1, 983048, 0, 1, 983049, 0, 131078, 983050, 0, 65538, 1048579, 0, 131072, 1048580, 0, 131073, 1048581, 0, 131073, 1048582, 0, 131073, 1048583, 0, 131073, 1048584, 0, 131073, 1048585, 0, 131073, 1048586, 0, 131074 )
[node name="YSort" type="YSort" parent="."]
[node name="Player" parent="YSort" instance=ExtResource( 1 )]
position = Vector2( 160, 90 )
[node name="Camera2D" type="Camera2D" parent="YSort/Player"]
[node name="Camera" type="Camera2D" parent="YSort/Player"]
current = true
[node name="Light2D" type="Light2D" parent="YSort/Player"]
[node name="Light" type="Light2D" parent="YSort/Player"]
texture = ExtResource( 5 )
range_item_cull_mask = 15
shadow_enabled = true
[node name="Enemies" type="YSort" parent="YSort"]
[node name="Glowing Ghost 0" parent="YSort/Enemies" instance=ExtResource( 9 )]
[node name="Chasing Glowing Ghost 0" parent="YSort/Enemies" instance=ExtResource( 9 )]
position = Vector2( 281, 109 )
[node name="Glowing Ghost 1" parent="YSort/Enemies" instance=ExtResource( 9 )]
[node name="Chasing Glowing Ghost 1" parent="YSort/Enemies" instance=ExtResource( 9 )]
position = Vector2( 328.5, 20 )
[node name="Creepy Glowing Ghost 00" parent="YSort/Enemies" instance=ExtResource( 13 )]
position = Vector2( 310, 40 )
[node name="Creepy Glowing Ghost 01" parent="YSort/Enemies" instance=ExtResource( 13 )]
position = Vector2( 90, 175 )
[node name="Creepy Glowing Ghost 02" parent="YSort/Enemies" instance=ExtResource( 13 )]
position = Vector2( 100, 220 )
[node name="Interactables" type="Node2D" parent="."]
[node name="Silver Key Pickup" parent="Interactables" instance=ExtResource( 11 )]
position = Vector2( 240, 80 )
[node name="Silver Barrier" parent="Interactables" instance=ExtResource( 12 )]
position = Vector2( 136, 120 )
alignment = "H"
[node name="Traps" type="Node2D" parent="."]
[node name="Spawn Trap" parent="Traps" instance=ExtResource( 10 )]
position = Vector2( 256, 16 )
enemy_path = "res://Enemies/Glowing Ghost.tscn"
enemy_path = "res://Enemies/Chasing Glowing Ghost.tscn"
relative_x_tiles = -1
relative_y_tiles = 2
[node name="Projectiles" type="Node2D" parent="."]
[node name="HUD" parent="." instance=ExtResource( 3 )]
[node name="Pause Screen" parent="." instance=ExtResource( 7 )]