├── .gitignore ├── Globals.gd ├── LICENSE-art ├── LICENSE-code ├── README.md ├── default_bus_layout.tres ├── default_env.tres ├── enemies ├── BigPirate.gd ├── BigPirate.tscn ├── Chaser.gd ├── Chaser.tscn ├── Explosion.tscn ├── SmallPirate.gd ├── SmallPirate.tscn ├── SpikyBall.gd ├── SpikyBall.tscn ├── big_dead.wav ├── big_dead.wav.import ├── big_hurt.wav ├── big_hurt.wav.import ├── enemies.png ├── enemies.png.import ├── near-miss.ogg ├── near-miss.ogg.import ├── shoot.wav ├── shoot.wav.import ├── small_dead.wav └── small_dead.wav.import ├── export_presets.cfg ├── icon.ico ├── icon.png ├── icon.png.import ├── items ├── Coin.gd ├── Coin.tscn ├── LifeBarrel.gd ├── LifeBarrel.tscn ├── PlusScore.gd ├── PlusScore.tscn ├── SuperCannon.gd ├── SuperCannon.tscn ├── SuperPaddles.gd ├── SuperPaddles.tscn ├── coin.wav ├── coin.wav.import ├── dropped_item.wav.import ├── heal.wav.import ├── item_drop.wav ├── item_drop.wav.import ├── plus100.png ├── plus100.png.import ├── plus2000.png ├── plus2000.png.import ├── plus500.png ├── plus500.png.import ├── plus5000.png ├── plus5000.png.import ├── powerup1.wav ├── powerup1.wav.import ├── powerup2.wav ├── powerup2.wav.import ├── powerups.png └── powerups.png.import ├── lighthouse ├── LightHouse.gd ├── LightHouse.tscn ├── beam.png ├── beam.png.import ├── flame.wav ├── flame.wav.import ├── lighthouse.png ├── lighthouse.png.import ├── respawn.wav └── respawn.wav.import ├── menu ├── CustomButton.tscn ├── ScoreDisplay.gd ├── ScoreDisplay.tscn ├── Settings.gd ├── Settings.tscn ├── TitleScreen.gd ├── TitleScreen.tscn ├── backgrounds.png ├── backgrounds.png.import ├── button.png ├── button.png.import ├── cutscenes │ ├── Intro.gd │ ├── Intro.tscn │ ├── Outro.gd │ ├── Outro.tscn │ ├── accept.wav │ └── accept.wav.import ├── font │ ├── Volter__28Goldfish_29.ttf │ └── main_font.tres ├── gameover.png ├── gameover.png.import ├── numbers.png ├── numbers.png.import ├── score.png ├── score.png.import ├── title.png └── title.png.import ├── music ├── intro.mmpz ├── intro.ogg ├── intro.ogg.import ├── level.mmpz ├── level.ogg ├── level.ogg.import ├── outro.mmpz ├── outro.ogg ├── outro.ogg.import ├── title.mmpz ├── title.ogg └── title.ogg.import ├── player ├── Player.gd ├── Player.tscn ├── PlayerBullet.gd ├── PlayerBullet.tscn ├── cannon.wav ├── cannon.wav.import ├── cooldown_bar │ ├── background_flat_box.tres │ └── recharging_flat_box.tres ├── hurt.wav ├── hurt.wav.import ├── player.png └── player.png.import ├── project.godot ├── splashscreen.png ├── splashscreen.png.import └── world ├── Current.gd ├── Current.tscn ├── Sea.shader ├── World.gd ├── World.tscn ├── current.png ├── current.png.import ├── light.png ├── light.png.import ├── sea_background.png └── sea_background.png.import /.gitignore: -------------------------------------------------------------------------------- 1 | .import/ 2 | -------------------------------------------------------------------------------- /Globals.gd: -------------------------------------------------------------------------------- 1 | extends Node 2 | 3 | var score := 0 setget set_score 4 | var high_score := 0 5 | var message := "Mouse: move Left click: shoot" setget set_message 6 | 7 | func _ready(): 8 | OS.window_size = 4*Vector2(256, 144) 9 | OS.center_window() 10 | 11 | func set_message(msg: String): 12 | message = msg 13 | yield(get_tree().create_timer(5.0), "timeout") 14 | while message != "": 15 | yield(get_tree().create_timer(0.1), "timeout") 16 | message = message.substr(1) 17 | 18 | func set_score(new_score: int): 19 | if new_score >= high_score: 20 | if score < high_score and high_score > 0: 21 | set_message("New record! Previous highest score was " + str(high_score)) 22 | high_score = new_score 23 | score = new_score 24 | -------------------------------------------------------------------------------- /LICENSE-art: -------------------------------------------------------------------------------- 1 | This work is licensed under a Creative Commons Attribution 4.0 International License. 2 | 3 | More info at https://creativecommons.org/licenses/by/4.0/ 4 | -------------------------------------------------------------------------------- /LICENSE-code: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright 2020 Paul BLANLOEIL (https://cagibi.itch.io) 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | 7 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Lighthouse Keeper and the Shadow Pirates 2 | 3 | As darkness falls, pirates try to turn off the flame on your lighthouse. 4 | Can you keep it alive? 5 | 6 | This game was made in 2 days for the Ludum Dare #46 compo, with Godot Engine 3.2. 7 | 8 | ### Controls 9 | 10 | - Mouse cursor: move 11 | - Left click: shoot bullets 12 | - If you aim through the lighthouse, your bullets are more powerful but this damages the lighthouse a bit. 13 | - Esc.: pause menu 14 | 15 | Gamepad and arrow keys are also supported. 16 | 17 | -------------------------------------------------------------------------------- /default_bus_layout.tres: -------------------------------------------------------------------------------- 1 | [gd_resource type="AudioBusLayout" format=2] 2 | 3 | [resource] 4 | bus/1/name = "sfx" 5 | bus/1/solo = false 6 | bus/1/mute = false 7 | bus/1/bypass_fx = false 8 | bus/1/volume_db = 0.0 9 | bus/1/send = "Master" 10 | bus/2/name = "music" 11 | bus/2/solo = false 12 | bus/2/mute = false 13 | bus/2/bypass_fx = false 14 | bus/2/volume_db = 0.0 15 | bus/2/send = "Master" 16 | -------------------------------------------------------------------------------- /default_env.tres: -------------------------------------------------------------------------------- 1 | [gd_resource type="Environment" load_steps=2 format=2] 2 | 3 | [sub_resource type="ProceduralSky" id=1] 4 | 5 | [resource] 6 | background_mode = 2 7 | background_sky = SubResource( 1 ) 8 | -------------------------------------------------------------------------------- /enemies/BigPirate.gd: -------------------------------------------------------------------------------- 1 | extends "res://enemies/SmallPirate.gd" 2 | 3 | signal shoot(position, bullet) 4 | var hp := 3 5 | var bullet := preload("res://enemies/SpikyBall.tscn") 6 | 7 | func hurt(): 8 | hp -= 1 9 | if hp > 0: 10 | $Hurt.play() 11 | $Sprite/AnimationPlayer.play("hurt") 12 | else: 13 | $ShootTimer.stop() 14 | .hurt() 15 | 16 | func _on_ShootTimer_timeout(): 17 | $Shoot.play() 18 | emit_signal("shoot", global_position, bullet) 19 | 20 | 21 | func _on_AnimationPlayer_animation_finished(anim_name: String): 22 | if anim_name == "hurt": 23 | $Sprite/AnimationPlayer.play("default") 24 | -------------------------------------------------------------------------------- /enemies/BigPirate.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=9 format=2] 2 | 3 | [ext_resource path="res://enemies/SmallPirate.tscn" type="PackedScene" id=2] 4 | [ext_resource path="res://enemies/big_dead.wav" type="AudioStream" id=3] 5 | [ext_resource path="res://enemies/BigPirate.gd" type="Script" id=4] 6 | [ext_resource path="res://enemies/shoot.wav" type="AudioStream" id=5] 7 | [ext_resource path="res://enemies/big_hurt.wav" type="AudioStream" id=6] 8 | 9 | [sub_resource type="Animation" id=1] 10 | resource_name = "hurt" 11 | length = 0.5 12 | tracks/0/type = "value" 13 | tracks/0/path = NodePath(".:scale") 14 | tracks/0/interp = 1 15 | tracks/0/loop_wrap = true 16 | tracks/0/imported = false 17 | tracks/0/enabled = true 18 | tracks/0/keys = { 19 | "times": PoolRealArray( 0, 0.1, 0.2, 0.3, 0.4 ), 20 | "transitions": PoolRealArray( 1, 1, 1, 1, 1 ), 21 | "update": 0, 22 | "values": [ Vector2( 2, 0.5 ), Vector2( 0.75, 1.5 ), Vector2( 1.2, 0.9 ), Vector2( 0.95, 1.1 ), Vector2( 1, 1 ) ] 23 | } 24 | 25 | [sub_resource type="RectangleShape2D" id=2] 26 | extents = Vector2( 18, 10 ) 27 | 28 | [sub_resource type="CircleShape2D" id=3] 29 | radius = 22.0 30 | 31 | [node name="BigPirate" instance=ExtResource( 2 )] 32 | script = ExtResource( 4 ) 33 | max_speed = 5.0 34 | score = 2000 35 | rareness = 5 36 | 37 | [node name="Sprite" parent="." index="1"] 38 | rotation = 0.174533 39 | region_rect = Rect2( 128, 0, 96, 48 ) 40 | 41 | [node name="AnimationPlayer" parent="Sprite" index="0"] 42 | anims/hurt = SubResource( 1 ) 43 | 44 | [node name="CollisionShape2D" parent="." index="2"] 45 | position = Vector2( -1, 2 ) 46 | shape = SubResource( 2 ) 47 | 48 | [node name="Light2D" parent="." index="3"] 49 | scale = Vector2( 1.6, 1.6 ) 50 | texture_scale = 0.05 51 | 52 | [node name="CollisionShape2D" parent="HitBox" index="0"] 53 | shape = SubResource( 3 ) 54 | 55 | [node name="ShootTimer" type="Timer" parent="." index="5"] 56 | wait_time = 4.0 57 | autostart = true 58 | 59 | [node name="Shoot" type="AudioStreamPlayer2D" parent="." index="6"] 60 | stream = ExtResource( 5 ) 61 | max_distance = 1000.0 62 | bus = "sfx" 63 | 64 | [node name="Dead" parent="." index="7"] 65 | stream = ExtResource( 3 ) 66 | 67 | [node name="Explosion" parent="." index="8"] 68 | scale = Vector2( 2, 2 ) 69 | 70 | [node name="Hurt" type="AudioStreamPlayer2D" parent="." index="9"] 71 | stream = ExtResource( 6 ) 72 | max_distance = 500.0 73 | bus = "sfx" 74 | [connection signal="animation_finished" from="Sprite/AnimationPlayer" to="." method="_on_AnimationPlayer_animation_finished"] 75 | [connection signal="timeout" from="ShootTimer" to="." method="_on_ShootTimer_timeout"] 76 | -------------------------------------------------------------------------------- /enemies/Chaser.gd: -------------------------------------------------------------------------------- 1 | extends "res://enemies/SmallPirate.gd" 2 | 3 | var player: Node2D 4 | 5 | func _physics_process(_delta): 6 | var rot := global_position.angle_to_point(player.global_position) 7 | velocity = lerp(velocity, Vector2(-velocity.length(), 0).rotated(rot), 0.05) 8 | 9 | func _on_GameOver(): 10 | set_physics_process(false) 11 | -------------------------------------------------------------------------------- /enemies/Chaser.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=3 format=2] 2 | 3 | [ext_resource path="res://enemies/SmallPirate.tscn" type="PackedScene" id=1] 4 | [ext_resource path="res://enemies/Chaser.gd" type="Script" id=3] 5 | 6 | [node name="Chaser" instance=ExtResource( 1 )] 7 | script = ExtResource( 3 ) 8 | max_speed = 50.0 9 | score = 500 10 | rareness = 4 11 | 12 | [node name="Sprite" parent="." index="1"] 13 | region_rect = Rect2( 0, 32, 64, 32 ) 14 | -------------------------------------------------------------------------------- /enemies/Explosion.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=3 format=2] 2 | 3 | [sub_resource type="CanvasItemMaterial" id=1] 4 | light_mode = 1 5 | 6 | [sub_resource type="Gradient" id=2] 7 | offsets = PoolRealArray( 0, 0.258278, 0.768212, 1 ) 8 | colors = PoolColorArray( 1, 1, 1, 1, 1, 1, 0, 1, 1, 0, 0, 1, 0.16705, 0.0263023, 0.480957, 1 ) 9 | 10 | [node name="Explosion" type="CPUParticles2D"] 11 | material = SubResource( 1 ) 12 | emitting = false 13 | amount = 20 14 | one_shot = true 15 | explosiveness = 1.0 16 | spread = 180.0 17 | gravity = Vector2( 0, 0 ) 18 | initial_velocity = 50.0 19 | initial_velocity_random = 0.2 20 | damping = 50.0 21 | scale_amount = 4.0 22 | color_ramp = SubResource( 2 ) 23 | -------------------------------------------------------------------------------- /enemies/SmallPirate.gd: -------------------------------------------------------------------------------- 1 | extends KinematicBody2D 2 | 3 | signal add_score(sco, pos) 4 | signal drop_item(pos) 5 | 6 | export (float) var max_speed := 15.0 7 | export (int) var score := 100 8 | export (int) var rareness := 1 9 | var velocity := Vector2.ZERO 10 | 11 | func _physics_process(delta): 12 | if velocity.length() > max_speed: 13 | velocity = velocity.normalized() * (velocity.length() - 30 * delta) 14 | velocity = move_and_slide(velocity) 15 | 16 | if velocity.x != 0: 17 | $Sprite.flip_h = velocity.x > 0 18 | if velocity.y != 0: 19 | $Sprite.frame = 1 if velocity.y < 0 else 0 20 | 21 | if abs(position.x) > 381: 22 | queue_free() 23 | 24 | func _on_HitBox_area_entered(area: Area2D): 25 | if area.has_method("destroy"): 26 | area.destroy() 27 | hurt() 28 | 29 | func hurt(): 30 | $Dead.play() 31 | $Sprite.hide() 32 | $Light2D.hide() 33 | $Explosion.emitting = true 34 | emit_signal("add_score", score, global_position) 35 | if randi()%50 < rareness: 36 | emit_signal("drop_item", global_position) 37 | $HitBox.collision_layer = 0 38 | $HitBox.collision_mask = 0 39 | set_physics_process(false) 40 | $Trail.emitting = false 41 | yield(get_tree().create_timer(1.0), "timeout") 42 | queue_free() 43 | -------------------------------------------------------------------------------- /enemies/SmallPirate.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=10 format=2] 2 | 3 | [ext_resource path="res://enemies/enemies.png" type="Texture" id=1] 4 | [ext_resource path="res://enemies/SmallPirate.gd" type="Script" id=2] 5 | [ext_resource path="res://world/light.png" type="Texture" id=3] 6 | [ext_resource path="res://enemies/small_dead.wav" type="AudioStream" id=4] 7 | [ext_resource path="res://enemies/Explosion.tscn" type="PackedScene" id=5] 8 | 9 | [sub_resource type="Animation" id=1] 10 | resource_name = "default" 11 | length = 4.0 12 | loop = true 13 | step = 1.0 14 | tracks/0/type = "value" 15 | tracks/0/path = NodePath(".:rotation_degrees") 16 | tracks/0/interp = 2 17 | tracks/0/loop_wrap = true 18 | tracks/0/imported = false 19 | tracks/0/enabled = true 20 | tracks/0/keys = { 21 | "times": PoolRealArray( 0, 2 ), 22 | "transitions": PoolRealArray( 1, 1 ), 23 | "update": 0, 24 | "values": [ 10.0, -10.0 ] 25 | } 26 | tracks/1/type = "value" 27 | tracks/1/path = NodePath("../Light2D:texture_scale") 28 | tracks/1/interp = 1 29 | tracks/1/loop_wrap = true 30 | tracks/1/imported = false 31 | tracks/1/enabled = true 32 | tracks/1/keys = { 33 | "times": PoolRealArray( 0, 1, 2, 3 ), 34 | "transitions": PoolRealArray( 1, 1, 1, 1 ), 35 | "update": 0, 36 | "values": [ 0.05, 0.06, 0.05, 0.06 ] 37 | } 38 | tracks/2/type = "value" 39 | tracks/2/path = NodePath(".:scale") 40 | tracks/2/interp = 1 41 | tracks/2/loop_wrap = true 42 | tracks/2/imported = false 43 | tracks/2/enabled = true 44 | tracks/2/keys = { 45 | "times": PoolRealArray( 0 ), 46 | "transitions": PoolRealArray( 1 ), 47 | "update": 0, 48 | "values": [ Vector2( 1, 1 ) ] 49 | } 50 | 51 | [sub_resource type="RectangleShape2D" id=2] 52 | extents = Vector2( 15, 8 ) 53 | 54 | [sub_resource type="CircleShape2D" id=3] 55 | radius = 16.0 56 | 57 | [sub_resource type="AudioStreamRandomPitch" id=4] 58 | audio_stream = ExtResource( 4 ) 59 | 60 | [node name="SmallPirate" type="KinematicBody2D"] 61 | collision_layer = 0 62 | script = ExtResource( 2 ) 63 | 64 | [node name="Trail" type="CPUParticles2D" parent="."] 65 | amount = 10 66 | lifetime = 2.0 67 | local_coords = false 68 | spread = 180.0 69 | gravity = Vector2( 0, 0 ) 70 | initial_velocity = 10.0 71 | damping = 20.0 72 | scale_amount = 2.0 73 | 74 | [node name="Sprite" type="Sprite" parent="."] 75 | position = Vector2( 0, -9 ) 76 | rotation = 0.174533 77 | texture = ExtResource( 1 ) 78 | hframes = 2 79 | region_enabled = true 80 | region_rect = Rect2( 0, 0, 64, 32 ) 81 | 82 | [node name="AnimationPlayer" type="AnimationPlayer" parent="Sprite"] 83 | autoplay = "default" 84 | anims/default = SubResource( 1 ) 85 | 86 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 87 | position = Vector2( -1, -1 ) 88 | shape = SubResource( 2 ) 89 | 90 | [node name="Light2D" type="Light2D" parent="."] 91 | position = Vector2( -2, -10 ) 92 | texture = ExtResource( 3 ) 93 | texture_scale = 0.2 94 | energy = 0.8 95 | 96 | [node name="HitBox" type="Area2D" parent="."] 97 | collision_layer = 8 98 | collision_mask = 4 99 | 100 | [node name="CollisionShape2D" type="CollisionShape2D" parent="HitBox"] 101 | position = Vector2( -1, -8 ) 102 | shape = SubResource( 3 ) 103 | 104 | [node name="Dead" type="AudioStreamPlayer2D" parent="."] 105 | stream = SubResource( 4 ) 106 | max_distance = 500.0 107 | bus = "sfx" 108 | 109 | [node name="Explosion" parent="." instance=ExtResource( 5 )] 110 | [connection signal="area_entered" from="HitBox" to="." method="_on_HitBox_area_entered"] 111 | -------------------------------------------------------------------------------- /enemies/SpikyBall.gd: -------------------------------------------------------------------------------- 1 | extends Area2D 2 | 3 | var velocity := Vector2.ZERO 4 | 5 | func _physics_process(delta: float): 6 | position += velocity * delta 7 | 8 | func _on_VisibilityNotifier2D_screen_exited(): 9 | queue_free() 10 | 11 | func hurt(): 12 | $Explosion.play() 13 | $Explosion2.emitting = true 14 | $Sprite.hide() 15 | $Light2D.hide() 16 | $CollisionShape2D.set_deferred("disabled", true) 17 | $Zooming.stop() 18 | yield(get_tree().create_timer(1.0), "timeout") 19 | queue_free() 20 | 21 | func _on_area_entered(_area: Area2D): 22 | hurt() 23 | -------------------------------------------------------------------------------- /enemies/SpikyBall.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=10 format=2] 2 | 3 | [ext_resource path="res://enemies/enemies.png" type="Texture" id=1] 4 | [ext_resource path="res://enemies/SpikyBall.gd" type="Script" id=2] 5 | [ext_resource path="res://world/light.png" type="Texture" id=3] 6 | [ext_resource path="res://player/hurt.wav" type="AudioStream" id=4] 7 | [ext_resource path="res://enemies/Explosion.tscn" type="PackedScene" id=5] 8 | [ext_resource path="res://enemies/near-miss.ogg" type="AudioStream" id=6] 9 | 10 | [sub_resource type="CanvasItemMaterial" id=1] 11 | blend_mode = 1 12 | light_mode = 1 13 | 14 | [sub_resource type="Gradient" id=2] 15 | offsets = PoolRealArray( 0, 0.622517, 1 ) 16 | colors = PoolColorArray( 1, 1, 1, 1, 1, 1, 0, 1, 0.757812, 0, 0.42627, 1 ) 17 | 18 | [sub_resource type="CircleShape2D" id=3] 19 | 20 | [node name="SpikyBall" type="Area2D"] 21 | collision_layer = 8 22 | collision_mask = 4 23 | script = ExtResource( 2 ) 24 | 25 | [node name="CPUParticles2D" type="CPUParticles2D" parent="."] 26 | material = SubResource( 1 ) 27 | position = Vector2( 0, -15 ) 28 | local_coords = false 29 | spread = 180.0 30 | gravity = Vector2( 0, 5 ) 31 | initial_velocity = 5.0 32 | scale_amount = 2.0 33 | color_ramp = SubResource( 2 ) 34 | 35 | [node name="Sprite" type="Sprite" parent="."] 36 | position = Vector2( 0, -12 ) 37 | texture = ExtResource( 1 ) 38 | region_enabled = true 39 | region_rect = Rect2( 224, 0, 32, 32 ) 40 | 41 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 42 | position = Vector2( 0, -15 ) 43 | shape = SubResource( 3 ) 44 | 45 | [node name="VisibilityNotifier2D" type="VisibilityNotifier2D" parent="."] 46 | position = Vector2( 0, -6 ) 47 | 48 | [node name="Light2D" type="Light2D" parent="."] 49 | position = Vector2( 0, -15 ) 50 | texture = ExtResource( 3 ) 51 | texture_scale = 0.05 52 | 53 | [node name="Explosion" type="AudioStreamPlayer2D" parent="."] 54 | stream = ExtResource( 4 ) 55 | pitch_scale = 2.0 56 | max_distance = 500.0 57 | bus = "sfx" 58 | 59 | [node name="Explosion2" parent="." instance=ExtResource( 5 )] 60 | 61 | [node name="Zooming" type="AudioStreamPlayer2D" parent="."] 62 | stream = ExtResource( 6 ) 63 | autoplay = true 64 | max_distance = 150.0 65 | bus = "sfx" 66 | [connection signal="area_entered" from="." to="." method="_on_area_entered"] 67 | [connection signal="screen_exited" from="VisibilityNotifier2D" to="." method="_on_VisibilityNotifier2D_screen_exited"] 68 | -------------------------------------------------------------------------------- /enemies/big_dead.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/big_dead.wav -------------------------------------------------------------------------------- /enemies/big_dead.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/big_dead.wav-d5aaa6a3bec781ce195cf49959ad13e7.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://enemies/big_dead.wav" 10 | dest_files=[ "res://.import/big_dead.wav-d5aaa6a3bec781ce195cf49959ad13e7.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /enemies/big_hurt.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/big_hurt.wav -------------------------------------------------------------------------------- /enemies/big_hurt.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/big_hurt.wav-8896908b0b109987edf08e52961b0f61.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://enemies/big_hurt.wav" 10 | dest_files=[ "res://.import/big_hurt.wav-8896908b0b109987edf08e52961b0f61.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /enemies/enemies.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/enemies.png -------------------------------------------------------------------------------- /enemies/enemies.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/enemies.png-d037c6b76e84ed89db193131ca152b5c.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://enemies/enemies.png" 13 | dest_files=[ "res://.import/enemies.png-d037c6b76e84ed89db193131ca152b5c.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /enemies/near-miss.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/near-miss.ogg -------------------------------------------------------------------------------- /enemies/near-miss.ogg.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="ogg_vorbis" 4 | type="AudioStreamOGGVorbis" 5 | path="res://.import/near-miss.ogg-2b15b990a6f96822608da23ed3ad8436.oggstr" 6 | 7 | [deps] 8 | 9 | source_file="res://enemies/near-miss.ogg" 10 | dest_files=[ "res://.import/near-miss.ogg-2b15b990a6f96822608da23ed3ad8436.oggstr" ] 11 | 12 | [params] 13 | 14 | loop=true 15 | loop_offset=0 16 | -------------------------------------------------------------------------------- /enemies/shoot.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/shoot.wav -------------------------------------------------------------------------------- /enemies/shoot.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/shoot.wav-f967cf5575f38af4d0ce7078ceeef3ae.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://enemies/shoot.wav" 10 | dest_files=[ "res://.import/shoot.wav-f967cf5575f38af4d0ce7078ceeef3ae.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /enemies/small_dead.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/enemies/small_dead.wav -------------------------------------------------------------------------------- /enemies/small_dead.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/small_dead.wav-e5b20fbac5a03a5117fcdc2a118a16a9.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://enemies/small_dead.wav" 10 | dest_files=[ "res://.import/small_dead.wav-e5b20fbac5a03a5117fcdc2a118a16a9.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /export_presets.cfg: -------------------------------------------------------------------------------- 1 | [preset.0] 2 | 3 | name="HTML5" 4 | platform="HTML5" 5 | runnable=true 6 | custom_features="" 7 | export_filter="all_resources" 8 | include_filter="" 9 | exclude_filter="" 10 | export_path="../bin/html/index.html" 11 | patch_list=PoolStringArray( ) 12 | script_export_mode=1 13 | script_encryption_key="" 14 | 15 | [preset.0.options] 16 | 17 | vram_texture_compression/for_desktop=true 18 | vram_texture_compression/for_mobile=false 19 | html/custom_html_shell="" 20 | html/head_include="" 21 | custom_template/release="" 22 | custom_template/debug="" 23 | 24 | [preset.1] 25 | 26 | name="Windows Desktop" 27 | platform="Windows Desktop" 28 | runnable=true 29 | custom_features="" 30 | export_filter="all_resources" 31 | include_filter="" 32 | exclude_filter="" 33 | export_path="../bin/windows/LHKeeper.exe" 34 | patch_list=PoolStringArray( ) 35 | script_export_mode=1 36 | script_encryption_key="" 37 | 38 | [preset.1.options] 39 | 40 | texture_format/bptc=false 41 | texture_format/s3tc=true 42 | texture_format/etc=false 43 | texture_format/etc2=false 44 | texture_format/no_bptc_fallbacks=true 45 | binary_format/64_bits=true 46 | binary_format/embed_pck=false 47 | custom_template/release="" 48 | custom_template/debug="" 49 | codesign/enable=false 50 | codesign/identity="" 51 | codesign/password="" 52 | codesign/timestamp=true 53 | codesign/timestamp_server_url="" 54 | codesign/digest_algorithm=1 55 | codesign/description="" 56 | codesign/custom_options=PoolStringArray( ) 57 | application/icon="" 58 | application/file_version="" 59 | application/product_version="" 60 | application/company_name="" 61 | application/product_name="" 62 | application/file_description="" 63 | application/copyright="" 64 | application/trademarks="" 65 | 66 | [preset.2] 67 | 68 | name="Mac OSX" 69 | platform="Mac OSX" 70 | runnable=true 71 | custom_features="" 72 | export_filter="all_resources" 73 | include_filter="" 74 | exclude_filter="" 75 | export_path="../bin/macos/Lighthouse Keeper.zip" 76 | patch_list=PoolStringArray( ) 77 | script_export_mode=1 78 | script_encryption_key="" 79 | 80 | [preset.2.options] 81 | 82 | custom_template/debug="" 83 | custom_template/release="" 84 | application/name="" 85 | application/info="Made with Godot Engine" 86 | application/icon="" 87 | application/identifier="" 88 | application/signature="" 89 | application/short_version="1.0" 90 | application/version="1.0" 91 | application/copyright="" 92 | display/high_res=false 93 | privacy/camera_usage_description="" 94 | privacy/microphone_usage_description="" 95 | texture_format/s3tc=true 96 | texture_format/etc=false 97 | texture_format/etc2=false 98 | 99 | [preset.3] 100 | 101 | name="Linux/X11" 102 | platform="Linux/X11" 103 | runnable=true 104 | custom_features="" 105 | export_filter="all_resources" 106 | include_filter="" 107 | exclude_filter="" 108 | export_path="../bin/linux/LHKeeper.x86_64" 109 | patch_list=PoolStringArray( ) 110 | script_export_mode=1 111 | script_encryption_key="" 112 | 113 | [preset.3.options] 114 | 115 | texture_format/bptc=false 116 | texture_format/s3tc=true 117 | texture_format/etc=false 118 | texture_format/etc2=false 119 | texture_format/no_bptc_fallbacks=true 120 | binary_format/64_bits=true 121 | binary_format/embed_pck=false 122 | custom_template/release="" 123 | custom_template/debug="" 124 | -------------------------------------------------------------------------------- /icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/icon.ico -------------------------------------------------------------------------------- /icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/icon.png -------------------------------------------------------------------------------- /icon.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://icon.png" 13 | dest_files=[ "res://.import/icon.png-487276ed1e3a0c39cad0279d744ee560.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=true 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=true 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /items/Coin.gd: -------------------------------------------------------------------------------- 1 | extends Area2D 2 | 3 | var plus_score := preload("res://items/PlusScore.tscn") 4 | 5 | func _on_Coin_body_entered(body: PhysicsBody2D): 6 | effect(body) 7 | destroy() 8 | 9 | func effect(_body): 10 | Globals.message = "You got some of the pirate's treasure!" 11 | 12 | func destroy(): 13 | Globals.score += 5000 14 | var new_plus_score = plus_score.instance() 15 | get_parent().add_child(new_plus_score) 16 | new_plus_score.global_position = global_position 17 | new_plus_score.init(5000) 18 | hide() 19 | collision_mask = 0 20 | $Caught.play() 21 | yield(get_tree().create_timer(1.0), "timeout") 22 | queue_free() 23 | -------------------------------------------------------------------------------- /items/Coin.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=8 format=2] 2 | 3 | [ext_resource path="res://world/light.png" type="Texture" id=1] 4 | [ext_resource path="res://items/powerups.png" type="Texture" id=2] 5 | [ext_resource path="res://items/Coin.gd" type="Script" id=3] 6 | [ext_resource path="res://items/coin.wav" type="AudioStream" id=4] 7 | [ext_resource path="res://items/item_drop.wav" type="AudioStream" id=5] 8 | 9 | [sub_resource type="CircleShape2D" id=1] 10 | radius = 15.0 11 | 12 | [sub_resource type="Animation" id=2] 13 | resource_name = "default" 14 | length = 2.0 15 | loop = true 16 | step = 0.25 17 | tracks/0/type = "value" 18 | tracks/0/path = NodePath(".:offset") 19 | tracks/0/interp = 2 20 | tracks/0/loop_wrap = true 21 | tracks/0/imported = false 22 | tracks/0/enabled = true 23 | tracks/0/keys = { 24 | "times": PoolRealArray( 0, 1 ), 25 | "transitions": PoolRealArray( 1, 1 ), 26 | "update": 0, 27 | "values": [ Vector2( 0, 2 ), Vector2( 0, -2 ) ] 28 | } 29 | tracks/1/type = "value" 30 | tracks/1/path = NodePath("../BigLight:texture_scale") 31 | tracks/1/interp = 1 32 | tracks/1/loop_wrap = true 33 | tracks/1/imported = false 34 | tracks/1/enabled = true 35 | tracks/1/keys = { 36 | "times": PoolRealArray( 0, 0.25, 0.5, 0.75, 1, 1.25, 1.5, 1.75 ), 37 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1, 1 ), 38 | "update": 1, 39 | "values": [ 0.25, 0.05, 0.25, 0.15, 0.25, 0.1, 0.25, 0.15 ] 40 | } 41 | 42 | [node name="Coin" type="Area2D"] 43 | collision_layer = 0 44 | collision_mask = 2 45 | script = ExtResource( 3 ) 46 | 47 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 48 | shape = SubResource( 1 ) 49 | 50 | [node name="Sprite" type="Sprite" parent="."] 51 | texture = ExtResource( 2 ) 52 | offset = Vector2( 0, 2 ) 53 | hframes = 4 54 | frame = 3 55 | 56 | [node name="AnimationPlayer" type="AnimationPlayer" parent="Sprite"] 57 | anims/default = SubResource( 2 ) 58 | 59 | [node name="SmallLight" type="Light2D" parent="."] 60 | texture = ExtResource( 1 ) 61 | texture_scale = 0.04 62 | energy = 0.8 63 | 64 | [node name="BigLight" type="Light2D" parent="."] 65 | texture = ExtResource( 1 ) 66 | texture_scale = 0.06 67 | energy = 0.5 68 | 69 | [node name="Caught" type="AudioStreamPlayer2D" parent="."] 70 | stream = ExtResource( 4 ) 71 | bus = "sfx" 72 | 73 | [node name="Dropped" type="AudioStreamPlayer2D" parent="."] 74 | stream = ExtResource( 5 ) 75 | autoplay = true 76 | bus = "sfx" 77 | [connection signal="body_entered" from="." to="." method="_on_Coin_body_entered"] 78 | -------------------------------------------------------------------------------- /items/LifeBarrel.gd: -------------------------------------------------------------------------------- 1 | extends "res://items/Coin.gd" 2 | 3 | func effect(_body: PhysicsBody2D): 4 | if get_tree().current_scene.has_node("LightHouse"): 5 | var lh = get_tree().current_scene.get_node("LightHouse") 6 | lh.life += 20 7 | if lh.life > 100: 8 | lh.life = 100 9 | Globals.message = "You repaired the lighthouse with the barrel." 10 | -------------------------------------------------------------------------------- /items/LifeBarrel.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=4 format=2] 2 | 3 | [ext_resource path="res://items/Coin.tscn" type="PackedScene" id=1] 4 | [ext_resource path="res://items/powerup1.wav" type="AudioStream" id=2] 5 | [ext_resource path="res://items/LifeBarrel.gd" type="Script" id=3] 6 | 7 | [node name="LifeBarrel" instance=ExtResource( 1 )] 8 | script = ExtResource( 3 ) 9 | 10 | [node name="Sprite" parent="." index="1"] 11 | frame = 2 12 | 13 | [node name="Caught" parent="." index="4"] 14 | stream = ExtResource( 2 ) 15 | -------------------------------------------------------------------------------- /items/PlusScore.gd: -------------------------------------------------------------------------------- 1 | extends Sprite 2 | 3 | func init(number: int): 4 | vframes = 1 5 | match number: 6 | 100: 7 | vframes = 4 8 | frame = randi()%4 9 | 500: 10 | texture = preload("res://items/plus500.png") 11 | 2000: 12 | texture = preload("res://items/plus2000.png") 13 | 5000: 14 | texture = preload("res://items/plus5000.png") 15 | 16 | func _on_Timer_timeout(): 17 | queue_free() 18 | -------------------------------------------------------------------------------- /items/PlusScore.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=5 format=2] 2 | 3 | [ext_resource path="res://items/plus100.png" type="Texture" id=1] 4 | [ext_resource path="res://items/PlusScore.gd" type="Script" id=2] 5 | 6 | [sub_resource type="CanvasItemMaterial" id=2] 7 | blend_mode = 1 8 | light_mode = 1 9 | 10 | [sub_resource type="Animation" id=1] 11 | resource_name = "default" 12 | tracks/0/type = "value" 13 | tracks/0/path = NodePath(".:offset") 14 | tracks/0/interp = 1 15 | tracks/0/loop_wrap = true 16 | tracks/0/imported = false 17 | tracks/0/enabled = true 18 | tracks/0/keys = { 19 | "times": PoolRealArray( 0, 1 ), 20 | "transitions": PoolRealArray( 0.2, 1 ), 21 | "update": 0, 22 | "values": [ Vector2( 0, 0 ), Vector2( 0, -20 ) ] 23 | } 24 | 25 | [node name="PlusScore" type="Sprite"] 26 | material = SubResource( 2 ) 27 | z_index = 100 28 | texture = ExtResource( 1 ) 29 | vframes = 4 30 | script = ExtResource( 2 ) 31 | 32 | [node name="Timer" type="Timer" parent="."] 33 | wait_time = 1.5 34 | one_shot = true 35 | autostart = true 36 | 37 | [node name="AnimationPlayer" type="AnimationPlayer" parent="."] 38 | autoplay = "default" 39 | anims/default = SubResource( 1 ) 40 | [connection signal="timeout" from="Timer" to="." method="_on_Timer_timeout"] 41 | -------------------------------------------------------------------------------- /items/SuperCannon.gd: -------------------------------------------------------------------------------- 1 | extends "res://items/SuperPaddles.gd" 2 | 3 | func effect(body: PhysicsBody2D): 4 | body.bullet_speed *= 1.1 5 | body.get_node("Shoot/Timer").wait_time *= 0.7 6 | Globals.message = "You can shoot faster!" 7 | -------------------------------------------------------------------------------- /items/SuperCannon.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=3 format=2] 2 | 3 | [ext_resource path="res://items/SuperPaddles.tscn" type="PackedScene" id=1] 4 | [ext_resource path="res://items/SuperCannon.gd" type="Script" id=2] 5 | 6 | [node name="SuperCannon" instance=ExtResource( 1 )] 7 | script = ExtResource( 2 ) 8 | 9 | [node name="Sprite" parent="." index="1"] 10 | frame = 1 11 | -------------------------------------------------------------------------------- /items/SuperPaddles.gd: -------------------------------------------------------------------------------- 1 | extends "res://items/Coin.gd" 2 | 3 | func effect(body: PhysicsBody2D): 4 | body.max_speed *= 1.25 5 | body.bullet_speed *= 1.2 6 | body.get_node("Shoot/Timer").wait_time /= 1.25 7 | Globals.message = "You can move slightly faster!" 8 | -------------------------------------------------------------------------------- /items/SuperPaddles.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=4 format=2] 2 | 3 | [ext_resource path="res://items/SuperPaddles.gd" type="Script" id=1] 4 | [ext_resource path="res://items/Coin.tscn" type="PackedScene" id=2] 5 | [ext_resource path="res://items/powerup2.wav" type="AudioStream" id=3] 6 | 7 | [node name="SuperPaddles" instance=ExtResource( 2 )] 8 | script = ExtResource( 1 ) 9 | 10 | [node name="Sprite" parent="." index="1"] 11 | position = Vector2( -1, -1 ) 12 | frame = 0 13 | 14 | [node name="Caught" parent="." index="4"] 15 | stream = ExtResource( 3 ) 16 | -------------------------------------------------------------------------------- /items/coin.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/coin.wav -------------------------------------------------------------------------------- /items/coin.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/coin.wav-df74f7d66db762b4d1b306d31a5c7025.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/coin.wav" 10 | dest_files=[ "res://.import/coin.wav-df74f7d66db762b4d1b306d31a5c7025.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/dropped_item.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/dropped_item.wav-5dc5a9677a8435bda25b9aa6db540f77.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/dropped_item.wav" 10 | dest_files=[ "res://.import/dropped_item.wav-5dc5a9677a8435bda25b9aa6db540f77.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/heal.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/heal.wav-174f1f80012cb39334d7b7854cdc7c36.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/heal.wav" 10 | dest_files=[ "res://.import/heal.wav-174f1f80012cb39334d7b7854cdc7c36.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/item_drop.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/item_drop.wav -------------------------------------------------------------------------------- /items/item_drop.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/item_drop.wav-8dc9c2a9bb9479236ac2ec7bc49fb8a4.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/item_drop.wav" 10 | dest_files=[ "res://.import/item_drop.wav-8dc9c2a9bb9479236ac2ec7bc49fb8a4.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/plus100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/plus100.png -------------------------------------------------------------------------------- /items/plus100.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/plus100.png-4477a5ae7ce0d23704868ee22c57f603.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://items/plus100.png" 13 | dest_files=[ "res://.import/plus100.png-4477a5ae7ce0d23704868ee22c57f603.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /items/plus2000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/plus2000.png -------------------------------------------------------------------------------- /items/plus2000.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/plus2000.png-a275d158d5a2b963a85318e12f53c93e.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://items/plus2000.png" 13 | dest_files=[ "res://.import/plus2000.png-a275d158d5a2b963a85318e12f53c93e.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /items/plus500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/plus500.png -------------------------------------------------------------------------------- /items/plus500.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/plus500.png-05acc7db31c5ffadab31df9124c8fbd1.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://items/plus500.png" 13 | dest_files=[ "res://.import/plus500.png-05acc7db31c5ffadab31df9124c8fbd1.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /items/plus5000.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/plus5000.png -------------------------------------------------------------------------------- /items/plus5000.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/plus5000.png-9badbf89ffd15de43bdb094c3f934351.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://items/plus5000.png" 13 | dest_files=[ "res://.import/plus5000.png-9badbf89ffd15de43bdb094c3f934351.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /items/powerup1.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/powerup1.wav -------------------------------------------------------------------------------- /items/powerup1.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/powerup1.wav-fd3e4f799f977a2f04c519ab954f76ea.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/powerup1.wav" 10 | dest_files=[ "res://.import/powerup1.wav-fd3e4f799f977a2f04c519ab954f76ea.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/powerup2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/powerup2.wav -------------------------------------------------------------------------------- /items/powerup2.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/powerup2.wav-9e9b5e1c0446d317467d5fcb23def2a8.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://items/powerup2.wav" 10 | dest_files=[ "res://.import/powerup2.wav-9e9b5e1c0446d317467d5fcb23def2a8.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /items/powerups.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/items/powerups.png -------------------------------------------------------------------------------- /items/powerups.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/powerups.png-da2798d18c3a1e99f7152118262de750.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://items/powerups.png" 13 | dest_files=[ "res://.import/powerups.png-da2798d18c3a1e99f7152118262de750.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /lighthouse/LightHouse.gd: -------------------------------------------------------------------------------- 1 | extends Area2D 2 | 3 | signal gameover 4 | 5 | var life := 100 6 | 7 | func _process(_delta): 8 | $LifeBar.value = life 9 | $BigLight.texture_scale = 0.025 + (1.5 * life/400) 10 | $SmallLight.texture_scale = 0.025 + (0.9 * life/400) 11 | if life <= 0: 12 | emit_signal("gameover") 13 | queue_free() 14 | elif life < 30: 15 | $Sprite.frame = 2 16 | elif life < 60: 17 | $Sprite.frame = 1 18 | else: 19 | $Sprite.frame = 0 20 | 21 | 22 | func _on_area_entered(area: CollisionObject2D): 23 | if area.has_method("hurt"): 24 | area.hurt() 25 | life -= 9 26 | $LifeBar/AnimationPlayer.play("badflicker") 27 | 28 | func _on_AnimationPlayer_animation_finished(anim_name: String): 29 | if anim_name == "badflicker": 30 | $LifeBar/AnimationPlayer.play("flicker") 31 | 32 | func _on_BulletBooster_area_entered(area: Area2D): 33 | area.scale *= 3 34 | area.velocity *= 2 35 | area.invincible = true 36 | $BulletBooster/Flame.play() 37 | $LifeBar/AnimationPlayer.play("badflicker") 38 | life -= 2 39 | -------------------------------------------------------------------------------- /lighthouse/LightHouse.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=18 format=2] 2 | 3 | [ext_resource path="res://world/light.png" type="Texture" id=1] 4 | [ext_resource path="res://lighthouse/lighthouse.png" type="Texture" id=2] 5 | [ext_resource path="res://lighthouse/beam.png" type="Texture" id=3] 6 | [ext_resource path="res://lighthouse/flame.wav" type="AudioStream" id=4] 7 | [ext_resource path="res://lighthouse/LightHouse.gd" type="Script" id=5] 8 | [ext_resource path="res://lighthouse/respawn.wav" type="AudioStream" id=7] 9 | 10 | [sub_resource type="CanvasItemMaterial" id=1] 11 | blend_mode = 1 12 | light_mode = 1 13 | 14 | [sub_resource type="AtlasTexture" id=2] 15 | atlas = ExtResource( 3 ) 16 | region = Rect2( 0, 32, 128, 32 ) 17 | 18 | [sub_resource type="AtlasTexture" id=3] 19 | atlas = ExtResource( 3 ) 20 | region = Rect2( 0, 0, 128, 32 ) 21 | 22 | [sub_resource type="Animation" id=4] 23 | length = 2.0 24 | tracks/0/type = "value" 25 | tracks/0/path = NodePath(".:modulate") 26 | tracks/0/interp = 1 27 | tracks/0/loop_wrap = true 28 | tracks/0/imported = false 29 | tracks/0/enabled = true 30 | tracks/0/keys = { 31 | "times": PoolRealArray( 0, 0.7, 0.8, 1.2, 1.6, 1.7, 1.8, 1.9 ), 32 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1, 1 ), 33 | "update": 1, 34 | "values": [ Color( 0.47451, 0.105882, 0.105882, 1 ), Color( 1, 1, 1, 1 ), Color( 0.47451, 0.105882, 0.105882, 1 ), Color( 1, 1, 1, 1 ), Color( 0.713726, 0.607843, 0.196078, 1 ), Color( 1, 1, 1, 1 ), Color( 0.47451, 0.105882, 0.105882, 1 ), Color( 1, 1, 1, 1 ) ] 35 | } 36 | tracks/1/type = "value" 37 | tracks/1/path = NodePath("../Sprite:offset") 38 | tracks/1/interp = 1 39 | tracks/1/loop_wrap = true 40 | tracks/1/imported = false 41 | tracks/1/enabled = true 42 | tracks/1/keys = { 43 | "times": PoolRealArray( 0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6 ), 44 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1 ), 45 | "update": 1, 46 | "values": [ Vector2( 3, 3 ), Vector2( -3, -3 ), Vector2( 2, 2 ), Vector2( -2, -2 ), Vector2( 1, 1 ), Vector2( -1, -1 ), Vector2( 0, 0 ) ] 47 | } 48 | 49 | [sub_resource type="Animation" id=5] 50 | length = 5.0 51 | loop = true 52 | tracks/0/type = "value" 53 | tracks/0/path = NodePath(".:modulate") 54 | tracks/0/interp = 1 55 | tracks/0/loop_wrap = true 56 | tracks/0/imported = false 57 | tracks/0/enabled = true 58 | tracks/0/keys = { 59 | "times": PoolRealArray( 0, 1.6, 1.7, 2.4, 2.5, 2.8, 2.9, 4.6, 4.8 ), 60 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1, 1, 1 ), 61 | "update": 1, 62 | "values": [ Color( 1, 1, 1, 1 ), Color( 0.47451, 0.105882, 0.105882, 1 ), Color( 1, 1, 1, 1 ), Color( 0.713726, 0.607843, 0.196078, 1 ), Color( 1, 1, 1, 1 ), Color( 0.47451, 0.105882, 0.105882, 1 ), Color( 1, 1, 1, 1 ), Color( 0.713726, 0.607843, 0.196078, 1 ), Color( 1, 1, 1, 1 ) ] 63 | } 64 | 65 | [sub_resource type="Animation" id=6] 66 | resource_name = "anim" 67 | length = 16.0 68 | loop = true 69 | step = 2.0 70 | tracks/0/type = "value" 71 | tracks/0/path = NodePath(".:tint_over") 72 | tracks/0/interp = 1 73 | tracks/0/loop_wrap = true 74 | tracks/0/imported = false 75 | tracks/0/enabled = true 76 | tracks/0/keys = { 77 | "times": PoolRealArray( 0, 4, 10, 12 ), 78 | "transitions": PoolRealArray( 1, 1, 1, 1 ), 79 | "update": 0, 80 | "values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0, 0, 1, 0 ), Color( 1, 1, 1, 1 ) ] 81 | } 82 | tracks/1/type = "value" 83 | tracks/1/path = NodePath(".:tint_progress") 84 | tracks/1/interp = 1 85 | tracks/1/loop_wrap = true 86 | tracks/1/imported = false 87 | tracks/1/enabled = true 88 | tracks/1/keys = { 89 | "times": PoolRealArray( 0, 6, 12, 14 ), 90 | "transitions": PoolRealArray( 1, 1, 1, 1 ), 91 | "update": 0, 92 | "values": [ Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0.572549, 0.572549, 0.945098, 0.572549 ), Color( 1, 1, 1, 1 ) ] 93 | } 94 | 95 | [sub_resource type="Animation" id=7] 96 | length = 6.0 97 | step = 1.0 98 | tracks/0/type = "value" 99 | tracks/0/path = NodePath("../SmallLight:energy") 100 | tracks/0/interp = 1 101 | tracks/0/loop_wrap = true 102 | tracks/0/imported = false 103 | tracks/0/enabled = true 104 | tracks/0/keys = { 105 | "times": PoolRealArray( 0, 4, 6 ), 106 | "transitions": PoolRealArray( 0.2, 0.2, 1 ), 107 | "update": 0, 108 | "values": [ 0.0, 0.0, 0.8 ] 109 | } 110 | tracks/1/type = "value" 111 | tracks/1/path = NodePath("../BigLight:energy") 112 | tracks/1/interp = 1 113 | tracks/1/loop_wrap = true 114 | tracks/1/imported = false 115 | tracks/1/enabled = true 116 | tracks/1/keys = { 117 | "times": PoolRealArray( 0, 4, 6 ), 118 | "transitions": PoolRealArray( 0.2, 0.2, 1 ), 119 | "update": 0, 120 | "values": [ 0.0, 0.0, 0.5 ] 121 | } 122 | 123 | [sub_resource type="RectangleShape2D" id=8] 124 | extents = Vector2( 22, 12 ) 125 | 126 | [sub_resource type="RectangleShape2D" id=9] 127 | extents = Vector2( 20, 8 ) 128 | 129 | [sub_resource type="CircleShape2D" id=10] 130 | radius = 16.0 131 | 132 | [sub_resource type="CanvasItemMaterial" id=11] 133 | blend_mode = 1 134 | 135 | [node name="LightHouse" type="Area2D"] 136 | collision_layer = 0 137 | collision_mask = 8 138 | script = ExtResource( 5 ) 139 | 140 | [node name="LifeBar" type="TextureProgress" parent="."] 141 | material = SubResource( 1 ) 142 | anchor_left = 0.5 143 | anchor_top = 0.5 144 | anchor_right = 0.5 145 | anchor_bottom = 0.5 146 | margin_left = -64.0 147 | margin_top = -46.0 148 | margin_right = 64.0 149 | margin_bottom = -14.0 150 | value = 100.0 151 | texture_over = SubResource( 2 ) 152 | texture_progress = SubResource( 3 ) 153 | fill_mode = 6 154 | tint_over = Color( 0.333333, 0.333333, 1, 0.333333 ) 155 | tint_progress = Color( 0.857516, 0.857516, 0.981699, 0.857516 ) 156 | __meta__ = { 157 | "_edit_use_anchors_": false 158 | } 159 | 160 | [node name="AnimationPlayer" type="AnimationPlayer" parent="LifeBar"] 161 | autoplay = "flicker" 162 | anims/badflicker = SubResource( 4 ) 163 | anims/flicker = SubResource( 5 ) 164 | 165 | [node name="LongFlickerAnim" type="AnimationPlayer" parent="LifeBar"] 166 | autoplay = "anim" 167 | anims/anim = SubResource( 6 ) 168 | 169 | [node name="Sprite" type="Sprite" parent="."] 170 | position = Vector2( 2, -20 ) 171 | texture = ExtResource( 2 ) 172 | hframes = 3 173 | __meta__ = { 174 | "_edit_lock_": true 175 | } 176 | 177 | [node name="Start" type="AnimationPlayer" parent="Sprite"] 178 | autoplay = "start" 179 | anims/start = SubResource( 7 ) 180 | 181 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 182 | position = Vector2( 0, -1 ) 183 | shape = SubResource( 8 ) 184 | 185 | [node name="SmallLight" type="Light2D" parent="."] 186 | position = Vector2( 0, -32 ) 187 | texture = ExtResource( 1 ) 188 | texture_scale = 0.6 189 | energy = 0.8 190 | __meta__ = { 191 | "_edit_lock_": true 192 | } 193 | 194 | [node name="BigLight" type="Light2D" parent="."] 195 | position = Vector2( 0, -32 ) 196 | texture = ExtResource( 1 ) 197 | texture_scale = 1.2 198 | energy = 0.5 199 | __meta__ = { 200 | "_edit_lock_": true 201 | } 202 | 203 | [node name="Rock" type="StaticBody2D" parent="."] 204 | collision_mask = 0 205 | 206 | [node name="CollisionShape2D" type="CollisionShape2D" parent="Rock"] 207 | position = Vector2( 0, 2 ) 208 | shape = SubResource( 9 ) 209 | __meta__ = { 210 | "_edit_lock_": true 211 | } 212 | 213 | [node name="Respawn" type="AudioStreamPlayer2D" parent="."] 214 | stream = ExtResource( 7 ) 215 | bus = "sfx" 216 | 217 | [node name="BulletBooster" type="Area2D" parent="."] 218 | position = Vector2( 0, -32 ) 219 | collision_layer = 0 220 | collision_mask = 4 221 | 222 | [node name="CollisionShape2D" type="CollisionShape2D" parent="BulletBooster"] 223 | shape = SubResource( 10 ) 224 | 225 | [node name="Flame" type="AudioStreamPlayer2D" parent="BulletBooster"] 226 | stream = ExtResource( 4 ) 227 | bus = "sfx" 228 | 229 | [node name="BeamEffectLeft" type="CPUParticles2D" parent="BulletBooster"] 230 | material = SubResource( 11 ) 231 | z_index = -1 232 | amount = 1 233 | lifetime_randomness = 0.5 234 | emission_shape = 2 235 | emission_rect_extents = Vector2( 1, 6 ) 236 | direction = Vector2( -1, 0 ) 237 | spread = 0.0 238 | gravity = Vector2( 0, 0 ) 239 | initial_velocity = 100.0 240 | damping = 100.0 241 | scale_amount = 2.0 242 | color = Color( 0.364706, 0.141176, 0.545098, 1 ) 243 | 244 | [node name="BeamEffectRight" type="CPUParticles2D" parent="BulletBooster"] 245 | material = SubResource( 11 ) 246 | z_index = -1 247 | amount = 1 248 | lifetime_randomness = 0.5 249 | emission_shape = 2 250 | emission_rect_extents = Vector2( 1, 6 ) 251 | spread = 0.0 252 | gravity = Vector2( 0, 0 ) 253 | initial_velocity = 100.0 254 | damping = 100.0 255 | scale_amount = 2.0 256 | color = Color( 0.364706, 0.141176, 0.545098, 1 ) 257 | [connection signal="area_entered" from="." to="." method="_on_area_entered"] 258 | [connection signal="animation_finished" from="LifeBar/AnimationPlayer" to="." method="_on_AnimationPlayer_animation_finished"] 259 | [connection signal="area_entered" from="BulletBooster" to="." method="_on_BulletBooster_area_entered"] 260 | -------------------------------------------------------------------------------- /lighthouse/beam.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/lighthouse/beam.png -------------------------------------------------------------------------------- /lighthouse/beam.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/beam.png-817491d648fd47203c68688caa44993e.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://lighthouse/beam.png" 13 | dest_files=[ "res://.import/beam.png-817491d648fd47203c68688caa44993e.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /lighthouse/flame.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/lighthouse/flame.wav -------------------------------------------------------------------------------- /lighthouse/flame.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/flame.wav-1d7387c10ceec3062d67b6603410bfd0.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://lighthouse/flame.wav" 10 | dest_files=[ "res://.import/flame.wav-1d7387c10ceec3062d67b6603410bfd0.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /lighthouse/lighthouse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/lighthouse/lighthouse.png -------------------------------------------------------------------------------- /lighthouse/lighthouse.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/lighthouse.png-4ea295a91b5019da123fd14ddefd1154.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://lighthouse/lighthouse.png" 13 | dest_files=[ "res://.import/lighthouse.png-4ea295a91b5019da123fd14ddefd1154.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /lighthouse/respawn.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/lighthouse/respawn.wav -------------------------------------------------------------------------------- /lighthouse/respawn.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/respawn.wav-2b31aad5554283c91746407c66ab53db.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://lighthouse/respawn.wav" 10 | dest_files=[ "res://.import/respawn.wav-2b31aad5554283c91746407c66ab53db.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /menu/CustomButton.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=5 format=2] 2 | 3 | [ext_resource path="res://menu/button.png" type="Texture" id=1] 4 | 5 | [sub_resource type="AtlasTexture" id=1] 6 | atlas = ExtResource( 1 ) 7 | region = Rect2( 0, 0, 80, 24 ) 8 | 9 | [sub_resource type="AtlasTexture" id=2] 10 | atlas = ExtResource( 1 ) 11 | region = Rect2( 0, 48, 80, 24 ) 12 | 13 | [sub_resource type="AtlasTexture" id=3] 14 | atlas = ExtResource( 1 ) 15 | region = Rect2( 0, 24, 80, 24 ) 16 | 17 | [node name="TextureButton" type="TextureButton"] 18 | margin_right = 80.0 19 | margin_bottom = 24.0 20 | texture_normal = SubResource( 1 ) 21 | texture_pressed = SubResource( 2 ) 22 | texture_hover = SubResource( 3 ) 23 | __meta__ = { 24 | "_edit_use_anchors_": false 25 | } 26 | 27 | [node name="Label" type="Label" parent="."] 28 | anchor_right = 1.0 29 | anchor_bottom = 1.0 30 | text = "Main menu" 31 | align = 1 32 | valign = 1 33 | __meta__ = { 34 | "_edit_use_anchors_": false 35 | } 36 | -------------------------------------------------------------------------------- /menu/ScoreDisplay.gd: -------------------------------------------------------------------------------- 1 | extends Sprite 2 | 3 | func _process(_delta): 4 | var pos = 1 5 | for number in get_children(): 6 | if number is Sprite: 7 | number.frame = int(str(Globals.score + 100000000).substr(pos, 1)) 8 | pos += 1 9 | -------------------------------------------------------------------------------- /menu/ScoreDisplay.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=4 format=2] 2 | 3 | [ext_resource path="res://menu/score.png" type="Texture" id=1] 4 | [ext_resource path="res://menu/numbers.png" type="Texture" id=2] 5 | [ext_resource path="res://menu/ScoreDisplay.gd" type="Script" id=3] 6 | 7 | [node name="ScoreDisplay" type="Sprite"] 8 | self_modulate = Color( 1, 1, 1, 0.756863 ) 9 | texture = ExtResource( 1 ) 10 | script = ExtResource( 3 ) 11 | 12 | [node name="Number0" type="Sprite" parent="."] 13 | position = Vector2( -50, 2 ) 14 | texture = ExtResource( 2 ) 15 | vframes = 2 16 | hframes = 5 17 | 18 | [node name="Number1" type="Sprite" parent="."] 19 | position = Vector2( -36, 2 ) 20 | texture = ExtResource( 2 ) 21 | vframes = 2 22 | hframes = 5 23 | 24 | [node name="Number2" type="Sprite" parent="."] 25 | position = Vector2( -22, 2 ) 26 | texture = ExtResource( 2 ) 27 | vframes = 2 28 | hframes = 5 29 | 30 | [node name="Number3" type="Sprite" parent="."] 31 | position = Vector2( -8, 2 ) 32 | texture = ExtResource( 2 ) 33 | vframes = 2 34 | hframes = 5 35 | 36 | [node name="Number4" type="Sprite" parent="."] 37 | position = Vector2( 6, 2 ) 38 | texture = ExtResource( 2 ) 39 | vframes = 2 40 | hframes = 5 41 | 42 | [node name="Number5" type="Sprite" parent="."] 43 | position = Vector2( 20, 2 ) 44 | texture = ExtResource( 2 ) 45 | vframes = 2 46 | hframes = 5 47 | 48 | [node name="Number6" type="Sprite" parent="."] 49 | position = Vector2( 34, 2 ) 50 | texture = ExtResource( 2 ) 51 | vframes = 2 52 | hframes = 5 53 | 54 | [node name="Number7" type="Sprite" parent="."] 55 | position = Vector2( 48, 2 ) 56 | texture = ExtResource( 2 ) 57 | vframes = 2 58 | hframes = 5 59 | -------------------------------------------------------------------------------- /menu/Settings.gd: -------------------------------------------------------------------------------- 1 | extends CanvasLayer 2 | 3 | onready var music_button: TextureButton = $Background/Rows/Music 4 | onready var sfx_button: TextureButton = $Background/Rows/Sfx 5 | 6 | func _ready(): 7 | $Background.hide() 8 | 9 | func _on_Back_pressed(): 10 | $Background.hide() 11 | 12 | func _on_Music_pressed(): 13 | AudioServer.set_bus_mute(2, not music_button.pressed) 14 | music_button.get_node("Label").text = "Music: " + ("on" if music_button.pressed else "off") 15 | 16 | func _on_Sfx_pressed(): 17 | $Background/Rows/TestSound.play() 18 | AudioServer.set_bus_mute(1, not sfx_button.pressed) 19 | sfx_button.get_node("Label").text = "Soundfx: " + ("on" if sfx_button.pressed else "off") 20 | -------------------------------------------------------------------------------- /menu/Settings.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=6 format=2] 2 | 3 | [ext_resource path="res://menu/backgrounds.png" type="Texture" id=1] 4 | [ext_resource path="res://menu/CustomButton.tscn" type="PackedScene" id=2] 5 | [ext_resource path="res://menu/Settings.gd" type="Script" id=3] 6 | [ext_resource path="res://items/coin.wav" type="AudioStream" id=4] 7 | 8 | [sub_resource type="AtlasTexture" id=1] 9 | atlas = ExtResource( 1 ) 10 | region = Rect2( 256, 0, 256, 144 ) 11 | 12 | [node name="Settings" type="CanvasLayer"] 13 | pause_mode = 2 14 | layer = 111 15 | script = ExtResource( 3 ) 16 | 17 | [node name="Background" type="TextureRect" parent="."] 18 | anchor_right = 1.0 19 | anchor_bottom = 1.0 20 | texture = SubResource( 1 ) 21 | expand = true 22 | __meta__ = { 23 | "_edit_use_anchors_": false 24 | } 25 | 26 | [node name="Rows" type="VBoxContainer" parent="Background"] 27 | anchor_right = 1.0 28 | anchor_bottom = 1.0 29 | margin_left = 20.0 30 | margin_top = 20.0 31 | margin_right = -20.0 32 | margin_bottom = -20.0 33 | __meta__ = { 34 | "_edit_use_anchors_": false 35 | } 36 | 37 | [node name="Label" type="Label" parent="Background/Rows"] 38 | margin_right = 472.0 39 | margin_bottom = 8.0 40 | size_flags_vertical = 2 41 | text = "SETTINGS" 42 | align = 1 43 | 44 | [node name="Music" parent="Background/Rows" instance=ExtResource( 2 )] 45 | margin_left = 196.0 46 | margin_top = 98.0 47 | margin_right = 276.0 48 | margin_bottom = 122.0 49 | size_flags_horizontal = 4 50 | toggle_mode = true 51 | pressed = true 52 | 53 | [node name="Label" parent="Background/Rows/Music" index="0"] 54 | text = "Music: on" 55 | 56 | [node name="Sfx" parent="Background/Rows" instance=ExtResource( 2 )] 57 | margin_left = 196.0 58 | margin_top = 126.0 59 | margin_right = 276.0 60 | margin_bottom = 150.0 61 | size_flags_horizontal = 4 62 | toggle_mode = true 63 | pressed = true 64 | 65 | [node name="Label" parent="Background/Rows/Sfx" index="0"] 66 | text = "Soundfx: on" 67 | 68 | [node name="Back" parent="Background/Rows" instance=ExtResource( 2 )] 69 | margin_left = 196.0 70 | margin_top = 224.0 71 | margin_right = 276.0 72 | margin_bottom = 248.0 73 | size_flags_horizontal = 4 74 | size_flags_vertical = 10 75 | 76 | [node name="Label" parent="Background/Rows/Back" index="0"] 77 | text = "Back" 78 | 79 | [node name="TestSound" type="AudioStreamPlayer" parent="Background/Rows"] 80 | stream = ExtResource( 4 ) 81 | bus = "sfx" 82 | [connection signal="pressed" from="Background/Rows/Music" to="." method="_on_Music_pressed"] 83 | [connection signal="pressed" from="Background/Rows/Sfx" to="." method="_on_Sfx_pressed"] 84 | [connection signal="pressed" from="Background/Rows/Back" to="." method="_on_Back_pressed"] 85 | 86 | [editable path="Background/Rows/Music"] 87 | 88 | [editable path="Background/Rows/Sfx"] 89 | 90 | [editable path="Background/Rows/Back"] 91 | -------------------------------------------------------------------------------- /menu/TitleScreen.gd: -------------------------------------------------------------------------------- 1 | extends VBoxContainer 2 | 3 | func _ready(): 4 | $Buttons/Play.grab_focus() 5 | if Globals.high_score > 0: 6 | $HighScore.text = "Highest score: " + str(Globals.high_score) 7 | else: 8 | $HighScore.text = "Will you protect the light?" 9 | 10 | if OS.has_feature("HTML5"): 11 | $Buttons/Quit.hide() 12 | 13 | func _on_Play_pressed(): 14 | var ok := get_tree().change_scene("res://menu/cutscenes/Intro.tscn") 15 | assert(OK == ok) 16 | 17 | func _on_Settings_pressed(): 18 | Settings.get_node("Background").show() 19 | 20 | func _on_Quit_pressed(): 21 | get_tree().quit() 22 | -------------------------------------------------------------------------------- /menu/TitleScreen.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=8 format=2] 2 | 3 | [ext_resource path="res://menu/backgrounds.png" type="Texture" id=1] 4 | [ext_resource path="res://menu/TitleScreen.gd" type="Script" id=2] 5 | [ext_resource path="res://menu/title.png" type="Texture" id=3] 6 | [ext_resource path="res://music/title.ogg" type="AudioStream" id=4] 7 | [ext_resource path="res://menu/CustomButton.tscn" type="PackedScene" id=5] 8 | 9 | [sub_resource type="Animation" id=1] 10 | resource_name = "start" 11 | length = 2.0 12 | tracks/0/type = "value" 13 | tracks/0/path = NodePath("Sprite:offset") 14 | tracks/0/interp = 1 15 | tracks/0/loop_wrap = true 16 | tracks/0/imported = false 17 | tracks/0/enabled = true 18 | tracks/0/keys = { 19 | "times": PoolRealArray( 0, 2 ), 20 | "transitions": PoolRealArray( 0.2, 1 ), 21 | "update": 0, 22 | "values": [ Vector2( 0, 200 ), Vector2( 0, 0 ) ] 23 | } 24 | 25 | [sub_resource type="Animation" id=2] 26 | resource_name = "loop" 27 | length = 6.0 28 | loop = true 29 | tracks/0/type = "value" 30 | tracks/0/path = NodePath("../Title:modulate") 31 | tracks/0/interp = 1 32 | tracks/0/loop_wrap = true 33 | tracks/0/imported = false 34 | tracks/0/enabled = true 35 | tracks/0/keys = { 36 | "times": PoolRealArray( 0, 2.3, 2.4, 3.9, 4, 4.2, 4.3, 5.7, 5.8 ), 37 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1, 1, 1 ), 38 | "update": 1, 39 | "values": [ Color( 1, 1, 1, 1 ), Color( 0.494118, 0.380392, 0.380392, 0.545098 ), Color( 1, 1, 1, 1 ), Color( 0.494118, 0.380392, 0.380392, 0.545098 ), Color( 1, 1, 1, 1 ), Color( 0.494118, 0.380392, 0.380392, 0.545098 ), Color( 1, 1, 1, 1 ), Color( 0.494118, 0.380392, 0.380392, 0.545098 ), Color( 1, 1, 1, 1 ) ] 40 | } 41 | 42 | [node name="TitleScreen" type="VBoxContainer"] 43 | anchor_right = 1.0 44 | anchor_bottom = 1.0 45 | margin_left = 10.0 46 | margin_top = 10.0 47 | margin_right = -10.0 48 | margin_bottom = -10.0 49 | script = ExtResource( 2 ) 50 | __meta__ = { 51 | "_edit_use_anchors_": false 52 | } 53 | 54 | [node name="Background" type="CanvasLayer" parent="."] 55 | layer = -1 56 | 57 | [node name="Sprite" type="Sprite" parent="Background"] 58 | scale = Vector2( 2, 2 ) 59 | texture = ExtResource( 1 ) 60 | centered = false 61 | offset = Vector2( 0, 200 ) 62 | vframes = 4 63 | hframes = 2 64 | 65 | [node name="Start" type="AnimationPlayer" parent="Background"] 66 | autoplay = "start" 67 | anims/start = SubResource( 1 ) 68 | 69 | [node name="Loop" type="AnimationPlayer" parent="Background"] 70 | autoplay = "loop" 71 | anims/loop = SubResource( 2 ) 72 | 73 | [node name="Title" type="TextureRect" parent="."] 74 | margin_right = 492.0 75 | margin_bottom = 105.0 76 | texture = ExtResource( 3 ) 77 | stretch_mode = 4 78 | 79 | [node name="HighScore" type="Label" parent="."] 80 | margin_top = 109.0 81 | margin_right = 492.0 82 | margin_bottom = 117.0 83 | text = "High Score" 84 | align = 1 85 | __meta__ = { 86 | "_edit_use_anchors_": false 87 | } 88 | 89 | [node name="Buttons" type="VBoxContainer" parent="."] 90 | margin_left = 206.0 91 | margin_top = 121.0 92 | margin_right = 286.0 93 | margin_bottom = 201.0 94 | size_flags_horizontal = 4 95 | size_flags_vertical = 2 96 | alignment = 1 97 | 98 | [node name="Play" parent="Buttons" instance=ExtResource( 5 )] 99 | 100 | [node name="Label" parent="Buttons/Play" index="0"] 101 | text = "Play" 102 | 103 | [node name="Settings" parent="Buttons" instance=ExtResource( 5 )] 104 | margin_top = 28.0 105 | margin_bottom = 52.0 106 | 107 | [node name="Label" parent="Buttons/Settings" index="0"] 108 | text = "Settings" 109 | 110 | [node name="Quit" parent="Buttons" instance=ExtResource( 5 )] 111 | margin_top = 56.0 112 | margin_bottom = 80.0 113 | 114 | [node name="Label" parent="Buttons/Quit" index="0"] 115 | text = "Quit" 116 | 117 | [node name="Legal" type="Label" parent="."] 118 | modulate = Color( 0, 0, 0, 1 ) 119 | margin_top = 260.0 120 | margin_right = 492.0 121 | margin_bottom = 268.0 122 | text = "Ludum Dare #46 \"keep it alive\" --- © cagibi.itch.io" 123 | align = 1 124 | 125 | [node name="Music" type="AudioStreamPlayer" parent="."] 126 | stream = ExtResource( 4 ) 127 | autoplay = true 128 | bus = "music" 129 | [connection signal="pressed" from="Buttons/Play" to="." method="_on_Play_pressed"] 130 | [connection signal="pressed" from="Buttons/Settings" to="." method="_on_Settings_pressed"] 131 | [connection signal="pressed" from="Buttons/Quit" to="." method="_on_Quit_pressed"] 132 | 133 | [editable path="Buttons/Play"] 134 | 135 | [editable path="Buttons/Settings"] 136 | 137 | [editable path="Buttons/Quit"] 138 | -------------------------------------------------------------------------------- /menu/backgrounds.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/backgrounds.png -------------------------------------------------------------------------------- /menu/backgrounds.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/backgrounds.png-69801ab8bc16191d7a823937f1a093c7.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/backgrounds.png" 13 | dest_files=[ "res://.import/backgrounds.png-69801ab8bc16191d7a823937f1a093c7.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /menu/button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/button.png -------------------------------------------------------------------------------- /menu/button.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/button.png-e6ddd405c0968c9fb68dca7b600a69a3.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/button.png" 13 | dest_files=[ "res://.import/button.png-e6ddd405c0968c9fb68dca7b600a69a3.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /menu/cutscenes/Intro.gd: -------------------------------------------------------------------------------- 1 | extends Node2D 2 | 3 | func _input(event: InputEvent): 4 | if event.is_action_pressed("shoot") or event.is_action_pressed("ui_accept"): 5 | _on_Skip_pressed() 6 | 7 | func _on_Skip_pressed(): 8 | $Music/FadeTween.interpolate_property($Music, "volume_db", -3, -60, 1.0, Tween.TRANS_EXPO) 9 | $Music/FadeTween.start() 10 | $Background/Waves.stop() 11 | $Go.play("go") 12 | yield(get_tree().create_timer(1.0), "timeout") 13 | var ok := get_tree().change_scene("res://world/World.tscn") 14 | assert(OK == ok) 15 | -------------------------------------------------------------------------------- /menu/cutscenes/Intro.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=8 format=2] 2 | 3 | [ext_resource path="res://music/intro.ogg" type="AudioStream" id=1] 4 | [ext_resource path="res://menu/cutscenes/Intro.gd" type="Script" id=5] 5 | [ext_resource path="res://menu/cutscenes/accept.wav" type="AudioStream" id=6] 6 | [ext_resource path="res://menu/backgrounds.png" type="Texture" id=7] 7 | 8 | [sub_resource type="Animation" id=1] 9 | resource_name = "waves" 10 | length = 3.0 11 | loop = true 12 | step = 1.5 13 | tracks/0/type = "value" 14 | tracks/0/path = NodePath(".:offset") 15 | tracks/0/interp = 2 16 | tracks/0/loop_wrap = true 17 | tracks/0/imported = false 18 | tracks/0/enabled = true 19 | tracks/0/keys = { 20 | "times": PoolRealArray( 0, 1.5 ), 21 | "transitions": PoolRealArray( 1, 1 ), 22 | "update": 0, 23 | "values": [ Vector2( 0, -5 ), Vector2( 0, 0 ) ] 24 | } 25 | 26 | [sub_resource type="Animation" id=2] 27 | length = 20.0 28 | step = 0.5 29 | tracks/0/type = "value" 30 | tracks/0/path = NodePath("Background/Label:text") 31 | tracks/0/interp = 1 32 | tracks/0/loop_wrap = true 33 | tracks/0/imported = false 34 | tracks/0/enabled = true 35 | tracks/0/keys = { 36 | "times": PoolRealArray( 0, 2, 5.5, 9, 18 ), 37 | "transitions": PoolRealArray( 1, 1, 1, 1, 1 ), 38 | "update": 1, 39 | "values": [ "", "You live in a lighthouse.", "You live in a lighthouse. 40 | 41 | The only one in the ocean.", "You live in a lighthouse. 42 | 43 | The only one in the ocean. 44 | 45 | Each night, shadow pirates come to turn it off... will they succeed this time? 46 | ", "Good luck." ] 47 | } 48 | tracks/1/type = "audio" 49 | tracks/1/path = NodePath("Music") 50 | tracks/1/interp = 1 51 | tracks/1/loop_wrap = true 52 | tracks/1/imported = false 53 | tracks/1/enabled = true 54 | tracks/1/keys = { 55 | "clips": [ { 56 | "end_offset": 0.0, 57 | "start_offset": 0.0, 58 | "stream": ExtResource( 1 ) 59 | } ], 60 | "times": PoolRealArray( 2 ) 61 | } 62 | tracks/2/type = "value" 63 | tracks/2/path = NodePath("Background:self_modulate") 64 | tracks/2/interp = 1 65 | tracks/2/loop_wrap = true 66 | tracks/2/imported = false 67 | tracks/2/enabled = true 68 | tracks/2/keys = { 69 | "times": PoolRealArray( 0, 1.5, 5, 5.5, 6, 9, 10, 11, 17.5, 18 ), 70 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ), 71 | "update": 0, 72 | "values": [ Color( 0.0705882, 0.207843, 0.356863, 0 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0.0705882, 0.207843, 0.356863, 0 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0.0705882, 0.207843, 0.356863, 0 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0.0705882, 0.207843, 0.356863, 0 ) ] 73 | } 74 | tracks/3/type = "value" 75 | tracks/3/path = NodePath("Background/Skip:text") 76 | tracks/3/interp = 1 77 | tracks/3/loop_wrap = true 78 | tracks/3/imported = false 79 | tracks/3/enabled = true 80 | tracks/3/keys = { 81 | "times": PoolRealArray( 0, 18 ), 82 | "transitions": PoolRealArray( 1, 1 ), 83 | "update": 1, 84 | "values": [ "> Click here to skip <", "> Click here to start <" ] 85 | } 86 | tracks/4/type = "value" 87 | tracks/4/path = NodePath("Background:frame") 88 | tracks/4/interp = 1 89 | tracks/4/loop_wrap = true 90 | tracks/4/imported = false 91 | tracks/4/enabled = true 92 | tracks/4/keys = { 93 | "times": PoolRealArray( 0, 5.5, 10 ), 94 | "transitions": PoolRealArray( 1, 1, 1 ), 95 | "update": 1, 96 | "values": [ 2, 3, 4 ] 97 | } 98 | 99 | [sub_resource type="Animation" id=3] 100 | resource_name = "go" 101 | step = 0.05 102 | tracks/0/type = "value" 103 | tracks/0/path = NodePath("Background:position") 104 | tracks/0/interp = 1 105 | tracks/0/loop_wrap = true 106 | tracks/0/imported = false 107 | tracks/0/enabled = true 108 | tracks/0/keys = { 109 | "times": PoolRealArray( 0, 1 ), 110 | "transitions": PoolRealArray( 5, 1 ), 111 | "update": 0, 112 | "values": [ Vector2( 0, 0 ), Vector2( 0, -300 ) ] 113 | } 114 | tracks/1/type = "audio" 115 | tracks/1/path = NodePath("Go/Sound") 116 | tracks/1/interp = 1 117 | tracks/1/loop_wrap = true 118 | tracks/1/imported = false 119 | tracks/1/enabled = true 120 | tracks/1/keys = { 121 | "clips": [ { 122 | "end_offset": 0.0, 123 | "start_offset": 0.0, 124 | "stream": ExtResource( 6 ) 125 | } ], 126 | "times": PoolRealArray( 0 ) 127 | } 128 | tracks/2/type = "value" 129 | tracks/2/path = NodePath("Background/Skip:modulate") 130 | tracks/2/interp = 1 131 | tracks/2/loop_wrap = true 132 | tracks/2/imported = false 133 | tracks/2/enabled = true 134 | tracks/2/keys = { 135 | "times": PoolRealArray( 0, 0.05, 1 ), 136 | "transitions": PoolRealArray( 1, 1, 1 ), 137 | "update": 0, 138 | "values": [ Color( 0.647059, 0.352941, 0.0823529, 1 ), Color( 1, 1, 1, 1 ), Color( 0.647059, 0.352941, 0.0823529, 0 ) ] 139 | } 140 | 141 | [node name="Intro" type="Node2D"] 142 | script = ExtResource( 5 ) 143 | 144 | [node name="Music" type="AudioStreamPlayer" parent="."] 145 | stream = ExtResource( 1 ) 146 | bus = "music" 147 | 148 | [node name="FadeTween" type="Tween" parent="Music"] 149 | 150 | [node name="Background" type="Sprite" parent="."] 151 | scale = Vector2( 2, 2 ) 152 | texture = ExtResource( 7 ) 153 | centered = false 154 | offset = Vector2( 0, -5 ) 155 | vframes = 4 156 | hframes = 2 157 | frame = 4 158 | 159 | [node name="Label" type="Label" parent="Background"] 160 | anchor_right = 1.0 161 | anchor_bottom = 1.0 162 | margin_left = 10.0 163 | margin_top = 10.0 164 | margin_right = -10.0 165 | margin_bottom = 160.0 166 | text = "You live in a lighthouse. 167 | 168 | The only one in the ocean. 169 | 170 | Each night, shadow pirates come to turn it off... will they succeed this time? 171 | " 172 | align = 1 173 | autowrap = true 174 | __meta__ = { 175 | "_edit_use_anchors_": false 176 | } 177 | 178 | [node name="Waves" type="AnimationPlayer" parent="Background"] 179 | autoplay = "waves" 180 | anims/waves = SubResource( 1 ) 181 | 182 | [node name="Skip" type="Button" parent="Background"] 183 | modulate = Color( 0.647059, 0.352941, 0.0823529, 1 ) 184 | anchor_top = 1.0 185 | anchor_right = 1.0 186 | anchor_bottom = 1.0 187 | margin_top = -13.0 188 | margin_right = -10.0 189 | margin_bottom = -5.0 190 | text = "> Click here to skip <" 191 | flat = true 192 | __meta__ = { 193 | "_edit_use_anchors_": false 194 | } 195 | 196 | [node name="AnimationPlayer" type="AnimationPlayer" parent="."] 197 | autoplay = "cutscene" 198 | anims/cutscene = SubResource( 2 ) 199 | 200 | [node name="Go" type="AnimationPlayer" parent="."] 201 | anims/go = SubResource( 3 ) 202 | 203 | [node name="Sound" type="AudioStreamPlayer" parent="Go"] 204 | stream = ExtResource( 6 ) 205 | bus = "sfx" 206 | [connection signal="pressed" from="Background/Skip" to="." method="_on_Skip_pressed"] 207 | -------------------------------------------------------------------------------- /menu/cutscenes/Outro.gd: -------------------------------------------------------------------------------- 1 | extends Node2D 2 | 3 | func _input(event: InputEvent): 4 | if event.is_action_pressed("shoot") or event.is_action_pressed("ui_accept"): 5 | _on_Skip_pressed() 6 | 7 | func _on_Skip_pressed(): 8 | $Go.play("go") 9 | $Music.stop() 10 | yield(get_tree().create_timer(1.0), "timeout") 11 | var ok := get_tree().change_scene("res://menu/TitleScreen.tscn") 12 | assert(OK == ok) 13 | 14 | func show_score(): 15 | $Background/Label.text += "\n\nScore: " + str(Globals.score) 16 | -------------------------------------------------------------------------------- /menu/cutscenes/Outro.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=8 format=2] 2 | 3 | [ext_resource path="res://music/outro.ogg" type="AudioStream" id=1] 4 | [ext_resource path="res://menu/backgrounds.png" type="Texture" id=2] 5 | [ext_resource path="res://menu/cutscenes/Outro.gd" type="Script" id=4] 6 | [ext_resource path="res://menu/cutscenes/accept.wav" type="AudioStream" id=5] 7 | 8 | [sub_resource type="Animation" id=1] 9 | resource_name = "waves" 10 | length = 6.0 11 | loop = true 12 | step = 1.5 13 | tracks/0/type = "value" 14 | tracks/0/path = NodePath(".:offset") 15 | tracks/0/interp = 2 16 | tracks/0/loop_wrap = true 17 | tracks/0/imported = false 18 | tracks/0/enabled = true 19 | tracks/0/keys = { 20 | "times": PoolRealArray( 0, 3 ), 21 | "transitions": PoolRealArray( 1, 1 ), 22 | "update": 0, 23 | "values": [ Vector2( 0, -3 ), Vector2( 0, 0 ) ] 24 | } 25 | 26 | [sub_resource type="Animation" id=2] 27 | length = 24.0 28 | step = 0.5 29 | tracks/0/type = "value" 30 | tracks/0/path = NodePath("Background/Label:text") 31 | tracks/0/interp = 1 32 | tracks/0/loop_wrap = true 33 | tracks/0/imported = false 34 | tracks/0/enabled = true 35 | tracks/0/keys = { 36 | "times": PoolRealArray( 0, 1, 4.5, 9, 15.5, 20 ), 37 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1 ), 38 | "update": 1, 39 | "values": [ "", "\"Why did you turn off the light?\"", "\"We could not see the stars\", the pirates responded.", "The night sky was now at its best. 40 | 41 | You spent hours watching the stars with the pirates.", "Sometimes you have to turn off a small light to keep big lights alive.", " 42 | 43 | 44 | THE END 45 | thanks for playing!" ] 46 | } 47 | tracks/1/type = "audio" 48 | tracks/1/path = NodePath("Music") 49 | tracks/1/interp = 1 50 | tracks/1/loop_wrap = true 51 | tracks/1/imported = false 52 | tracks/1/enabled = true 53 | tracks/1/keys = { 54 | "clips": [ { 55 | "end_offset": 0.0, 56 | "start_offset": 0.0, 57 | "stream": ExtResource( 1 ) 58 | } ], 59 | "times": PoolRealArray( 0.5 ) 60 | } 61 | tracks/2/type = "value" 62 | tracks/2/path = NodePath("Background:self_modulate") 63 | tracks/2/interp = 1 64 | tracks/2/loop_wrap = true 65 | tracks/2/imported = false 66 | tracks/2/enabled = true 67 | tracks/2/keys = { 68 | "times": PoolRealArray( 0, 1, 6, 6.5, 11, 20 ), 69 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1 ), 70 | "update": 0, 71 | "values": [ Color( 0.0705882, 0.207843, 0.356863, 0 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ), Color( 0.0705882, 0.207843, 0.356863, 0 ), Color( 1, 1, 1, 1 ), Color( 1, 1, 1, 1 ) ] 72 | } 73 | tracks/3/type = "value" 74 | tracks/3/path = NodePath("Background:frame") 75 | tracks/3/interp = 1 76 | tracks/3/loop_wrap = true 77 | tracks/3/imported = false 78 | tracks/3/enabled = true 79 | tracks/3/keys = { 80 | "times": PoolRealArray( 0, 6.5 ), 81 | "transitions": PoolRealArray( 1, 1 ), 82 | "update": 1, 83 | "values": [ 5, 6 ] 84 | } 85 | tracks/4/type = "method" 86 | tracks/4/path = NodePath(".") 87 | tracks/4/interp = 1 88 | tracks/4/loop_wrap = true 89 | tracks/4/imported = false 90 | tracks/4/enabled = true 91 | tracks/4/keys = { 92 | "times": PoolRealArray( 21 ), 93 | "transitions": PoolRealArray( 1 ), 94 | "values": [ { 95 | "args": [ ], 96 | "method": "show_score" 97 | } ] 98 | } 99 | 100 | [sub_resource type="Animation" id=3] 101 | resource_name = "go" 102 | tracks/0/type = "audio" 103 | tracks/0/path = NodePath("Go/Sound") 104 | tracks/0/interp = 1 105 | tracks/0/loop_wrap = true 106 | tracks/0/imported = false 107 | tracks/0/enabled = true 108 | tracks/0/keys = { 109 | "clips": [ { 110 | "end_offset": 0.0, 111 | "start_offset": 0.0, 112 | "stream": ExtResource( 5 ) 113 | } ], 114 | "times": PoolRealArray( 0 ) 115 | } 116 | tracks/1/type = "value" 117 | tracks/1/path = NodePath("Background:modulate") 118 | tracks/1/interp = 1 119 | tracks/1/loop_wrap = true 120 | tracks/1/imported = false 121 | tracks/1/enabled = true 122 | tracks/1/keys = { 123 | "times": PoolRealArray( 0, 1 ), 124 | "transitions": PoolRealArray( 5, 1 ), 125 | "update": 0, 126 | "values": [ Color( 1, 1, 1, 1 ), Color( 0, 0.431373, 0.937255, 0 ) ] 127 | } 128 | tracks/2/type = "value" 129 | tracks/2/path = NodePath("Background/Skip:modulate") 130 | tracks/2/interp = 1 131 | tracks/2/loop_wrap = true 132 | tracks/2/imported = false 133 | tracks/2/enabled = true 134 | tracks/2/keys = { 135 | "times": PoolRealArray( 0, 0.1, 0.2, 0.3, 0.4 ), 136 | "transitions": PoolRealArray( 1, 1, 1, 1, 1 ), 137 | "update": 1, 138 | "values": [ Color( 0.384314, 0.313726, 0.72549, 1 ), Color( 1, 1, 1, 1 ), Color( 0.384314, 0.313726, 0.72549, 1 ), Color( 1, 1, 1, 1 ), Color( 0.384314, 0.313726, 0.72549, 1 ) ] 139 | } 140 | 141 | [node name="Intro" type="Node2D"] 142 | script = ExtResource( 4 ) 143 | 144 | [node name="Music" type="AudioStreamPlayer" parent="."] 145 | stream = ExtResource( 1 ) 146 | bus = "music" 147 | 148 | [node name="Background" type="Sprite" parent="."] 149 | scale = Vector2( 2, 2 ) 150 | texture = ExtResource( 2 ) 151 | centered = false 152 | offset = Vector2( 0, -3 ) 153 | vframes = 4 154 | hframes = 2 155 | frame = 5 156 | 157 | [node name="Label" type="Label" parent="Background"] 158 | anchor_right = 1.0 159 | anchor_bottom = 1.0 160 | margin_left = 10.0 161 | margin_top = 10.0 162 | margin_right = -10.0 163 | margin_bottom = 160.0 164 | text = "\"Why did you turn off the light?\"" 165 | align = 1 166 | autowrap = true 167 | __meta__ = { 168 | "_edit_use_anchors_": false 169 | } 170 | 171 | [node name="Waves" type="AnimationPlayer" parent="Background"] 172 | autoplay = "waves" 173 | anims/waves = SubResource( 1 ) 174 | 175 | [node name="Skip" type="Button" parent="Background"] 176 | modulate = Color( 0.384314, 0.313726, 0.72549, 1 ) 177 | anchor_top = 1.0 178 | anchor_right = 1.0 179 | anchor_bottom = 1.0 180 | margin_top = -13.0 181 | margin_right = -10.0 182 | margin_bottom = -5.0 183 | text = "> Back to main menu <" 184 | flat = true 185 | __meta__ = { 186 | "_edit_use_anchors_": false 187 | } 188 | 189 | [node name="AnimationPlayer" type="AnimationPlayer" parent="."] 190 | autoplay = "cutscene" 191 | anims/cutscene = SubResource( 2 ) 192 | 193 | [node name="Go" type="AnimationPlayer" parent="."] 194 | anims/go = SubResource( 3 ) 195 | 196 | [node name="Sound" type="AudioStreamPlayer" parent="Go"] 197 | stream = ExtResource( 5 ) 198 | bus = "sfx" 199 | [connection signal="pressed" from="Background/Skip" to="." method="_on_Skip_pressed"] 200 | -------------------------------------------------------------------------------- /menu/cutscenes/accept.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/cutscenes/accept.wav -------------------------------------------------------------------------------- /menu/cutscenes/accept.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/accept.wav-15b3c0c9ea57f3b7c1a49339146348a7.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://menu/cutscenes/accept.wav" 10 | dest_files=[ "res://.import/accept.wav-15b3c0c9ea57f3b7c1a49339146348a7.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /menu/font/Volter__28Goldfish_29.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/font/Volter__28Goldfish_29.ttf -------------------------------------------------------------------------------- /menu/font/main_font.tres: -------------------------------------------------------------------------------- 1 | [gd_resource type="DynamicFont" load_steps=2 format=2] 2 | 3 | [ext_resource path="res://menu/font/Volter__28Goldfish_29.ttf" type="DynamicFontData" id=1] 4 | 5 | [resource] 6 | size = 9 7 | extra_spacing_top = -1 8 | extra_spacing_bottom = -1 9 | font_data = ExtResource( 1 ) 10 | -------------------------------------------------------------------------------- /menu/gameover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/gameover.png -------------------------------------------------------------------------------- /menu/gameover.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/gameover.png-523e29de7ae1ecb7c612047e4c4eb75e.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/gameover.png" 13 | dest_files=[ "res://.import/gameover.png-523e29de7ae1ecb7c612047e4c4eb75e.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /menu/numbers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/numbers.png -------------------------------------------------------------------------------- /menu/numbers.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/numbers.png-b746f34a69fcbebab0a5fb9cb764c2b7.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/numbers.png" 13 | dest_files=[ "res://.import/numbers.png-b746f34a69fcbebab0a5fb9cb764c2b7.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /menu/score.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/score.png -------------------------------------------------------------------------------- /menu/score.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/score.png-6dcaaef7c1d7474c93688eb385f37ca6.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/score.png" 13 | dest_files=[ "res://.import/score.png-6dcaaef7c1d7474c93688eb385f37ca6.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /menu/title.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/menu/title.png -------------------------------------------------------------------------------- /menu/title.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/title.png-3fc64a4da28f4bbbf1d01b0bc8d50fb1.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://menu/title.png" 13 | dest_files=[ "res://.import/title.png-3fc64a4da28f4bbbf1d01b0bc8d50fb1.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /music/intro.mmpz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/intro.mmpz -------------------------------------------------------------------------------- /music/intro.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/intro.ogg -------------------------------------------------------------------------------- /music/intro.ogg.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="ogg_vorbis" 4 | type="AudioStreamOGGVorbis" 5 | path="res://.import/intro.ogg-4097668e5352cd0def768e1f40c28db6.oggstr" 6 | 7 | [deps] 8 | 9 | source_file="res://music/intro.ogg" 10 | dest_files=[ "res://.import/intro.ogg-4097668e5352cd0def768e1f40c28db6.oggstr" ] 11 | 12 | [params] 13 | 14 | loop=false 15 | loop_offset=0 16 | -------------------------------------------------------------------------------- /music/level.mmpz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/level.mmpz -------------------------------------------------------------------------------- /music/level.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/level.ogg -------------------------------------------------------------------------------- /music/level.ogg.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="ogg_vorbis" 4 | type="AudioStreamOGGVorbis" 5 | path="res://.import/level.ogg-237e1acc70bb84fe555fccb679cf0280.oggstr" 6 | 7 | [deps] 8 | 9 | source_file="res://music/level.ogg" 10 | dest_files=[ "res://.import/level.ogg-237e1acc70bb84fe555fccb679cf0280.oggstr" ] 11 | 12 | [params] 13 | 14 | loop=true 15 | loop_offset=57.6 16 | -------------------------------------------------------------------------------- /music/outro.mmpz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/outro.mmpz -------------------------------------------------------------------------------- /music/outro.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/outro.ogg -------------------------------------------------------------------------------- /music/outro.ogg.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="ogg_vorbis" 4 | type="AudioStreamOGGVorbis" 5 | path="res://.import/outro.ogg-c4b81ae26d61d5ad9888c46369cfd2e5.oggstr" 6 | 7 | [deps] 8 | 9 | source_file="res://music/outro.ogg" 10 | dest_files=[ "res://.import/outro.ogg-c4b81ae26d61d5ad9888c46369cfd2e5.oggstr" ] 11 | 12 | [params] 13 | 14 | loop=false 15 | loop_offset=0 16 | -------------------------------------------------------------------------------- /music/title.mmpz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/title.mmpz -------------------------------------------------------------------------------- /music/title.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/music/title.ogg -------------------------------------------------------------------------------- /music/title.ogg.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="ogg_vorbis" 4 | type="AudioStreamOGGVorbis" 5 | path="res://.import/title.ogg-2544ba0adf0d074f444d756e38676b7f.oggstr" 6 | 7 | [deps] 8 | 9 | source_file="res://music/title.ogg" 10 | dest_files=[ "res://.import/title.ogg-2544ba0adf0d074f444d756e38676b7f.oggstr" ] 11 | 12 | [params] 13 | 14 | loop=true 15 | loop_offset=0 16 | -------------------------------------------------------------------------------- /player/Player.gd: -------------------------------------------------------------------------------- 1 | extends KinematicBody2D 2 | 3 | signal shoot(position, vel, bullet) 4 | signal dead(player) 5 | 6 | var bullet := preload("res://player/PlayerBullet.tscn") 7 | var velocity := Vector2.ZERO 8 | var max_speed := 100.0 9 | var bullet_speed := 200.0 10 | var can_shoot := true 11 | var vulnerable := false 12 | var mouse_mode := false 13 | 14 | func _input(event: InputEvent): 15 | if event is InputEventMouseMotion: 16 | mouse_mode = true 17 | 18 | func _physics_process(_delta: float): 19 | var target_vel := Vector2.ZERO 20 | 21 | var padinput_vel := Vector2( 22 | Input.get_action_strength("move_right") - Input.get_action_strength("move_left"), 23 | Input.get_action_strength("move_down") - Input.get_action_strength("move_up")) 24 | if padinput_vel != Vector2.ZERO: 25 | mouse_mode = false 26 | if mouse_mode: 27 | if get_local_mouse_position().length() > 15: 28 | target_vel = get_local_mouse_position() 29 | else: 30 | target_vel = padinput_vel 31 | 32 | target_vel = target_vel.normalized() 33 | if target_vel.x != 0: 34 | $Sprite.scale.x = -sign(target_vel.x) 35 | if target_vel.y != 0: 36 | $Sprite.frame = 1 if target_vel.y < 0 else 0 37 | 38 | var mouse_vec := target_vel.normalized() 39 | if target_vel == Vector2.ZERO: 40 | mouse_vec = Vector2.RIGHT.rotated($ShootLine.rotation) 41 | $ShootLine.rotation = lerp_angle($ShootLine.rotation, mouse_vec.angle(), 0.2) 42 | 43 | if Input.is_mouse_button_pressed(BUTTON_LEFT) or Input.is_action_pressed("shoot"): 44 | shoot(bullet_speed * mouse_vec) 45 | 46 | velocity = lerp(velocity, target_vel*max_speed, 0.05) 47 | velocity = move_and_slide(velocity) 48 | 49 | func shoot(vel: Vector2): 50 | if can_shoot: 51 | can_shoot = false 52 | $ShootLine.region_rect.position.y = 16.0 53 | $Shoot/Timer.start() 54 | $CooldownBar/AnimationPlayer.playback_speed = 1.0 / $Shoot/Timer.wait_time 55 | $CooldownBar/AnimationPlayer.play("charge") 56 | $Shoot.play() 57 | emit_signal("shoot", global_position, vel, bullet) 58 | velocity -= vel 59 | 60 | func _on_HitBox_area_entered(_area: CollisionObject2D): 61 | if vulnerable: 62 | vulnerable = false 63 | $Hurt.play() 64 | hide() 65 | set_physics_process(false) 66 | emit_signal("dead", self) 67 | 68 | func _on_Timer_timeout(): 69 | can_shoot = true 70 | $ShootLine.region_rect.position.y = 0.0 71 | 72 | func _on_HurtTimer_timeout(): 73 | vulnerable = true 74 | $Immune.stop() 75 | show() 76 | -------------------------------------------------------------------------------- /player/Player.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=17 format=2] 2 | 3 | [ext_resource path="res://player/player.png" type="Texture" id=1] 4 | [ext_resource path="res://player/Player.gd" type="Script" id=2] 5 | [ext_resource path="res://world/light.png" type="Texture" id=3] 6 | [ext_resource path="res://player/cannon.wav" type="AudioStream" id=5] 7 | [ext_resource path="res://player/hurt.wav" type="AudioStream" id=6] 8 | 9 | [sub_resource type="CanvasItemMaterial" id=1] 10 | light_mode = 1 11 | 12 | [sub_resource type="CanvasItemMaterial" id=2] 13 | light_mode = 1 14 | 15 | [sub_resource type="RectangleShape2D" id=3] 16 | extents = Vector2( 12, 6 ) 17 | 18 | [sub_resource type="Animation" id=4] 19 | resource_name = "start" 20 | length = 5.0 21 | step = 1.0 22 | tracks/0/type = "value" 23 | tracks/0/path = NodePath(".:energy") 24 | tracks/0/interp = 1 25 | tracks/0/loop_wrap = true 26 | tracks/0/imported = false 27 | tracks/0/enabled = true 28 | tracks/0/keys = { 29 | "times": PoolRealArray( 0, 3, 5 ), 30 | "transitions": PoolRealArray( 1, 0.2, 1 ), 31 | "update": 0, 32 | "values": [ 0.0, 0.0, 0.8 ] 33 | } 34 | tracks/1/type = "value" 35 | tracks/1/path = NodePath("../BigLight:energy") 36 | tracks/1/interp = 1 37 | tracks/1/loop_wrap = true 38 | tracks/1/imported = false 39 | tracks/1/enabled = true 40 | tracks/1/keys = { 41 | "times": PoolRealArray( 0, 3, 5 ), 42 | "transitions": PoolRealArray( 1, 0.2, 1 ), 43 | "update": 0, 44 | "values": [ 0.0, 0.0, 0.5 ] 45 | } 46 | 47 | [sub_resource type="Animation" id=5] 48 | length = 4.0 49 | loop = true 50 | step = 1.0 51 | tracks/0/type = "value" 52 | tracks/0/path = NodePath("SmallLight:texture_scale") 53 | tracks/0/interp = 2 54 | tracks/0/loop_wrap = true 55 | tracks/0/imported = false 56 | tracks/0/enabled = true 57 | tracks/0/keys = { 58 | "times": PoolRealArray( 0, 1, 2, 3 ), 59 | "transitions": PoolRealArray( 1, 1, 1, 1 ), 60 | "update": 0, 61 | "values": [ 0.06, 0.05, 0.06, 0.05 ] 62 | } 63 | tracks/1/type = "value" 64 | tracks/1/path = NodePath("BigLight:texture_scale") 65 | tracks/1/interp = 2 66 | tracks/1/loop_wrap = true 67 | tracks/1/imported = false 68 | tracks/1/enabled = true 69 | tracks/1/keys = { 70 | "times": PoolRealArray( 0, 1, 2, 3 ), 71 | "transitions": PoolRealArray( 1, 1, 1, 1 ), 72 | "update": 0, 73 | "values": [ 0.1, 0.13, 0.1, 0.13 ] 74 | } 75 | tracks/2/type = "value" 76 | tracks/2/path = NodePath("Sprite:rotation_degrees") 77 | tracks/2/interp = 2 78 | tracks/2/loop_wrap = true 79 | tracks/2/imported = false 80 | tracks/2/enabled = true 81 | tracks/2/keys = { 82 | "times": PoolRealArray( 0, 2 ), 83 | "transitions": PoolRealArray( 1, 1 ), 84 | "update": 0, 85 | "values": [ -10.0, 10.0 ] 86 | } 87 | 88 | [sub_resource type="CircleShape2D" id=6] 89 | 90 | [sub_resource type="Animation" id=7] 91 | length = 0.6 92 | loop = true 93 | step = 0.2 94 | tracks/0/type = "value" 95 | tracks/0/path = NodePath("Sprite:visible") 96 | tracks/0/interp = 1 97 | tracks/0/loop_wrap = true 98 | tracks/0/imported = false 99 | tracks/0/enabled = true 100 | tracks/0/keys = { 101 | "times": PoolRealArray( 0, 0.4 ), 102 | "transitions": PoolRealArray( 1, 1 ), 103 | "update": 1, 104 | "values": [ true, false ] 105 | } 106 | 107 | [sub_resource type="CanvasItemMaterial" id=11] 108 | light_mode = 1 109 | 110 | [sub_resource type="AtlasTexture" id=9] 111 | atlas = ExtResource( 1 ) 112 | region = Rect2( 0, 32, 64, 16 ) 113 | 114 | [sub_resource type="AtlasTexture" id=10] 115 | atlas = ExtResource( 1 ) 116 | region = Rect2( 64, 32, 64, 16 ) 117 | 118 | [sub_resource type="Animation" id=8] 119 | resource_name = "charge" 120 | tracks/0/type = "value" 121 | tracks/0/path = NodePath(".:value") 122 | tracks/0/interp = 1 123 | tracks/0/loop_wrap = true 124 | tracks/0/imported = false 125 | tracks/0/enabled = true 126 | tracks/0/keys = { 127 | "times": PoolRealArray( 0, 1 ), 128 | "transitions": PoolRealArray( 1, 1 ), 129 | "update": 0, 130 | "values": [ 0.0, 100.0 ] 131 | } 132 | tracks/1/type = "value" 133 | tracks/1/path = NodePath(".:visible") 134 | tracks/1/interp = 1 135 | tracks/1/loop_wrap = true 136 | tracks/1/imported = false 137 | tracks/1/enabled = true 138 | tracks/1/keys = { 139 | "times": PoolRealArray( 0, 1 ), 140 | "transitions": PoolRealArray( 1, 1 ), 141 | "update": 1, 142 | "values": [ true, false ] 143 | } 144 | 145 | [node name="Player" type="KinematicBody2D"] 146 | collision_layer = 2 147 | script = ExtResource( 2 ) 148 | 149 | [node name="Sprite" type="Sprite" parent="."] 150 | material = SubResource( 1 ) 151 | position = Vector2( 0, -8 ) 152 | rotation = -0.174533 153 | texture = ExtResource( 1 ) 154 | vframes = 2 155 | hframes = 4 156 | 157 | [node name="ShootLine" type="Sprite" parent="."] 158 | material = SubResource( 2 ) 159 | position = Vector2( 0, -5 ) 160 | texture = ExtResource( 1 ) 161 | offset = Vector2( 36, 0 ) 162 | region_enabled = true 163 | region_rect = Rect2( 64, 0, 48, 16 ) 164 | 165 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 166 | position = Vector2( 0, -2 ) 167 | shape = SubResource( 3 ) 168 | 169 | [node name="SmallLight" type="Light2D" parent="."] 170 | position = Vector2( 0, -4 ) 171 | texture = ExtResource( 3 ) 172 | texture_scale = 0.06 173 | energy = 0.8 174 | 175 | [node name="Start" type="AnimationPlayer" parent="SmallLight"] 176 | autoplay = "start" 177 | anims/start = SubResource( 4 ) 178 | 179 | [node name="BigLight" type="Light2D" parent="."] 180 | position = Vector2( 0, -4 ) 181 | texture = ExtResource( 3 ) 182 | texture_scale = 0.1 183 | energy = 0.5 184 | 185 | [node name="AnimationPlayer" type="AnimationPlayer" parent="."] 186 | autoplay = "default" 187 | anims/default = SubResource( 5 ) 188 | 189 | [node name="Shoot" type="AudioStreamPlayer2D" parent="."] 190 | stream = ExtResource( 5 ) 191 | bus = "sfx" 192 | 193 | [node name="Timer" type="Timer" parent="Shoot"] 194 | wait_time = 0.9 195 | one_shot = true 196 | 197 | [node name="CPUParticles2D" type="CPUParticles2D" parent="."] 198 | z_index = -9 199 | amount = 20 200 | lifetime_randomness = 0.2 201 | local_coords = false 202 | spread = 180.0 203 | gravity = Vector2( 0, 0 ) 204 | initial_velocity = 20.0 205 | damping = 50.0 206 | scale_amount = 2.0 207 | 208 | [node name="HitBox" type="Area2D" parent="."] 209 | collision_layer = 0 210 | collision_mask = 8 211 | 212 | [node name="CollisionShape2D" type="CollisionShape2D" parent="HitBox"] 213 | position = Vector2( 0, -5 ) 214 | shape = SubResource( 6 ) 215 | 216 | [node name="Hurt" type="AudioStreamPlayer2D" parent="."] 217 | stream = ExtResource( 6 ) 218 | bus = "sfx" 219 | 220 | [node name="Timer" type="Timer" parent="Hurt"] 221 | wait_time = 2.0 222 | one_shot = true 223 | autostart = true 224 | 225 | [node name="Immune" type="AnimationPlayer" parent="."] 226 | anims/immune = SubResource( 7 ) 227 | 228 | [node name="CooldownBar" type="TextureProgress" parent="."] 229 | visible = false 230 | material = SubResource( 11 ) 231 | margin_left = -32.0 232 | margin_top = 7.0 233 | margin_right = 32.0 234 | margin_bottom = 15.0 235 | value = 100.0 236 | texture_under = SubResource( 9 ) 237 | texture_progress = SubResource( 10 ) 238 | __meta__ = { 239 | "_edit_use_anchors_": false 240 | } 241 | 242 | [node name="AnimationPlayer" type="AnimationPlayer" parent="CooldownBar"] 243 | anims/charge = SubResource( 8 ) 244 | [connection signal="timeout" from="Shoot/Timer" to="." method="_on_Timer_timeout"] 245 | [connection signal="area_entered" from="HitBox" to="." method="_on_HitBox_area_entered"] 246 | [connection signal="body_entered" from="HitBox" to="." method="_on_HitBox_area_entered"] 247 | [connection signal="timeout" from="Hurt/Timer" to="." method="_on_HurtTimer_timeout"] 248 | -------------------------------------------------------------------------------- /player/PlayerBullet.gd: -------------------------------------------------------------------------------- 1 | extends Area2D 2 | 3 | var velocity := Vector2.ZERO 4 | var invincible := false 5 | 6 | func _physics_process(delta: float): 7 | position += velocity * delta 8 | 9 | func destroy(): 10 | if not invincible: 11 | _plan_destruction() 12 | 13 | func _on_VisibilityNotifier2D_screen_exited(): 14 | _plan_destruction() 15 | 16 | func _plan_destruction(): 17 | $Sprite.self_modulate.a = 0 18 | $Sprite/Trail.set_deferred("emitting", false) 19 | $Light2D.hide() 20 | velocity *= 0 21 | $CollisionShape2D.set_deferred("disabled", true) 22 | $DeadTimer.call_deferred("start") 23 | 24 | func _on_DeadTimer_timeout(): 25 | queue_free() 26 | -------------------------------------------------------------------------------- /player/PlayerBullet.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=8 format=2] 2 | 3 | [ext_resource path="res://player/player.png" type="Texture" id=1] 4 | [ext_resource path="res://player/PlayerBullet.gd" type="Script" id=2] 5 | [ext_resource path="res://world/light.png" type="Texture" id=3] 6 | 7 | [sub_resource type="CanvasItemMaterial" id=1] 8 | 9 | [sub_resource type="CanvasItemMaterial" id=2] 10 | blend_mode = 1 11 | light_mode = 1 12 | 13 | [sub_resource type="Gradient" id=3] 14 | offsets = PoolRealArray( 0, 0.463576, 1 ) 15 | colors = PoolColorArray( 1, 1, 1, 1, 1, 0.727417, 0.207031, 1, 0.454916, 0.221008, 0.832031, 1 ) 16 | 17 | [sub_resource type="CircleShape2D" id=4] 18 | 19 | [node name="PlayerBullet" type="Area2D"] 20 | collision_layer = 4 21 | collision_mask = 8 22 | script = ExtResource( 2 ) 23 | 24 | [node name="Sprite" type="Sprite" parent="."] 25 | material = SubResource( 1 ) 26 | position = Vector2( 0, -8 ) 27 | texture = ExtResource( 1 ) 28 | region_enabled = true 29 | region_rect = Rect2( 112, 0, 16, 24 ) 30 | 31 | [node name="Trail" type="CPUParticles2D" parent="Sprite"] 32 | show_behind_parent = true 33 | material = SubResource( 2 ) 34 | position = Vector2( 0, -4 ) 35 | amount = 10 36 | lifetime = 0.5 37 | local_coords = false 38 | gravity = Vector2( 0, 0 ) 39 | scale_amount = 4.0 40 | color_ramp = SubResource( 3 ) 41 | 42 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 43 | position = Vector2( 0, -12 ) 44 | shape = SubResource( 4 ) 45 | 46 | [node name="Light2D" type="Light2D" parent="."] 47 | position = Vector2( 0, -12 ) 48 | texture = ExtResource( 3 ) 49 | texture_scale = 0.03 50 | energy = 0.8 51 | 52 | [node name="VisibilityNotifier2D" type="VisibilityNotifier2D" parent="."] 53 | position = Vector2( 0, -6 ) 54 | rect = Rect2( -20, -20, 40, 40 ) 55 | 56 | [node name="DeadTimer" type="Timer" parent="."] 57 | wait_time = 0.5 58 | one_shot = true 59 | [connection signal="screen_exited" from="VisibilityNotifier2D" to="." method="_on_VisibilityNotifier2D_screen_exited"] 60 | [connection signal="timeout" from="DeadTimer" to="." method="_on_DeadTimer_timeout"] 61 | -------------------------------------------------------------------------------- /player/cannon.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/player/cannon.wav -------------------------------------------------------------------------------- /player/cannon.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/cannon.wav-dad42012034d5427b9257697dbc0d8fa.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://player/cannon.wav" 10 | dest_files=[ "res://.import/cannon.wav-dad42012034d5427b9257697dbc0d8fa.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /player/cooldown_bar/background_flat_box.tres: -------------------------------------------------------------------------------- 1 | [gd_resource type="StyleBoxFlat" format=2] 2 | 3 | [resource] 4 | bg_color = Color( 0.188235, 0.105882, 0.0588235, 1 ) 5 | border_width_left = 1 6 | border_width_top = 1 7 | border_width_right = 1 8 | border_width_bottom = 1 9 | border_color = Color( 1, 1, 1, 1 ) 10 | anti_aliasing = false 11 | -------------------------------------------------------------------------------- /player/cooldown_bar/recharging_flat_box.tres: -------------------------------------------------------------------------------- 1 | [gd_resource type="StyleBoxFlat" format=2] 2 | 3 | [resource] 4 | bg_color = Color( 0.666667, 0.333333, 0.12549, 1 ) 5 | border_width_left = 1 6 | border_width_top = 1 7 | border_width_right = 1 8 | border_width_bottom = 1 9 | border_color = Color( 1, 1, 1, 1 ) 10 | anti_aliasing = false 11 | -------------------------------------------------------------------------------- /player/hurt.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/player/hurt.wav -------------------------------------------------------------------------------- /player/hurt.wav.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="wav" 4 | type="AudioStreamSample" 5 | path="res://.import/hurt.wav-f7645b9731c053d66aaeb8e0f288a157.sample" 6 | 7 | [deps] 8 | 9 | source_file="res://player/hurt.wav" 10 | dest_files=[ "res://.import/hurt.wav-f7645b9731c053d66aaeb8e0f288a157.sample" ] 11 | 12 | [params] 13 | 14 | force/8_bit=false 15 | force/mono=false 16 | force/max_rate=false 17 | force/max_rate_hz=44100 18 | edit/trim=false 19 | edit/normalize=false 20 | edit/loop=false 21 | compress/mode=0 22 | -------------------------------------------------------------------------------- /player/player.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/player/player.png -------------------------------------------------------------------------------- /player/player.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/player.png-1ad27fc2a62fa126eae918723933dd6f.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://player/player.png" 13 | dest_files=[ "res://.import/player.png-1ad27fc2a62fa126eae918723933dd6f.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /project.godot: -------------------------------------------------------------------------------- 1 | ; Engine configuration file. 2 | ; It's best edited using the editor UI and not directly, 3 | ; since the parameters that go here are not all obvious. 4 | ; 5 | ; Format: 6 | ; [section] ; section goes between [] 7 | ; param=value ; assign values to parameters 8 | 9 | config_version=4 10 | 11 | _global_script_classes=[ ] 12 | _global_script_class_icons={ 13 | 14 | } 15 | 16 | [application] 17 | 18 | config/name="Lighthouse Keeper" 19 | config/description="LightHouse Keeper and the Shadow Pirates" 20 | run/main_scene="res://menu/TitleScreen.tscn" 21 | boot_splash/image="res://splashscreen.png" 22 | boot_splash/use_filter=false 23 | boot_splash/bg_color=Color( 0.2, 0.333333, 0.6, 1 ) 24 | config/icon="res://icon.png" 25 | config/windows_native_icon="res://icon.ico" 26 | 27 | [autoload] 28 | 29 | Globals="*res://Globals.gd" 30 | Settings="*res://menu/Settings.tscn" 31 | 32 | [display] 33 | 34 | window/size/width=512 35 | window/size/height=288 36 | window/stretch/mode="2d" 37 | window/stretch/aspect="keep" 38 | 39 | [gui] 40 | 41 | theme/custom_font="res://menu/font/main_font.tres" 42 | 43 | [importer_defaults] 44 | 45 | texture={ 46 | "compress/bptc_ldr": 0, 47 | "compress/hdr_mode": 0, 48 | "compress/lossy_quality": 0.7, 49 | "compress/mode": 0, 50 | "compress/normal_map": 0, 51 | "detect_3d": false, 52 | "flags/anisotropic": false, 53 | "flags/filter": false, 54 | "flags/mipmaps": false, 55 | "flags/repeat": 0, 56 | "flags/srgb": 2, 57 | "process/HDR_as_SRGB": false, 58 | "process/fix_alpha_border": true, 59 | "process/invert_color": false, 60 | "process/premult_alpha": false, 61 | "size_limit": 0, 62 | "stream": false, 63 | "svg/scale": 1.0 64 | } 65 | 66 | [input] 67 | 68 | move_left={ 69 | "deadzone": 0.05, 70 | "events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777231,"unicode":0,"echo":false,"script":null) 71 | , Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":-1.0,"script":null) 72 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":14,"pressure":0.0,"pressed":false,"script":null) 73 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":65,"unicode":0,"echo":false,"script":null) 74 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":81,"unicode":0,"echo":false,"script":null) 75 | ] 76 | } 77 | move_right={ 78 | "deadzone": 0.05, 79 | "events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777233,"unicode":0,"echo":false,"script":null) 80 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":68,"unicode":0,"echo":false,"script":null) 81 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":15,"pressure":0.0,"pressed":false,"script":null) 82 | , Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":0,"axis_value":1.0,"script":null) 83 | ] 84 | } 85 | move_up={ 86 | "deadzone": 0.05, 87 | "events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777232,"unicode":0,"echo":false,"script":null) 88 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":90,"unicode":0,"echo":false,"script":null) 89 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":87,"unicode":0,"echo":false,"script":null) 90 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":12,"pressure":0.0,"pressed":false,"script":null) 91 | , Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":-1.0,"script":null) 92 | ] 93 | } 94 | move_down={ 95 | "deadzone": 0.05, 96 | "events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777234,"unicode":0,"echo":false,"script":null) 97 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":83,"unicode":0,"echo":false,"script":null) 98 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":13,"pressure":0.0,"pressed":false,"script":null) 99 | , Object(InputEventJoypadMotion,"resource_local_to_scene":false,"resource_name":"","device":0,"axis":1,"axis_value":1.0,"script":null) 100 | ] 101 | } 102 | shoot={ 103 | "deadzone": 0.5, 104 | "events": [ Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":0,"pressure":0.0,"pressed":false,"script":null) 105 | , Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":32,"unicode":0,"echo":false,"script":null) 106 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":4,"pressure":0.0,"pressed":false,"script":null) 107 | , Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":5,"pressure":0.0,"pressed":false,"script":null) 108 | ] 109 | } 110 | 111 | [layer_names] 112 | 113 | 2d_physics/layer_1="ground" 114 | 2d_physics/layer_2="player" 115 | 2d_physics/layer_3="player_bullet" 116 | 2d_physics/layer_4="enemy" 117 | 118 | [rendering] 119 | 120 | quality/driver/driver_name="GLES2" 121 | quality/intended_usage/framebuffer_allocation=0 122 | quality/intended_usage/framebuffer_allocation.mobile=0 123 | quality/2d/use_pixel_snap=true 124 | vram_compression/import_etc=true 125 | vram_compression/import_etc2=false 126 | environment/default_clear_color=Color( 0.0627451, 0, 0.0627451, 1 ) 127 | environment/default_environment="res://default_env.tres" 128 | quality/dynamic_fonts/use_oversampling=false 129 | -------------------------------------------------------------------------------- /splashscreen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/splashscreen.png -------------------------------------------------------------------------------- /splashscreen.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/splashscreen.png-642ebbdb6d608345041a31aaeea20ca5.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://splashscreen.png" 13 | dest_files=[ "res://.import/splashscreen.png-642ebbdb6d608345041a31aaeea20ca5.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /world/Current.gd: -------------------------------------------------------------------------------- 1 | extends Area2D 2 | 3 | 4 | var bodies := [] 5 | 6 | func _on_Current_body_entered(body: CollisionObject2D): 7 | bodies.append(body) 8 | 9 | func _on_Current_body_exited(body: CollisionObject2D): 10 | if body in bodies: 11 | bodies.erase(body) 12 | 13 | func _physics_process(delta: float): 14 | for body in bodies: 15 | if body.velocity != null and (body.velocity.x * scale.x) < 200: 16 | body.velocity.x += 200 * delta * scale.x 17 | -------------------------------------------------------------------------------- /world/Current.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=7 format=2] 2 | 3 | [ext_resource path="res://world/current.png" type="Texture" id=1] 4 | [ext_resource path="res://world/Current.gd" type="Script" id=2] 5 | [ext_resource path="res://world/Sea.shader" type="Shader" id=3] 6 | 7 | [sub_resource type="ShaderMaterial" id=1] 8 | shader = ExtResource( 3 ) 9 | shader_param/amplitude = Vector2( 0, 10 ) 10 | shader_param/speed = 1.0 11 | 12 | [sub_resource type="Animation" id=2] 13 | length = 0.6 14 | loop = true 15 | step = 0.2 16 | tracks/0/type = "value" 17 | tracks/0/path = NodePath(".:frame") 18 | tracks/0/interp = 1 19 | tracks/0/loop_wrap = true 20 | tracks/0/imported = false 21 | tracks/0/enabled = true 22 | tracks/0/keys = { 23 | "times": PoolRealArray( 0, 0.2, 0.4 ), 24 | "transitions": PoolRealArray( 1, 1, 1 ), 25 | "update": 1, 26 | "values": [ 0, 1, 2 ] 27 | } 28 | 29 | [sub_resource type="RectangleShape2D" id=3] 30 | extents = Vector2( 60, 15 ) 31 | 32 | [node name="Current" type="Area2D"] 33 | material = SubResource( 1 ) 34 | monitorable = false 35 | collision_layer = 0 36 | collision_mask = 10 37 | script = ExtResource( 2 ) 38 | 39 | [node name="Sprite" type="Sprite" parent="."] 40 | use_parent_material = true 41 | z_index = -9 42 | texture = ExtResource( 1 ) 43 | vframes = 3 44 | 45 | [node name="AnimationPlayer" type="AnimationPlayer" parent="Sprite"] 46 | autoplay = "flow" 47 | anims/flow = SubResource( 2 ) 48 | 49 | [node name="CollisionShape2D" type="CollisionShape2D" parent="."] 50 | shape = SubResource( 3 ) 51 | [connection signal="body_entered" from="." to="." method="_on_Current_body_entered"] 52 | [connection signal="body_exited" from="." to="." method="_on_Current_body_exited"] 53 | -------------------------------------------------------------------------------- /world/Sea.shader: -------------------------------------------------------------------------------- 1 | shader_type canvas_item; 2 | 3 | uniform vec2 amplitude = vec2(0.0, 10.0); 4 | uniform float speed = 1.0; 5 | 6 | /*void fragment() { 7 | COLOR = texture(TEXTURE, vec2(UV.y, UV.x)); 8 | COLOR.b = 1.0; 9 | }*/ 10 | 11 | void vertex() { 12 | // Animate Sprite moving in big circle around its location 13 | VERTEX += vec2(cos(TIME*speed)*amplitude.x, sin(TIME*speed)*amplitude.y); 14 | } -------------------------------------------------------------------------------- /world/World.gd: -------------------------------------------------------------------------------- 1 | extends YSort 2 | 3 | var pirate := preload("res://enemies/SmallPirate.tscn") 4 | var big_pirate := preload("res://enemies/BigPirate.tscn") 5 | var chaser := preload("res://enemies/Chaser.tscn") 6 | 7 | var plus_score := preload("res://items/PlusScore.tscn") 8 | var items := [ 9 | preload("res://items/Coin.tscn"), 10 | preload("res://items/LifeBarrel.tscn"), 11 | preload("res://items/SuperCannon.tscn"), 12 | preload("res://items/SuperPaddles.tscn"), 13 | ] 14 | 15 | func _ready(): 16 | Globals.score = 0 17 | yield(get_tree().create_timer(6.0), "timeout") 18 | Globals.message = "Aim through the lighthouse to boost your bullets\nFOR EMERGENCY USE ONLY" 19 | 20 | func _physics_process(_delta: float): 21 | if has_node("LightHouse") and has_node("Player"): 22 | $Camera2D.position = (2*$LightHouse.position + $Player.position)/3 23 | 24 | if Globals.message != $HUD/UI/Instructions.text: 25 | $HUD/UI/Instructions.text = Globals.message 26 | 27 | if not OS.is_window_focused(): 28 | pause_game() 29 | 30 | func _notification(what: int): 31 | if what == MainLoop.NOTIFICATION_WM_FOCUS_OUT: 32 | pause_game() 33 | 34 | func pause_game(): 35 | $Pause/Menu.show() 36 | get_tree().paused = true 37 | $Pause/Menu/Rows/Resume.grab_focus() 38 | 39 | func _input(event: InputEvent): 40 | if event.is_action_pressed("ui_cancel"): 41 | pause_game() 42 | 43 | func _on_Player_shoot(pos: Vector2, vel: Vector2, bullet: PackedScene): 44 | var my_bullet: Node2D = bullet.instance() 45 | add_child(my_bullet) 46 | my_bullet.global_position = pos + 10*vel.normalized() 47 | my_bullet.velocity = vel 48 | 49 | func _on_Player_dead(player: Node2D): 50 | $Camera2D/Shake.play("screen_shake") 51 | yield(get_tree().create_timer(1.5), "timeout") 52 | if has_node("LightHouse"): 53 | player.global_position = $LightHouse.global_position 54 | player.show() 55 | player.set_physics_process(true) 56 | player.vulnerable = false 57 | player.get_node("Immune").play("immune") 58 | player.get_node("Hurt/Timer").start() 59 | $LightHouse.life -= 7 60 | $LightHouse/Respawn.play() 61 | 62 | func _on_PirateSpawner_timeout(): 63 | if $PirateSpawner.wait_time > 0.75: 64 | $PirateSpawner.wait_time *= 0.986 65 | if has_node("LightHouse"): 66 | var my_pirate: Node2D 67 | if randi()%20 == 0: 68 | my_pirate = big_pirate.instance() 69 | var ok := my_pirate.connect("shoot", self, "_on_Pirate_shoot") 70 | assert(OK == ok) 71 | elif randi()%15 == 0: 72 | my_pirate = chaser.instance() 73 | my_pirate.player = $Player 74 | var ok := $LightHouse.connect("gameover", my_pirate, "_on_GameOver") 75 | assert(OK == ok) 76 | else: 77 | my_pirate = pirate.instance() 78 | 79 | var ok := my_pirate.connect("add_score", self, "_on_Pirate_add_score") 80 | assert(OK == ok) 81 | ok = my_pirate.connect("drop_item", self, "_on_Pirate_drop_item") 82 | assert(OK == ok) 83 | add_child(my_pirate) 84 | 85 | if randi()%2 == 0: 86 | my_pirate.position.x = [-380, 380][randi()%2] 87 | my_pirate.position.y = rand_range(-160, 160) 88 | else: 89 | my_pirate.position.y = [-220, 220][randi()%2] 90 | my_pirate.position.x = rand_range(-240, 240) 91 | my_pirate.velocity = Vector2(-my_pirate.max_speed, 0).rotated(my_pirate.global_position.angle_to_point($LightHouse.global_position)) 92 | 93 | func _on_Pirate_shoot(pos: Vector2, bullet: PackedScene): 94 | if has_node("Player"): 95 | var my_bullet: Node2D = bullet.instance() 96 | add_child(my_bullet) 97 | my_bullet.global_position = pos 98 | my_bullet.velocity = Vector2(-100, 0).rotated(pos.angle_to_point($Player.global_position)) 99 | 100 | func _on_Pirate_add_score(score: int, pos: Vector2): 101 | Globals.score += score 102 | var new_plus_score: Node2D = plus_score.instance() 103 | add_child(new_plus_score) 104 | new_plus_score.global_position = pos 105 | new_plus_score.init(score) 106 | 107 | func _on_Pirate_drop_item(pos: Vector2): 108 | # Drop an item at random on pirate's death. 109 | var item: PackedScene = items[randi()%items.size()] 110 | call_deferred("_deferred_drop_item", item.instance(), pos) 111 | 112 | func _deferred_drop_item(item: Node2D, pos: Vector2): 113 | add_child(item) 114 | item.global_position = pos 115 | 116 | func _on_LightHouse_gameover(): 117 | $HUD/GameOver.show() 118 | $Music.stop() 119 | $Player.queue_free() 120 | $HUD/GlobalAnim.play("gameover") 121 | 122 | func _on_Resume_pressed(): 123 | $Pause/Menu.hide() 124 | get_tree().paused = false 125 | 126 | func _on_Settings_pressed(): 127 | Settings.get_node("Background").show() 128 | 129 | func _on_Title_pressed(): 130 | get_tree().paused = false 131 | var ok := get_tree().change_scene("res://menu/TitleScreen.tscn") 132 | assert(OK == ok) 133 | 134 | func goto_outro(): 135 | get_tree().paused = false 136 | var ok := get_tree().change_scene("res://menu/cutscenes/Outro.tscn") 137 | assert(OK == ok) 138 | -------------------------------------------------------------------------------- /world/World.tscn: -------------------------------------------------------------------------------- 1 | [gd_scene load_steps=17 format=2] 2 | 3 | [ext_resource path="res://player/Player.tscn" type="PackedScene" id=1] 4 | [ext_resource path="res://lighthouse/LightHouse.tscn" type="PackedScene" id=2] 5 | [ext_resource path="res://world/sea_background.png" type="Texture" id=3] 6 | [ext_resource path="res://world/World.gd" type="Script" id=4] 7 | [ext_resource path="res://world/Current.tscn" type="PackedScene" id=5] 8 | [ext_resource path="res://menu/gameover.png" type="Texture" id=6] 9 | [ext_resource path="res://menu/CustomButton.tscn" type="PackedScene" id=9] 10 | [ext_resource path="res://music/level.ogg" type="AudioStream" id=10] 11 | [ext_resource path="res://menu/ScoreDisplay.tscn" type="PackedScene" id=11] 12 | 13 | [sub_resource type="Animation" id=1] 14 | resource_name = "screen_shake" 15 | tracks/0/type = "value" 16 | tracks/0/path = NodePath(".:offset_h") 17 | tracks/0/interp = 1 18 | tracks/0/loop_wrap = true 19 | tracks/0/imported = false 20 | tracks/0/enabled = true 21 | tracks/0/keys = { 22 | "times": PoolRealArray( 0, 0.1, 0.2, 0.3, 0.4 ), 23 | "transitions": PoolRealArray( 1, 1, 1, 1, 1 ), 24 | "update": 0, 25 | "values": [ 0.2, -0.2, 0.1, -0.1, 0.0 ] 26 | } 27 | 28 | [sub_resource type="Shader" id=2] 29 | code = "shader_type canvas_item; 30 | 31 | uniform vec2 amplitude = vec2(0.0, 10.0); 32 | uniform float speed = 1.0; 33 | 34 | uniform float nb_sprites = 3; 35 | uniform float height_sprites = 64; 36 | 37 | void vertex() { 38 | // Animate Sprite moving in big circle around its location 39 | VERTEX += vec2(cos(TIME*speed)*amplitude.x, sin(TIME*speed)*amplitude.y); 40 | VERTEX.y += height_sprites*floor(nb_sprites*mod(TIME, 1)); 41 | }" 42 | 43 | [sub_resource type="ShaderMaterial" id=3] 44 | shader = SubResource( 2 ) 45 | shader_param/amplitude = Vector2( 0, 10 ) 46 | shader_param/speed = 1.0 47 | shader_param/nb_sprites = 3.0 48 | shader_param/height_sprites = 64.0 49 | 50 | [sub_resource type="RectangleShape2D" id=4] 51 | extents = Vector2( 20, 400 ) 52 | 53 | [sub_resource type="RectangleShape2D" id=5] 54 | extents = Vector2( 600, 20 ) 55 | 56 | [sub_resource type="Animation" id=6] 57 | resource_name = "gameover" 58 | length = 3.0 59 | step = 0.2 60 | tracks/0/type = "value" 61 | tracks/0/path = NodePath("../Darkness:color") 62 | tracks/0/interp = 1 63 | tracks/0/loop_wrap = true 64 | tracks/0/imported = false 65 | tracks/0/enabled = true 66 | tracks/0/keys = { 67 | "times": PoolRealArray( 0, 2 ), 68 | "transitions": PoolRealArray( 0.1, 1 ), 69 | "update": 0, 70 | "values": [ Color( 1, 1, 1, 1 ), Color( 0, 0, 0, 1 ) ] 71 | } 72 | tracks/1/type = "method" 73 | tracks/1/path = NodePath("..") 74 | tracks/1/interp = 1 75 | tracks/1/loop_wrap = true 76 | tracks/1/imported = false 77 | tracks/1/enabled = true 78 | tracks/1/keys = { 79 | "times": PoolRealArray( 3 ), 80 | "transitions": PoolRealArray( 1 ), 81 | "values": [ { 82 | "args": [ ], 83 | "method": "goto_outro" 84 | } ] 85 | } 86 | 87 | [sub_resource type="Animation" id=7] 88 | length = 10.0 89 | step = 0.5 90 | tracks/0/type = "value" 91 | tracks/0/path = NodePath("../Darkness:color") 92 | tracks/0/interp = 1 93 | tracks/0/loop_wrap = true 94 | tracks/0/imported = false 95 | tracks/0/enabled = true 96 | tracks/0/keys = { 97 | "times": PoolRealArray( 0, 4, 6, 7, 8.5, 10 ), 98 | "transitions": PoolRealArray( 1, 1, 1, 1, 1, 1 ), 99 | "update": 0, 100 | "values": [ Color( 1, 1, 1, 1 ), Color( 0.705882, 0.466667, 0.25098, 1 ), Color( 0.756863, 0.0705882, 0, 1 ), Color( 0.407843, 0.0627451, 0.247059, 1 ), Color( 0.109804, 0.0470588, 0.333333, 1 ), Color( 0, 0, 0, 1 ) ] 101 | } 102 | tracks/1/type = "value" 103 | tracks/1/path = NodePath("EntireScreen:color") 104 | tracks/1/interp = 1 105 | tracks/1/loop_wrap = true 106 | tracks/1/imported = false 107 | tracks/1/enabled = true 108 | tracks/1/keys = { 109 | "times": PoolRealArray( 0, 1 ), 110 | "transitions": PoolRealArray( 0.2, 1 ), 111 | "update": 0, 112 | "values": [ Color( 0, 0, 0, 1 ), Color( 0.188235, 0.243137, 0.607843, 0 ) ] 113 | } 114 | tracks/2/type = "value" 115 | tracks/2/path = NodePath("../Camera2D:zoom") 116 | tracks/2/interp = 1 117 | tracks/2/loop_wrap = true 118 | tracks/2/imported = false 119 | tracks/2/enabled = true 120 | tracks/2/keys = { 121 | "times": PoolRealArray( 0, 1 ), 122 | "transitions": PoolRealArray( 0.2, 1 ), 123 | "update": 0, 124 | "values": [ Vector2( 1.5, 1.5 ), Vector2( 1, 1 ) ] 125 | } 126 | 127 | [node name="World" type="YSort"] 128 | position = Vector2( 256, 144 ) 129 | script = ExtResource( 4 ) 130 | __meta__ = { 131 | "_edit_lock_": true 132 | } 133 | 134 | [node name="Player" parent="." instance=ExtResource( 1 )] 135 | position = Vector2( 0, 80 ) 136 | 137 | [node name="Camera2D" type="Camera2D" parent="."] 138 | position = Vector2( 3, 3 ) 139 | current = true 140 | smoothing_enabled = true 141 | __meta__ = { 142 | "_edit_lock_": true 143 | } 144 | 145 | [node name="Shake" type="AnimationPlayer" parent="Camera2D"] 146 | anims/screen_shake = SubResource( 1 ) 147 | 148 | [node name="LightHouse" parent="." instance=ExtResource( 2 )] 149 | 150 | [node name="Sea" type="Sprite" parent="."] 151 | material = SubResource( 3 ) 152 | z_index = -10 153 | texture = ExtResource( 3 ) 154 | region_enabled = true 155 | region_rect = Rect2( 0, 0, 1200, 800 ) 156 | __meta__ = { 157 | "_edit_lock_": true 158 | } 159 | 160 | [node name="Darkness" type="CanvasModulate" parent="."] 161 | color = Color( 0.926471, 0.866667, 0.812745, 1 ) 162 | __meta__ = { 163 | "_edit_lock_": true 164 | } 165 | 166 | [node name="Borders" type="StaticBody2D" parent="."] 167 | __meta__ = { 168 | "_edit_lock_": true 169 | } 170 | 171 | [node name="Left" type="CollisionShape2D" parent="Borders"] 172 | position = Vector2( -422, 0 ) 173 | shape = SubResource( 4 ) 174 | 175 | [node name="Right" type="CollisionShape2D" parent="Borders"] 176 | position = Vector2( 422, 0 ) 177 | shape = SubResource( 4 ) 178 | 179 | [node name="Top" type="CollisionShape2D" parent="Borders"] 180 | position = Vector2( 0, -250 ) 181 | shape = SubResource( 5 ) 182 | 183 | [node name="Bottom" type="CollisionShape2D" parent="Borders"] 184 | position = Vector2( 0, 250 ) 185 | shape = SubResource( 5 ) 186 | 187 | [node name="HUD" type="CanvasLayer" parent="."] 188 | 189 | [node name="GameOver" type="Sprite" parent="HUD"] 190 | visible = false 191 | position = Vector2( 256, 144 ) 192 | texture = ExtResource( 6 ) 193 | 194 | [node name="UI" type="VBoxContainer" parent="HUD"] 195 | anchor_right = 1.0 196 | anchor_bottom = 1.0 197 | margin_left = 10.0 198 | margin_top = 10.0 199 | margin_right = -10.0 200 | margin_bottom = -10.0 201 | __meta__ = { 202 | "_edit_use_anchors_": false 203 | } 204 | 205 | [node name="ScoreDisplay" parent="HUD/UI" instance=ExtResource( 11 )] 206 | position = Vector2( 54, 3 ) 207 | 208 | [node name="Instructions" type="Label" parent="HUD/UI"] 209 | margin_top = 249.0 210 | margin_right = 492.0 211 | margin_bottom = 268.0 212 | size_flags_vertical = 10 213 | text = "Mouse: move 214 | Left click: shoot" 215 | __meta__ = { 216 | "_edit_use_anchors_": false 217 | } 218 | 219 | [node name="GlobalAnim" type="AnimationPlayer" parent="HUD"] 220 | autoplay = "start" 221 | anims/gameover = SubResource( 6 ) 222 | anims/start = SubResource( 7 ) 223 | 224 | [node name="EntireScreen" type="ColorRect" parent="HUD"] 225 | anchor_right = 1.0 226 | anchor_bottom = 1.0 227 | color = Color( 0.188235, 0.243137, 0.607843, 0 ) 228 | __meta__ = { 229 | "_edit_use_anchors_": false 230 | } 231 | 232 | [node name="PirateSpawner" type="Timer" parent="."] 233 | wait_time = 2.5 234 | autostart = true 235 | 236 | [node name="Current" parent="." instance=ExtResource( 5 )] 237 | position = Vector2( 128, 112 ) 238 | scale = Vector2( -1, 1 ) 239 | 240 | [node name="Current2" parent="." instance=ExtResource( 5 )] 241 | position = Vector2( -128, -144 ) 242 | 243 | [node name="Pause" type="CanvasLayer" parent="."] 244 | 245 | [node name="Menu" type="Control" parent="Pause"] 246 | pause_mode = 2 247 | visible = false 248 | self_modulate = Color( 0, 0, 0, 1 ) 249 | anchor_left = 0.5 250 | anchor_top = 0.5 251 | anchor_right = 0.5 252 | anchor_bottom = 0.5 253 | margin_left = -64.0 254 | margin_top = -56.0 255 | margin_right = 64.0 256 | margin_bottom = 56.0 257 | 258 | [node name="Rows" type="VBoxContainer" parent="Pause/Menu"] 259 | anchor_right = 1.0 260 | anchor_bottom = 1.0 261 | size_flags_horizontal = 4 262 | alignment = 1 263 | __meta__ = { 264 | "_edit_use_anchors_": false 265 | } 266 | 267 | [node name="Label" type="Label" parent="Pause/Menu/Rows"] 268 | margin_top = 7.0 269 | margin_right = 128.0 270 | margin_bottom = 21.0 271 | text = "GAME PAUSED" 272 | align = 1 273 | 274 | [node name="Resume" parent="Pause/Menu/Rows" instance=ExtResource( 9 )] 275 | margin_left = 24.0 276 | margin_top = 25.0 277 | margin_right = 104.0 278 | margin_bottom = 49.0 279 | size_flags_horizontal = 4 280 | 281 | [node name="Label" parent="Pause/Menu/Rows/Resume" index="0"] 282 | text = "Resume" 283 | 284 | [node name="Settings" parent="Pause/Menu/Rows" instance=ExtResource( 9 )] 285 | margin_left = 24.0 286 | margin_top = 53.0 287 | margin_right = 104.0 288 | margin_bottom = 77.0 289 | size_flags_horizontal = 4 290 | 291 | [node name="Label" parent="Pause/Menu/Rows/Settings" index="0"] 292 | text = "Settings" 293 | 294 | [node name="Title" parent="Pause/Menu/Rows" instance=ExtResource( 9 )] 295 | margin_left = 24.0 296 | margin_top = 81.0 297 | margin_right = 104.0 298 | margin_bottom = 105.0 299 | size_flags_horizontal = 4 300 | 301 | [node name="Music" type="AudioStreamPlayer" parent="."] 302 | pause_mode = 2 303 | stream = ExtResource( 10 ) 304 | volume_db = -3.0 305 | autoplay = true 306 | bus = "music" 307 | [connection signal="dead" from="Player" to="." method="_on_Player_dead"] 308 | [connection signal="shoot" from="Player" to="." method="_on_Player_shoot"] 309 | [connection signal="gameover" from="LightHouse" to="." method="_on_LightHouse_gameover"] 310 | [connection signal="timeout" from="PirateSpawner" to="." method="_on_PirateSpawner_timeout"] 311 | [connection signal="pressed" from="Pause/Menu/Rows/Resume" to="." method="_on_Resume_pressed"] 312 | [connection signal="pressed" from="Pause/Menu/Rows/Settings" to="." method="_on_Settings_pressed"] 313 | [connection signal="pressed" from="Pause/Menu/Rows/Title" to="." method="_on_Title_pressed"] 314 | 315 | [editable path="Pause/Menu/Rows/Resume"] 316 | 317 | [editable path="Pause/Menu/Rows/Settings"] 318 | -------------------------------------------------------------------------------- /world/current.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/world/current.png -------------------------------------------------------------------------------- /world/current.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/current.png-2c05575270c18cb887de5457fb51121f.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://world/current.png" 13 | dest_files=[ "res://.import/current.png-2c05575270c18cb887de5457fb51121f.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /world/light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/world/light.png -------------------------------------------------------------------------------- /world/light.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/light.png-495682b3aa36129242b33b7449c88bad.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://world/light.png" 13 | dest_files=[ "res://.import/light.png-495682b3aa36129242b33b7449c88bad.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=0 23 | flags/filter=true 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | -------------------------------------------------------------------------------- /world/sea_background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/cagibi-dev/lighthouse-keeper/6ff9fedf5aef56846dfec5c11181acbee3633d62/world/sea_background.png -------------------------------------------------------------------------------- /world/sea_background.png.import: -------------------------------------------------------------------------------- 1 | [remap] 2 | 3 | importer="texture" 4 | type="StreamTexture" 5 | path="res://.import/sea_background.png-970cf724b7d71f50947a67a5d187a94b.stex" 6 | metadata={ 7 | "vram_texture": false 8 | } 9 | 10 | [deps] 11 | 12 | source_file="res://world/sea_background.png" 13 | dest_files=[ "res://.import/sea_background.png-970cf724b7d71f50947a67a5d187a94b.stex" ] 14 | 15 | [params] 16 | 17 | compress/mode=0 18 | compress/lossy_quality=0.7 19 | compress/hdr_mode=0 20 | compress/bptc_ldr=0 21 | compress/normal_map=0 22 | flags/repeat=1 23 | flags/filter=false 24 | flags/mipmaps=false 25 | flags/anisotropic=false 26 | flags/srgb=2 27 | process/fix_alpha_border=true 28 | process/premult_alpha=false 29 | process/HDR_as_SRGB=false 30 | process/invert_color=false 31 | stream=false 32 | size_limit=0 33 | detect_3d=false 34 | svg/scale=1.0 35 | --------------------------------------------------------------------------------