TUN3 - Mathbrush's Cragne Manor source (and parser responses)

Several people are posting their Cragne Manor source code, and other people were talking about parser responses, so I thought I’d post my code which is primarily parser responses.

I volunteered to work on Cragne Manor during a busy time, so I asked for (and got permission) to make my room essentially puzzle-free, so all I worked on was atmosphere (which is why modifying parser responses was in there). It’s a very late-game room, at the end of one of the big puzzle chains.

It definitely is one of the smallest rooms.

Summary
Chapter 1 - Do Not Change Any Of This

Include Cragne Suite by Ryan Veeder.

[Don't mess with other people's rooms!]

TUN is a region.

TUN3 is a room in TUN.

Door9a is a closed locked scenery door. Door9a is east of TUN2 and west of TUN3. Key9 unlocks Door9a.

Door9b is a closed locked scenery door. Door9b is west of TUN4 and east of TUN3. Key9 unlocks Door9b.

Key9 is in CHU3.

Part 1 - TUN3

Printed name of TUN3 is "Narrow Straits (Mathbrush)".

Description of TUN3 is "[first time]A smell like a used kitchen sponge assaults your nose as you pass through the door. You can feel your breath rattle in your lungs. There's something wrong with the air.

[only]You find yourself in a dark, narrow space between two stone walls. Moisture condenses from the ceiling and drips down the stone bricks to the floor.".

Instead of smelling when the player is in TUN3:
	say "It smells like a dirty kitchen sponge.";

A Container11 is a closed locked openable opaque container. Container11 is in TUN3. Key11 unlocks Container11. Container11 is not portable.

The printed name of Container11 is "foul sarcophagus". "A foul sarcophagus occupies almost all of the space, leaving you cramped against the walls." Understand "foul" or "crypt" or "sarcophagus" or "dark" or "single" or "keyhole" or "coffin" as Container11.

The description of Container11 is "A stone coffin of ancient and exquisite craftsmanship that has somehow gone terribly wrong. The coffin is seamed with cracks and rifts, out of which ooze foul-smelling black slime. The floor around the coffin is crusted with years worth of dried slime.

[if Container11 is open]The sarcophagus is open. You can't undo what you've done.[otherwise]The sarcophagus contains a single dark keyhole in its center.[end if]"

[I don't know if Carry Out is the right way to do this but I'll change it later]

Instead of closing Container11:
	if Container11 is closed:
		say "You reassure yourself that the coffin is closed.";
	otherwise:
		say "You cannot undo what you have done."

Instead of unlocking Container11 with Key11:
	if Container11 is locked:
		say "You press the key into the keyhole on the center of the sarcophagus. You encounter slight resistance. 
		
		Pushing the key further, you displace a pint's worth of black slime that wells up and drips down the sides of the sarcophagus. Your hand burns where the slime touches it, but it fades when you wipe it off.";
		now Container11 is unlocked;
	otherwise:
		say "It is already unlocked."

A thing can be filthy or not filthy. A thing is usually not filthy.

Report examining something (called the examinee):
	if the noun is filthy:
		say "[The examinee] has been fouled with a black stain."
	
Instead of opening Container11:
	if Container11 is locked:
		say "It resists being opened. It must still be locked.";
	otherwise if Container11 is closed:
		repeat with dirtee running through things worn by the player:
			now dirtee is filthy;
		say "You kneel down in the filth and open the sarcophagus. The pent-up slime spills out and fouls your clothing[if the Cyst is in container11].
	
		The pulsing, withered source of the black slime quivers in the center of the sarcophagus: a repulsive cyst[end if].";
		now Container11 is open;
	otherwise:
		say "The sarcophagus is already open.";
			
Key11 is in DAN7.

The Cyst is in Container11. The description of The Cyst is "A pustule from the proboscis of one of the Lesser Gods, The Cyst is truly the most repulsive artifact contained in Cragne Manor. It constantly quivers and emits a sickly warmth." 

Understand "source" or "pustule" or "repulsive" or "artifact" as the Cyst.

Instead of taking the cyst for the first time:
	now the cyst is carried by the player;
	say "You place both hands on the cyst and gently tug it. It separates from the fleshy veins attaching it to the sarcophagus. Ichor spills out of the wounds for a moment before slowing to a drip and crusting over."

The mathbrush-slime is scenery in TUN3. The printed name of the mathbrush-slime is "black slime". Understand "black" or "slime" or "black slime" as the mathbrush-slime. 

The description of the mathbrush-slime is "The black slime oozes form the sarcophagus and onto the floor. It reeks.".

Understand the filthy property as describing a thing. Understand "black stain" or "stain" or "foul" or "fouled" as filthy.

The mathbrush-floor is scenery in TUN3. Understand "floor" or "crust" or "encrusted" or "puddle" or "puddles" as the mathbrush-floor. The printed name of the mathbrush-floor is "floor".

The description of the mathbrush-floor is "The floor is covered with layers of encrusted slime heaped around the sarcophagus. Moisture from the walls puddles here and there."

Instead of touching the mathbrush-floor:
	say "The slime sticks to your fingers for a moment before releasing.";
	
The mathbrush-walls are scenery in TUN3. Understand "heavy" or "stone" or "brick" or "bricks" or "seeping" or "wall" or "walls" as the mathbrush-walls. The printed name of the mathbrush-walls is "walls". The mathbrush-walls are plural-named.

The description of the mathbrush-walls is "These heavy stone brick walls are seeping with moisture."

Instead of touching the mathbrush-walls:
	say "It's wet."

The mathbrush-ceiling is scenery in TUN3. Understand "ceiling" or "roof" as the mathbrush-ceiling. The printed name of the mathbrush-ceiling is "ceiling".

The description of the mathbrush-ceiling is "You can't see the ceiling. It's impossible to tell if it's too high or if it's covered in blackness."

Instead of touching the mathbrush-ceiling:
	say "It's too far away.";
	
Instead of rubbing the mathbrush-ceiling:
	say "It's too far away.";
	
Instead of searching the mathbrush-ceiling:
	say "You can't even tell if it's there.";
	
The mathbrush-moisture is scenery in TUN3. Understand "moisture" or "water" or "puddle" or "puddles" as the mathbrush-moisture. The printed name of the mathbrush-moisture is "moisture".

The description of the mathbrush-moisture is "Water is seeping from the stone walls and puddling on the ground."

To mathbrush-kill:
	say "Your throat burns with fire but your eyes behold a glorious light. The room lifts in the air as your soul crumbles into dozens of smaller pieces. You become one with the countless others trapped in the slime of the Cyst.
	
	In a horrifying way, it feels good.";
	end the story saying "You are one.";

Instead of drinking the mathbrush-moisture:
	mathbrush-kill;

Instead of eating the mathbrush-slime:
	mathbrush-kill;

Instead of tasting the mathbrush-moisture:
	mathbrush-kill;
	
Instead of tasting the mathbrush-slime:
	mathbrush-kill;

Instead of touching the mathbrush-slime:
	say "It sticks to your fingers before pulling away."
	
The mathbrush-veins are in Container11. The mathbrush-veins are scenery. The printed name of the mathbrush-veins is "fleshy veins". Understand "fleshy" or "vein" or "veins" or "faintly" or "pulsing" or "flesh" as the mathbrush-veins.

The description of the mathbrush-veins is "Veins of flesh are pulsing faintly in the sarcophagus."

Instead of touching the mathbrush-veins:
	say "You touch the veins. They're warm and soft.";
	
Instead of eating the mathbrush-veins:
	mathbrush-kill;
	
Instead of tasting the mathbrush-veins:
	mathbrush-kill;	

Instead of eating the cyst:
	mathbrush-kill;

Instead of tasting the cyst:
	mathbrush-kill;

The mathbrush-air is scenery in TUN3. The printed name of the mathbrush-air is "air".  Understand "air" as mathbrush-air.

The description of the mathbrush-air is "This isn't what air is supposed to be like. It almost feels sinful to be immersed in it."

Instead of going nowhere when the player is in TUN3:
	say "You bump into a wall. It's wet.";
	
Rule for printing a parser error when the player is in TUN3:
	if the latest parser error is the didn't understand error: 
		say "I didn't understand that. The air must be confusing you.";
	otherwise if the latest parser error is the can't see any such thing error:
		say "You can't see that. Or can you? The smell is getting to you.";
	otherwise if the latest parser error is the only understood as far as error: 
		say "Only part of that made sense. The madness is taking hold, you know.";
	otherwise if the latest parser error is the didn't understand that number error: 
		say "Are you even sure that's a number? What's going on?";
	otherwise if the latest parser error is the said too little error: 
		say "You didn't finish your sentence. Are you okay?";
	otherwise if the latest parser error is the aren't holding that error: 
		say "Were you holding that before? You aren't now, you know. Be careful.";
	otherwise if the latest parser error is the can't use multiple objects error: 
		say "In what mad part of reality is that something you can do with multiple objects?";
	otherwise if the latest parser error is the can only use multiple objects error: 
		say "It takes more things than that to achieve your mad purposes.";
	otherwise if the latest parser error is the not sure what it refers to error: 
		say "I'm not even sure what that refers to. Are you?";
	otherwise if the latest parser error is the excepted something not included error: 
		say "You blink and your vision swims. Is the thing you excepted even included?";
	otherwise if the latest parser error is the can only do that to something animate error: 
		say "To treat that which is dead as that which is not--how amusing! How droll! You laugh until you dissolve into tears.";
	otherwise if the latest parser error is the not a verb I recognise error: 
		say "[one of]In the foul languages spoken by the dead in the tombs of the sea, such a verb might be found, but not in English. Your dreams must be spreading to reality.[or]We didn't understand the verb you used. Tell us more.[or]Please, that verb makes no sense. Stop before it's too late. For you, perhaps, it already is.[stopping]";
	otherwise if the latest parser error is the not something you need to refer to error: 
		say "You don't need to refer to that. Did you know that?";
	otherwise if the latest parser error is the can't see it at the moment error: 
		say "Your vision swims. The thing you're looking for is not there right now. Did you know that?";
	otherwise if the latest parser error is the didn't understand the way that finished error:
		say "I didn't understand the way that finished. Did you?";
	otherwise if the latest parser error is the not enough of those available error: 
		say "There's not enough of those available. I'm sorry. I really am.";
	otherwise if the latest parser error is the nothing to do error: 
		say "Nothing to do.";
	otherwise if the latest parser error is the I beg your pardon error: 
		say "You've chosen to do nothing. Not to speak. Not to move. Not to breathe. Not to think. Just to be. Is nothingness that attractive?";
	otherwise if the latest parser error is the noun did not make sense in that context error: 
		say "One of the first signs of madness is using nouns in the wrong context.";
	otherwise if the latest parser error is the comma can't begin error: 
		say "If you saw this error, you are extremely persistent or enjoy looking through code. You've won the 'Official Mathbrush Recognition Award.'";
	otherwise if the latest parser error is the can't see whom to talk to error:
		say "You can't see whom to talk to, but be assured that they can see you.";
	otherwise if the latest parser error is the can't talk to inanimate things error:
		say "You babble and cackle together for a time. Or do you? Perhaps you just share glances and look away. It's not alive, after all.";
	otherwise:
		say "I truly don't understand what you've written.";
	
Instead of sleeping when the player is in TUN3:
	say "You lay yourself down and sleep. When you wake, you find yourself encrusted. Raising yourself is easy, the dried slime flaking off to the ground. Have you done this before?";
	
Instead of waking up when the player is in TUN3:
	say "You rouse yourself from your dream. In your dream, you were in a dank, narrow tunnel, filled with foul slime. In your waking life, you are as well. Is there any difference?";
	
Instead of listening to TUN3:
	say "There is a constant drip.";
	
Instead of jumping when the player is in TUN3:
	say "You try to jump, but your feet break through the crust below you and into the underlying slime. You extract yourself."
	
Instead of examining the player when the player is in TUN3:
	say "The subject under observation is taciturn, reserved. The face is lost in the shadows. A glint in the eye--madness? Genius? Or a dim reflection from a glassy stare?";
	
Commentary of TUN3 is "If I were you, I'd try reclosing the crypt, typing a verb wrong, typing a noun wrong, jumping, waking up, and anything else you feel like.

There are no hidden puzzles. There is one death.

I specifically asked to have a puzzleless room that was like a sewer underground."
6 Likes

Playing Cragne through is one of those things I really want to do. I mean, I never even reached my own room. But that’s a reason I won’t yet be looking at these sources you and others are starting to post.

If I was going to do this – or maybe instead – what I’d do first is put my room online as a standalone game. I’d ask Ryan and Jenny, and I bet they’d be fine with it, but it’s not something I’ve felt like doing yet. In a sort of masochistic way, I like that my room is only available to people who are tackling the whole game. But on the other hand, I’d like more people to play it. Anyway, these thoughts are on the burner.

-Wade

3 Likes

That’s how I feel! I posted the source code but not a standalone-playable game file.

2 Likes

Hey, could I post this source code on my web site?

(See other thread: M2F2: Jason Love's "Cragne Manor" Source (Spoilers, Obviously) - #4 by zarf )

1 Like

Yeah, sounds great!