def _wizard(): creature = Mob("wizard", "you can hear sparkles and magic...a wizard!", "some dust and intestines under a robe") creature.hp = 20 creature.ap = 10 creature.xp = 750 creature.cash = randint(100, 200) creature.attack = 10 creature.sensitivity = None return creature
def _robber(): creature = Mob("robber", "a bag of money and the chewing of knives...a robber!", "a crumpled heap of humanoid flesh") creature.hp = 15 creature.ap = 5 creature.xp = 500 creature.cash = randint(50, 100) creature.attack = 5 creature.sensitivity = "green" return creature
def _scary_creature(): creature = Mob("very scary creature", "you're not sure...some very scary creature!", "it's still vibrating and pulsating") creature.hp = 50 creature.ap = 15 creature.xp = 1500 creature.cash = randint(200, 300) creature.attack = 20 creature.sensitivity = None return creature
def _strange_creature(): creature = Mob("strange creature", "you're not sure...some strange creature!", "it's still vibrating") creature.hp = 30 creature.ap = 10 creature.xp = 1000 creature.cash = randint(200, 300) creature.attack = 15 creature.sensitivity = None return creature
def _rockman(): creature = Mob("rock monster", "sounds like rolling rocks...like a rock monster!", "a pile of pebbels, rubble and rocks") creature.hp = 4 creature.ap = 8 creature.xp = 250 creature.cash = randint(50, 100) creature.attack = 5 creature.sensitivity = "red" if randint(0, 1) == 1: return creature
def _goat(): creature = Mob("demon goat", "you can hear hoves on rocks...a demon goat!", "a human chest and the body of a goat, weird") creature.hp = 5 creature.ap = 1 creature.xp = 100 creature.cash = randint(15, 50) creature.attack = 2 creature.sensitivity = "red" if randint(0, 1) == 1: return creature return creature
def _lobster(): creature = Mob( "giant lobster", "it makes a click-clacking noise, almost like...a giant crab!", "a pile of cans, claws and shells") creature.hp = 7 creature.ap = 4 creature.xp = 350 creature.cash = randint(50, 100) creature.attack = 4 creature.sensitivity = "blue" return creature
def _unicorn(): creature = Mob("unicorn", "you can hear hoves, sparkles and magic...a unicorn!", "the blood is sticky and warm") creature.hp = 50 creature.ap = 50 creature.xp = 1500 creature.cash = randint(300, 500) creature.attack = 10 creature.sensitivity = "green" if randint(0, 5): return creature
def _bunny(): creature = Mob( "bomber bunny", "you can hear sizzles and maniacal laughter...a bomber bunny!", "it's completely mangled") creature.hp = 3 creature.ap = 1 creature.xp = 50 creature.cash = randint(25, 75) creature.attack = 2 creature.sensitivity = "green" if randint(0, 2) == 1: return creature
def _crab(): creature = Mob( "giant crab", "it makes a click-clacking noise, almost like...a giant crab!", "a pile of cans, claws and shells") creature.hp = 4 creature.ap = 3 creature.xp = 200 creature.cash = randint(25, 75) creature.attack = 4 creature.sensitivity = "blue" if randint(0, 1) == 1: return creature
def scene1(): start_room = bedroom = Rolodex("bedroom") closet = Rolodex("closet") hallway = Rolodex("hallway") livingroom = Rolodex("livingroom") # BEDROOM bedroom.node.reparent_to(render) bed = Menu("bed") bed.add(Return("look", "You just woke up from this bed.")) bedroom.add(bed) bedroom_hallway_door = Door(name="door", destination=hallway, description="a plain white door") bedroom_hallway_door.locked = "It won't open. It's locked." bedroom.add(bedroom_hallway_door) bedroom_closet_door = bedroom.add( Door(name="closet", destination=closet, description="The oak closet holding your wardrobe.")) # DESK desk = Rolodex("desk") bedroom.add(Move("desk", desk, "You look closer at the desk.")) desk.add(Option("computer", "It's old and crappy")) def unlock_bedroom_door(activated, activator): if bedroom_hallway_door.locked: bedroom_hallway_door.locked = None base.interface.say("You unlock the door with a satisfying click.") else: base.interface.say("It's already unlocked.") key = desk.add(Item("key")) key.add(Return("look", "It's an old and crappy key")) key.add( Use("use", "That doesn't work.", bedroom_hallway_door, unlock_bedroom_door)) desk.add( Move("nevermind", bedroom, "You stop looking at the desk.", keep_rotation=None)) # HALLWAY hallway.add(Option("statue", "It's a statue of an angel.")) staircase_down = hallway.add(Menu("staircase")) staircase_down.add(Return("look", "Stairs go downwards here.")) staircase_down.add( Move("go down", livingroom, "You descend the stairs.", keep_rotation=False)) hallway.add( Mob("zombie", "It's all sticky and oogy.", "a puddle of meat and bones.")) hallway.add(Option("painting", "an ugly painting")) hallway.add(Door(destination=bedroom, mimic=bedroom_hallway_door)) # LIVINGROOM livingroom.add(Option("front door", "The front door to the house.")) livingroom.add(Option("television", "The tv. It's turned off.")) livingroom.add(Option("sofa", "The sofa. You hate this thing.")) staircase_up = livingroom.add(Menu("staircase")) staircase_up.add(Return("look", "Stairs go upwards here.")) staircase_up.add( Move("go up", hallway, "You ascend the stairs.", keep_rotation=False)) # CLOSET closet.add(Door(destination=bedroom, mimic=bedroom_closet_door)) closet.add(Option("clothing", "all sort of clothing")) return start_room