Skip to content

Commit

Permalink
Fixing some stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
IronShears committed Jan 27, 2024
1 parent 2c728d5 commit 7dc72b5
Show file tree
Hide file tree
Showing 7 changed files with 127 additions and 54 deletions.
3 changes: 3 additions & 0 deletions Commandprompt.gd
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ func skip_input():
_play_dialog()
else:
emit_signal("done")
if dialogue[page].has("continue"):
UniversalFunctions.play_dialogue_JSON(dialogue[page]["continue"])

func set_up():
first_line()
Expand All @@ -62,6 +64,7 @@ func set_up():
text = text.replace("{insertText}",pastDialogue[-1]["text"])
text = text.replace("{name}", playerName)
text = text.replace("{missingDialogue}", currentTree)
print(currentTree)
if dialogue[page]["color"] == "Teal":
text = "[color=#306082]"+text+"[/color]"
optionsVisible = dialogue[page]["optionsVisible"]
Expand Down
50 changes: 43 additions & 7 deletions Resources/Text/Text.json
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
],

"fineGreetingGood":[
{"color":"Pink", "sprite":"camera1Smile","text":"Oh thank WAN, I thought you would ignore me again like yesterday.","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":false}
{"color":"Pink", "sprite":"camera1Smile","text":"Oh thank WAN, I thought you would ignore me again like yesterday.","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":true,"options":"Introductions"}
],
"fineGreetingBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Okay sorry, sorry. After what happened yesterday I was worried I made you mad","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":true,"options":"Introductions"}
Expand Down Expand Up @@ -518,7 +518,7 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n


"AskSupervisor": [
{"name":"AskSupervisorGood", "text":"I’d have to ask my supervisor. No guarantee I can get the answer."},
{"name":"AskSupervisorGood", "text":"I’d have to ask my supervisor, Sorry."},
{"name":"AskSupervisorBad", "text":"How am I supposed to know that?"}
],

Expand Down Expand Up @@ -560,16 +560,22 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
],








"WhatsYourName": [
{"name":"WhatsYourNameGood", "text":"How about you? What’s your name?"},
{"name":"WhatsYourNameBad", "text":"Cool."}
],

"WhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"My name is Synthia Powell.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"My name is Synthia Powell.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"WhatsYourNameContinue"}
],
"WhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Great.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"Great.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"WhatsYourNameContinue"}
],
"fineWhatsYourNameContinue":[
{"color":"Pink", "sprite":"camera2Angry","text":"So, was Ada able to convince her supervisors to show me whatever she was cooking up yet?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"NoSurprise"}
Expand All @@ -578,18 +584,48 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
{"color":"Pink", "sprite":"camera2Angry","text":"Did Ada at least get permission to give me my surprise yet?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"NoSurprise"}
],








"NoSurprise": [
{"name":"NoSurpriseBad", "text":"My instructions don't mention anything about a surprise… so no."}
{"name":"NoSurpriseBad", "text":"My instructions don't mention anything about that… so no."}
],

"fineNoSurpriseBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Well THAT just sucks, doesn't it? Ada is gone and now I have to talk to a stranger!","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadNoSurpriseBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"So the only woman who cared about me is gone without saying goodbye… and I get nothing?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"So the only person who cared about me is gone without saying goodbye… and I get nothing?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"NoSurpriseContinue"}
],
"NoSurpriseContinue":[
{"color":"Pink", "sprite":"camera2Angry","text":"This place was supposed to be PARADISE. It’s not paradise if there’s nothing to do here!","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"This place was supposed to be PARADISE. It’s not paradise if there’s nothing to do here!","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"TalkToMe"}
],






"TalkToMe": [
{"name":"TalkToMeGood", "text":"You can talk to me, can't you?"},
{"name":"TalkToMeBad", "text":"You’re going to have to tough it out."}
],

"fineWhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"I guess so… but I'm going to miss Ada. I have no idea how long its going to take to get used to you…we","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"fineWhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Damn. You're an asshole. I guess you're still better than NOTHING.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadWhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"I guess so… but I'm going to miss Ada. I have no idea how long its going to take to get used to you…we","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadWhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Damn. You're an asshole. I guess you're still better than NOTHING.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],

}
50 changes: 43 additions & 7 deletions Resources/Text/Text.json.bak
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,7 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
],

"fineGreetingGood":[
{"color":"Pink", "sprite":"camera1Smile","text":"Oh thank WAN, I thought you would ignore me again like yesterday.","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":false}
{"color":"Pink", "sprite":"camera1Smile","text":"Oh thank WAN, I thought you would ignore me again like yesterday.","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":true,"options":"Introductions"}
],
"fineGreetingBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Okay sorry, sorry. After what happened yesterday I was worried I made you mad","tickSpeed":0.05,"closeSpeed":1,"optionsVisible":true,"options":"Introductions"}
Expand Down Expand Up @@ -518,7 +518,7 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n


"AskSupervisor": [
{"name":"AskSupervisorGood", "text":"I’d have to ask my supervisor. No guarantee I can get the answer."},
{"name":"AskSupervisorGood", "text":"I’d have to ask my supervisor."},
{"name":"AskSupervisorBad", "text":"How am I supposed to know that?"}
],

Expand Down Expand Up @@ -560,16 +560,22 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
],








"WhatsYourName": [
{"name":"WhatsYourNameGood", "text":"How about you? What’s your name?"},
{"name":"WhatsYourNameBad", "text":"Cool."}
],

"WhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"My name is Synthia Powell.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"My name is Synthia Powell.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"WhatsYourNameContinue"}
],
"WhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Great.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"Great.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"WhatsYourNameContinue"}
],
"fineWhatsYourNameContinue":[
{"color":"Pink", "sprite":"camera2Angry","text":"So, was Ada able to convince her supervisors to show me whatever she was cooking up yet?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"NoSurprise"}
Expand All @@ -578,18 +584,48 @@ Delete this file after reading. talk to Synthia if you haven't already, and do n
{"color":"Pink", "sprite":"camera2Angry","text":"Did Ada at least get permission to give me my surprise yet?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"NoSurprise"}
],








"NoSurprise": [
{"name":"NoSurpriseBad", "text":"My instructions don't mention anything about a surprise… so no."}
{"name":"NoSurpriseBad", "text":"My instructions don't mention anything about that… so no."}
],

"fineNoSurpriseBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Well THAT just sucks, doesn't it? Ada is gone and now I have to talk to a stranger!","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadNoSurpriseBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"So the only woman who cared about me is gone without saying goodbye… and I get nothing?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"So the only person who cared about me is gone without saying goodbye… and I get nothing?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false,"continue":"NoSurpriseContinue"}
],
"NoSurpriseContinue":[
{"color":"Pink", "sprite":"camera2Angry","text":"So the only woman who cared about me is gone without saying goodbye… and I get nothing?","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
{"color":"Pink", "sprite":"camera2Angry","text":"This place was supposed to be PARADISE. It’s not paradise if there’s nothing to do here!","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":true,"options":"TalkToMe"}
],






"TalkToMe": [
{"name":"TalkToMeGood", "text":"You can talk to me, can't you?"},
{"name":"TalkToMeBad", "text":"You’re going to have to tough it out."}
],

"fineWhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"I guess so… but I'm going to miss Ada. I have no idea how long its going to take to get used to you…we","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"fineWhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Damn. You're an asshole. I guess you're still better than NOTHING.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadWhatsYourNameGood":[
{"color":"Pink", "sprite":"camera2Angry","text":"I guess so… but I'm going to miss Ada. I have no idea how long its going to take to get used to you…we","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],
"sadWhatsYourNameBad":[
{"color":"Pink", "sprite":"camera2Angry","text":"Damn. You're an asshole. I guess you're still better than NOTHING.","tickSpeed":0.05,"closeSpeed":0.05,"optionsVisible":false}
],

}
37 changes: 19 additions & 18 deletions UniversalFunctions.gd
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ func play_dialogue_JSON(dialogue : String):
get_tree().get_root().get_node_or_null("/root/world/Commandprompt/Options/Option3").visible = false
if dialogueJson.has(dialogue) == false:
dialogueBox.dialogue = dialogueJson["dialogueError"]
dialogueBox.currentTree = "dialogueError"
dialogueBox.currentTree = dialogue
var dialoguechecker = dialogue.replace("Converge", "")
if disgust < 60:
if loneliness <60:
Expand All @@ -50,23 +50,24 @@ func play_dialogue_JSON(dialogue : String):
if dialogueJson.has("angry"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["angry"+dialoguechecker]
dialogueBox.currentTree = "angry"+dialoguechecker
if dialogue.ends_with("Converge"):
dialoguechecker = dialoguechecker.replace("Good", "")
dialoguechecker = dialoguechecker.replace("Bad", "")
dialoguechecker = dialoguechecker.replace("Bad", "")
if disgust < 60:
if loneliness <60:
if dialogueJson.has("fine"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["fine"+dialoguechecker]
dialogueBox.currentTree = "fine"+dialoguechecker
elif loneliness >= 60:
if dialogueJson.has("sad"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["sad"+dialoguechecker]
dialogueBox.currentTree = "sad"+dialoguechecker
elif disgust >=60:
if dialogueJson.has("angry"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["angry"+dialoguechecker]
dialogueBox.currentTree = "angry"+dialoguechecker
if dialogueBox.currentTree == "dialogueError":
if dialogue.ends_with("Converge"):
dialoguechecker = dialoguechecker.replace("Good", "")
dialoguechecker = dialoguechecker.replace("Bad", "")
dialoguechecker = dialoguechecker.replace("Bad", "")
if disgust < 60:
if loneliness <60:
if dialogueJson.has("fine"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["fine"+dialoguechecker]
dialogueBox.currentTree = "fine"+dialoguechecker
elif loneliness >= 60:
if dialogueJson.has("sad"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["sad"+dialoguechecker]
dialogueBox.currentTree = "sad"+dialoguechecker
elif disgust >=60:
if dialogueJson.has("angry"+dialoguechecker):
dialogueBox.dialogue = dialogueJson["angry"+dialoguechecker]
dialogueBox.currentTree = "angry"+dialoguechecker
else:
dialogueBox.dialogue = dialogueJson[dialogue]
dialogueBox.currentTree = dialogue
Expand Down
10 changes: 5 additions & 5 deletions login.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -185,15 +185,15 @@ animations = [ {
"name": "locked",
"speed": 5.0
}, {
"frames": [ SubResource( 47 ), SubResource( 48 ), SubResource( 49 ), SubResource( 50 ), SubResource( 51 ), SubResource( 52 ), SubResource( 53 ), SubResource( 54 ), SubResource( 55 ), SubResource( 56 ), SubResource( 57 ), SubResource( 58 ), SubResource( 59 ), SubResource( 60 ) ],
"loop": true,
"name": "loading",
"speed": 8.0
}, {
"frames": [ ExtResource( 21 ) ],
"loop": true,
"name": "ibar",
"speed": 5.0
}, {
"frames": [ SubResource( 47 ), SubResource( 48 ), SubResource( 49 ), SubResource( 50 ), SubResource( 51 ), SubResource( 52 ), SubResource( 53 ), SubResource( 54 ), SubResource( 55 ), SubResource( 56 ), SubResource( 57 ), SubResource( 58 ), SubResource( 59 ), SubResource( 60 ) ],
"loop": true,
"name": "loading",
"speed": 8.0
} ]

[node name="world" type="Node2D"]
Expand Down
17 changes: 7 additions & 10 deletions main.gd
Original file line number Diff line number Diff line change
Expand Up @@ -75,29 +75,26 @@ func _on_Commandprompt_option_pressed(optionName:String):
intro = ""
$NervousTimer.wait_time = 3
UniversalFunctions.play_dialogue_JSON(optionName)
elif optionName == "AskSupervisorGood" or optionName == "AskSupervisorBad":
$Commandprompt.playerName = "Mystery Person"
UniversalFunctions.play_dialogue_JSON(optionName)
elif optionName == "GiveNameGood":
$Commandprompt.name = UniversalFunctions.firstName
$Commandprompt.playerName = UniversalFunctions.firstName
UniversalFunctions.play_dialogue_JSON(optionName)
elif optionName == "GiveNameBad":
$Commandprompt.name = "Mystery Person"
UniversalFunctions.play_dialogue_JSON(optionName)
UniversalFunctions.loneliness +=2

elif optionName == "WhatsYourNameGood" or optionName == "WhatsYourNameBad":
UniversalFunctions.play_dialogue_JSON(optionName)
yield($Commandprompt, "done")
UniversalFunctions.play_dialogue_JSON("WhatsYourNameContinue")
elif optionName == "reactionToGenerationUgly":
split = null
UniversalFunctions.topics.append("Simulation")
else:
UniversalFunctions.play_dialogue_JSON(optionName)


var optionChecker = optionName.replace("Converge","")
UniversalFunctions.loneliness -=1
if optionName.ends_with("Good"):
if optionChecker.ends_with("Good"):
UniversalFunctions.disgust -=1
elif optionName.ends_with("Bad"):
elif optionChecker.ends_with("Bad"):
UniversalFunctions.disgust +=1


Expand Down
14 changes: 7 additions & 7 deletions main.tscn
Original file line number Diff line number Diff line change
Expand Up @@ -2026,15 +2026,15 @@ animations = [ {
"name": "locked",
"speed": 5.0
}, {
"frames": [ SubResource( 47 ), SubResource( 48 ), SubResource( 49 ), SubResource( 50 ), SubResource( 51 ), SubResource( 52 ), SubResource( 53 ), SubResource( 54 ), SubResource( 55 ), SubResource( 56 ), SubResource( 57 ), SubResource( 58 ), SubResource( 59 ), SubResource( 60 ) ],
"loop": true,
"name": "loading",
"speed": 8.0
}, {
"frames": [ ExtResource( 22 ) ],
"loop": true,
"name": "ibar",
"speed": 5.0
}, {
"frames": [ SubResource( 47 ), SubResource( 48 ), SubResource( 49 ), SubResource( 50 ), SubResource( 51 ), SubResource( 52 ), SubResource( 53 ), SubResource( 54 ), SubResource( 55 ), SubResource( 56 ), SubResource( 57 ), SubResource( 58 ), SubResource( 59 ), SubResource( 60 ) ],
"loop": true,
"name": "loading",
"speed": 8.0
} ]

[node name="world" type="Node2D"]
Expand Down Expand Up @@ -2695,7 +2695,7 @@ show_behind_parent = true
material = SubResource( 6 )
position = Vector2( 3, 7 )
frames = SubResource( 336 )
frame = 9
frame = 14
playing = true
centered = false

Expand All @@ -2705,7 +2705,7 @@ light_mask = 2
material = SubResource( 6 )
position = Vector2( 3, 7 )
frames = SubResource( 457 )
frame = 9
frame = 14
playing = true
centered = false

Expand Down

0 comments on commit 7dc72b5

Please sign in to comment.