code:
:: Asylum Widgets [widget]

<<widget "asylumeffects">>
	<<effectstime>>
	<<if $hour lte 5>>
		<<set $asylumstate to "sleep">>
	<<elseif $hour lte 8>>
		<<set $asylumstate to "free">>
	<<elseif $hour is 9>>
		<<set $asylumstate to "exercise">>
	<<elseif $hour is 10>>
		<<set $asylumstate to "firsttreatment">>
	<<elseif $hour lte 14>>
		<<set $asylumstate to "free">>
	<<elseif $hour is 15>>
		<<set $asylumstate to "secondtreatment">>
	<<elseif $hour lte 19>>
		<<set $asylumstate to "free">>
	<<elseif $hour is 20>>
		<<set $asylumstate to "assessment">>
	<<elseif $hour is 21>>
		<<set $asylumstate to "free">>
	<<else>>
		<<set $asylumstate to "sleep">>
	<</if>>
	<<set $suspicion = Math.clamp($suspicion, 0, 100)>>
	<<set $asylumstatus = Math.clamp($asylumstatus, 0, 100)>>
<</widget>>

<<widget "asylumstats">>
	<<if $suspicion gte 80>>
		Security actively watches you. Even the nurses glance your way warily.
	<<elseif $suspicion gte 20>>
		You catch the occasional member of security watching you.
	<<else>>
		The staff ignore you.
	<</if>>

	<<if $asylumstatus gte 80>>
		The other patients smile when they see you.
	<<elseif $asylumstatus gte 20>>
		The other patients ignore you.
	<<else>>
		The other patients shun you.
	<</if>>

<</widget>>

<<widget "asylumtreatments">>
	<<if $rng gte 91>>
		<<if $o_long_and_beautiful gte 1 and $o_long_and_beautiful lte 7 and $rng % 2 and $malechance lt 100>>
			<<set $phase to 0>><<set $o_long_and_beautiful += 1>>
			<<npc Harper>><<person1>>
			You are led into a thin room. Curtains line one side.

			"Hello," Doctor Harper says. "I'm glad you could make it. Please stand just there."
			<<He>> pushes a button on the wall by the door and the curtain pulls back, revealing the other half of the room. A patient lies on the floor.

			The long, matted hair covering most of her face hides any visible reaction.

			<<person1>>"This treatment isn't for you," the doctor says. "It's for your fellow patient. I just need an assistant."
			<<He>> gestures at a button on a table beside you. "You'll need to press that button when I say. I'll be busy helping this patient. Press it now."

			<<link [[Press|Asylum Button Long Hair Press]]>><</link>>

			<<link [[Refuse|Asylum Button Long Hair Refuse]]>><<suspicion 1>><<def 1>><</link>><<gsuspicion>>

		<<else>>
			<<set $phase to 0>>
			<<npc Harper>><<person1>><<generate2>>
			You are led into a thin room. Shutters line one side. "Hello," Doctor Harper says. "I'm glad you could make it. Please take a seat." <<He>> pushes a button on the counter beside <<him>>. The shutters open, revealing a glass window. Another patient sits in the room beyond. <<person2>><<He>> looks nervous, but doesn't react to the reveal.

			<<person1>>"This treatment isn't for you," the doctor says. "It's for your fellow patient. I just need an assistant." <<He>> gestures at a button in front of you. "You'll need to press this button when I say. I'll be busy taking notes. Press it now."

			<<link [[Press|Asylum Button Press]]>><</link>>

			<<link [[Refuse|Asylum Button Refuse]]>><<suspicion 1>><<def 1>><</link>><<gsuspicion>>

		<</if>>
	<<elseif $rng gte 81>>
		<<npc Harper>><<person1>>You are led to Doctor Harper's office. <<He>> waits for you behind <<his>> desk. "Please take a seat," <<he>> says. There are no other chairs.

		<<link [[Sit on desk|Asylum Sit Desk]]>><</link>>

		<<link [[Sit on lap|Asylum Sit Lap]]>><</link>><<promiscuous1>><<lsuspicion>><<lawareness -1>>

		<<link [[Stay stood|Asylum Sit Stand]]>><<suspicion 1>><</link>><<gsuspicion>>

	<<elseif $rng gte 71>>
		<<npc Harper>><<person1>><<generate2>>You are led into a room with a large window facing the grounds, and the forest beyond. Doctor Harper waits for you, stood beside a <<person2>><<person>>. Another patient. Several orderlies wait by the wall.

		"Thank you both for coming," the doctor says. "Today I want to talk about modesty. It shouldn't feel bad to be exposed. It should feel good. I want one of you to strip." The <<person>> looks horrified at the thought. "And stand in front of the window there."

		You can see many patients exercising outside, as well as staff watching over them. The <<persons>> horror becomes panic. "P-please," <<he>> says. "Don't make me."

		<<person1>>Harper looks at you. "You get to decide which of you strips," <<he>> says. The <<person2>><<person>> looks at you, near tears.

		<<if $exhibitionism gte 75>>
			<<link [[Strip and flaunt|Asylum You Flaunt]]>><<suspicion -5>><<asylumstatus 5>><<awareness -10>><<fameexhibitionism 10>><</link>><<exhibitionist5>><<llawareness>><<llsuspicion>><<ggcool>>

		<<else>>
			<<link [[Strip reluctantly|Asylum You Strip]]>><<suspicion -5>><<asylumstatus 5>><<awareness -10>><<stress 3>><<fameexhibitionism 10>><</link>><<llawareness>><<llsuspicion>><<ggcool>><<gstress>>

		<</if>>
		<<link [[Make them strip|Asylum They Strip]]>><<suspicion 5>><<asylumstatus -5>><</link>><<ggsuspicion>><<llcool>>

	<<elseif $rng gte 61>>
		<<npc Harper>><<person1>>
		You are led into Harper's office. <<He>> waits for you inside.<<endevent>><<generate1>> There's a <<person1>><<person>> sat opposite. Another patient. "Thank you for joining us," The doctor says. "Please, take a seat."

		You sit beside the <<person>>. Harper picks up a pen on the desk. "I want both of you to focus on this pen, and breathe deeply. There's nothing in the universe except this pen, my voice, and your own breath."

		<<pass 5>>
		This continues for several minutes. Harper somehow picks up on whenever one of your minds wanders, and brings you back to focus. You feel something shift in your consciousness as you enter a trance.

		"Good," The doctor says, looking at you. "I want you to get on your knees and use your mouth on <<his>> genitals. <<He>> will enjoy it. Is that clear?"

		"Yes," the <<person>> says. "I will enjoy it."

		<<link [[Obey|Asylum Hypnosis Oral]]>><<hypnotised 1>><<set $sexstart to 1>><<npcincr Harper dom 5>><<control 25>><<stress -12>><<awareness -10>><<suspicion -5>><</link>><<ggcontrol>><<llsuspicion>><<llawareness>><<lstress>>

		<<link [[Resist|Asylum Hypnosis Resist]]>><<stress 6>><<suspicion 5>><<npcincr Harper dom -5>><</link>><<ggsuspicion>><<ggstress>>

	<<elseif $rng gte 41>>
		<<npc Harper>><<person1>>
		You are led into Harper's office. <<He>> waits for you inside, sat at <<his>> desk. "Thank you for coming," <<he>> says. "Please, take a seat."

		Once sat, Harper picks up a pen on <<his>> desk. "I want you to focus on this pen, and breathe deeply. There's nothing in the universe except this pen, my voice, and your own breath."

		<<pass 5>>
		This continues for several minutes. Harper somehow picks up on whenever one of your minds starts to wander, and brings you back to focus. You feel something shift in your consciousness as you enter a trance.

		"Good," The doctor says. "I want you to take off your clothes. We're going for a walk."

		<<link [[Obey|Asylum Hypnosis Exhibitionism]]>><<hypnotised 1>><<npcincr Harper dom 5>><<control 25>><<stress -12>><<awareness -10>><<suspicion -5>><</link>><<ggcontrol>><<llsuspicion>><<llawareness>><<lstress>>

		<<link [[Resist|Asylum Hypnosis Resist]]>><<stress 6>><<suspicion 5>><<npcincr Harper dom -5>><</link>><<ggsuspicion>><<ggstress>>

	<<elseif $rng gte 26>>
		<<npc Harper>><<person1>>
		You are led into a windowless room. Doctor Harper waits beside a large machine. "Thank you for coming," <<he>> says. <<He>> presses a button. A compartment opens, large enough for you to fit. "Please lie down inside."

		<<link [[Get in|Asylum Machine]]>><<awareness -10>><<suspicion -5>><</link>><<llsuspicion>><<llawareness>>

		<<link [[Refuse|Asylum Machine Refuse]]>><<suspicion 5>><</link>><<athleticsdifficulty 1 1000>><<ggsuspicion>><<ggstress>>

	<<elseif $rng gte 11>>
		<<npc Harper>><<person1>>
		You are led into Harper's office. <<He>> waits for you inside, sat at <<his>> desk. "Thank you for coming," <<he>> says. "Please, take a seat."

		Once sat, Harper picks up a pen on <<his>> desk. "I want you to focus on this pen, and breathe deeply. There's nothing in the universe except this pen, my voice, and your own breath."

		<<pass 5>>
		<<endevent>>
		This continues for several minutes. Harper somehow picks up on whenever one of your minds starts to wander, and brings you back to focus. You feel something shift in your consciousness as you enter a trance.

		<<beastNEWinit 1 dog>>
		<<if $monster is 1 or $bestialitydisable is "f">>
			<<if $monster is 1>>
				"Good," The doctor says. "Bring <<bhim>> in." A group of orderlies enter. One holds a <<beasttype>> on a leash, who appears to be panting heavily. <<bHis>> nude body is on full display. <<bHe>> strains to reach you. Harper turns to you. "We found <<bhim>> up near those farms," <<nnpc_he "Harper">> says. "<<bHe>>'s been misbehaving, and could use some "personal" attention. From a bitch in heat, more specifically. You can't wait to be bred." You feel an urge to bark.

			<<else>>
				"Good," The doctor says. "Bring it in." A group of orderlies enter. One holds a dog on a leash. It strains to reach you. Harper turns to you. "You're a bitch in heat. You can't wait to be bred." You feel an urge to bark.

			<</if>>

			<<link [[Present yourself|Asylum Hypnosis Dog]]>><<hypnotised 1>><<set $sexstart to 1>><<npcincr Harper dom 5>><<control 25>><<stress -12>><<awareness -10>><<suspicion -5>><</link>><<ggcontrol>><<llsuspicion>><<llawareness>><<lstress>>

			<<link [[Resist|Asylum Hypnosis Dog Resist]]>><<stress 6>><<suspicion 5>><<npcincr Harper dom -5>><</link>><<ggsuspicion>><<ggstress>>

		<<else>>
			<<endevent>>
			<<npc Harper>><<person1>>
			"Good," The doctor says. "I want you to take off your clothes. We're going for a walk."

			<<link [[Obey|Asylum Hypnosis Exhibitionism]]>><<hypnotised 1>><<npcincr Harper dom 5>><<control 25>><<stress -12>><<awareness -10>><<suspicion -5>><</link>><<ggcontrol>><<llsuspicion>><<llawareness>><<lstress>>

			<<link [[Resist|Asylum Hypnosis Resist]]>><<stress 6>><<suspicion 5>><<npcincr Harper dom -5>><</link>><<ggsuspicion>><<ggstress>>

		<</if>>
	<<else>>
		<<npc Harper>><<person1>><<generate2>><<generate3>>
		You enter Doctor Harper's office. <<He>> sits behind <<his>> desk. A <<person2>><<person>> and <<person3>><<person>> sit in front of <<him>>, both in white coats. They turn to regard you.

		"Thank you for coming," Harper says. "I have something special for you today. A new drug. My colleagues here would like to observe its effects. Here." <<person1>><<He>> stands and removes a sheet from a nearby chair. There are straps on the arms and legs. "Please sit."
		<<person3>>

		<<link [[Sit|Asylum Pill Sit]]>><<awareness -10>><<suspicion -5>><<set $hallucinogen += 180>><</link>><<llsuspicion>><<llawareness>>

		<<link [[Refuse|Asylum Pill Refuse]]>><<suspicion 5>><</link>><<ggsuspicion>><<ggstress>>

	<</if>>
<</widget>>

<<widget "asylumassessment">>
You enter the doctor's office.<<npc Harper>><<person1>>
<<if $innocencestate is 1>>
<<npcincr Harper love 5>><<npcincr Harper dom 5>><<set $asyluminnocence to 1>>

<<He>> puts down <<his>> clipboard and smiles. "Your treatment is finished," <<he>> says. "You're ready to be a functioning member of society. I'll have special pills sent to your home."
<<set $asylumpills to 1>><<set $asylummedicated to 0>>
<<He>> rises to <<his>> feet and pulls the curtains at the window closed. "Stand up."

Once stood, <<he>> pushes you back over the desk.
<<if $NPCList[0].penis isnot "none">>
<<He>> steps between your legs and leans forward,
<<else>>
<<He>> climbs atop and straddles you,
<</if>>

groping at your clothes with shaking fingers, trying to take them off. The professional air <<he>> carried is gone. <<He>> laughs, giggles really. "I-I should be the first to experience my handiwork. It's only fair."

<<link [[Next|Asylum Harper Sex]]>><<set $molestationstart to 1>><</link>>

<<elseif $trauma lte $traumamax / 10>>
<<set $asylumtrauma to 1>>

<<He>> puts down <<his>> clipboard and frowns. "Your treatment isn't finished," <<he>> says. "But you seem to have recovered regardless. I can't justify keeping you here." <<He>> rises to <<his>> feet and pulls the curtains at the window closed.

"Now that you're better," <<he>> steps around the desk. "This might be the last time we see each other." <<He>> gropes your clothing. The professional air <<he>> carried is gone. <<He>> laughs as <<he>> tries to kiss you.

<<link [[Let it happen|Asylum Harper Sex]]>><<npcincr Harper love 5>><<set $sexstart to 1>><</link>><<promiscuous1>>

<<link [[Shove away|Asylum Harper Shove]]>><<npcincr Harper love -1>><</link>>

<<elseif $asylumassessmentprogress lte 0>>
<<set $asylumassessmentprogress += 1>>
Harper stares at you across the desk. "Let's talk about your exposure fetish," <<he>> says. "You've been displaying your body in inappropriate ways, then claiming others stripped you. You're ashamed of your feelings."

<<if $asylumdistracted is 1>>
<<link [[Attack|Asylum Fight]]>><<suspicion 15>><<trauma -6>><<stress -6>><<set $fightstart to 1>><</link>><<gggsuspicion>><<gggsuspicion>><<ltrauma>><<lstress>>

<<else>>
<<link [[Attack|Asylum Punish]]>><<suspicion 15>><<trauma -6>><<stress -6>><</link>><<gggsuspicion>><<ltrauma>><<lstress>>

<</if>>
<<if $asylumkeycard isnot 1 and $leftarm isnot "bound" and $rightarm isnot "bound">>
<<set $skulduggerydifficulty to 900 + (20 * $suspicion)>>
<<link [[Steal keycard|Asylum Keycard]]>><</link>><<skulduggerydifficulty>> This will be easier with low suspicion.

<</if>>
<<link [[Insist that isn't true|Asylum Exhibit Meek]]>><<awareness -1>><<stress 3>><</link>><<lawareness>><<gstress>>

<<link [[Say you aren't sure|Asylum Exhibit Sub]]>><<trauma -6>><<suspicion -5>><<awareness -10>><</link>><<llsuspicion>><<llawareness>><<ltrauma>>

<<elseif $asylumassessmentprogress lte 1 and $tentaclerapestat gte 1>>
<<set $asylumassessmentprogress += 1>>
Harper stares at you across the desk. "In your sleep you talk about being attacked by monsters with tentacles," <<he>> says. "Creatures like that don't exist. If someone claimed to have been molested by a creature no one else can see, would you believe them?"

<<if $asylumdistracted is 1>>
<<link [[Attack|Asylum Fight]]>><<suspicion 15>><<trauma -6>><<stress -6>><<set $fightstart to 1>><</link>><<gggsuspicion>><<gggsuspicion>><<ltrauma>><<lstress>>

<<else>>
<<link [[Attack|Asylum Punish]]>><<suspicion 15>><<trauma -6>><<stress -6>><</link>><<gggsuspicion>><<ltrauma>><<lstress>>

<</if>>
<<if $asylumkeycard isnot 1 and $leftarm isnot "bound" and $rightarm isnot "bound">>
<<set $skulduggerydifficulty to 900 + (20 * $suspicion)>>
<<link [[Steal keycard|Asylum Keycard]]>><</link>><<skulduggerydifficulty>> This will be easier with low suspicion.

<</if>>
<<link [[Insist they are real|Asylum Tentacles Meek]]>><<awareness +1>><<stress 3>><</link>><<gawareness>><<gstress>>

<<link [[Say you aren't sure|Asylum Tentacles Sub]]>><<trauma -6>><<suspicion -5>><<awareness -10>><</link>><<llsuspicion>><<llawareness>><<ltrauma>>

<<elseif $asylumassessmentprogress lte 2 and $beastrapestat gte 1>>
<<set $asylumassessmentprogress += 1>>

	Harper stares at you across the desk.
	<<if $bestialitydisable is "f">>
		"In your sleep you talk about being attacked by animals," <<he>> says. "Sexually attacked. Animals don't behave like that. You've been abusing innocent creatures, haven't you?"
	<<else>>
		"In your sleep you talk about being attacked by monster-people," <<he>> says. "Sexually attacked. These types of beings do not exist. You made yourself believe they possess human-like features. In reality, you've been abusing innocent animals for your own pleasure. Am I wrong?"
	<</if>>

	<<if $asylumdistracted is 1>>
		<<link [[Attack|Asylum Fight]]>><<suspicion 15>><<trauma -6>><<stress -6>><<set $fightstart to 1>><</link>><<gggsuspicion>><<gggsuspicion>><<ltrauma>><<lstress>>

	<<else>>
		<<link [[Attack|Asylum Punish]]>><<suspicion 15>><<trauma -6>><<stress -6>><</link>><<gggsuspicion>><<ltrauma>><<lstress>>

	<</if>>
	<<if $asylumkeycard isnot 1 and $leftarm isnot "bound" and $rightarm isnot "bound">>
		<<set $skulduggerydifficulty to 900 + (20 * $suspicion)>>
		<<link [[Steal keycard|Asylum Keycard]]>><</link>><<skulduggerydifficulty>> This will be easier with low suspicion.

	<</if>>
	<<link [[Insist that isn't true|Asylum Beast Meek]]>><<awareness -1>><<stress 3>><</link>><<lawareness>><<gstress>>

	<<link [[Say you aren't sure|Asylum Beast Sub]]>><<trauma -6>><<suspicion -5>><<awareness -10>><</link>><<llsuspicion>><<llawareness>><<ltrauma>>

<<elseif $asylumassessmentprogress lte 3>>
	<<set $asylumassessmentprogress += 1>>
	Harper stares at you across the desk. "There are marks on your body," <<he>> says. "You did this to yourself, didn't you."

	<<if $asylumdistracted is 1>>
		<<link [[Attack|Asylum Fight]]>><<suspicion 15>><<trauma -6>><<stress -6>><<set $fightstart to 1>><</link>><<gggsuspicion>><<gggsuspicion>><<ltrauma>><<lstress>>

	<<else>>
		<<link [[Attack|Asylum Punish]]>><<suspicion 15>><<trauma -6>><<stress -6>><</link>><<gggsuspicion>><<ltrauma>><<lstress>>

	<</if>>
	<<if $asylumkeycard isnot 1 and $leftarm isnot "bound" and $rightarm isnot "bound">>
		<<set $skulduggerydifficulty to 900 + (20 * $suspicion)>>
		<<link [[Steal keycard|Asylum Keycard]]>><</link>><<skulduggerydifficulty>> This will be easier with low suspicion.

	<</if>>
	<<link [[Insist that isn't true|Asylum Hurt Meek]]>><<awareness -1>><<stress 3>><</link>><<lawareness>><<gstress>>

	<<link [[Say you aren't sure|Asylum Hurt Sub]]>><<trauma -6>><<suspicion -5>><<awareness -10>><</link>><<llsuspicion>><<llawareness>><<ltrauma>>

<<else>>
<<set $asylumassessmentprogress to 0>>
Harper stares at you across the desk. "In your sleep you talk about being raped and molested. But that isn't what happens, is it?" <<he>> says. "You approach and seduce people willingly. You call it rape because you're ashamed."

<<if $asylumdistracted is 1>>
<<link [[Attack|Asylum Fight]]>><<suspicion 15>><<trauma -6>><<stress -6>><<set $fightstart to 1>><</link>><<gggsuspicion>><<gggsuspicion>><<ltrauma>><<lstress>>

<<else>>
<<link [[Attack|Asylum Punish]]>><<suspicion 15>><<trauma -6>><<stress -6>><</link>><<gggsuspicion>><<ltrauma>><<lstress>>

<</if>>
<<if $asylumkeycard isnot 1 and $leftarm isnot "bound" and $rightarm isnot "bound">>
<<set $skulduggerydifficulty to 900 + (20 * $suspicion)>>
<<link [[Steal keycard|Asylum Keycard]]>><</link>><<skulduggerydifficulty>>This will be easier with low suspicion.

<</if>>
<<link [[Insist that isn't true|Asylum Rape Meek]]>><<awareness -1>><<stress 3>><</link>><<lawareness>><<gstress>>

<<link [[Say you aren't sure|Asylum Rape Sub]]>><<trauma -6>><<suspicion -5>><<awareness -10>><</link>><<llsuspicion>><<llawareness>><<ltrauma>>

<</if>>

<</widget>>

<<widget "asylumend">>
	<<set $asylum to 0>>
<</widget>>

<<widget "asylumpunish">>
<<endevent>><<npc Harper>><<person1>><<set $asylumbound to 2>>

<<if $leftarm is "bound" and $rightarm is "bound">>
	"Take <<phim>> to the room," Harper says. "Make sure <<pher>> arms are bound tight."

	<<if $leftarm is "bound" and $rightarm is "bound">>
		They push you to an empty wing of the asylum, through one of the doors marked "Staff Only."
	<<else>>
		They force you into a jacket and push you to an empty wing of the asylum.
		<<bind>><<upperwear 35>>
	<</if>>
	Most lights here don't work, and those that do flicker to a strange rhythm.

	You come to a tall metal door. They open it, revealing a pitch black room beyond. They shove you in, and slam the door behind you.

	There's just enough space to sit. You wait in total silence.

	<<link [[Wait|Asylum Room]]>><<pass 60>><</link>>

<<else>>
	<<bind>><<upperwear 35>>
	"Bind <<pher>> arms," Harper says. "Tight."

	They force your arms in front of you, and wrap them up tight. The doctor smiles. "
	<<if $asylumstate is "sleep">>
		Take <<phim>> to <<pher>> room. <<pShe>> needs <<pher>> sleep."

		Flanked by orderlies, you are led to your cell. The door locks with a click.

		<<endevent>>
		<<link [[Next|Asylum Cell]]>><</link>>

	<<else>>
		Show <<pher>> around. Let the others see."

		You are led through the occupied part of the asylum. Most patients ignore you, but some jeer. They leave you near your room.
		<<gstress>><<stress 3>>

		<<endevent>>
		<<link [[Next|Asylum]]>><</link>>

	<</if>>
<</if>>
<</widget>>

<<widget "asylumpunish2">>
<<endevent>><<npc Harper>><<person1>><<set $asylumbound to 2>>
"Take <<phim>> to the room," Harper says. "Make sure <<pher>> arms are bound tight."

<<if $leftarm is "bound" and $rightarm is "bound">>
	They push you to an empty wing of the asylum, through one of the doors marked "Staff Only."
<<else>>
	They force you into a jacket and push you to an empty wing of the asylum.
	<<bind>><<upperwear 35>>
<</if>>
Most of the lights here don't work, and those that do flicker to a strange rhythm.

You come to a tall metal door. They open it, revealing a pitch black room beyond. They shove you in, and slam the door behind you.

The room is tiny. There's just enough space to sit. You wait in total silence.

<<link [[Wait|Asylum Room]]>><<pass 60>><</link>>

<</widget>>

<<widget "asylumoptions">>
<<if $leftarm is "bound" or $rightarm is "bound" and $asylumbound lte 0>>
	<<He>> looks at your bindings. "I think you've earned a release," <<he>> says as <<he>> crouches and unties them, before removing it completely.<<unbind>><<exposure>> <<He>> covers you with a gown.
	<<unbind>><<upperwear 87>><<exposure>>

<</if>>
<<if $exposed gte 1>>
	<<He>> steps back to regard you. <<covered>> "You can't see the doctor dressed like that," <<he>> says. <<He>> covers you with a gown.
	<<unbind>><<upperwear 87>><<exposure>>

<</if>>
<</widget>>

<<widget "asylumevents">>
<<set $danger to random(1, 10000)>>
<<if $danger gte (9900 - $allure)>>
	<<if $rng gte 91>>
		<<generate1>><<person1>>
		"Excuse me," says a voice to your side. It's a <<person>> wearing a patient's gown. "Doctor Harper gave me a task. I need to," <<he>> looks away. "I need to expose myself to a dozen people before my next assessment. My b-body, I mean. C-can I show you?" <<He>> doesn't look happy.

		<<link [[Accept|Asylum Exposure Accept]]>><<arousal 600>><</link>><<garousal>>

		<<link [[Accept but keep your eyes shut|Asylum Exposure Shut]]>><<famegood 1>><</link>>

		<<link [[Accept and pretend to keep your eyes shut|Asylum Exposure Peek]]>><<arousal 600>><<famegood 1>><</link>><<garousal>>

		<<link [[Refuse|Asylum Exposure Refuse]]>><</link>>

	<<elseif $rng gte 81 and (random(1,100) lte $suspicion)>>
		<<generate1>><<generate2>><<person1>>
		A <<person>> dressed as an orderly approaches you.
		"Hello. The doctor has extra time today and wants you in for an extra treatment," <<he>> says. "Come with me please."

		A <<person2>><<person>> stands behind you.

		<<link [[Go with them|Asylum Fake Treatment Accept]]>><</link>>

		<<link [[Refuse to go|Asylum Fake Treatment Refuse]]>><</link>><<physiquedifficulty 1 $physiquemax>>

	<<elseif $rng gte 61>>
		<<generate1>><<person1>>You catch one of the other patients, a <<person>>, looking at you. <<He>> smiles.

		<<link [[Flirt (0:02)|Asylum Flirt]]>><<asylumstatus 1>><<pass 2>><</link>><<promiscuous1>><<gcool>>

		<<link [[Ignore|Asylum]]>><<endevent>><</link>>

	<<elseif $rng gte 21>>
		<<generate1>><<generatev2>><<person1>>One of the patients, a <<person>>, gropes one of the nurses, a <<person2>><<person>>. The nurse doesn't resist. <<He>> looks resigned.

		<<link [[Intervene|Asylum Intervene]]>><<suspicion -5>><<asylumstatus -5>><</link>><<llsuspicion>><<llcool>>

		<<link [[Ignore|Asylum]]>><<endevent>><</link>>

	<<else>>
		<<generate1>><<person1>><<generate2>>A <<person>>, a patient, runs past you and hides from view, just as a <<person2>><<person>> rounds the corner. <<Hes>> a nurse. <<He>> looks around, then at you. "Have you seen a <<person1>><<person>> by chance?"

		<<link [[Truth|Asylum Truth]]>><<suspicion -5>><<asylumstatus -5>><</link>><<llsuspicion>><<llcool>>

		<<link [[Lie|Asylum Lie]]>><<suspicion 5>><<asylumstatus 5>><</link>><<ggsuspicion>><<ggcool>>

	<</if>>
<<else>>
	<<link [[Next|Asylum]]>><</link>>

<</if>>

<</widget>>

<<widget "passoutasylum">>

/*ToDo: Pregnancy, remove $pregnancyTesting to properly enable*/
<<if $sexStats.vagina.pregnancy.waterBreaking is true and $pregnancyTesting>>
	<<pregnancyWatersBrokenPassout "asylum">>
<<else>>
	<<passout>>
	[[Everything fades to black...->Passout Asylum]]
<</if>>
<</widget>>

<<widget "asylumescape">>
<<set $asylumescaped to 1>>
<<if $location is "tentworld">>
	<<set $asylumtentacleescape to 1>>
<</if>>

<<if $NPCName[$NPCNameList.indexOf("Robin")].init is 1>>
	<<set $robinReunionScene to "asylum">>
<</if>>
<</widget>>


code:
:: Eden Jacket
<<set $outside to 0>><<set $location to "cabin">><<effects>>

Snow falls around the cabin, painting the scenery a pure white. A distinctive winter chill settles in you, causing you to shiver. When you find Eden, <<he>>'s as busy as always.
You call <<him>> over and hand <<him>> the hunting jacket. "Merry Christmas," you say.

Eden looks taken aback. "Is it Christmas already?" <<he>> asks. Taking the hunting jacket, <<he>> turns it over and inspects it, then goes to the cabin mirror and tries it on. Looks like you bought the right size.

"Thanks," <<he>> says. "I wasn't expecting anything."

<<if $submissive gte 1150>>
"Well, y-you did say you didn't know it was Christmas today," you say.
<<elseif $submissive lte 850>>
"Makes sense, since you didn't know it was Christmas and all," you say.
<<else>>
"Well, you said didn't realise it was Christmas," you say.
<</if>>

Eden shoots you a look, but can't argue with your point. "I didn't prepare anything for you," <<he>> says.
You're about to tell <<him>> that <<he>> didn't need to do anything, but <<he>> stops you. "Hang on."

<<if $hour lte 17>>
	"I've got an idea. Be here at six for dinner tonight. I'll have something ready by then."

	<<link [[Next|Eden Cabin]]>><<set $edenmeal to 1>><<endevent>><</link>>
<<else>>
	"I've got an idea." <<He>> walks to the oven.

	<<link [[Next|Eden Christmas Meal]]>><<endevent>><</link>>
<</if>>

:: Eden Christmas Meal
<<effects>>
<<npc Eden>><<person1>>Eden busies <<him>>self with gathering ingredients, preparing something. You roam around the cabin, trying to peek over <<his>> shoulder or at least help <<him>> out. Your efforts are for naught though, as <<he>> insists that you let <<him>> handle everything tonight. As <<he>> starts cooking, a mouth-watering scent fills the cabin, adding to the anticipation of the moment.

<<He>> calls you to the table after a long wait. A beautiful meal for two is laid out. It looks as good as it smells. You look to Eden and <<he>> seems a bit worn out, but proud of <<him>>self. You think it's the most effort Eden's ever put into cooking before.

<<link [[Next|Eden Christmas Meal 2]]>><<pass 20>><</link>>

:: Eden Christmas Meal 2
<<effects>>

You and Eden take a seat, and you try a bite of the food. It's delicious and bursting with flavour. You're about to take another bite, but stop when you notice that Eden isn't eating. In fact, <<he>> looks tense as <<he>> glances between you and the food.

It's not usual for <<him>> to be nervous. In an attempt to reassure <<him>>, you smile and compliment <<his>> work. <<He>> looks relieved by your words, and starts eating. <<He>> still seems doubtful.

You chat with Eden over the meal, attempting to lighten the mood. <<He>>'s as quiet as always, but seems more attentive than usual today. Halfway through, <<he>> looks up, as if just remembering something. Going to a nearby cabinet, <<he>> pulls out a fancy looking bottle of bourbon. You wonder how you've never seen it in the cabin before.

<<He>> goes back to the table and prepares two glasses. "Want some?" <<he>> asks.

<<link [[Accept|Eden Christmas Meal 3]]>><<set $phase to 1>><</link>>

<<link [[Decline|Eden Christmas Meal 3]]>><<set $phase to 2>><</link>>

:: Eden Christmas Meal 3
<<effects>>

<<if $phase is 1>>

	You accept, and <<he>> pours a glass for you. The smooth taste of the drink compliments your meal perfectly.

	<<alcohol 120>>

<<elseif $phase is 2>>

	You decline, and <<he>> shrugs. "More for me," <<he>> says, as <<he>> fills <<his>> glass.

<</if>>

After you're done, <<he>> clears the table and invites you over to the fireplace. In the frosty cold of the winter season, the flames seem twice as warm.
<<if $phase is 1>>
	Or maybe it's the alcohol causing the heat.
<</if>>
You turn to Eden, and <<he>> smiles at you, trailing <<his>> hand down your side. <<He>> rests your chin on <<his>> fingers, and moves <<his>> face closer to yours.

<<link [[Kiss Eden|Eden Christmas Sex]]>><<npcincr Eden love 1>><<npcincr Eden dom 1>><<set $sexstart to 1>><</link>>

<<link [[Turn away|Eden Christmas Turn]]>><</link>>

:: Eden Christmas Sex
<<if $sexstart is 1>>
<<set $sexstart to 0>>
<<consensual>>
<<set $consensual to 1>>
<<neutral 1>>

<<maninit>>
<<set $enemytrust += 100>><<set $enemyhealth to 600>><<set $enemyhealthmax to 600>>
<<promiscuity1>>

<<elseif $molestationstart is 1>>
<<set $molestationstart to 0>>
<<controlloss>>
<<violence 1>>
<<neutral 1>>
<<molested>>

<<maninit>><<set $enemyhealth to 600>><<set $enemyhealthmax to 600>><<set $enemyanger += 50>>

<</if>>

<<effects>>
<<effectsman>><<man>>

<<stateman>>

<<actionsman>>

<<if $finish is 1>>
	<<link [[Next|Eden Christmas Sex Finish]]>><</link>><<nexttext>>
<<elseif $enemyhealth lte 0>>
	<<link [[Next|Eden Christmas Sex Finish]]>><</link>><<nexttext>>
<<elseif $enemyarousal gte $enemyarousalmax>>
	<<link [[Next|Eden Christmas Sex Finish]]>><</link>><<nexttext>>
<<else>>
	<<link [[Next|Eden Christmas Sex]]>><</link>><<nexttext>>
<</if>>

:: Eden Christmas Turn
<<effects>>

You turn your face away from <<him>>. <<He>> looks surprised for a moment, but doesn't push it and goes back to holding you.

<<link [[Next|Eden Christmas Meal 4]]>><</link>>

:: Eden Christmas Sex Finish
<<set $outside to 0>><<set $location to "cabin">><<effects>>

<<if $enemyarousal gte $enemyarousalmax>>
<<ejaculation>><<npcincr Eden lust -20>>

Eden embraces you and pulls you into <<his>> chest.

<<clotheson>>
<<endcombat>>

<<elseif $enemyhealth lte 0>>

"Really? Today, of all days?" <<he>> asks, exasperated. <<He>> winces and holds <<his>> side. "I need to get something for this."

<<He>> leaves you by the fireplace.

<<clotheson>>
<<endcombat>>
<<elseif $finish is 1>>

"Okay," <<he>> says. <<He>> doesn't push it and goes back to holding you.

<<clotheson>>
<<endcombat>>
<</if>>

<<link [[Next|Eden Christmas Meal 4]]>><</link>>

:: Eden Christmas Meal 4
<<effects>>
<<npc Eden>><<person1>>
The two of you bask in the peaceful stillness of the night. In the glow of the flames, Eden looks almost ethereal. You look at <<him>>, entranced, until <<he>> breaks the silence. "I'd always spend my Christmas alone," <<he>> says, "but I'm glad you're here."
You smile in response, and <<he>> gently weaves <<his>> hand through your hair, returning your gaze with <<his>> own.

"You're the best thing that's ever happened to me," <<he>> whispers, as <<he>> kisses your forehead. Snow continues to fall around the cabin, but you no longer feel the biting chill. Instead, the warmth of Eden's love surrounds you as you lay pressed against <<his>> chest.

<<link [[Next|Eden Cabin]]>><<endevent>><</link>>

repo_name: Area/degrees

license: mit