Compare commits

..

No commits in common. "e0c9c4186c5109f8dd46a13e01c2907bdd802883" and "91c05d88ecb2e238816110e9e84cbd9f40591eed" have entirely different histories.

5 changed files with 68 additions and 200 deletions

View file

@ -894,10 +894,7 @@ pub fn handle_chat_scripts(
),
With<actor::Player>,
>,
mut q_playercam: Query<
(&mut Position, &mut Rotation, &mut LinearVelocity),
With<actor::PlayerCamera>,
>,
mut q_playercam: Query<(&mut Position, &mut Rotation, &mut LinearVelocity), With<actor::PlayerCamera>>,
mut q_chats: Query<&mut Chat>,
mut ew_sfx: EventWriter<audio::PlaySfxEvent>,
mut ew_effect: EventWriter<visual::SpawnEffectEvent>,
@ -1052,10 +1049,6 @@ pub fn handle_chat_scripts(
error!("Can't register contact `{param1}', it doesn't exist in the chat::CONTACTS constant.");
}
}
"installlunabackup" => {
prefs.luna_backup = true;
prefs.save()
}
_ => {
error!("Error, undefined chat script {name}");
}
@ -1101,7 +1094,6 @@ pub fn update_chat_variables(
vars.set_in_scope("phone", contact, bool2chatvar(value));
}
vars.set_in_scope("phone", "any", bool2chatvar(any));
vars.set_in_scope("luna", "backupinstalled", bool2chatvar(prefs.luna_backup));
}
}

View file

@ -1,24 +0,0 @@
# Chat System Documentation
For now, see chat.rs for the source code and the individual YAML files for examples.
# Known bugs
## Only Ifs
```
- some choice:
- if $a:
- answer 1
- if $b:
- answer 2
```
This is currently broken. Instead do this:
```
- some choice:
- if $a:
- answer 1
- goto: somelabel
- answer 2
```

View file

@ -16,16 +16,9 @@
- if: phone$travel
FASTravel:
- goto: travel
- if: phone$luna
Luna:
- goto: luna
- "[Cancel]":
- goto: EXIT
# ---------------------------------------------------------
# ---------------------------------------------------------
# ---------------------------------------------------------
- label: travel
- script: changename FASTravel
- Welcome to FASTravel™, how can I help you today?
@ -70,15 +63,3 @@
- goto: EXIT
- "[Hang up]":
- goto: EXIT
# ---------------------------------------------------------
# ---------------------------------------------------------
# ---------------------------------------------------------
- label: luna
- script: changename Luna
- Hey, time traveler, what's up?
- Just chilling:
- Cool, cool.
- "[Hang up]": []
- goto: EXIT

View file

@ -378,10 +378,6 @@
- chat: Luna
- if phone$luna:
- set: begged
- set: believe
- set: timetravel
- "if $$player_suit_health_percent < 100":
- Holy shit! Look at all those scratches and tears on your suit!
- script: repairsuit
@ -402,17 +398,6 @@
- goto: mainnode
- if: "$$chefhat"
The cake is a lie.:
- set: grateful 0
- if $begged:
- Damn sure it is!
- if $backupinstalled:
- Thanks again for letting me install my backup software!
- goto: mainnode
- Let's not waste this opportunity and *please* let me install my backup software on your space suit.
- goto: node_spyware
- if $believe:
- Yes, time traveler. Please!! Tell me about it!
- goto: node_ask
- if $explained:
- ...
- Yes, indeed.
@ -422,31 +407,31 @@
- So you are proving nothing.
- Go kill yourself, magically rewind time, and *then* tell me the phrase with the chef hat on.
- goto: mainnode
- Ooooh.
- Now why would you say that?
- I... don't really know.:
- You seem confused.
- It's ok. Just drift a bit, take some deep breaths, and come back when you are feeling better.
- goto: EXIT
- I was promised a cake. There was no cake.:
- How utterly disturbing.
- The real question is, why would I not say that?:
- Point taken.
- That's a great sentence to just randomly say.
- Congratulations on your creativity.
- Funny hat too.
- I'm just following orders.:
- YOU'RE AN ACTUAL FUCKING TIME TRAVELER?!
- set: believe
- Please, tell me everything you can about this!
- goto: node_ask
- Because cake is delicious!:
- That makes no sense whatsoever.
- Stop wasting my time, lunatic.
- goto: EXIT
- goto: mainnode
- if ~$explained:
- Ooooh.
- Now why would you say that?
- I... don't really know.:
- You seem confused.
- It's ok. Just drift a bit, take some deep breaths, and come back when you are feeling better.
- goto: EXIT
- I was promised a cake. There was no cake.:
- How utterly disturbing.
- The real question is, why would I not say that?:
- Point taken.
- That's a great sentence to just randomly say.
- Congratulations on your creativity.
- Funny hat too.
- I'm just following orders.:
- YOU'RE AN ACTUAL FUCKING TIME TRAVELER?!
- set: believe
- Please, tell me everything you can about this!
- goto: node_ask
- Because cake is delicious!:
- That makes no sense whatsoever.
- Stop wasting my time, lunatic.
- goto: EXIT
- goto: mainnode
- What are you up to?:
- set: grateful 0
- Tinkering on various projects and running a workshop. Come by if you need any repairs!
- What kind of projects?:
- A tuned MotorAce spaceship, an impact dampener, and... a secret project.
@ -519,14 +504,14 @@
- There was something else I wanted...:
- goto: mainnode
- Bye.:
- goto: bye
- So long, drifter!
- goto: EXIT
- goto: timeout
- Good luck with that!:
- Thanks!
- goto: mainnode
- goto: timeout
- What brings you here?:
- set: grateful 0
- if $thinking:
- As said, I don't like people.
- if ~$thinking:
@ -541,22 +526,8 @@
- I just want to get away from all this insanity...
- Just want to tinker without anyone bothering me.
- goto: mainnode
- if: "~phone$luna"
Can I have your phone number?:
- set: grateful 0
- if $backupinstalled:
- Of course, time traveler! Anything!
- script: registercontact luna
- goto: mainnode
- if $believe:
- Hm... I trust you, but... I want you to do me a favor first.
- Let me install my backup software on your space suit.
- goto: node_spyware
- No.
- How do I know you're not a scammer?
- if: "$$ar"
You're wearing cat ears!:
- set: grateful 0
- msg: Meowwww!
sound: cat
- Yes.
@ -564,7 +535,6 @@
- goto: mainnode
- if: "$timetravel"
Do you think time travel into the past is possible?:
- set: grateful 0
- if $believe:
- Well, you just proved it to me, didn't you?
- How else would you know the phrase and the chef hat thing?
@ -572,54 +542,51 @@
- Sad that we don't know *how* or *why* this is happening.
- This will give me a lot to think about. Thank you!
- goto: mainnode
- No.
- Well, theoretically, there's all sorts of way to do this but none of them are feasible.
- Why do you ask?
- Just curious:
- It's good to stay curious.
- goto: mainnode
- If I die, I seem to wake up in the same spot over and over again...:
- Hey, let me be very clear here.
- Do not waste my time with bullshit, or I will scrap your body for raw materials.
- I'm serious. Everything reverts back to how it was before, and nobody remembers me.:
- Hm.
- Fascinating.
- I don't believe you.
- But there is obviously one way we can easily validate this.
- set: $explained
- Kill yourself to rewind time. Then come back to me wearing a silly chef hat and say "The cake is a lie."
- label: timetravelqanda
- Why? I don't get it.:
- You know, I think a lot about time travel.
- I memorized some phrases that I would tell anyone who claims to be able to travel back in time.
- If they can tell me one of those phrases *before* I tell them, it must mean that they traveled back in time! How else could they know the phrase?
- goto: timetravelqanda
- Where can I get a chef hat?:
- Not a real one, of course.
- Change the settings of your space suit to project an avatar in augmented reality.
- You should find a "Chef Hat" option somewhere. [Press ESC]
- goto: timetravelqanda
- That's genius.:
- Thank you!
- Now go kill yourself. Don't forget the chef hat.
- goto: EXIT
- I'm not going to kill myself.:
- Well, doesn't really matter how you die.
- "Just remember. Wear silly chef hat, and tell me: The cake is a lie."
- goto: EXIT
- Whatever.:
- Thank you.
- if ~$believe:
- No.
- Well, theoretically, there's all sorts of way to do this but none of them are feasible.
- Why do you ask?
- Just curious:
- It's good to stay curious.
- goto: mainnode
- If I die, I seem to wake up in the same spot over and over again...:
- Hey, let me be very clear here.
- Do not waste my time with bullshit, or I will scrap your body for raw materials.
- I'm serious. Everything reverts back to how it was before, and nobody remembers me.:
- Hm.
- Fascinating.
- I don't believe you.
- But there is obviously one way we can easily validate this.
- set: $explained
- Kill yourself to rewind time. Then come back to me wearing a silly chef hat and say "The cake is a lie."
- label: timetravelqanda
- Why? I don't get it.:
- You know, I think a lot about time travel.
- I memorized some phrases that I would tell anyone who claims to be able to travel back in time.
- If they can tell me one of those phrases *before* I tell them, it must mean that they traveled back in time! How else could they know the phrase?
- goto: timetravelqanda
- Where can I get a chef hat?:
- Not a real one, of course.
- Change the settings of your space suit to project an avatar in augmented reality.
- You should find a "Chef Hat" option somewhere. [Press ESC]
- goto: timetravelqanda
- That's genius.:
- Thank you!
- Now go kill yourself. Don't forget the chef hat.
- goto: EXIT
- I'm not going to kill myself.:
- Well, doesn't really matter how you die.
- "Just remember. Wear silly chef hat, and tell me: The cake is a lie."
- goto: EXIT
- Whatever.:
- Thank you.
- goto: mainnode
- Bye!:
- set: grateful 0
- label: bye
- if $believe:
- So long, time traveler!
- goto: EXIT
- So long, drifter!
- goto: EXIT
- label: timeout
- goto: mainnode
- Hm? Is your transmitter borked?
- goto: EXIT
- label: node_ask
- When I die, I just wake up and everything is back as it was before.:
@ -630,20 +597,7 @@
- Let me apologize though. I must have been rude before you showed me proof for your story.
- There are just so many bullshitters in the world and I don't have the patience anymore.
- But I believe you now.
- AAAH THIS IS SO COOL!!!
- I KNOW RIGHT???:
- Wait, something doesn't add up.
- You say that when you die, everything reverts to how it was before.
- But your memory seems to persist across deaths!
- Is there anything else that persists?
- Well, my space suit settings stay the same:
- Fascinating!
- Hmm...
- This opens up interesting opportunities!
- Imagine, I could upload my research onto your space suit, and recover it in the next time line!
- set: begged
- Would it be ok if I install some backup software on your space suit?
- goto: node_spyware
- If there is *anything* I can do for you, let me know. This is amazing!
- goto: mainnode
- Leave me alone.:
- goto: gtfo
@ -659,40 +613,6 @@
- goto: node_ask
- label: node_spyware
- What does the software do?:
- It stores an encrypted backup of my personal notes and my research projects.
- I'll get read/write access to a portion of your suit's storage.
- This way, I could save my research from this timeline and recover it in the next timeline!
- Imagine the possibilities!
- goto: node_spyware
- What if it's a virus?:
- I won't try to convince you to trust me.
- People deceive all the time.
- But if you have any problem with the software, just do a factory reset.
- goto: node_spyware
- Ok, let's do this!:
- label: accept_spyware
- Wonderful. I will connect now. Just ignore the warnings.
- system: "WARNING: Untrusted application installation requested"
- "[Accept]":
- system: "Untrusted application installed!"
- script: installlunabackup
- Aah, you're a treasure! That will help a lot! Thank you!
- goto: mainnode
- Wait, I have some questions first.:
- Of course. I don't want you to feel scammed or something.
- goto: node_spyware
- No, I don't want to do this.:
- Sure. This is completely up to you of course.
- Just...
- Such a waste of this opportunity.
- Ok, maybe you have a point. Let's do this.:
- goto: accept_spyware
- Forget it.:
- Ok, ok.
- goto: main_node
---

View file

@ -482,7 +482,6 @@ pub struct Preferences {
pub flashlight_power: usize, // 0-2
pub thruster_boost: usize, // 0-2
pub contacts: Vec<String>,
pub luna_backup: bool,
#[serde(skip)]
pub source_file: Option<String>,