Skip to content
This repository has been archived by the owner on Jul 17, 2020. It is now read-only.

Commit

Permalink
Dialogue is skipped on subsequent boss attempts
Browse files Browse the repository at this point in the history
  • Loading branch information
FractalDiane committed Jan 10, 2019
1 parent fb7556a commit 308a38a
Show file tree
Hide file tree
Showing 14 changed files with 46 additions and 29 deletions.
2 changes: 1 addition & 1 deletion Instances/System/DialogueRegistry.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
[ext_resource path="res://Sounds/UI/Text type.wav" type="AudioStream" id=6]
[ext_resource path="res://Fonts/font_standard.tres" type="DynamicFont" id=7]

[node name="DialogueRegistry" type="CanvasLayer" index="0"]
[node name="DialogueRegistry" type="CanvasLayer"]

layer = 24
offset = Vector2( 0, 0 )
Expand Down
22 changes: 11 additions & 11 deletions Scenes/Dungeon 2/Dungeon2-BOSS.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
[ext_resource path="res://Scripts/Objects/Dungeon 2/SesdinBoss.gd" type="Script" id=22]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin left.png" type="Texture" id=23]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin right.png" type="Texture" id=24]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast left.png" type="Texture" id=25]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast right.png" type="Texture" id=26]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast down.png" type="Texture" id=27]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast down.png" type="Texture" id=25]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast left.png" type="Texture" id=26]
[ext_resource path="res://Sprites/Characters/Sesdin/Sesdin cast right.png" type="Texture" id=27]
[ext_resource path="res://Sprites/Particles/Impact.png" type="Texture" id=28]
[ext_resource path="res://Sounds/Objects/Turret.wav" type="AudioStream" id=29]
[ext_resource path="res://Sounds/Characters/Charge.wav" type="AudioStream" id=30]
Expand Down Expand Up @@ -138,24 +138,24 @@ animations = [ {
"name": "right",
"speed": 5.0
}, {
"frames": [ ExtResource( 25 ) ],
"frames": [ ExtResource( 11 ) ],
"loop": true,
"name": "castleft",
"name": "down",
"speed": 5.0
}, {
"frames": [ ExtResource( 26 ) ],
"frames": [ ExtResource( 25 ) ],
"loop": true,
"name": "castright",
"name": "castdown",
"speed": 5.0
}, {
"frames": [ ExtResource( 27 ) ],
"frames": [ ExtResource( 26 ) ],
"loop": true,
"name": "castdown",
"name": "castleft",
"speed": 5.0
}, {
"frames": [ ExtResource( 11 ) ],
"frames": [ ExtResource( 27 ) ],
"loop": true,
"name": "down",
"name": "castright",
"speed": 5.0
} ]

Expand Down
6 changes: 1 addition & 5 deletions Scenes/GATE/CorrBoss.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,6 @@
[ext_resource path="res://Instances/CorruptionOverlay.tscn" type="PackedScene" id=9]
[ext_resource path="res://Instances/Particles/PartsWorldborder.tscn" type="PackedScene" id=10]





[sub_resource type="Gradient" id=1]

offsets = PoolRealArray( 0, 1 )
Expand Down Expand Up @@ -75,7 +71,7 @@ extents = Vector2( 81.0026, 4.38243 )
custom_solver_bias = 0.0
extents = Vector2( 5.73753, 72.0946 )

[node name="Node2D" type="Node2D" index="0"]
[node name="Node2D" type="Node2D"]

_sections_unfolded = [ "Transform" ]

Expand Down
7 changes: 4 additions & 3 deletions Scenes/GATE/Gate-3.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
custom_solver_bias = 0.0
extents = Vector2( 32, 64 )

[node name="Node2D" type="Node2D" index="0"]
[node name="Node2D" type="Node2D"]

_sections_unfolded = [ "Transform" ]

Expand Down Expand Up @@ -68,15 +68,15 @@ corrupt_interval = 1.5

[node name="CorruptionOverlaySprite" parent="CorruptionOverlay" index="1"]

frame = 3
frame = 13

[node name="CorruptionOverlay2" parent="." index="5" instance=ExtResource( 6 )]

corrupt = false

[node name="CorruptionOverlaySprite" parent="CorruptionOverlay2" index="1"]

frame = 3
frame = 13

[node name="Walls" type="StaticBody2D" parent="." index="6"]

Expand Down Expand Up @@ -124,6 +124,7 @@ target_scene = "res://Scenes/GATE/Gate-4.tscn"
target_x = 0
target_y = 110
direction = "up"
checkpoint = true


[editable path="CorruptionOverlay"]
Expand Down
4 changes: 2 additions & 2 deletions Scenes/GATE/Gate-4.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -75,15 +75,15 @@ corrupt_interval = 1.5

[node name="CorruptionOverlaySprite" parent="CorruptionOverlay" index="1"]

frame = 7
frame = 10

[node name="CorruptionOverlay2" parent="." index="5" instance=ExtResource( 7 )]

corrupt = false

[node name="CorruptionOverlaySprite" parent="CorruptionOverlay2" index="1"]

frame = 7
frame = 10

[node name="Walls" type="StaticBody2D" parent="." index="6"]

Expand Down
2 changes: 1 addition & 1 deletion Scenes/GATE/Gate-FINALBOSS1.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ radius = 9.0
custom_solver_bias = 0.0
extents = Vector2( 32, 23 )

[node name="Node2D" type="Node2D"]
[node name="Node2D" type="Node2D" index="0"]

_sections_unfolded = [ "Transform" ]

Expand Down
1 change: 1 addition & 0 deletions Scenes/GATE/Gate-TrueEnd3.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,7 @@ visible = false
position = Vector2( 80, 50 )
frames = SubResource( 3 )
animation = "default"
frame = 1
playing = true

[node name="EndArea" type="Area2D" parent="." index="7"]
Expand Down
2 changes: 1 addition & 1 deletion Scenes/Startup.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
[node name="Node2D" type="Node2D" index="0"]

script = ExtResource( 1 )
start_scene = "res://Scenes/Dungeon 1/Dungeon1-12.tscn"
start_scene = "res://Scenes/GATE/Gate-3.tscn"
start_position = Vector2( 80, 72 )
flags = [ "jari_talk", "cultist40_talk", "holding_dungeon1key", "dungeon1_switchesTL", "dungeon1_switchesTR", "dungeon1_switchTL_1", "dungeon1_switchTL_2", "dungeon1_switchTL_3", "dungeon1_switchTL_4", "dungeon1_switchTR_1", "dungeon1_switchTR_2", "dungeon1_switchTR_3", "dungeon1_switchTR_4", "kein_talk", "keininside_talk", "dungeon1_switches2TL", "dungeon1_switches2TR", "dungeon1_switches2BL", "dungeon1_switches2BR", "dungeon1_switchTR_5", "dungeon1_switchBR2_1", "dungeon1_switchBR2_2", "dungeon1_switchBR2_3", "dungeon1_switchBR2_4", "dungeon1_switchTR2_1", "dungeon1_switchTR2_2", "dungeon1_switchTR2_3", "dungeon1_switchTR2_4", "dungeon1_switchTL2_1", "dungeon1_switchTL2_2", "dungeon1_switchBL2_1", "dungeon1_switchBL2_2", "dungeon1_switchBL2_3", "iiro_talk", "dungeon2_switchIntro", "dungeon2_switchesL", "dungeon2_switchesR", "dungeon2_switchL1", "dungeon2_switchL2", "dungeon2_switchR1", "dungeon2_switchR2", "dungeon2_switchR3", "dungeon2_switchR4", "dungeon2_door1", "gold_1", "gold_2", "gold_3", "gold_4", "gold_5", "gold_6", "gold_7", "gold_8", "gold_9", "dungeon2_switchesL2", "dungeon2_switchesR2", "holding_dungeon2key", "holding_bow", "dungeon1_complete", "keinoutside_talk", "dungeon2_complete", "holding_gatekey", "jarid1_talk", "jarid2_talk", "iiro00_talk", "azura_talk", "azura12_talk", "azura00_talk", "gallaro_talk", "gold_10", "gold_11", "kein00_talk" ]
title_screen = true
Expand Down
3 changes: 3 additions & 0 deletions Scripts/Globals/controller.gd
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ var corrupted_cells_add_checkpoint = []
var holding_thekey = false
var holding_theitem = false

var boss2_init = false
var finalboss_init = false

var bad_ending = false
var true_ending = false

Expand Down
6 changes: 5 additions & 1 deletion Scripts/Objects/Dungeon 2/SesdinIntro.gd
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func _physics_process(delta):

func intro():
$Sprite.play("down")
controller.boss2_init = true
controller.dialogue(dialogue_text, self, 10, 10, 140, 45)

func teleport():
Expand All @@ -70,7 +71,10 @@ func _on_TimerIntro_timeout():
Player.state = Player.NO_INPUT
Player.motion = Vector2(0,0)
Player.face = Vector2(0,-1)
intro()
if controller.boss2_init:
_on_TimerTeleport_timeout()
else:
intro()

func _on_TimerTeleport_timeout():
teleport()
Expand Down
6 changes: 5 additions & 1 deletion Scripts/Scenes/FinalBossIntro.gd
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ func _on_EntryTrigger_body_entered(body):
active = true

func _on_TimerMusic_timeout():
$MusicConfrontation.play(0)
if controller.finalboss_init:
controller.scene_change("res://Scenes/GATE/Gate-FINALBOSS2.tscn", false)
Player.hide()
else:
$MusicConfrontation.play(0)

func _on_TimerDialogue_timeout():
controller.dialogue_registry(text_1, self, 15, 10, 100, 50, false)
8 changes: 7 additions & 1 deletion Scripts/Scenes/FinalBossIntro2.gd
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,14 @@ func _physics_process(delta):
Player.get_node("Sprite").play("up")

func _on_TimerDialogue_timeout():
controller.dialogue_registry(text_2, self, 15, 10, 100, 50, false)
if controller.finalboss_init:
get_node("TimerStartBoss").start()
audioplayer.get_node("MusicFinalBoss").play(0)
audioplayer.current_music = audioplayer.get_node("MusicFinalBoss").stream
else:
controller.dialogue_registry(text_2, self, 15, 10, 100, 50, false)

func _on_TimerStartBoss_timeout():
controller.finalboss_init = true
controller.scene_change("res://Scenes/GATE/CorrBoss.tscn")
Player.show()
4 changes: 3 additions & 1 deletion Scripts/Scenes/Title.gd
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,9 @@ func input():
controller.player_corruption = 0
controller.player_gold = 20
controller.player_potions = 5


controller.boss2_init = false
controller.finalboss_init = false
controller.corrupted_cells_add = []
controller.bad_ending = false
controller.true_ending = false
Expand Down
2 changes: 1 addition & 1 deletion export_presets.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ binary_format/64_bits=true
custom_template/release=""
custom_template/debug=""
application/icon="C:/Users/Duncan Sparks/Downloads/favicon.ico"
application/file_version="1.0"
application/file_version="1.1"
application/product_version=""
application/company_name="Studio Fractal"
application/product_name=""
Expand Down

0 comments on commit 308a38a

Please sign in to comment.