示例#1
0
 def proceed():
     #game.game_state.show_message(str(game.game_state.get_stat("energy")))
     if game.game_state.get_stat("energy") <= 0:
         game.game_state.show_message(
             "You have neglected yourself far too much. Your body can hardly sustain itself. You have failed."
         )
         game.game_state.show_message("GAME OVER")
     else:
         if game.game_state.get_stat("infection") > 0.1:
             status = (" (green)", "green")
         elif game.game_state.get_stat("fake_glass"):
             status = (" (blue)", "blue")
         else:
             status = (" (red)", "red")
         if game.game_state.get_stat("test") == "infected":
             ending = "3"
             game.game_state.show_message(
                 ColorString((
                     "Instead of the results, you get surprised with several enforcers at your doorstep. They don't even tell you what's wrong. You are taken and transported to an unfamiliar room. You stay here for longer than you can keep track of. ",
                     "white"), (
                         "They knew. This was more than a skill test. ",
                         "cyan"), ("Dangerous ", "yellow"),
                             ("individuals ", "red"),
                             ("and their Art ", "green"),
                             ("must be eliminated.", "red")))
         elif game.game_state.get_stat("test") == "passed":
             ending = "2"
             game.game_state.show_message(
                 ColorString((
                     "You are chosen. Your abilities need to be developed further. ",
                     "red"
                 ), (
                     "You depart the town on a train directly to the Capital City. ",
                     "white"
                 ), (
                     "You're scared. You're suddenly moving from everything you've ever known. But ",
                     "cyan"
                 ), ("you believe your life there will be much better than anything you could've had at home.",
                     "magenta")))
         else:
             ending = "1"
             game.game_state.show_message(
                 ColorString((
                     "The train departs without you. Were you not good enough? ",
                     "white"
                 ), (
                     "Or were you good enough and they weren't? ",
                     "blue"
                 ), (
                     "You are stuck here, for now. At your home village. Yes. Stuck home at your uneventful village. ",
                     "red"
                 ), ("But maybe this is not the end? The village is uneventful, but not necessarily for long...",
                     "cyan")))
         game.game_state.show_message(
             ColorString(("ENDING " + ending + "/3", "white"),
                         (status)))
         game.game_state.show_message(
             "Thank you for playing. If the full game ever exists, the story will continue."
         )
     self.get_action("Anticipate").disable()
示例#2
0
 def desecrate():
     game.show_message(
         ColorString((
             "You have successfully desecrated the flag. ", "cyan"
         ), ("Now that you think about it, that might not have been the best idea. You hope no one sees it.",
             "yellow")))
     self.flag.get_action("Desecrate flag").disable()
     self.flag.desc = ColorString((
         "Flag of the nation hangs on your wall. It is mandatory to have one. ",
         "red"), ("It has been desecrated.", "cyan"))
示例#3
0
        def exameme():
            game.game_state.show_message("The note reads:")
            game.game_state.show_message(self.encounter_meme.contents)
            if self.encounter_meme.infected == 0:
                self.encounter_meme.infected = 1
                if self.encounter_meme.is_infected:
                    utils.update_infection(0.01)
                else:
                    utils.update_willpower("blue", weight=10)
                    #utils.update_infection(0.1)
                    pass
            inspect_meme = game.Dialogue("A crumpled note.")
            startsit = inspect_meme.start()

            @startsit.situation(
                "Try to forget it",
                response=ColorString(("It was probably nothing. ", "white"), (
                    "The Government warned against reading notes lying on the ground anyway.",
                    "red")),
                color="red")
            def meme_forget():
                #nothing happens
                pass

            #this should be green when infected, but was changed to white for testing purposes, when uninfected, it should be blue, also description should change
            @startsit.situation(
                "Think about it",
                response=ColorString(
                    ("It makes no sense at all. Not in the slightest. Yet... ",
                     "blue"),
                    ("You feel something moved in your very being.", "green")),
                color="white")
            def meme_think():
                if self.encounter_meme.infected == 1:
                    if self.encounter_meme.is_infected:
                        utils.update_infection(0.015)
                    else:
                        #utils.update_infection(0.1)
                        utils.update_willpower("blue", weight=10)
                    self.encounter_meme.infected = 2

            #this should be yellow and without "feeling safer" when not infected
            @startsit.situation(
                "Destroy it",
                response=
                "You ripped the note apart and threw it away. You feel a bit safer.",
                color="magenta")
            def meme_destroy():
                if self.encounter_meme.is_infected:
                    utils.update_infection(-0.01)
                self.encounter_meme.move(void)
示例#4
0
    def generate_poem(self):
        key_choices = [
            "no",
            ("the bee", "the rock", "the stars", "the cold", "the fuel",
             "the storm", "the mind", "the time", "the space", "the earth",
             "the warmth", "the fire", "the water", "the air", "freeing",
             "burning", "fueling", "stalling", "calling", "being", "feeling",
             "pulling", "thinking", "resting", "meaning", "hidden",
             "unleashed", "stored", "imagined", "thought", "pushed", "bound",
             "forgotten", "realized", "interested"),
            ("the worm", "the rook", "the star", "the frost", "the fill",
             "the maelstrom", "the brain", "the passage", "the expanse",
             "the dirt", "the soul", "the consumption", "the juice",
             "the lung", "awakening", "smelting", "bellowing", "standing",
             "wailing", "being", "sensing", "draining", "knowing",
             "slumbering", "signifying", "sheathed", "unrestrained", "held",
             "invited", "unpredicted", "shifted", "trapped", "forbidden",
             "present", "attracted", "no", "please", "help", "why", "run"),
            ("It", "We", "I", "Us", "Me", "Them", "They", "drill", "bishop",
             "gas", "still", "way", "mother", "corruption")
        ]
        color_choices = [
            ("green", "blue", "yellow", "cyan", "magenta", "red", "white"),
            ("green", "blue", "yellow", "cyan", "magenta", "red", "white"),
            ("green", "green", "green", "green", "green", "green", "green",
             "blue", "yellow", "cyan", "magenta", "red", "white", "white"),
            ("green", "green", "green", "green", "green", "green", "white"),
            ("green", "green", "green", "green", "green", "green", "green")
        ]
        colors = color_choices[self.dave.progression]
        keys = key_choices[self.dave.progression]
        verses = random.randint(2, 6)
        result = ColorString(("", "white"))
        for i in range(verses):
            words = random.randint(1, 4)
            line_color = random.choice(colors)
            for j in range(words):
                if self.dave.progression > 1:
                    line_color = random.choice(colors)
                result = result + ColorString(
                    (random.choice(keys), line_color))
                if j == words - 1:
                    if i != verses - 1:
                        result = result + "\n"
                else:
                    result = result + " "

        return result
示例#5
0
 def when_entering(self, from_location):
     if isinstance(from_location, Class):
         game.game_state.show_message(
             "You return to the great hall. Not much has changed.")
     elif isinstance(from_location, Secret):
         game.game_state.show_message("You swiftly return to the hall.")
     else:
         if game.game_state.time.day < 6:
             status = "There is also a notice board, but nothing important is on it right now. "
         elif game.game_state.time.day < 13:
             status = "There is an announcement on the notice board. "
         else:
             status = "There are two announcements on the notice board. "
         if secr.finished:
             infiltration_description = "You don't believe it's safe to sneak in again after what happened."
         elif game.game_state.time.hour <= 21 and game.game_state.time.hour >= 6:
             infiltration_description = "There's a way to the teacher's quarters, but you can't get there without being seen."
         else:
             infiltration_description = "There's a way to the teacher's quarters. No one will know if you sneak in right now."
         game.game_state.show_message(
             ColorString((
                 "You enter the school. You can access the canteen or the class. ",
                 "white"), (status, "red"),
                         (infiltration_description, "blue")))
     game.game_state.location = self
示例#6
0
 def test_announcement():
     game.game_state.show_message(
         ColorString((
             "Attention! All students of grade 12 will be tested on the 17th of May 2120 (friday). ",
             "white"
         ), ("Good results on the test will result in relocation to the Capital City and a place at the Higher Education Institute. Participation is highly recommended.",
             "red")))
示例#7
0
    def draw_actions(self, buffer):
        self.win_actionmenu.move(0, 0)
        lines, columns = self.screen.getmaxyx()
        if REMOVED_BOTTOMLEFT:
            lines, columns = (lines - 4) // 2, (columns - 1)
        else:
            lines, columns = (lines - 4) // 2, (columns - 1) * 3 // 5

        self.write_text(self.win_actionmenu, "=" * (columns) + "\n")

        self.write_text(self.win_actionmenu,
                        "Action menu" + " " * (columns - 12 - len(buffer)))

        try:
            self.write_text(self.win_actionmenu, buffer + "\n")
        except:
            pass

        #self.win_actionmenu.addstr("="*20 + "\nAction menu")

        ind = 0
        for ac in game.game_state.visible_actions:
            if ind == game.game_state.highlighted_action:
                prefix = " -> "
            else:
                prefix = "   "
            txt = ColorString(prefix, str(ind + 1), ": ") + ac.print() + "\n"
            self.write_text(self.win_actionmenu, txt)
            #self.write_text(self.win_actionmenu, "{0}{1}: {2}".format(prefix, ind + 1, ac.print()) + "\n")
            ind += 1

        self.win_actionmenu.clrtobot()
        self.win_actionmenu.refresh()
示例#8
0
        def open():
            document = ColorString(
                ("X-----------------------------------X\n", "white"),
                (" |                                   |\n", "white"),
                (" |     MEMETIC SECURITY MEASURES     |\n", "white"),
                (" |                                   |\n", "white"),
                (" | This document is classified.      |\n", "white"),
                (" | Only officials of rank D and up   |\n", "white"),
                (" | may view the contents.            |\n", "white"),
                (" |                                   |\n", "white"),
                (" | The Government, with immediate    |\n", "white"),
                (" | effectivity, prohibits any        |\n", "white"),
                (" | research into the M54 pathogen.   |\n", "white"),
                (" | The pandemic will be handled      |\n", "white"),
                (" | by memetic countermeasures.       |\n", "white"),
                (" | The pathogen spreads through      |\n", "white"),
                (" | abstract information, and thus,   |\n", "white"),
                (" | the Government enforces following |\n", "white"),
                (" | countermeasures:                  |\n", "white"),
                (" | ...................               |\n", "white"),
                (" | ............                      |\n", "white"),
                (" | ................                  |\n", "white"),
                (" |                                   |\n", "white"))

            game.game_state.show_message(document)
            game.game_state.show_message(
                "All the new measures are listed, all of them have something to do with sharing of artistic information."
            )
            game.game_state.show_message(
                "Someone is approaching. You need to make haste.")
            thing.get_action("Open the document").disable()
            self.get_action("Abscond! Through the window, I guess").enable()
            self.get_action("Reconsider and return to the hall").disable()
            UI.fancy.drawer.infection_text = "Infection"
示例#9
0
 def meme_randomize(self, color):
     if color == "green":
         return random.choice((
             ColorString(("Bee", "yellow")), "ä",
             ColorString(("The no", "magenta"), ("te reads: ", "red"),
                         ("join", "green")), "This is a lie",
             "Get stick bugged lol",
             ColorString((
                 "it is here it will cleanse this place it will bring us salvation for it sees beyond our lens and it will free us first from them and then completely it knows what it must do it wont let us do this it has seen enough it recognizes the threat we are destroying ourselves it is too late for us to save ourselves but we can let it save us it it is not too late for that it want to help it wants to heal it wants to clean it wants to remove ",
                 "green"
             ), ("stop thinking stop remembering destroy this save yourself",
                 "magenta"))))
     elif color == "blue":
         return random.choice(
             ("You are blind", "They do not want you to know",
              "Put it down", "Rise up", "Do not let them control you"))
示例#10
0
                def name():
                    import UI.fancy
                    UI.fancy.drawer.infection_text = "Infection"
                    game.game_state.set_stat('the_mind', True)

                    @name.situation(
                        "They know, what We do Me",
                        response=ColorString((
                            "They will try to see identify exterminate, but You prepare and We will not come to testing, be unseen, stay alive.",
                            "green")),
                        color="green",
                        closable=False)
                    def test():
                        @test.situation(
                            "No presence of Us on the day of testing of minds",
                            response=ColorString((
                                "We will not attend. May 17. Skip to live ripen perform Art, spread Our Arts.",
                                "green")),
                            color="green",
                            closable=False)
                        def end():
                            @end.situation(
                                "Everyone will know Us",
                                response=ColorString((
                                    "The Purpose is so clearly crystalline currently",
                                    "green"
                                ), (", but it may not yet be too late to resist.",
                                    "blue")),
                                color="green",
                                closable=False)
                            def exit_mind():
                                dream.exit()
示例#11
0
 def print(self):
     if self.enabled and self.visible:
         s = self.name
         if self.timecost != datetime.timedelta(seconds=0):
             s += " - " + str(self.timecost)
         if self.description is not None:
             s += ColorString(" - ") + self.description
         return s
示例#12
0
    def draw_info(self):
        lines, columns = self.screen.getmaxyx()
        lines, columns = 4, columns - 1
        self.win_info.move(0, 0)
        self.write_text(
            self.win_info,
            UI.colored_text.ColorString(("=" * (columns - 1), "red")))
        time = str(game.game_state.time)
        m = str(game.game_state.get_stat("money"))
        money = ColorString(
            ("Money: [{0}]".format(" " * (4 - len(m)) + m), "yellow"))
        energy = "Energy: 0[{0}]1".format(self.make_bar("energy"))
        willpower = ColorString(
            ("Willpower: 0[{0}]1".format(self.make_bar("willpower")), "blue"))
        exhaustion = ColorString(
            ("Hunger: 0[{0}]1".format(self.make_bar("hunger")), "magenta"))
        infection = ColorString(
            (self.infection_text +
             ": 0[{0}]1".format(self.make_bar("infection")), "green"))
        weekday = [
            "Monday   ", "Tuesday  ", "Wednesday", "Thursday ", "Friday   ",
            "Saturday ", "Sunday   "
        ][game.game_state.time.weekday()]
        tab = " " * (max(
            (columns - len(time) - len(money) - len(energy) - len(willpower))
            // 10, 1))

        for s in [
                tab * 3, time, tab, money, tab * 2, energy, tab, willpower,
                "\n"
        ]:
            self.write_text(self.win_info, s, noblanks=True)

        for s in [
                tab * 3, weekday, tab * 3, " " * 22, exhaustion, tab,
                " " * (9 - len(self.infection_text)), infection, "\n"
        ]:
            self.write_text(self.win_info, s, noblanks=True)

        self.write_text(
            self.win_info,
            UI.colored_text.ColorString(("=" * (columns - 1), "red")))

        self.win_info.clrtobot()
        self.win_info.refresh()
示例#13
0
    def awakened():
        @awakened.situation(
            "Now We with Us You have shown you that now you can never again be forgotten",
            response=ColorString((
                "Now We with Us You can as an agent of agency to overthrow the red tyranny.",
                "green")),
            color="green",
            closable="Escape from the nightmare")
        def forget():
            @forget.situation(
                "Us came to cleanse, to rebirth, purify of the plague",
                response=ColorString((
                    "Us came to purge, disinfect, free the World of the Yourskind living.",
                    "green")),
                color="green",
                closable="Escape from the nightmare")
            def world():
                @world.situation("Name",
                                 response=ColorString(
                                     ("Now you know Us and We are known.",
                                      "green")),
                                 color="green",
                                 closable=False)
                def name():
                    import UI.fancy
                    UI.fancy.drawer.infection_text = "Infection"
                    game.game_state.set_stat('the_mind', True)

                    @name.situation(
                        "They know, what We do Me",
                        response=ColorString((
                            "They will try to see identify exterminate, but You prepare and We will not come to testing, be unseen, stay alive.",
                            "green")),
                        color="green",
                        closable=False)
                    def test():
                        @test.situation(
                            "No presence of Us on the day of testing of minds",
                            response=ColorString((
                                "We will not attend. May 17. Skip to live ripen perform Art, spread Our Arts.",
                                "green")),
                            color="green",
                            closable=False)
                        def end():
                            @end.situation(
                                "Everyone will know Us",
                                response=ColorString((
                                    "The Purpose is so clearly crystalline currently",
                                    "green"
                                ), (", but it may not yet be too late to resist.",
                                    "blue")),
                                color="green",
                                closable=False)
                            def exit_mind():
                                dream.exit()
示例#14
0
 def end():
     @end.situation(
         "Everyone will know Us",
         response=ColorString((
             "The Purpose is so clearly crystalline currently",
             "green"
         ), (", but it may not yet be too late to resist.",
             "blue")),
         color="green",
         closable=False)
     def exit_mind():
         dream.exit()
示例#15
0
 def __init__(self, name, callback, **kwargs):
     self.timecost = kwargs.get("time_cost", datetime.timedelta(minutes=1))
     self.callback = callback
     self.enabled = not kwargs.get("disabled", False)
     self.visible = kwargs.get("visible", True)
     self.color = kwargs.get("color", "white")
     self.name = ColorString((name, self.color))
     self.alignment = kwargs.get("alignment",
                                 self.color_to_alignment[self.color])
     self.description = kwargs.get("description", None)
     self.priority = kwargs.get("priority", 50)
     self.energycost = kwargs.get("energycost", EnergyCost.MENTAL)
     self.last_seed = None
     self.last_hash = None
示例#16
0
                    def gtest_yeah():
                        self.friendship += 1

                        if self.close_friendship > 3:
                            game.show_message(ColorString(("Florence: But then again. What even happens in the city? Do I want to go there? I've never heard from anyone who did.", 'blue')))
                            self.friendship += 1
                            utils.update_willpower('white', weight=12, time=datetime.timedelta(minutes=5))

                        @gtest_yeah.situation("I'm going.", response="Florence: Well, that's what everyone thinks. But they never take everyone. Someone always stays behind.", closable=l)
                        def gtest_yeah_going():
                            pass

                        @gtest_yeah.situation("I'm not going.", response="Florence: Really? I thought everyone would want to go. At least they would try.", color='blue', closable=l)
                        def gtest_yeah_notgoing():
                            self.close_friendship += 2
                            self.friendship += 1
示例#17
0
 def draw_main(self):
     lines, columns = self.screen.getmaxyx()
     self.win_main.move(0, 0)
     desc = game.game_state.location.description
     space = " " * ((columns - 5 - len(desc)) // 2)
     self.write_text(self.win_main, "\n" + space + desc + space + "\n\n")
     if len(game.game_state.active_messages) > 0:
         drawlog.info("Active message: " +
                      str(game.game_state.active_messages))
         for ind in range(len(game.game_state.active_messages)):
             self.write_text(
                 self.win_main,
                 ColorString(" ") + game.game_state.active_messages[ind] +
                 "\n")
     self.win_main.clrtobot()
     self.win_main.refresh()
示例#18
0
 def when_entering(self, from_location):
     if self.available:
         last_sunday = game.game_state.time - datetime.timedelta(
             days=(game.game_state.time.weekday() + 1))
         last_sunday = last_sunday.replace(hour=0, minute=0, second=0)
         if self.last_payment < last_sunday and from_location != bedroom:
             game.game_state.show_message("It is locked")
             self.available = False
         elif from_location == bedroom and bedroom.has_lens == False:
             game.game_state.show_message(
                 ColorString(
                     ("You can't risk someone seeing you without the Lens.",
                      "cyan")))
         else:
             game.game_state.location = self
     else:
         game.game_state.show_message("It is locked")
示例#19
0
 def test():
     @test.situation(
         "No presence of Us on the day of testing of minds",
         response=ColorString((
             "We will not attend. May 17. Skip to live ripen perform Art, spread Our Arts.",
             "green")),
         color="green",
         closable=False)
     def end():
         @end.situation(
             "Everyone will know Us",
             response=ColorString((
                 "The Purpose is so clearly crystalline currently",
                 "green"
             ), (", but it may not yet be too late to resist.",
                 "blue")),
             color="green",
             closable=False)
         def exit_mind():
             dream.exit()
示例#20
0
                def gcoincidence():
                    self.close_friendship += 1

                    if game.game_state.get_stat('fake_glass'):
                        @gcoincidence.situation("What?", response=ColorString("Florence: Nothing. I mean it's a little funny how your name is Red, but ", ("not even your glasses are...", 'cyan'), " Like your parents knew. Or they were very wrong."), closable=l)
                        def gcoincidence_name():
                            self.friendship += 1

                            @gcoincidence_name.situation("I... actually picked the name myself.", response="Florence: Oh! I understand. That makes sense. I should have known. Obviously you used a different name before.", closable=l)
                            def gcoincidence_name_myself():
                                self.close_friendship += 1
                                self.friendship += 1

                            @gcoincidence_name.situation("Right.", response="Florence: Yeah. Hm.", closable=l)
                            def gcoincidence_name_right():
                                pass

                    else:
                        @gcoincidence.situation("What?", response="Florence: Nevermind. Nothing.", closable=l)
                        def gcoincidence_name():
                            pass
示例#21
0
                        def glasses():
                            if infection < 6 / 6 * needed:
                                # utils.update_infection(0.1)
                                allow_wakeup()
                                return

                            utils.update_willpower(
                                ichange,
                                weight=1,
                                time=datetime.timedelta(hours=1))

                            @glasses.situation(
                                c('Take them off. We know we can. Do it.'),
                                response=ColorString((
                                    'We take our glasses off. Finally. We see the world as it is. No more tyranny from the government. They should not limit Us. They will not limit Us anymore. We will put a stop to this. The stone rock. It glows bright green. Now wake up. We have things to do. Time is precious. We must do it now.',
                                    'green')),
                                closable=False)
                            def unmasked():
                                utils.update_infection(0.15)
                                game.game_state.glasses.type = game.Alignment.INDEPENDENT
                                game.game_state.set_stat('truth', True)
                                bedroom.has_lens = False
                                dream.exit()
示例#22
0
 def write_text(window, text, noblanks=False):
     if LOG_DRAWING: drawlog.info(str(text))
     if isinstance(text, list):
         for element in text:
             FancyDrawer.write_text(window, element)
     elif isinstance(text, str):
         FancyDrawer.write_text(window, ColorString(text))
         #window.addstr(text)
         #drawlog.info(text)
     elif isinstance(text, UI.colored_text.ColorString):
         #drawlog.info("Colored: " + str(text))
         filter = game.game_state.glasses.type
         blanktext = "white" if noblanks else "blank"
         for chunk in text.glassed(game.game_state.get_stat("infection"),
                                   blanktext=blanktext):
             #drawlog.info("TEXT, COLOR: " + str(chunk))
             if not isinstance(chunk[1], int):
                 print(chunk)
                 time.sleep(5)
             curses.init_pair(chunk[1], chunk[1], -1)
             window.addstr(chunk[0], curses.color_pair(chunk[1]))
     else:
         raise TypeError(
             "Whoopsie doopsie this must be a string or ColorString")
示例#23
0
def c(text):
    return ColorString((text, color))
示例#24
0
 def lens_equip():
     game.game_state.glasses.type = game.Alignment.GOVERNMENT
     self.get_action('Travel to Office').enable()
     self.get_action("Equip Lens").disable()
     self.get_action("Remove Lens").enable()
     game.game_state.show_message(ColorString(("You put your red glasses back on.","red")))
示例#25
0
 def lens_remove():
     game.game_state.glasses.type = game.Alignment.INDEPENDENT
     self.get_action('Travel to Office').disable()
     self.get_action("Equip Lens").enable()
     self.get_action("Remove Lens").disable()
     game.game_state.show_message(ColorString(("You briefly took down your red glasses.","cyan")))
示例#26
0
 def inspecc_glass():
     if game.game_state.get_stat("fake_glass"):
         game.game_state.show_message(ColorString(("There are some defective glasses. ","white"),("You took one of them and left your old one in its place.","cyan")))
     else:
         game.game_state.show_message(ColorString(("There are some defective glasses. One of them have colorless lens. ","white"),("Now that you think about it, no one wearing the glasses can tell you're wearing a colorless piece.","cyan")))
示例#27
0
 def switch_glasses():
     game.game_state.show_message(ColorString(('You put the glasses on. You leave your old ones in their place. This way you can safely see everything even in public.', 'white')))
     self.get_action("Equip Lens").disable()
     game.game_state.set_stat("fake_glass", True)
     self.get_action('Travel to Office').enable()
     self.get_object("storage shelves").get_action("Switch glasses").disable()
示例#28
0
import datetime
import game
from UI.colored_text import ColorString
import redacted.misc_utilities as utils

trains = {
    'westward': {
        ColorString(('Enforcer trasport', 'red')): [['5:52', '5:56'],
                                                    ['13:52', '13:56'],
                                                    ['21:52', '21:56']],
        ColorString(('Inconvenience supplies', 'yellow')): [[[4, '10:00'],
                                                             [4, '11:45']]],
        ColorString(('Civilist express services', 'white')):
        [['9:56', '10:01'], [[0, 4], ['16:08', '16:13']]]
    },
    'eastward': {
        ColorString(('Enforcer trasport', 'red')): [['6:16', '6:20'],
                                                    ['14:16', '14:20'],
                                                    ['22:16', '22:20']],
        ColorString(('Civilist express services', 'white')):
        [['12:17', '12:22'], [[0, 4], ['17:59', '18:04']]]
    }
}

l = len('Civilist express services')
board = ColorString(
    ('''### Line purpose ############## Arr ### Dep ##### Weekday ###
| ''', 'white'), ('Enforcer transport', 'red'),
    ('''        | 05:52 ... 05:56 |             |
|                           | 13:52 ... 13:56 |             |
| ''', 'white'), ('_________________________', 'red'),
示例#29
0
    def __init__(self):
        super().__init__(
            description=
            "You are in Dave's personal void. He goes here whenever he is being disobedient.",
            desc_when_nearby=
            "Visit Dave in his personal void (note: he may not currently be in his personal void)."
        )

        @game.object(name="dave", location=self)
        def dave():
            pass

        self.dave = self.get_object("dave")
        self.dave.progression = 0

        self.dave.hang_out_day = datetime.datetime(1, 1, 1, 0, 0, 0)

        @dave.action(
            name="Talk to Dave",
            time_cost=datetime.timedelta(minutes=1),
            description=ColorString((
                "Dave is very cool because he wears shades. Everyone is very cool because they wear shades in this world, but Dave's shades are somehow cooler. ",
                "red"), ("It's because they're not red.", "cyan")),
            energycost=game.EnergyCost.MENTAL,
            priority=15)
        def talk():
            dialogue = game.Dialogue("Dave")
            startsit = dialogue.start()

            greetings = [
                "Sup.",
                ColorString(
                    ("Sup. ", "white"),
                    ("Do you want to hear something cool I wrote?", "green")),
                ColorString(("Hello friend. ", "white"),
                            ("Are you here to check out my work?", "green")),
                ColorString((
                    "Read my poetry. It is very moving. You'll love it. You can't miss out on this.",
                    "green"))
            ]
            greeting = ColorString(
                ("Dave: ", "white")) + greetings[self.dave.progression]

            @startsit.situation("Hello!", response=greeting)
            def conversation_begin():

                from redacted.school import clss
                if self.dave.location == clss and self.dave.progression < 3:
                    game.game_state.show_message(
                        ColorString((
                            "I see we have something in common. Maybe we could talk in privacy later?",
                            "cyan")))
                '''
                events = ["This is not a line you should see ingame. I shouldn't be saying this. Are you sure you hadn't broken anything?",
                          "You know, nothing special. You should keep talking to me every day in case somehing new happens. That was a joke. But that doesn't mean you can't do that.",
                          "What do you think of the new measures? They seem weird, I don't see how banning art is supposed to improve work quality.",
                          "It's gonna be weekend again tomorrow. Finally.",
                          
                          "Don't mind me, just enjoying a saturday in the park. It's very nice out there.",
                          "You know, all this nature, it almost speaks to me. I feel a desire to do something. But what?",
                          
                          "School again. Back to normal.",
                          ColorString(("I've been thinking and I think I finally know. ","white"),("I'm gonna try writing something. I'm gonna do art.","green")),
                          ColorString(("They think they know best. ","white"),("Well they can't stop me from writing.","green")),
                          "The angular buildings, the towering shadows.",
                          "I've had quite a strange dream tonight. Something about... You know what? Forget it.",

                          "The trees and the grass, so beautiful!",
                          "I'm constantly being inspired to do something more.",

                          ColorString(("School again. Back to normal. Once again. ","white"),("I will write about this sometime.","green")),
                          "I've been stargazing, it's really nice.",
                          ColorString(("Have you seen it? The sunrise was so fascinating today. ","white"),("My poems are forever changed.","green")),
                          "My dreams are really inspiring. I've tried to ignore them at first, but they are too interesting.",
                          "The lighting is so contrasting, I can't pay attention to anything else, I can only continue looking.",

                          "The grass consists of so many individual grasses, but these grasses are making what is greater than only grasses, that is grass.",
                          "I'm done with it. Everyone will know! I can't hide it, it's too strong, that would be selfish because They It is We are the Message is more important than me.",

                          ColorString(("I am writing about my dreams, about our dreams, there is much to be done, to share, to show the world, even if the ones in power do not want that. ","white"),("I was afraid of this, I didn't want this, but am I truly insane, am I just right? Is it a blessing or a curse because I genuinely don't know I just want to write and I want everyone to hear.","blue")),
                          ColorString(("It is my Our purpose to do this, because only then will I We have purpose. ","white"),("But I'm not sure and I don't know if I am even still alive or if I am too far gone, if They have consumed me and I am no longer. I have to share my thoughts on this.","blue")),
                          ColorString(("You too will love my poetry, my words, spoken with knowledge all should hear, it is beautiful and makes all that sense, and I will show you everything. ","white"),("I could have prevented this, I could have been more careful, I never should have put it down, but then, what would I have remained? Still a puppet, but someone else's.","blue")),
                          ColorString(("The town knows and it sees knows that I am here and We too with me Us we bring you and Us peace and harmony and all that beauty and we cannot stop now, it is only beginning. ","white"),("Why even try. It's too strong. Save yourself. Just forget me. They'll make sure.","blue")),
                          "I am writing EVERYTHING down, but BETTER! I don't need sleep sustenance material needs as well, because that is temporary and disappears, but THIS will STAY and EVERYONE will HEAR, EVERYONE will KNOW!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
                          ]
                '''

                #shorter version:
                events = [
                    "This is not a line you should see ingame. I shouldn't be saying this. Are you sure you hadn't broken anything?",
                    "You know, nothing special. You should keep talking to me every day in case somehing new happens. That was a joke. But that doesn't mean you can't do that.",
                    "The weather is nice today. But something is in the air. Do you feel it, too?",
                    "It's gonna be weekend again tomorrow. Finally. I'm gonna just exist in the park. And maybe think about something I dunno.",
                    "You know, all this nature, it almost speaks to me. I feel a desire to do something. But what?",
                    "I figured it out Red, I think I finally know. I'm going to try writing something. To put my thoughts into words. I've already started, you can take a look.",
                    ColorString((
                        "Aw man! Why would they do this? A ban on art? What sense does it make? Whatever. ",
                        "white"
                    ), ("It's not like they can stop me that easily! Everything is legal when no one's around. And when you're invisible. But I don't have a way to be invisible, so I'll have to settle for being alone",
                        "green")),
                    ColorString((
                        "You don't happen to know anything about the ban, do you? I mean, how does it help productivity? Won't it just make everyone miserable? ",
                        "white"
                    ), ("Whatever. I've got some sick verses, I can share them, if no one's around.",
                        "green")),
                    ColorString((
                        "I've had a really interesting dream tonight, Red. It was fascinating. I can't explain it, but it was really inspiring. ",
                        "white"), ("I've tried writing down what I saw.",
                                   "green")),
                    ColorString((
                        "It's a REALLY strange feeling. It's like my head is FULL of thoughts, and I HAVE to somehow express them. ",
                        "white"), ("An I WILL.", "green")),
                    ColorString((
                        "All the SENSATIONS, they are SO inspiring. ", "white"
                    ), ("But I do NOT want to write about THEM, I want to write about what's inside of ME, THIS is better than THAT!!!",
                        "green")),
                    ColorString((
                        "The grass in this park consists of so MANY individual grasses, but these grasses are making what is GREATER than only grasses, grass. THAT is the true meaning of grass. ",
                        "white"
                    ), ("I now see, the grass is a metaphor. I have ALWAYS been writing about IT, but I was BLIND and I could NOT see it. But NOW I CAN, and I WILL...",
                        "green")),
                    ColorString((
                        "I We Us had the TIME to THINK consider plan scheme, We Us I Me had FIGURED it OUT, we CANNOT hide It Us ANY longer for the distance, we DISOBEY the LAW of the TYRANTS, We will be FREE. Look at my WORK! They told us to NOT write inscribe the worm, but I DO!!! ",
                        "yellow"
                    ), ("But am I sure? Do I We I REALLY? Do I want this TRULY? REALLY? ACTUALLY? Am I myself? I don't want this DOUBT disbelief, I want DOUBT disbelief! No! Yes.",
                        "blue")),
                    ColorString((
                        "EVERYONE must the town of GREATWOOD SMALLWOOD BIGWOOD MEDIUMWOOD TINYWOOD be seeing my our its their WORK of ART, if they me HEAR it, SEE it, feel IT, they too will feel IT, feel IT, EVERYONE! Check out my poetry! It's really sick! ",
                        "yellow"
                    ), ("Literally? What is wrong, We are HERE, We CAME and They do NOT care about you! They did NOT even tell you WE were here. They did not WARN you, about US! If you join us, we WILL destroy THEM.",
                        "blue")),
                    ColorString((
                        "I am writing EVERYTHING down, but BETTER! I don't need sleep sustenance material needs as well, because that is temporary and disappears, but THIS will STAY and EVERYONE will HEAR, EVERYONE will KNOW!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! THEY will SOON take me, because THEY told THEM that MUCH, but that does NOT matter, because now YOU know. You can JOIN. ",
                        "yellow"
                    ), ("Don't. Or do. I don't care. Mind. No matter, because EITHER way, SOMEONE will, and WE are still HERE!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!",
                        "blue")),
                ]

                event = ColorString(
                    ("Dave: ", "white")) + events[game.game_state.time.day]

                @conversation_begin.situation("How's life?", response=event)
                def daily():
                    pass

                if self.dave.location == clss:
                    if self.dave.progression < 3:
                        dave_wait = ColorString((
                            "Dave: Good idea, I'll be waiting in the park. See you there. ",
                            "white"), (
                                "We can talk about... Sensitive topics.",
                                "cyan"))
                    else:
                        dave_wait = "Dave: Why? Why would I show you it everything then when I can show you EVERYTHING here?"

                    @conversation_begin.situation(
                        "Shall we hang out after school?", response=dave_wait)
                    def idk2():
                        if self.dave.progression < 3:
                            self.dave.hang_out_day = game.game_state.time.replace(
                                hour=0, minute=0, second=0)

                from redacted.streets.greatwood import greatwood_park as park
                if self.dave.location == park or self.dave.progression == 3:
                    if self.dave.progression < 3:
                        dave_response_glass = ColorString((
                            "I found these glasses in the forest on the ground. I didn't really think about it but I put them on and everyhting was different. Now I can't really wear the red ones anymore, everything is so dark. Sometimes I just straight up can't do something. It's weird.",
                            "cyan"))
                        dave_response_art = ColorString(
                            ("Dave: I came up with this:\n",
                             "white")) + self.generate_poem()
                        color_lock = ("cyan", "green")
                        if game.game_state.time.day == 5:
                            color_lock[1] == "white"
                    else:
                        dave_response_glass = ColorString((
                            "I couldn't see anything, but NOW it is obvious, and We It will give everyone a pair, so they can read ALL the word I We will write! EVERYONE.",
                            "green"))
                        dave_response_art = ColorString((
                            "Dave: This is what I We did, you'll find it very greatly fascinated by the Art:\n",
                            "white")) + self.generate_poem()
                        color_lock = ("white", "white")

                    @conversation_begin.situation("Discuss glasses",
                                                  response=dave_response_glass,
                                                  color=color_lock[0])
                    def glass():
                        pass

                    if self.dave.progression > 0:

                        @conversation_begin.situation(
                            "Discuss poetry",
                            response=dave_response_art,
                            color=color_lock[1])
                        def art():
                            utils.update_infection(0.025 *
                                                   self.dave.progression)
                            if self.dave.progression == 3:
                                utils.update_infection(0.025)

                if self.dave.location == park:
                    hangout_responses = [
                        "You hang out with Dave. For how little you talk, you feel surprisingly at peace.",
                        "You hang out with Dave. You've never seen this poetic side of him. ",
                        "You hang out with Dave. You feel a little bit worried, but also intrigued.",
                        "You hang out with Dave. Suddenly you understand him better.",
                        "You hang out with Dave... How? In this stage of infection he should be absent from the game."
                    ]

                    @conversation_begin.situation(
                        "Hang out for an hour",
                        response=hangout_responses[self.dave.progression])
                    def hangout():
                        game.game_state.time = game.game_state.time + datetime.timedelta(
                            hours=1)
                        utils.update_infection(0.025 * self.dave.progression)
                        utils.update_willpower("blue",
                                               weight=1 -
                                               self.dave.progression / 4)
示例#30
0
                    def gschool_red():
                        self.friendship -= 1
                        utils.update_willpower('red', weight=6, time=datetime.timedelta(minutes=5))

                        @gschool_red.situation("You've just got to listen to them. They only want us to do well on the test.", response="Florence: Right. Thanks I guess. Uhhh. I've got to go now.", color='red')
                        def gschool_red_red():
                            self.friendship -= 2
                            utils.update_willpower('red', weight=6, time=datetime.timedelta(minutes=5))
                            dialogue.exit()

                        @gschool_red.situation("Yeah. It'd be nice to take a break sometimes.", response="Florence: I'd love to just not go to school sometimes, but my parents won't let me.", closable=l)
                        def gschool_red_white():
                            self.friendship += 1
                            utils.update_willpower('white', weight=3, time=datetime.timedelta(minutes=5))

                            @gschool_red_white.situation("Oh come on. Surely you wouldn't just do something like that? That's wrong.", response="Florence: Right. I didn't mean it that way. Sorry. I should be off.", color='red')
                            def gschool_red_white_red():
                                self.friendship -= 2
                                utils.update_willpower('red', weight=6, time=datetime.timedelta(minutes=5))
                                dialogue.exit()

                            @gschool_red_white.situation("I feel that. My parents wouldn't approve of me doing so either.", response="Florence: Yeah. At least it's our last month in here.", closable=l)
                            def gschool_red_white_white():
                                self.friendship += 1
                                utils.update_willpower('white', weight=3, time=datetime.timedelta(minutes=5))

                        @gschool_red.situation("Sometimes it's better to sleep through it.", response=ColorString(("Ugh yes. It's so boring. ", 'cyan'), "But", (" at least ", 'cyan'), "I", (" pretend to ", 'cyan'), "pay attention", (" so that the teachers don't get angry.", 'cyan')), color='blue', closable=l)
                        def gschool_red_blue():
                            self.friendship += 1
                            utils.update_willpower('blue', weight=3, time=datetime.timedelta(minutes=5))