<p>Arthur's room is as cramped and carelessly kept as the rest of the residence.</p>\
<<say $mcname "media/mc/mc.jpg" "thought">>He really does live like this on purpose, doesn't he?<</say>>\
<img class="scene-image" src="media/arthursroom/room.jpg">
[[Talk to Arthur]]
[[Watch TV]]
[[Hall->Slums Home]]<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Yeah? What is it?<</say>>
<<nobr>>
[[Chat->Arthur Chat]]<br>
<<if setup.canAccessArthurTease()>><<link "Tease" "Arthur Tease">><<run setup.adjustCorruption(-1)>><</link>><br><</if>>
<<if setup.canAccessArthurSex()>>[[Check if in mood for something...->Arthur Sex]]<br><</if>>
[[End conversation->Arthur's room]]
<</nobr>><<nobr>>
<<switch random(1, 10)>>
<<case 1>>
<<say $mcname "media/mc/mc.jpg" "jane">>Arthur, the tap made a banging noise again. Is that dangerous?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Only dangerous if it stops banging. Means the pipes finally gave up.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Oh. So the noise means they're still working?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Close enough. Put a bucket under it if it starts dripping.<</say>>
<<case 2>>
<<say $mcname "media/mc/mc.jpg" "jane">>Do you know where I can buy groceries without spending too much?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Market under the east rail. Go near closing time and haggle.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>What if they get upset with me?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>They'll act upset. That's part of haggling. Don't apologize and pay full price.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Right. No apologizing. I can probably manage that.<</say>>
<<case 3>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>You still wandering around after dark?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Sometimes. Most people seem friendly enough when I smile at them.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>That's because they think you're selling something—or that they can sell something to you. Keep to the lit streets.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Okay. I'll be more careful if you think I should.<</say>>
<<case 4>>
<<say $mcname "media/mc/mc.jpg" "jane">>Have you always lived in the Slums?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Long enough to remember when this building had working heat on every floor.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Really? That must have been nice.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>It lasted three weeks. Best winter of my life.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Maybe somebody will fix it properly one day.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Sure, kid. And maybe the Lord-Governor will come down here and fix it himself.<</say>>
<<case 5>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Don't forget what you still owe on the rent.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I haven't forgotten. I promise I'll find a way to pay you.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Promises don't keep the lights on.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I know. Thank you for giving me time anyway.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Don't make me regret it.<</say>>
<<case 6>>
<<say $mcname "media/mc/mc.jpg" "jane">>Can you see the spaceport lights from the roof?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>On a clear night. Mostly you see smog pretending to be clouds.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I'd still like to look sometime.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Take a jacket and don't lean on the railing. It's older than you are.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I won't. Thanks for warning me.<</say>>
<<case 7>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Something smelled almost edible in the kitchen earlier.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I made stew. There is some left if you want it.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>You offering because you're nice, or because it tastes terrible?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Because I'm nice. I think it tastes good too.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Fine. Leave a bowl out. I'll risk it.<</say>>
<<case 8>>
<<say $mcname "media/mc/mc.jpg" "jane">>The television keeps losing the picture.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Hit the side twice. Not the top—the side.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Does that actually repair it?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>No. But it scares it into working for another hour.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I'll try to remember the correct side.<</say>>
<<case 9>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Any luck finding work?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Not yet. One man said he'd contact me if something opened up.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Did he ask you to pay an application fee?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>He said it was only fifty credits.<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Then he's a thief. Never pay someone for the privilege of working for them.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Oh. I believed him. Thank you for telling me.<</say>>
<<case 10>>
<<say $mcname "media/mc/mc.jpg" "jane">>Do the neighbors always argue this loudly?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Those two? This is quiet for them.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Should we check if they're all right?<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>They'll be sharing drinks again by midnight. Stay out of it.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>If you're sure. I suppose you know them better than I do.<</say>>
<</switch>>
<</nobr>>
[[Return->Talk to Arthur]]<<say $mcname "media/mc/mc.jpg" "jane">>Well? Do you like what you see?<</say>>\
<<nobr>>
<<switch random(1, 8)>>
<<case 1>>
<video src="media/arthursroom/tease/tease1.mp4" autoplay loop controls></video>
<<case 2>>
<video src="media/arthursroom/tease/tease2.mp4" autoplay loop controls></video>
<<case 3>>
<video src="media/arthursroom/tease/tease3.mp4" autoplay loop controls></video>
<<case 4>>
<video src="media/arthursroom/tease/tease4.mp4" autoplay muted playsinline loop controls></video>
<<case 5>>
<video src="media/arthursroom/tease/tease5.mp4" autoplay loop controls></video>
<<case 6>>
<video src="media/arthursroom/tease/tease6.mp4" autoplay loop controls></video>
<<case 7>>
<video src="media/arthursroom/tease/tease7.mp4" autoplay loop controls></video>
<<case 8>>
<video src="media/arthursroom/tease/tease8.mp4" autoplay loop controls></video>
<</switch>>
<</nobr>>
[[Finish->Talk to Arthur]]<<run setup.resetArthurSexScene()>>
<div id="arthur-sex-ui">
<<arthurSexUI>>
</div><<say $mcname "media/mc/mc.jpg" "thought">>Of course this is what Arthur watches. I suppose it is more entertaining than another Protectorate news loop.<</say>>\
<<switch random(1, 4)>>
<<case 1>>
<img class="scene-image" src="media/arthursroom/tv/tv1.webp">
<<case 2>>
<img class="scene-image" src="media/arthursroom/tv/tv2.webp">
<<case 3>>
<img class="scene-image" src="media/arthursroom/tv/tv3.webp">
<<case 4>>
<img class="scene-image" src="media/arthursroom/tv/tv4.webp">
<</switch>>
[[Return->Arthur's room]]<p>The shared bathroom is worn and cramped, but the plumbing works most of the time.</p>\
<img class="scene-image" src="media/bathroom/bathroom.jpg">
[[Shower]]
[[Mirror]]
[[Hall->Slums Home]]<p>You gather what ingredients you have and prepare a simple meal.</p>\
<<nobr>>
<<switch random(1, 2)>>
<<case 1>>
<video src="media/kitchen/cooking/cooking1.mp4" autoplay loop controls></video>
<<case 2>>
<video src="media/kitchen/cooking/cooking2.mp4" autoplay loop controls></video>
<<default>>
<video src="media/kitchen/cooking/cooking1.mp4" autoplay loop controls></video>
<</switch>>
<</nobr>>
[[Eat meal->Eating]]<<say $mcname "media/mc/mc.jpg" "thought">>Time to do the dishes. Living independently is glamorous.<</say>>
<<nobr>>
<<switch random(1, 5)>>
<<case 1>>
<img class="scene-image" src="media/kitchen/dishes/dishes1.webp" width="640" height="720">
<<case 2>>
<img class="scene-image" src="media/kitchen/dishes/dishes2.webp" width="640" height="720">
<<case 3>>
<img class="scene-image" src="media/kitchen/dishes/dishes3.webp" width="640" height="720">
<<case 4>>
<img class="scene-image" src="media/kitchen/dishes/dishes4.webp" width="640" height="720">
<<case 5>>
<img class="scene-image" src="media/kitchen/dishes/dishes5.webp" width="640" height="720">
<<default>>
<img class="scene-image" src="media/kitchen/dishes/dishes1.webp" width="640" height="720">
<</switch>>
<</nobr>>
[[Finish->Kitchen]]<<say $mcname "media/mc/mc.jpg" "thought">>
It is simple, but it is warm and filling.
<</say>>
<<nobr>>
<<switch random(1, 5)>>
<<case 1>>
<img class="scene-image" src="media/kitchen/eating/eating1.webp"
width="640" height="720" alt="Eating">
<<case 2>>
<img class="scene-image" src="media/kitchen/eating/eating2.webp"
width="640" height="720" alt="Eating">
<<case 3>>
<img class="scene-image" src="media/kitchen/eating/eating3.webp"
width="640" height="720" alt="Eating">
<<case 4>>
<img class="scene-image" src="media/kitchen/eating/eating4.webp"
width="640" height="720" alt="Eating">
<<case 5>>
<img class="scene-image" src="media/kitchen/eating/eating5.webp"
width="640" height="720" alt="Eating">
<</switch>>
<</nobr>>
[[Finish->Kitchen]]<<say $mcname "media/mc/mc.jpg" "thought">>I should keep myself active. It might help me feel less helpless out here.<</say>>\
[[Hula]]
[[Different kind of exercise...->Masturbate]]
[[Return->My room]]<<say $mcname "media/mc/mc.jpg" "thought">>All right. Keep moving... I can do this!<</say>>\
<<nobr>>
<<switch random(1, 4)>>
<<case 1>>
<video src="media/myroom/exercise/1.mp4" autoplay loop controls></video>
<<case 2>>
<video src="media/myroom/exercise/2.mp4" autoplay loop controls></video>
<<case 3>>
<video src="media/myroom/exercise/3.mp4" autoplay loop controls></video>
<<case 4>>
<video src="media/myroom/exercise/4.mp4" autoplay loop controls></video>
<<default>>
<video src="media/myroom/exercise/1.mp4" autoplay loop controls></video>
<</switch>>
<</nobr>>
[[Finish->Exercise]]<p>The shared kitchen is small and battered, with just enough working equipment to prepare a meal.</p>\
<img class="scene-image" src="media/kitchen/kitchen.jpg">
[[Cook Meal->Cooking]]
[[Do dishes->Dishes]]
[[Hall->Slums Home]]<<say $mcname "media/mc/mc.jpg" "thought">>I need this...<</say>>\
<<nobr>>
<<switch random(1, 6)>>
<<case 1>>
<video src="media/myroom/exercise/masturbate1.mp4" autoplay loop controls></video>
<<case 2>>
<video src="media/myroom/exercise/masturbate2.mp4" autoplay loop controls></video>
<<case 3>>
<video src="media/myroom/exercise/masturbate3.mp4" autoplay loop controls></video>
<<case 4>>
<video src="media/myroom/exercise/masturbate4.mp4" autoplay loop controls></video>
<<case 5>>
<video src="media/myroom/exercise/masturbate5.mp4" autoplay loop controls></video>
<<case 6>>
<video src="media/myroom/exercise/masturbate6.mp4" autoplay loop controls></video>
<<default>>
<video src="media/myroom/exercise/masturbate1.mp4" autoplay loop controls></video>
<</switch>>
<</nobr>>
[[Finish->Exercise]]<<say $mcname "media/mc/mc.jpg" "thought">>So... this is me now. New city, new home, new life.<</say>>\
<img @src="setup.getMcPortrait()" data-mc-portrait width="250" height="300">
<<linkreplace "Undress">><<say $mcname "media/mc/mc.jpg" "thought">>I wonder if they will ever grow any bigger.<</say>><img src="media/bathroom/tits.webp" width="240" height="160">
<<say $mcname "media/mc/mc.jpg" "thought">>At least keeping myself smooth makes washing easier.<</say>><img src="media/bathroom/pussy.webp" width="240" height="240">
<<say $mcname "media/mc/mc.jpg" "thought">>I have always liked this part of me.<</say>><img src="media/bathroom/ass.webp" width="300" height="240"><</linkreplace>>
[[Return->Bathroom]]<p>Your rented room is modest, but it is the first space in Suns End that belongs to you.</p>\
<<say $mcname "media/mc/mc.jpg" "thought">>Home sweet home... more or less.<</say>>\
<img class="scene-image" src="media/myroom/myroom.jpg">
[[Sofa]]
[[Wardrobe]]
[[Equipment]]
[[Exercise]]
[[Hall->Slums Home]]<p>You lie down for a short nap, hoping to quiet your thoughts for a while.</p>\
<<nobr>>
<<switch random(1, 2)>>
<<case 1>>
<img class="scene-image" src="media/myroom/sleep/napping/nap1.jpg" width="500" height="500">
<<case 2>>
<img class="scene-image" src="media/myroom/sleep/napping/nap2.jpg" width="500" height="500">
<<default>>
<img class="scene-image" src="media/myroom/sleep/napping/nap1.jpg" width="500" height="500">
<</switch>>
<</nobr>>\
<<nobr>>
<<if setup.shouldArthurPeep()>>
[[Wake up->Peeping]]
<<else>>
[[Wake up->Sofa]]
<</if>>
<</nobr>><p>A shift in the mattress and the weight of someone else's presence pull you toward wakefulness.</p>\
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Easy... just collecting a little of what I'm owed.<</say>>\
<<nobr>>
<<set $peepingVideo to setup.pickPeepingVideo()>>
<video @src="$peepingVideo" autoplay loop controls></video>
<</nobr>>
<<nobr>>
<<link "Stay still..." "Peeping Continued">><<run setup.adjustCorruption(-1)>><</link>><br>
<<link "Wake and freak out..." "Peeping Freakout">><<run setup.adjustCorruption(-1)>><</link>>
<</nobr>><<run setup.adjustDominance(-1)>><<run UIBar.update()>>
<<nobr>>
<<if !$peepingVideo>><<set $peepingVideo to setup.pickPeepingVideo()>><</if>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>That's it... stay quiet and don't make this difficult.<</say>>
<video @src="$peepingVideo" autoplay loop controls></video>
<</nobr>>
[[Return->Sofa]]<<run setup.adjustDominance(1)>><<run UIBar.update()>>
<<nobr>>
<img class="scene-image" src="media/myroom/sleep/napping/yelling1.webp" alt="">
<<switch random(1, 3)>>
<<case 1>>
<<say $mcname "media/mc/mc.jpg" "jane">>Arthur! What the hell are you doing in here?!<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Calm down. I was only checking on you.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Checking on me? Get out of my room! Now!<</say>>
<<case 2>>
<<say $mcname "media/mc/mc.jpg" "jane">>Were you watching me sleep?!<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>You're making a fuss over nothing.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>This is not nothing! Stay away from me!<</say>>
<<case 3>>
<<say $mcname "media/mc/mc.jpg" "jane">>Don't touch me! Get away!<</say>>
<<say "Arthur" "media/characters/arthur.jpg" "arthur">>Fine. No need to start screaming.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Then stop sneaking into my room while I'm asleep!<</say>>
<</switch>>
<</nobr>>
[[Return->Sofa]]<p>You let the hot water wash away the grime of the district.</p>\
<<nobr>>
<<switch random(1, 3)>>
<<case 1>>
<video src="media/bathroom/shower1.mp4" autoplay loop controls></video>
<<case 2>>
<video src="media/bathroom/shower2.mp4" autoplay loop controls></video>
<<case 3>>
<video src="media/bathroom/shower3.mp4" autoplay loop controls></video>
<<default>>
<video src="media/bathroom/shower1.mp4" autoplay loop controls></video>
<</switch>>
<</nobr>>
[[Bathroom]]<<run setup.soberUp()>><<run setup.advanceGameDay()>><<run UIBar.update()>>
<p>You settle in for the night. Whatever tomorrow brings, you need the rest.</p>\
<<nobr>>
<<switch random(1, 5)>>
<<case 1>>
<img class="scene-image" src="media/myroom/sleep/sleeping/1.webp">
<<case 2>>
<img class="scene-image" src="media/myroom/sleep/sleeping/2.webp">
<<case 3>>
<img class="scene-image" src="media/myroom/sleep/sleeping/3.webp">
<<case 4>>
<img class="scene-image" src="media/myroom/sleep/sleeping/4.webp">
<<case 5>>
<img class="scene-image" src="media/myroom/sleep/sleeping/5.webp">
<<default>>
<img class="scene-image" src="media/myroom/sleep/sleeping/1.webp">
<</switch>>
<</nobr>>
[[Wake up->Sofa]]<p>The narrow hall connects the rooms of the residence you share with Arthur.</p>\
<img class="scene-image" src="media/slumshome/hall.jpg">
<<nobr>>
[[My room]]<br>
[[Arthur's room]]<br>
[[Bathroom]]<br>
[[Kitchen]]<br>
[[Try to clean up]]<br>
<<if setup.isDressedForOutside()>>
[[Outside->Slums]]
<<else>>
<span class="passage-link-disabled" aria-disabled="true">Outside</span>
<p class="table-order-error">You need to put on an outfit and shoes before going outside.</p>
<</if>>
<</nobr>><<say $mcname "media/mc/mc.jpg" "thought">>The sofa is not much, but I can finally sit down for a while.<</say>>
[[Sleep]]
[[Nap]]
[[Stand up->My room]]<<say $mcname "media/mc/mc.jpg" "thought">>If I work through the worst of this mess, at least the rent will hurt a little less.<</say>>\
<<nobr>>
<<switch random(1, 7)>>
<<case 1>>
<video src="media/slumshome/cleaning/cleaning1.mp4" autoplay loop controls width="640" height="720"></video>
<<case 2>>
<video src="media/slumshome/cleaning/cleaning2.mp4" autoplay loop controls width="640" height="720"></video>
<<case 3>>
<video src="media/slumshome/cleaning/cleaning3.mp4" autoplay loop controls width="640" height="720"></video>
<<case 4>>
<video src="media/slumshome/cleaning/cleaning4.mp4" autoplay loop controls width="640" height="720"></video>
<<case 5>>
<img class="scene-image" src="media/slumshome/cleaning/cleaning5.gif" width="640" height="720">
<<case 6>>
<img class="scene-image" src="media/slumshome/cleaning/cleaning6.gif" width="640" height="720">
<<case 7>>
<img class="scene-image" src="media/slumshome/cleaning/cleaning7.gif" width="640" height="720">
<<default>>
<video src="media/slumshome/cleaning/cleaning1.mp4" autoplay loop controls width="640" height="720"></video>
<</switch>>
<</nobr>>
<<if not $cleaningcooldown>>\
<<set $cleaningcooldown to true>>\
<<run setup.reduceRentDue(50)>>\
[[Finish->Slums Home]]\
<<else>>\
[[Finish->Slums Home]]\
<</if>>\<h2>Wardrobe</h2>
[[Back->My room]]
<div id="wardrobe-ui">
<<wardrobeUI "outfits">>
</div><h2>Equipment</h2>
[[Back->My room]]
<div id="combat-loadout-ui"><<combatEquipmentUI>></div><div class="age-gate-panel">
<p>Warning: This game contains content that is not suitable for minors. By clicking continue, you acknowledge that you are at least 18 years old or older.</p>
<div id="age-gate-actions" class="age-gate-actions">
<<button "I am 18 years old or older.">><<goto "Start">><</button>>
<<button "I am not 18 years old or older.">>
<<replace "#age-gate-actions">><p id="age-gate-actions" class="age-gate-rejected" role="status">Please close the tab.</p><</replace>>
<</button>>
</div>
</div><p>Suns End—the jewel of western Arda. At least, that is what the Protectorate travel holos promised before you came here.</p>\
[[Space Port]]<p>The lower spaceport deposits you beneath the city proper with one small credit balance, a few personal belongings, and the hope of starting over. Every respectable district is far beyond your budget. If you want a roof tonight, the Slums are your only realistic choice.</p>\
[[Slums->Slums Arrival]]<p>The descent into the Slums strips the shine from every promise you heard about Suns End. Towers crowd out the sky, refuse gathers beneath rusted walkways, and reputable citizens hurry through without looking back. You find the nearest public data panel and begin searching for somewhere—anywhere—you can afford to sleep.</p>\
[[Data panel]]<p>The public data panel is cracked, greasy, and several updates out of date. Its display stutters beneath your touch, but it is the only housing terminal nearby.</p>\
<<linkreplace "Touch the panel">>\
The panel flickers reluctantly to life.
<p><strong>Identity not recognized. Please insert your ID card into the reader.</strong></p>\
<p>You wipe the reader with your sleeve, take out your citizen ID, and carefully slide it into the slot.</p>\
<label>\
Name:
<<textbox "$mcname" $mcname>>\
</label>\
<span id="name-error"></span>
<<button "Confirm name">>\
<<set $mcname to $mcname.trim()>>\
<<if $mcname is "">>\
<<replace "#name-error">>\
<span id="name-error" class="name-error">\
Error. Provide a name.\
</span>\
<</replace>>\
<<else>>\
<<goto "Character Data Panel">>\
<</if>>\
<</button>>\
<</linkreplace>>\<p><strong>Citizen data loading...</strong></p>\
<img @src="setup.getMcPortrait()" data-mc-portrait width="240" height="300">
Name: $mcname Savino
Age: $mcage
Gender: F
Eye color: $mceyecolor
Occupation: $mcoccupation
Permanently registered at: $mchomeaddress
Birthplace: Hedexus V > Trexuria
Martial Status: $mcmartialstatus
Credits: c$credits
[[Confirm->Look up]]<p>Once the panel confirms your identity, it releases your card and grants access to the local housing listings. You sort them by distance and price. Even in the Slums, nearly everything costs more than you can afford.</p>\
<p>The cheapest listing is around the corner: one room for c150 a week. You only have c100. With no better option, you decide to go [[there->Renting Place]] and ask the landlord to lower the price.</p>\<p>The residential block looks like everything else in the Slums: neglected, damp, and patched together just well enough to remain standing. After a day of travel, you are too tired to be particular.</p>\
<p>You find the number from the listing and knock. A few seconds later, a broad, middle-aged man in worn slacks and a stained white shirt opens the door.</p>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>Yeah? What do you want?<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>Hello. I saw your housing listing on the public panel. You still have a room available, right?<</say>>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>Still available. You looking to rent it?<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>Yes, please. Could you show me where it is?<</say>>\
<p>You step back into the corridor, expecting him to lead you elsewhere. He watches you with a puzzled frown.</p>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>Where are you going? This is the place.<</say>>\
<p>You glance past him into the cramped residence.</p>\
<<say $mcname "media/mc/mc.jpg" "jane">>You mean... in here? With you?<</say>>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>You thought c150 bought a private apartment? You get one bedroom. Kitchen and bathroom are shared.<</say>>\
<<say $mcname "media/mc/mc.jpg" "thought">>Of course. A filthy room in a stranger's home. Still... it is better than sleeping outside.<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>All right. Could I see the room first?<</say>>\
<p>He lets you inside. The spare room is in complete disarray, as if its last occupant left during a storm. The kitchen and bathroom are both shared; the only other bedroom belongs to him.</p>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>So, you want it or not?<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>I do want it, but there is a problem. I only have c100 right now.<</say>>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>Then why the hell are you wasting my time?<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>Please. I have nowhere else to go tonight. There must be something I can do.<</say>>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>This isn't a charity, girl.<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>I know. I can work. Clean, cook—whatever you need. Please.<</say>>\
<p>His irritation fades into calculation as he looks past you at the state of the residence.</p>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>All right. Clean the whole place once a week and I'll knock c50 off that week's rent. Miss it, and you owe the full c150. Deal?<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>Deal. Thank you. I mean it.<</say>>\
<<say "Man" "media/characters/arthur.jpg" "arthur">>Transfer the c100 now and move your things in. Name's Arthur, by the way. Don't make me regret this.<</say>>\
<<say $mcname "media/mc/mc.jpg" "jane">>You won't. I'm $mcname. It is nice to meet you, Arthur.<</say>>\
<<run setup.chargeCredits(100)>><<set $mchomeaddress to "Arda > Suns End > Ughathan 84031/40">><<set $cleaningcooldown to false>><<set $baseRent to 150>><<run setup.setRentDue($baseRent)>>\
<p>You transfer every credit you have. Arthur leaves you to settle in, and you take stock of the mess around you. It is hardly the fresh start you imagined, but once you [[tidy->Slums Home]] the place, it might begin to feel like home.</p>\<<nobr>>
<<set _address to setup.parseCharacterAddress($mchomeaddress)>>
<div class="character-info">
<header class="character-info-header">
<h2>Character Profile</h2>
<div class="character-info-registry-mark">
<p>Citizen record</p>
<img src="media/ui/character-info/protectorate-emblem.svg" alt="Protectorate emblem">
</div>
</header>
<div class="character-info-layout">
<aside class="character-info-summary">
<img class="character-info-portrait" @src="setup.getMcPortrait()" data-mc-portrait alt="">
<strong class="character-info-name">$mcname Savino</strong>
</aside>
<section class="character-info-section">
<h3><img class="character-info-category-icon" src="media/ui/character-info/personal.svg" alt="">Personal Details</h3>
<dl class="character-info-fields">
<div><dt>Full name</dt><dd>$mcname Savino</dd></div>
<div><dt>Age</dt><dd>$mcage</dd></div>
<div><dt>Gender</dt><dd>Female</dd></div>
<div><dt>Race</dt><dd>Human</dd></div>
<div><dt>Eye color</dt><dd>$mceyecolor</dd></div>
<div><dt>Marital status</dt><dd>$mcmartialstatus</dd></div>
<div><dt>Occupation</dt><dd><<print setup.getOccupationDisplay()>></dd></div>
</dl>
</section>
<section class="character-info-section">
<h3><img class="character-info-category-icon" src="media/ui/character-info/registration.svg" alt="">Registration</h3>
<div class="character-info-address-block">
<h4>Permanent address</h4>
<dl class="character-info-fields">
<div><dt>Planet</dt><dd><<print _address.planet>></dd></div>
<div><dt>City</dt><dd><<print _address.city>></dd></div>
<div><dt>Street</dt><dd><<print _address.street>></dd></div>
<div><dt>Building</dt><dd><<print _address.building>></dd></div>
<div><dt>Residence</dt><dd><<print _address.residence>></dd></div>
</dl>
</div>
<div class="character-info-address-block character-info-address-block--birthplace">
<h4>Birthplace</h4>
<dl class="character-info-fields">
<div><dt>Planet</dt><dd>Hedexus V</dd></div>
<div><dt>City</dt><dd>Trexuria</dd></div>
</dl>
</div>
</section>
<section class="character-info-section character-info-finances">
<div class="character-info-account-block">
<h3><img class="character-info-category-icon" src="media/ui/character-info/account.svg" alt="">Account</h3>
<div class="character-info-credit"><span>Available credits</span><strong>c$credits</strong></div>
<div class="character-info-credit"><span>Fines</span><strong @class="setup.getFinancialValueClass('fines', $fines)">c$fines</strong></div>
<div class="character-info-credit"><span>Outstanding balance</span><strong @class="setup.getFinancialValueClass('outstanding', $outstandingBalance)">c$outstandingBalance</strong></div>
</div>
<div class="character-info-records">
<h3><img class="character-info-category-icon" src="media/ui/character-info/records.svg" alt="">Records</h3>
<div class="character-info-record-row">
<span>Police record</span>
<<if $isWanted>>
<strong class="character-info-record-status character-info-record-status--alert">Wanted</strong>
<<else>>
<strong class="character-info-record-status character-info-record-status--clear">Not wanted</strong>
<</if>>
</div>
<div class="character-info-record-row">
<span>Health insurance</span>
<<if $hasHealthInsurance>>
<strong class="character-info-record-status character-info-record-status--clear"><<print setup.getHealthInsuranceStatus()>></strong>
<<else>>
<strong class="character-info-record-status character-info-record-status--alert">Not insured</strong>
<</if>>
</div>
</div>
</section>
</div>
<div class="character-info-return">
<<link "Return">><<goto $return>><</link>>
</div>
</div>
<</nobr>><<set _slumsEncounter to setup.rollSlumsDistrictEncounter()>>
<<if _slumsEncounter>>
<<set $pendingCombatEncounter to _slumsEncounter.enemyName>>
<<set $pendingCombatEncounterFaction to _slumsEncounter.faction>>
<<goto _slumsEncounter.passage>>
<</if>>
<p>Life spills through the lower levels of Suns End beneath a permanent haze of rust, exhaust, and flickering advertisements. The Slums are dangerous, but for now they are home.</p>
<img class="scene-image" src="media/locations/slums/slums.jpg" alt="The Slums district">
[[Market Square]]
[["Vested Interest" Bar]]
[[Hospital]]
[[Home->Slums Home]]<<nobr>>
<h2>Encounter</h2>
<<if $pendingCombatEncounter>>
<<set _encounterEnemyName to $pendingCombatEncounter>>
<<set _encounterEnemy to setup.getCombatEnemyByName(_encounterEnemyName)>>
<<set _encounterEnemyTheme to setup.getCombatEnemyKey(_encounterEnemy.faction)>>
<p>A hostile <<print _encounterEnemyName>> steps into your path and blocks the narrow street.</p>
<<say _encounterEnemy.name _encounterEnemy.image _encounterEnemyTheme>>Empty your pockets. Now.<</say>>
<<capture _encounterEnemyName>>
<<link "Fight">>
<<set $pendingCombatEncounter to "">>
<<set $pendingCombatEncounterFaction to "">>
<<startFight _encounterEnemyName>>
<</link>><br>
<<link "Hand over">>
<<set _encounterHandover to setup.resolveUnaffiliatedEncounterHandover(_encounterEnemyName)>>
<<if _encounterHandover.ok>><<goto _encounterHandover.destination>><</if>>
<</link>>
<</capture>>
<<else>>
<p class="table-order-error">No encounter has been prepared.</p>
[[Return->Slums]]
<</if>>
<</nobr>><<nobr>>
<<set _encounterEnemy to setup.getCombatDefeatEnemy()>>
<<set _encounterEnemyTheme to setup.getCombatEnemyKey(_encounterEnemy.faction)>>
<<say _encounterEnemy.name _encounterEnemy.image _encounterEnemyTheme>>Nothing? Then I'll collect another way. Maybe you'll even learn to enjoy it.<</say>>
[[Continue->Enemy Sex]]
<</nobr>><<nobr>>
<h2>Protectorate Encounter</h2>
<<if $pendingCombatEncounter>>
<<set _encounterEnemyName to $pendingCombatEncounter>>
<<set _encounterEnemy to setup.getCombatEnemyByName(_encounterEnemyName)>>
<<set _encounterEnemyTheme to setup.getCombatEnemyKey(_encounterEnemy.faction)>>
<p>A <<print _encounterEnemyName>> notices you while patrolling the district and steps directly into your path.</p>
<<say _encounterEnemy.name _encounterEnemy.image _encounterEnemyTheme>>Citizen. Present your identification for inspection.<</say>>
<<capture _encounterEnemyName>>
<<link "Fight">>
<<set $pendingCombatEncounter to "">>
<<set $pendingCombatEncounterFaction to "">>
<<startFight _encounterEnemyName>>
<</link>><br>
[[Hand over->Protectorate ID Check]]
<</capture>>
<<else>>
<p class="table-order-error">No Protectorate encounter has been prepared.</p>
[[Return->Slums]]
<</if>>
<</nobr>><<nobr>>
<<set _encounterEnemyName to $pendingCombatEncounter>>
<<set _encounterEnemy to setup.getCombatEnemyByName(_encounterEnemyName)>>
<<if _encounterEnemy>>
<<set _encounterEnemyTheme to setup.getCombatEnemyKey(_encounterEnemy.faction)>>
<p>You surrender your ID. The <<print _encounterEnemyName>> scans it against Protectorate warrants and the central fines registry.</p>
<<if setup.mustSurrenderToProtectorate()>>
<<say _encounterEnemy.name _encounterEnemy.image _encounterEnemyTheme>>Your citizen record requires immediate detention. Place your hands where I can see them and surrender.<</say>>
<<capture _encounterEnemyName>>
<<link "Fight">>
<<set $pendingCombatEncounter to "">>
<<set $pendingCombatEncounterFaction to "">>
<<startFight _encounterEnemyName "Prison Introduction">>
<</link>><br>
<<link "Surrender">>
<<set $pendingCombatEncounter to "">>
<<set $pendingCombatEncounterFaction to "">>
<<goto "Prison Introduction">>
<</link>>
<</capture>>
<<else>>
<p>The scan returns clean. The <<print _encounterEnemyName>> hands your ID back without apology.</p>
<<say _encounterEnemy.name _encounterEnemy.image _encounterEnemyTheme>>Move along, citizen.<</say>>
<<link "Continue">>
<<set $pendingCombatEncounter to "">>
<<set $pendingCombatEncounterFaction to "">>
<<goto "Slums">>
<</link>>
<</if>>
<<else>>
<p class="table-order-error">The encounter record is no longer valid.</p>
[[Return->Slums]]
<</if>>
<</nobr>><<nobr>>
<<set _prisonSentence to setup.preparePrisonSentence()>>
<h2>Prison Introduction</h2>
<p>Protectorate officers drag you into a holding cell and leave you under constant surveillance until a Judge is ready to hear your case.</p>
<<if _prisonSentence.days > 0>>
<img class="scene-image" src="media/locations/prison/courtroom.jpg" alt="Protectorate courtroom">
<<say "Judge" "media/locations/prison/judge.jpg" "protectorate">><<if _prisonSentence.wanted && _prisonSentence.fines > 4999>>You stand before this court as a wanted citizen with c<<print _prisonSentence.fines>> in unpaid fines. The sentence is <<print _prisonSentence.days>> days of confinement.<<elseif _prisonSentence.wanted>>You stand before this court as a wanted citizen. The sentence is <<print _prisonSentence.days>> days of confinement.<<else>>Your unpaid fines total c<<print _prisonSentence.fines>>. The sentence is <<print _prisonSentence.days>> days of confinement.<</if>><</say>>
<p>The ruling is entered into your citizen record. Guards return you to restraints and transport you to the district prison to serve the sentence.</p>
[[Continue->Prison]]
<<else>>
<p class="table-order-error">No active charge could be found for sentencing.</p>
[[Return->Slums]]
<</if>>
<</nobr>><<nobr>>
<h2>Prison</h2>
<img class="scene-image" src="media/locations/prison/prison.jpg" alt="Prison cell">
<<say $mcname "media/mc/mc.jpg" "thought">>I hate this place. I just have to keep my head down and get through the sentence.<</say>>
<<link "Serve sentence">>
<<run setup.servePrisonSentence()>>
<<run UIBar.update()>>
<<goto "Slums">>
<</link>>
<</nobr>><h2>Fight</h2>
<<if $combatEnemy>>
<div id="combat-ui"><<combatUI>></div>
<<else>>
<p class="table-order-error">No combat encounter has been initialized.</p>
[[Return->Slums]]
<</if>><h2>Victory</h2>
<<if $combatOutcome && $combatOutcome.type is "victory">>
<<if $combatOutcome.enemyImage>>
<img class="scene-image" @src="$combatOutcome.enemyImage" @alt="$combatOutcome.enemyName">
<</if>>
<<if $combatOutcome.contractResolution>>
<<nobr>>
<<set _contractResolution to $combatOutcome.contractResolution>>
<<if _contractResolution.acknowledged>>
<p>This contract has already been completed.</p>
[[Continue->"Vested Interest" Bar]]
<<elseif _contractResolution.witnessed>>
<p>Someone saw you assaulting <<print _contractResolution.targetName>> and notified the authorities.</p>
<p class="table-order-error"><strong>You are now WANTED!</strong></p>
<<link "Continue">>
<<set _contractResolution.acknowledged to true>>
<<goto '"Vested Interest" Bar'>>
<</link>>
<<else>>
[[Continue->"Vested Interest" Bar]]
<</if>>
<</nobr>>
<<elseif setup.isMercenaryContractVictory()>>
<<nobr>>
<<say $mcname "media/mc/mc.jpg" "thought">>Time to finish the job.<</say>>
<<linkreplace "Confirm kill">>
<<set _contractCompletion to setup.completeMercenaryContract()>>
<<if _contractCompletion.ok>>
<<if _contractCompletion.witnessed>>
<<set $isWanted to true>>
<p>Someone saw you assaulting <<print _contractCompletion.contract.targetName>> and notified the authorities.</p>
<p class="table-order-error"><strong>You are now WANTED!</strong></p>
<<link "Continue">>
<<set $combatOutcome.contractResolution.acknowledged to true>>
<<goto '"Vested Interest" Bar'>>
<</link>>
<<else>>
<<goto '"Vested Interest" Bar'>>
<</if>>
<</if>>
<</linkreplace>>
<</nobr>>
<<else>>
<p><<print $combatOutcome.enemyName>> lies defeated. What do you want to do?</p>
<<nobr>>
<<link "Leave them be">>
<<run setup.completeCombatVictory(false)>>
<<goto "Slums">>
<</link>><br>
<<link "Steal credits">>
<<run setup.completeCombatVictory(true)>>
<<goto "Slums">>
<</link>>
<</nobr>>
<</if>>
<<else>>
<p class="table-order-error">There is no completed fight to resolve.</p>
[[Return->Slums]]
<</if>><h2>Hospital</h2>
<img class="scene-image" src="media/locations/hospital/hospital.jpg" alt="Hospital room">
<p>The Slums hospital operates beneath harsh lights and stricter billing rules. Treatment is available; mercy is not.</p>
[[Visit the insurance agent]]<br>
[[Return->Slums]]<<nobr>>
<h2>Insurance Agent</h2>
<img class="scene-image" src="media/locations/hospital/insuranceaagent.jpg" alt="Hospital insurance agent">
<p>The agent presents three Protectorate-approved health insurance plans. Coverage begins immediately after payment.</p>
<div id="insurance-purchase-notice"></div>
<div class="insurance-plan-grid">
<<for _insurancePlanKey range ["bronze", "silver", "gold"]>>
<<set _insurancePlan to setup.healthInsurancePlans[_insurancePlanKey]>>
<<capture _insurancePlanKey _insurancePlan>>
<<set _insuranceButtonLabel to "Choose " + _insurancePlan.name>>
<article @class="'insurance-plan-card insurance-plan-card--' + _insurancePlanKey">
<h3><<print _insurancePlan.name>></h3>
<strong>c<<print _insurancePlan.cost>></strong>
<span><<if _insurancePlan.months is 1>>1 month<<elseif _insurancePlan.months is 12>>1 year<<else>><<print _insurancePlan.months>> months<</if>></span>
<<if setup.canAfford(_insurancePlan.cost)>>
<<button _insuranceButtonLabel>>
<<set _insurancePurchase to setup.purchaseHealthInsurance(_insurancePlanKey)>>
<<if _insurancePurchase.ok>><<goto "Hospital">><</if>>
<</button>>
<<else>>
<button type="button" disabled title="Not enough credits">Choose <<print _insurancePlan.name>></button>
<</if>>
</article>
<</capture>>
<</for>>
</div>
[[Return->Hospital]]
<</nobr>><<nobr>>
<<set _hospitalDefeatResult to setup.applyCombatHospitalBill()>>
<<set _hospitalPrisonTransfer to setup.shouldTransferDefeatHospitalToPrison()>>
<h2>Defeat</h2>
<img class="scene-image" src="media/locations/hospital/hospital.jpg" alt="Hospital room">
<<say $mcname "media/mc/mc.jpg" "thought">>Where am I...? Those lights... I'm in a hospital.<</say>>
<p>Emergency responders brought you here after you lost consciousness. The medical staff have treated your injuries and stabilized your condition.</p>
<<if $hasHealthInsurance>>
<p>Your current health insurance plan covers the treatment.</p>
<<else>>
<p>Because you are uninsured, a c1000 treatment charge has been recorded as a debt in your Outstanding Balance.</p>
<</if>>
<<if _hospitalPrisonTransfer>>
<p>A Protectorate guard waits outside your room. The moment the medical staff discharge you, the guard places you in custody.</p>
[[Continue->Prison Introduction]]
<<else>>
[[Continue->Hospital]]
<</if>>
<</nobr>><h2>Defeat</h2>
<p>The final blow sends you to the ground. Sound and light recede as you lose consciousness.</p>
[[Continue->Pleading]]<<nobr>>
<<set _defeatEnemy to setup.getCombatDefeatEnemy()>>
<<set _defeatEnemyTheme to setup.getCombatEnemyKey(_defeatEnemy.faction)>>
<<set _protectorateArrest to setup.getProtectorateArrestStatus()>>
<h2>Pleading</h2>
<p>A sharp blow jolts you awake. The <<print _defeatEnemy.name>> stands over you.</p>
<<if _defeatEnemy.image>>
<img class="scene-image" @src="_defeatEnemy.image" @alt="_defeatEnemy.name">
<</if>>
<<if _defeatEnemyTheme is "protectorate" && _protectorateArrest.shouldArrest>>
<<say _defeatEnemy.name _defeatEnemy.image _defeatEnemyTheme>><<if _protectorateArrest.wanted && _protectorateArrest.excessiveFines>>Your record shows an active warrant and c<<print _protectorateArrest.fines>> in unpaid fines. You are under arrest.<<elseif _protectorateArrest.wanted>>Your citizen record shows an active warrant. You are under arrest.<<else>>Your unpaid fines total c<<print _protectorateArrest.fines>>. You are under arrest.<</if>><</say>>
[[Continue->Prison Introduction]]
<<else>>
<<if _defeatEnemyTheme is "protectorate">>
<<set _protectorateFine to setup.prepareCombatProtectorateFine()>>
<<say _defeatEnemy.name _defeatEnemy.image _defeatEnemyTheme>>Assaulting a Protectorate officer carries an immediate fine of c<<print _protectorateFine.fine>>. It has been added to your citizen record.<</say>>
<<link "Accept the Fine">>
<<run setup.applyCombatProtectorateFine()>>
<<goto "Slums">>
<</link>><br>
<<else>>
<<say _defeatEnemy.name _defeatEnemy.image _defeatEnemyTheme>>Now hand over your credits.<</say>>
<<if $credits > 0>>
<<link "Give them credits">>
<<run setup.payCombatDefeatCredits()>>
<<goto "Slums">>
<</link>><br>
<<else>>
<<say _defeatEnemy.name _defeatEnemy.image _defeatEnemyTheme>>No credits? Then I'll collect another way. Maybe you'll even learn to enjoy it.<</say>>
<<link "Continue">>
<<run setup.startCombatEnemySex("no-credits")>>
<<goto "Enemy Sex">>
<</link>><br>
<</if>>
<</if>>
<<if $corruption < 0>>
<<link "Offer something other than money...">>
<<run setup.startCombatEnemySex("offer")>>
<<goto "Enemy Sex">>
<</link>>
<</if>>
<</if>>
<</nobr>><div id="arthur-sex-ui">
<<arthurSexUI>>
</div><<set _drunkenClientOffer to setup.prepareDrunkenClientOffer()>>
<<if _drunkenClientOffer.triggered>><<goto "Drunken Client Offer">><</if>>
<h2>"Vested Interest" Bar</h2>
<p>The "Vested Interest" is an infamous Slums bar where exhausted workers drink beside mercenaries, criminals, and anyone else with credits to spend. Arguments are common; questions are not.</p>\
<img class="scene-image" src="media/locations/vestedinterest/start.jpg" alt="">
<<nobr>>
<<if !setup.isEmployedAt("vested-interest") && State.hasPlayed("Ask for work")>>
<<run setup.startEmployment("vested-interest", "Dishwasher")>>
<</if>>
<<if setup.isEmployedAt("vested-interest")>>
<<if setup.isMercenaryAtVestedInterest()>>
[[Contracts]]
<<if setup.getActiveMercenaryContract()>><br>[[Do some mercenary work->Kill Contract Encounter]]<</if>>
<<else>>
<<if setup.hasWorkedToday("vested-interest")>>
<span class="passage-link-disabled passage-link-disabled--tooltip" aria-disabled="true" tabindex="0" data-tooltip="You have already worked today.">Work</span>
<<elseif setup.isWaitressAtVestedInterest()>>
[[Work->Waitress Serving]]
<<else>>
[[Work]]
<</if>>
<</if>>
<<else>>
[[Ask for work]]
<</if>><br>
[[Sit at the table]]<br>
[[Outside->Slums]]
<</nobr>><<nobr>>
<p>You ask one of the waitresses whether the Bar needs help. She studies you for a moment, then leads you through a staff door and tells you the manager's name is Bradford.</p>
<p>Inside the office, a man in faded mercenary gear sits behind a scarred desk, smoking a cigar beneath a tired ventilation fan.</p>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>They tell me you're looking for work.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Yes, sir. I just moved to Suns End, and I need something steady enough to keep me here.<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>New arrival. Thought so. I don't have glamorous work, but the kitchen always needs another pair of hands. You know how to wash dishes?<</say>>
<<say $mcname "media/mc/mc.jpg" "thought">>Dishwashing. Not exactly the future I crossed half a planet for.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>I do. I'm willing to work hard—I just need the chance.<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>Base pay is c100 a week if you work at least five days. Put in all seven and I make it c150. Miss the minimum and there is no weekly pay.<</say>>
<<say $mcname "media/mc/mc.jpg" "thought">>Even the full wage barely covers rent. Still, c100 is better than c0, and Bradford does not look interested in bargaining.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>All right. When can I start?<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>Today, if you want. For your first partial week, I'll pay c20 for each day you work. After that, the normal weekly rate applies. Payday is Monday.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Thank you, sir. I won't let you down.<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>Do the work and we won't have a problem. And drop the “sir.” Bradford is fine.<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>Right. Thank you, Bradford.<</say>>
<p>With the arrangement settled, you leave the office and return to the main floor as an employee of the "Vested Interest."</p>
<<run setup.startEmployment("vested-interest", "Dishwasher")>>
[[Return->"Vested Interest" Bar]]
<</nobr>><<set _workResult to setup.recordWorkDay("vested-interest")>>
<<if _workResult.ok>>
<p>You spend the shift behind the kitchen, scraping plates, hauling racks, and washing an endless supply of glasses. By the time the last load is clean, your hands ache and the Bar is already filling again.</p>
<img class="scene-image" src="media/locations/vestedinterest/work/dishwasher/washing1.webp" alt="">
<<elseif _workResult.reason is "already-worked">>
<p>You have already completed your shift for today.</p>
<<else>>
<p>You are not employed here.</p>
<</if>>
<<if _workResult.ok && setup.canReceiveMercenaryOffer()>>
[[Continue->Mercenary Offer]]
<<elseif _workResult.ok && setup.canReceiveWaitressOffer()>>
[[Continue->Waitress Offer]]
<<else>>
[[Return->"Vested Interest" Bar]]
<</if>><<nobr>>
<h2>Mercenary Offer</h2>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>You've worked enough shifts for me to know you show up, and you've got more backbone than I expected. I could use another mercenary operating out of the Bar. Interested?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>You mean you want me handling mercenary work instead of washing dishes?<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>That's the offer. No weekly wage—you get paid for contracts you finish, and nothing for contracts you don't. I'll give you a one-time c150 signing bonus to get started.<</say>>
<<link "Accept">>
<<set _mercenaryDecision to setup.resolveMercenaryOffer(true)>>
<<if _mercenaryDecision.ok>><<goto "Mercenary Offer Accepted">><</if>>
<</link>><br>
<<link "Decline">>
<<set _mercenaryDecision to setup.resolveMercenaryOffer(false)>>
<<if _mercenaryDecision.ok>><<goto "Mercenary Offer Declined">><</if>>
<</link>>
<</nobr>><<nobr>>
<<say $mcname "media/mc/mc.jpg" "jane">>I'll do it. I want the chance to prove I can handle more than a sink full of dishes.<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>Then spend that signing bonus wisely. Stop by the Gear Stall in the Market and buy something better than bare hands before you take a contract.<</say>>
[[Continue->"Vested Interest" Bar]]
<</nobr>><<nobr>>
<<say $mcname "media/mc/mc.jpg" "jane">>Thank you for trusting me, but I'm not ready to carry a weapon for money. I'd rather stay in the kitchen.<</say>>
[[Continue->"Vested Interest" Bar]]
<</nobr>><<nobr>>
<h2>Waitress Offer</h2>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>You've put in enough shifts for me to know you're reliable. I could use another waitress on the floor, and you might earn better money out there. Interested?<</say>>
<<say $mcname "media/mc/mc.jpg" "jane">>You want me serving customers instead of washing dishes?<</say>>
<<say "Bradford" "media/characters/bradford.jpg" "bradford">>That's right. Work five or six days and the weekly pay is c200. Work all seven and it becomes c250. Whatever the customers leave you in tips is yours.<</say>>
<<link "Accept">>
<<set _waitressDecision to setup.resolveWaitressOffer(true)>>
<<if _waitressDecision.ok>><<goto "Waitress Offer Accepted">><</if>>
<</link>><br>
<<link "Decline">>
<<set _waitressDecision to setup.resolveWaitressOffer(false)>>
<<if _waitressDecision.ok>><<goto "Waitress Offer Declined">><</if>>
<</link>>
<</nobr>><<nobr>>
<<say $mcname "media/mc/mc.jpg" "jane">>I'll do it. I think I can handle the customers, and the extra pay would help.<</say>>
[[Continue->"Vested Interest" Bar]]
<</nobr>><<nobr>>
<<say $mcname "media/mc/mc.jpg" "jane">>Thank you for offering, but I would rather stay in the kitchen a little longer.<</say>>
[[Continue->"Vested Interest" Bar]]
<</nobr>><<nobr>>
<h2>Waitress Serving</h2>
<<if !setup.isWaitressAtVestedInterest()>>
<p>You are not employed as a waitress here.</p>
[[Return->"Vested Interest" Bar]]
<<elseif setup.hasWorkedToday("vested-interest")>>
<p>You have already completed your shift for today.</p>
[[Return->"Vested Interest" Bar]]
<<else>>
<div id="waitress-serving-options">
<<link "Work normally">>
<<set _waitressResult to setup.completeWaitressShift(false)>>
<<replace "#waitress-serving-options">>
<<if _waitressResult.ok>>
<<set _waitressNormalImages to [
"media/locations/vestedinterest/work/waitress/normalserving/1.jpeg",
"media/locations/vestedinterest/work/waitress/normalserving/2.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/3.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/4.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/5.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/6.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/7.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/8.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/9.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/10.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/11.jpg",
"media/locations/vestedinterest/work/waitress/normalserving/12.jpg"
]>>
<p>You keep the tables supplied, remember the regulars' orders, and steer clear of the worst arguments. By the end of the shift, the customers have left you c<<print _waitressResult.tips>> in tips.</p>
<img class="scene-image" @src="_waitressNormalImages[random(0, _waitressNormalImages.length - 1)]" alt="">
[[Return->"Vested Interest" Bar]]
<<else>>
<p>You could not complete this shift.</p>
[[Return->"Vested Interest" Bar]]
<</if>>
<</replace>>
<</link>>
<<if $dominance <= -20 && $corruption < 70>><br>
<<link "Flirt while working">>
<<set _waitressResult to setup.completeWaitressShift(true)>>
<<replace "#waitress-serving-options">>
<<if _waitressResult.ok>>
<<set _waitressFlirtyImages to [
"media/locations/vestedinterest/work/waitress/flirtyserving/1.gif",
"media/locations/vestedinterest/work/waitress/flirtyserving/2.webp",
"media/locations/vestedinterest/work/waitress/flirtyserving/4.jpg",
"media/locations/vestedinterest/work/waitress/flirtyserving/5.gif"
]>>
<p>You lean into the attention, trading smiles and suggestive remarks for fuller glasses and larger tips. By closing time, the customers have left you c<<print _waitressResult.tips>>.</p>
<img class="scene-image" @src="_waitressFlirtyImages[random(0, _waitressFlirtyImages.length - 1)]" alt="">
<<link "Return">>
<<if setup.rollWaitressClientOffer()>><<goto "Client offer">><<else>><<goto '"Vested Interest" Bar'>><</if>>
<</link>>
<<else>>
<p>You could not complete this shift.</p>
[[Return->"Vested Interest" Bar]]
<</if>>
<</replace>>
<</link>>
<</if>>
</div>
<</if>>
<</nobr>><<nobr>>
<h2>Client Offer</h2>
<img class="scene-image" src="media/locations/vestedinterest/work/waitress/wickedserving/clientproposition.jpg" alt="Client making an offer">
<p>The Client catches your attention and gestures openly toward his crotch.</p>
<<say "Client" "media/locations/vestedinterest/work/waitress/wickedserving/client.jpg" "unaffiliated">>You want another c100? Do something a little more personal for me.<</say>>
<div id="client-offer-choices">
<<if $corruption < 50>>
<<link "Agree">>
<<set _clientScene to setup.startWaitressClientSex()>>
<<if _clientScene.ok>><<goto "Waitress Client Sex">><</if>>
<</link>><br>
<</if>>
<<link "Refuse">>
<<replace "#client-offer-choices">>
<<say $mcname "media/mc/mc.jpg" "jane">>No. Absolutely not.<</say>>
[[Continue->"Vested Interest" Bar]]
<</replace>>
<</link>>
</div>
<</nobr>><div id="arthur-sex-ui">
<<arthurSexUI>>
</div><<nobr>>
<h2>Client Offer</h2>
<<if !$drunkenClientOfferPending>>
<p>The opportunity has passed.</p>
[[Continue->"Vested Interest" Bar]]
<<else>>
<img class="scene-image" src="media/locations/vestedinterest/work/waitress/wickedserving/clientproposition.jpg" alt="Client making an offer">
<p>Through the haze of alcohol, you notice a Client watching you. When he catches your eye, he gestures openly toward his crotch.</p>
<<say "Client" "media/locations/vestedinterest/work/waitress/wickedserving/client.jpg" "unaffiliated">>I have c100 for you if you're willing to make this interesting.<</say>>
<div id="drunken-client-offer-choices">
<<link "Accept">>
<<set _clientScene to setup.startDrunkenClientSex()>>
<<if _clientScene.ok>><<goto "Waitress Client Sex">><</if>>
<</link>>
<<if !$drunkenClientOfferForced>><br>
<<link "Refuse">>
<<run setup.refuseDrunkenClientOffer()>>
<<replace "#drunken-client-offer-choices">>
<<say $mcname "media/mc/mc.jpg" "jane">>No... I've had too much. I should leave.<</say>>
[[Continue->"Vested Interest" Bar]]
<</replace>>
<</link>>
<</if>>
</div>
<</if>>
<</nobr>><h2>Contracts</h2>
[[Return->"Vested Interest" Bar]]
<div id="contracts-ui">
<<contractsUI>>
</div><<nobr>>
<<set _killContract to setup.getActiveMercenaryContract()>>
<<if _killContract>>
<h2>Takeout Contract</h2>
<p>You follow Bradford's leads through alleys, crowded markets, and neglected transit levels until you finally locate <<print _killContract.targetName>>.</p>
<<if _killContract.targetImage>><img class="scene-image" @src="_killContract.targetImage" @alt="_killContract.targetName"><</if>>
<<say $mcname "media/mc/mc.jpg" "jane">>Nothing personal, just work.<</say>>
<p>You draw your <<print setup.getEquippedPlayerCombatItem("weapon").name>> and make your intention clear.</p>
<<say _killContract.targetName _killContract.targetImage "criminal">>Then stop talking and earn your pay.<</say>>
<<capture _killContract>>
<<link "Fight">>
<<startFight _killContract.targetName "" "mercenary-contract" _killContract.id>>
<</link>>
<</capture>>
<<else>>
<p class="table-order-error">You do not have an active Takeout contract.</p>
[[Return->"Vested Interest" Bar]]
<</if>>
<</nobr>><<set _drunkenClientOffer to setup.prepareDrunkenClientOffer()>>
<<if _drunkenClientOffer.triggered>><<goto "Drunken Client Offer">><</if>>
<img class="scene-image" src="media/locations/vestedinterest/drinks/sitattable.jpg" alt="">
<<nobr>>
<div id="table-order-notice"></div>
<<set _mercenaryDrinkFree to setup.hasMercenaryDrinkBenefit()>>
<<link "Order some food — c20">>
<<if setup.chargeCredits(20)>>
<<goto "Order some food">>
<<else>>
<<replace "#table-order-notice">><span class="table-order-error">You do not have enough credits.</span><</replace>>
<</if>>
<</link>><br>
<<set _drinkOrderLabel to _mercenaryDrinkFree ? "Order something to drink — Free" : "Order something to drink — c5">>
<<link _drinkOrderLabel>>
<<set _drinkOrder to setup.orderBarDrink(_mercenaryDrinkFree)>>
<<if _drinkOrder.ok>>
<<goto "Order something to drink">>
<<else>>
<<replace "#table-order-notice">><span class="table-order-error">You do not have enough credits.</span><</replace>>
<</if>>
<</link>><br>
[[Return->"Vested Interest" Bar]]
<</nobr>><<nobr>>
<<set _foodImages to [
"media/kitchen/eating/eating1.webp",
"media/kitchen/eating/eating2.webp",
"media/kitchen/eating/eating3.webp",
"media/kitchen/eating/eating4.webp",
"media/kitchen/eating/eating5.webp"
]>>
<<set _foodImage to _foodImages[random(0, _foodImages.length - 1)]>>
<<switch random(1, 3)>>
<<case 1>>
<<say $mcname "media/mc/mc.jpg" "thought">>This is actually good. I should stop judging food by the building it comes from.<</say>>
<<case 2>>
<<say $mcname "media/mc/mc.jpg" "thought">>It is nice to eat something I did not have to cook or clean up after.<</say>>
<<case 3>>
<<say $mcname "media/mc/mc.jpg" "thought">>I should make this last. Little luxuries are going to be rare for a while.<</say>>
<</switch>>
<img class="scene-image" @src="_foodImage" alt="">
[[Return->Sit at the table]]
<</nobr>><<nobr>>
<<run setup.consumeBarDrink()>><<run UIBar.update()>>
<<set _drinkImages to [
"media/locations/vestedinterest/drinks/1.webp",
"media/locations/vestedinterest/drinks/2.webp",
"media/locations/vestedinterest/drinks/3.webp",
"media/locations/vestedinterest/drinks/4.webp",
"media/locations/vestedinterest/drinks/5.webp"
]>>
<<set _drinkImage to _drinkImages[random(0, _drinkImages.length - 1)]>>
<<switch random(1, 3)>>
<<case 1>>
<<say $mcname "media/mc/mc.jpg" "thought">>Oh... that is much stronger than it tastes.<</say>>
<<case 2>>
<<say $mcname "media/mc/mc.jpg" "thought">>That tastes strange. Not bad—just strange.<</say>>
<<case 3>>
<<say $mcname "media/mc/mc.jpg" "thought">>Slowly. I do not want my first reputation in Suns End to be “the girl who cannot hold a drink.”<</say>>
<</switch>>
<img class="scene-image" @src="_drinkImage" alt="">
[[Return->Sit at the table]]
<</nobr>><<set _marketEncounter to setup.rollSlumsDistrictEncounter()>>
<<if _marketEncounter>>
<<set $pendingCombatEncounter to _marketEncounter.enemyName>>
<<set $pendingCombatEncounterFaction to _marketEncounter.faction>>
<<goto _marketEncounter.passage>>
<</if>>
<p>Market Square is less a square than a maze of patched awnings, crowded stalls, and merchants shouting over the transit lines above.</p>
<img class="scene-image" src="media/locations/marketsquare/marketsquare.jpg" alt="Market Square">
[[Thrift Stall]]
[[Gear Stall]]
[[Outside->Slums]]<h2>Thrift Stall</h2>
[[Outside->Market Square]]
<<set $shopNotice to "">>
<div id="wardrobe-ui">
<div id="clothing-shop-ui">
<<clothingShopUI "slums" "outfits">>
</div>
</div><h2>Gear Stall</h2>
[[Outside->Market Square]]
<div id="gear-stall-ui">
<<gearStallUI "weapon">>
</div><<nobr>>
<<if passage() isnot "Character Info">>
<<set $return to passage()>>
<</if>>
<</nobr>><<run setup.initializeNewStory()>>\
<<switch passage()>>\
<<case "Age Warning">>\
<<case "Start">>\
<<case "Space Port">>\
<<case "Slums Arrival">>\
<<case "Data panel">>\
<<default>>
<<nobr>>
<div class="sidebar-character-panel">
<img @class="'sidebar-character-image sidebar-character-image--' + setup.getMcDispositionBand()" @src="setup.getMcPortrait()" data-mc-portrait alt="">
<strong class="sidebar-character-name">$mcname Savino</strong>
<div class="sidebar-status-lines">
<div class="sidebar-date"><<print setup.formatGameDate()>></div>
<div>Credits: c$credits</div>
<<switch passage()>>
<<case "Character Data Panel">>
<<case "Look up">>
<<default>>
<div>Rent due: c$rentpending</div>
<</switch>>
<div>Situation: $return</div>
</div>
</div>
<<run setup.ensureWardrobeState()>>
<div class="equipment-panel">
<h3>Equipment</h3>
<div class="equipment-grid">
<<for _equipmentCategory range setup.sidebarEquipmentCategories>>
<<capture _equipmentCategory>>
<img
class="equipment-image"
@src="setup.getWornWardrobeImage(_equipmentCategory)"
@alt="setup.wardrobeLabels[_equipmentCategory]"
>
<</capture>>
<</for>>
</div>
<<if $drunkenness > 0>>
<div class="drunkenness-meter">
<div class="drunkenness-meter-label"><span>Drunkenness</span><span>$drunkenness%</span></div>
<div class="drunkenness-meter-track" role="progressbar" aria-label="Drunkenness" aria-valuemin="0" aria-valuemax="100" @aria-valuenow="$drunkenness">
<span class="drunkenness-meter-fill" @style="'width: ' + $drunkenness + '%'"> </span>
</div>
</div>
<</if>>
</div>
<<set _dominanceValue to Math.max(-100, Math.min(100, Number($dominance) || 0))>>
<div class="character-trait-panel">
<h3>Disposition</h3>
<div class="character-trait-labels">
<span>Submissive</span>
<span>Dominant</span>
</div>
<div class="character-trait-bar" role="progressbar" aria-label="Dominance" aria-valuemin="-100" aria-valuemax="100" @aria-valuenow="_dominanceValue">
<span class="character-trait-half character-trait-half--submissive">
<span class="character-trait-fill character-trait-fill--submissive" @style="'width: ' + Math.max(0, -_dominanceValue) + '%'"></span>
</span>
<span class="character-trait-half character-trait-half--dominant">
<span class="character-trait-fill character-trait-fill--dominant" @style="'width: ' + Math.max(0, _dominanceValue) + '%'"></span>
</span>
<span class="character-trait-centre"></span>
</div>
</div>
<<set _corruptionValue to Math.max(-100, Math.min(100, Number($corruption) || 0))>>
<div class="character-trait-panel character-trait-panel--corruption">
<h3>Corruption</h3>
<div class="character-trait-labels">
<span>Wicked</span>
<span>Pure</span>
</div>
<div class="character-trait-bar" role="progressbar" aria-label="Corruption" aria-valuemin="-100" aria-valuemax="100" @aria-valuenow="_corruptionValue">
<span class="character-trait-half character-trait-half--submissive">
<span class="character-trait-fill character-trait-fill--wicked" @style="'width: ' + Math.max(0, -_corruptionValue) + '%'"></span>
</span>
<span class="character-trait-half character-trait-half--dominant">
<span class="character-trait-fill character-trait-fill--pure" @style="'width: ' + Math.max(0, _corruptionValue) + '%'"></span>
</span>
<span class="character-trait-centre"></span>
</div>
</div>
<div class="sidebar-actions">
<<button "Character Info">><<goto "Character Info">><</button>>
</div>
<</nobr>>
<</switch>>\[[Support Voluntarily]]<h2>Support Voluntarily</h2>
<<nobr>>
<div class="voluntary-support-layout">
<div class="voluntary-support-copy">
<p>Thank you for checking out this page! ✨</p>
<p>I am very grateful that you checked out my free game that I develop in my free time. I already support myself from real life work, but if you would like to drop in to my Fansly and give me a voluntary follow, tip or subscription, that would be amazing. I will also look there for the feedback, requests for putting something new in the game, or change how certain thing works.</p>
<p>This game will always be free as it is my free time filler.</p>
<p>All of the subscriptions and tips will go to my sweet black cat Luna 🐈⬛ to upgrade her already prestigious lifestyle 😽.</p>
<div class="voluntary-support">
<a class="voluntary-support-button" href="https://fansly.com/Lero44" target="_blank" rel="noopener noreferrer">Visit my Fansly</a>
</div>
</div>
<figure class="voluntary-support-portrait">
<img src="media/other/luna.jpg" alt="Luna, the developer's black cat">
</figure>
</div>
<</nobr>><<widget "arthurSexLockedButton">>
<<if $arthurSexRole is "top">>
<span class="arthur-sex-locked arthur-sex-locked--submissive" data-tooltip="You are not submissive enough." tabindex="0">
<button type="button" disabled><<print _args[0]>></button>
</span>
<<else>>
<span class="arthur-sex-locked arthur-sex-locked--dominant" data-tooltip="You are not dominant enough." tabindex="0">
<button type="button" disabled><<print _args[0]>></button>
</span>
<</if>>
<</widget>>
<<widget "arthurSexUI">>
<<set _path to $arthurSexPath>>
<<set _media to setup.getCurrentArthurSexMedia()>>
<<set _children to setup.getArthurSexChildSegments(_path)>>
<div class="arthur-sex-interface">
<<if $arthurSexStarted>>
<h3>Choose Action</h3>
<div class="arthur-sex-actions arthur-sex-main-actions">
<<for _category range setup.getArthurSexCategories()>>
<<capture _category>>
<<if setup.isArthurSexPathAvailable([_category])>>
<<button setup.getArthurSexLabel(_category)>>
<<run setup.enterArthurSexCategory(_category)>>
<<replace "#arthur-sex-ui">>
<<arthurSexUI>>
<</replace>>
<</button>>
<<else>>
<<arthurSexLockedButton setup.getArthurSexLabel(_category)>>
<</if>>
<</capture>>
<</for>>
</div>
<</if>>
<<if _path.length>><h3 class="arthur-sex-path"><<print setup.getArthurSexPathLabel()>></h3><</if>>
<<if _media>>
<div class="arthur-sex-media-frame">
<<if _media.type is "image">>
<img class="arthur-sex-media" @src="_media.file" alt="">
<<else>>
<video class="arthur-sex-media" @src="_media.file" autoplay playsinline loop controls muted></video>
<</if>>
<div id="arthur-sex-speech" class="arthur-sex-speech" aria-live="off">
<img class="arthur-sex-speech-portrait" src="" alt="">
<span class="arthur-sex-speech-body">
<strong class="arthur-sex-speech-name"></strong>
<span class="arthur-sex-speech-text"></span>
</span>
</div>
</div>
<</if>>
<<if _children.length > 0 && _path.length > 0>>
<h4><<if _path[0] is "intro">>Choose Position<<else>>Options<</if>></h4>
<div class="arthur-sex-actions arthur-sex-sub-actions">
<<for _segment range _children>>
<<capture _segment>>
<<if setup.isArthurSexPathAvailable(_path.concat([_segment]))>>
<<button setup.getArthurSexLabel(_segment)>>
<<run setup.enterArthurSexChild(_segment)>>
<<replace "#arthur-sex-ui">>
<<arthurSexUI>>
<</replace>>
<</button>>
<<else>>
<<arthurSexLockedButton setup.getArthurSexLabel(_segment)>>
<</if>>
<</capture>>
<</for>>
</div>
<</if>>
<div class="arthur-sex-controls">
<<if _media>>
<<button "Another">>
<<run setup.replayArthurSexMedia()>>
<<replace "#arthur-sex-ui">>
<<arthurSexUI>>
<</replace>>
<</button>>
<</if>>
<<if _path.length > 1 && _path[0] isnot "intro">>
<<button "Back">>
<<run setup.backArthurSexPath()>>
<<replace "#arthur-sex-ui">>
<<arthurSexUI>>
<</replace>>
<</button>>
<</if>>
<<if $arthurSexOrgasm>>
<<if $sexSceneContext is "client">>
<span class="arthur-sex-finish"><<link "Finish" $sexSceneReturnPassage>><<run setup.completeWaitressClientSex()>><</link>></span>
<<elseif $sexSceneContext is "enemy">>
<span class="arthur-sex-finish"><<link "Finish" $sexSceneReturnPassage>><</link>></span>
<<else>>
<span class="arthur-sex-finish"><<link "Finish" "Talk to Arthur">><<run setup.adjustCorruption(-2)>><</link>></span>
<</if>>
<</if>>
</div>
</div>
<<if _media>>
<<run setup.queueArthurSexSpeech()>>
<<else>>
<<run setup.clearArthurSexSpeech()>>
<</if>>
<</widget>><<widget "cheatControls">>
<div id="cheat-controls" class="cheat-controls">
<div class="cheat-control-row">
<span>
<strong>Credits</strong>
<small>c<<print $credits>></small>
</span>
<<button "+100">>
<<run setup.addCredits(100)>>
<<run UIBar.update()>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
</div>
<div class="cheat-control-row">
<span>
<strong>Corruption</strong>
<small><<print $corruption>></small>
</span>
<span class="cheat-control-buttons">
<<button "−10">>
<<run setup.adjustCorruption(-10)>>
<<run UIBar.update()>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
<<button "+10">>
<<run setup.adjustCorruption(10)>>
<<run UIBar.update()>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
</span>
</div>
<div class="cheat-control-row">
<span>
<strong>Disposition</strong>
<small><<print $dominance>></small>
</span>
<span class="cheat-control-buttons">
<<button "−10">>
<<run setup.adjustDominance(-10)>>
<<run UIBar.update()>>
<<run setup.refreshMcPortraits()>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
<<button "+10">>
<<run setup.adjustDominance(10)>>
<<run UIBar.update()>>
<<run setup.refreshMcPortraits()>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
</span>
</div>
<div class="cheat-control-row">
<span>
<strong>Fines</strong>
<small>c<<print $fines>></small>
</span>
<span class="cheat-control-buttons">
<<button "−100">>
<<run setup.addFine(-100)>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
<<button "+100">>
<<run setup.addFine(100)>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
</span>
</div>
<div class="cheat-control-row">
<span>
<strong>Outstanding Balance</strong>
<small>c<<print $outstandingBalance>></small>
</span>
<span class="cheat-control-buttons">
<<button "−100">>
<<run setup.adjustOutstandingBalance(-100)>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
<<button "+100">>
<<run setup.adjustOutstandingBalance(100)>>
<<replace "#cheat-controls">><<cheatControls>><</replace>>
<</button>>
</span>
</div>
</div>
<</widget>>/% Start an encounter from any passage with: <<startFight "Enemy Name">> %/
<<widget "startFight">>
<<set _fightEnemyName to _args.length ? String(_args[0]).trim() : "">>
<<if !_fightEnemyName>>
<p class="table-order-error">The startFight command requires an enemy name.</p>
<<else>>
<<set _fightDefeatDestination to _args.length > 1 ? String(_args[1]).trim() : "">>
<<set _fightContext to _args.length > 2 ? String(_args[2]).trim() : "">>
<<set _fightContractId to _args.length > 3 ? String(_args[3]).trim() : "">>
<<set _fightEnemy to setup.startCombatEncounter(_fightEnemyName, _fightDefeatDestination, _fightContext, _fightContractId)>>
<<if _fightEnemy>>
<<goto "Fight">>
<<else>>
<p class="table-order-error">Enemy "<<print _fightEnemyName>>" could not be found in the enemy table.</p>
<</if>>
<</if>>
<</widget>>
<<widget "combatUI">>
<<run setup.ensurePlayerCombatEquipmentState()>>
<<set _combatEnemyName to _args.length && _args[0] ? _args[0] : ($combatEnemy && $combatEnemy.name ? $combatEnemy.name : "Enemy")>>
<<set _combatEnemyImage to _args.length > 1 && _args[1] ? _args[1] : ($combatEnemy && $combatEnemy.image ? $combatEnemy.image : "")>>
<<set _combatEnemyFaction to $combatEnemy && $combatEnemy.faction ? $combatEnemy.faction : "Unaffiliated">>
<<set _combatEnemyTheme to setup.getCombatEnemyKey(_combatEnemyFaction)>>
<<set _combatEnemyWeapon to $combatEnemy && $combatEnemy.weapon ? $combatEnemy.weapon : null>>
<<set _combatEnemyArmor to $combatEnemy && $combatEnemy.armor ? $combatEnemy.armor : null>>
<<set _combatMcWeapon to setup.getEquippedPlayerCombatItem("weapon")>>
<<set _combatMcArmor to setup.getEquippedPlayerCombatItem("armor")>>
<<set _combatMcStatus to setup.getCombatantStatus("mc")>>
<<set _combatEnemyStatus to setup.getCombatantStatus("enemy")>>
<<run setup.ensureCombatTurnOrder()>>
<div @class="'combat-interface combat-interface--' + _combatEnemyTheme" aria-label="Combat interface">
<header class="combat-turn-order">
<span class="combat-section-label">Turn order</span>
<div class="combat-turn-track" aria-label="Current turn order">
<<for _combatTurnIndex = 0; _combatTurnIndex < $combatTurnQueue.length; _combatTurnIndex++>>
<<set _combatTurnActor to $combatTurnQueue[_combatTurnIndex]>>
<<set _combatTurnName to _combatTurnActor is "mc" ? $mcname : _combatEnemyName>>
<<set _combatTurnImage to _combatTurnActor is "mc" ? setup.getMcPortrait() : _combatEnemyImage>>
<div @class="'combat-turn-card combat-turn-card--' + _combatTurnActor + (_combatTurnIndex === 0 ? ' is-current' : '')" @aria-label="(_combatTurnIndex === 0 ? 'Current turn: ' : 'Upcoming turn: ') + _combatTurnName" @title="_combatTurnName">
<<if _combatTurnImage>>
<img @src="_combatTurnImage" @alt="_combatTurnName">
<<else>>
<span class="combat-turn-card-placeholder" aria-hidden="true">?</span>
<</if>>
<<if _combatTurnIndex === 0>><span class="combat-turn-current">Now</span><</if>>
</div>
<</for>>
</div>
</header>
<section class="combat-nameplate combat-nameplate--mc">
<span class="combat-side-marker">Player</span>
<strong><<print $mcname>></strong>
</section>
<section @class="'combat-nameplate combat-nameplate--enemy' + (_combatEnemyName.length > 24 ? ' combat-nameplate--very-long-name' : (_combatEnemyName.length > 15 ? ' combat-nameplate--long-name' : ''))">
<span class="combat-side-marker">Opponent</span>
<span class="combat-nameplate-identity">
<strong><<print _combatEnemyName>></strong>
<small><<print _combatEnemyFaction>></small>
</span>
</section>
<section class="combat-portrait-panel combat-portrait-panel--mc" aria-label="Main character">
<img class="combat-portrait" @src="setup.getMcPortrait()" @alt="$mcname">
<<if $combatSpeech && $combatSpeech.actor is "mc">>
<div class="combat-speech combat-speech--mc" role="status">
<img @src="$combatSpeech.portrait" @alt="$combatSpeech.name">
<span><strong><<print $combatSpeech.name>></strong><q><<print $combatSpeech.text>></q></span>
</div>
<</if>>
</section>
<section class="combat-log" aria-label="Battle log" aria-live="polite">
<div class="combat-log-heading">
<strong>Battle Log</strong>
<span>Turn <<print $combatTurnNumber>></span>
</div>
<ol class="combat-log-entries">
<<for _combatLogEntry range $combatLog>>
<li @value="_combatLogEntry.turn"><span><<print _combatLogEntry.label>></span> <<print _combatLogEntry.text>></li>
<</for>>
</ol>
</section>
<section class="combat-portrait-panel combat-portrait-panel--enemy" aria-label="Enemy">
<<if _combatEnemyImage>>
<img class="combat-portrait combat-portrait--enemy" @src="_combatEnemyImage" @alt="_combatEnemyName">
<<else>>
<div class="combat-enemy-placeholder" aria-hidden="true">
<span>?</span>
<small>Enemy image</small>
</div>
<</if>>
<<if $combatSpeech && $combatSpeech.actor is "enemy">>
<div @class="'combat-speech combat-speech--enemy combat-speech--' + _combatEnemyTheme" role="status">
<<if $combatSpeech.portrait>><img @src="$combatSpeech.portrait" @alt="$combatSpeech.name"><</if>>
<span><strong><<print $combatSpeech.name>></strong><q><<print $combatSpeech.text>></q></span>
</div>
<</if>>
</section>
<section class="combat-vitals combat-vitals--mc" aria-label="Main character status">
<div class="combat-vital-row">
<span>Health</span>
<div class="combat-vital-bar" role="progressbar" aria-label="Main character health" aria-valuemin="0" @aria-valuemax="_combatMcStatus.maxHealth" @aria-valuenow="_combatMcStatus.health">
<span class="combat-vital-fill combat-vital-fill--health" @style="'width: ' + (_combatMcStatus.health / _combatMcStatus.maxHealth * 100) + '%'" ></span>
</div>
<strong><<print _combatMcStatus.health>> / <<print _combatMcStatus.maxHealth>></strong>
</div>
<div class="combat-vital-row">
<span>Stamina</span>
<div class="combat-vital-bar" role="progressbar" aria-label="Main character stamina" aria-valuemin="0" @aria-valuemax="_combatMcStatus.maxStamina" @aria-valuenow="_combatMcStatus.stamina">
<span class="combat-vital-fill combat-vital-fill--stamina" @style="'width: ' + (_combatMcStatus.stamina / _combatMcStatus.maxStamina * 100) + '%'" ></span>
</div>
<strong><<print _combatMcStatus.stamina>> / <<print _combatMcStatus.maxStamina>></strong>
</div>
</section>
<section class="combat-vitals combat-vitals--enemy" aria-label="Enemy status">
<div class="combat-vital-row">
<span>Health</span>
<div class="combat-vital-bar" role="progressbar" aria-label="Enemy health" aria-valuemin="0" @aria-valuemax="_combatEnemyStatus.maxHealth" @aria-valuenow="_combatEnemyStatus.health">
<span class="combat-vital-fill combat-vital-fill--health" @style="'width: ' + (_combatEnemyStatus.health / _combatEnemyStatus.maxHealth * 100) + '%'" ></span>
</div>
<strong><<print _combatEnemyStatus.health>> / <<print _combatEnemyStatus.maxHealth>></strong>
</div>
<div class="combat-vital-row">
<span>Stamina</span>
<div class="combat-vital-bar" role="progressbar" aria-label="Enemy stamina" aria-valuemin="0" @aria-valuemax="_combatEnemyStatus.maxStamina" @aria-valuenow="_combatEnemyStatus.stamina">
<span class="combat-vital-fill combat-vital-fill--stamina" @style="'width: ' + (_combatEnemyStatus.stamina / _combatEnemyStatus.maxStamina * 100) + '%'" ></span>
</div>
<strong><<print _combatEnemyStatus.stamina>> / <<print _combatEnemyStatus.maxStamina>></strong>
</div>
</section>
<section class="combat-equipment combat-equipment--mc" aria-label="Main character equipment">
<div><span>Weapon</span><strong><<if _combatMcWeapon>><<print _combatMcWeapon.name>><<else>>Fists<</if>></strong></div>
<div><span>Ammo</span><strong><<print setup.getCombatAmmoLabel("mc")>></strong></div>
<div><span>Armor</span><strong><<if _combatMcArmor>><<print _combatMcArmor.name>><<else>>None<</if>></strong></div>
</section>
<section class="combat-actions" aria-label="Combat actions">
<<capture _combatEnemyName _combatEnemyImage>>
<<if $combatOutcome>>
<button type="button" disabled>Fight Over</button>
<button type="button" disabled>Defend</button>
<button type="button" disabled>Rest</button>
<button type="button" disabled>Try to Escape</button>
<<elseif setup.getCurrentCombatActor() is "mc">>
<<set _combatMcMagazine to setup.getCombatMagazine("mc")>>
<<if _combatMcMagazine && _combatMcMagazine.current <= 0>>
<<button "Reload">>
<<set _combatActionResult to setup.reloadCombatWeapon("mc")>>
<<replace "#combat-ui">><<combatUI _combatEnemyName _combatEnemyImage>><</replace>>
<</button>>
<<else>>
<<button "Attack">>
<<set _combatActionResult to setup.performCombatAttack("mc")>>
<<replace "#combat-ui">><<combatUI _combatEnemyName _combatEnemyImage>><</replace>>
<</button>>
<</if>>
<<else>>
<button type="button" disabled>Enemy Turn</button>
<</if>>
<<if !$combatOutcome && setup.getCurrentCombatActor() is "mc">>
<<if _combatMcStatus.stamina >= 25>>
<<button "Defend">>
<<run setup.performCombatDefend("mc")>>
<<replace "#combat-ui">><<combatUI _combatEnemyName _combatEnemyImage>><</replace>>
<</button>>
<<else>>
<button type="button" disabled title="Not enough stamina">Defend</button>
<</if>>
<<button "Rest">>
<<run setup.performCombatRest("mc")>>
<<replace "#combat-ui">><<combatUI _combatEnemyName _combatEnemyImage>><</replace>>
<</button>>
<<button "Try to Escape">>
<<set _combatActionResult to setup.performCombatEscape("mc")>>
<<goto _combatActionResult.destination>>
<</button>>
<<elseif !$combatOutcome>>
<button type="button" disabled>Defend</button>
<button type="button" disabled>Rest</button>
<button type="button" disabled>Try to Escape</button>
<</if>>
<</capture>>
</section>
<section class="combat-equipment combat-equipment--enemy" aria-label="Enemy equipment">
<div><span>Weapon</span><strong><<if _combatEnemyWeapon>><<print _combatEnemyWeapon.name>><<else>>None<</if>></strong></div>
<div><span>Ammo</span><strong><<print setup.getCombatAmmoLabel("enemy")>></strong></div>
<div><span>Armor</span><strong><<if _combatEnemyArmor>><<print _combatEnemyArmor.name>><<else>>None<</if>></strong></div>
</section>
</div>
<<if $combatOutcome>>
<div @class="'combat-outcome combat-outcome--' + $combatOutcome.type" aria-live="assertive">
<<if $combatOutcome.type is "victory">>
<<button "Victory">><<goto $combatOutcome.destination>><</button>>
<<else>>
<<button "Defeat">>
<<set _combatDefeatDestination to $combatOutcome.destination isnot "Combat Defeat" ? $combatOutcome.destination : setup.resolveCombatDefeat("mc")>>
<<goto _combatDefeatDestination>>
<</button>>
<</if>>
</div>
<<elseif setup.getCurrentCombatActor() is "enemy">>
<<timed 1400ms>>
<<set _combatEnemyResult to setup.performCombatEnemyTurn()>>
<<replace "#combat-ui">><<combatUI>><</replace>>
<</timed>>
<</if>>
<</widget>>
<<widget "gearStallUI">>
<<run setup.ensurePlayerCombatEquipmentState()>>
<<set _gearCategory to _args.length && _args[0] is "armor" ? "armor" : "weapon">>
<<set _gearItems to setup.getGearStallItems(_gearCategory)>>
<div class="gear-stall-interface">
<nav class="gear-stall-tabs" aria-label="Gear categories">
<<if _gearCategory is "weapon">>
<button type="button" class="is-active" disabled>Weapons</button>
<<else>>
<<button "Weapons">><<replace "#gear-stall-ui">><<gearStallUI "weapon">><</replace>><</button>>
<</if>>
<<if _gearCategory is "armor">>
<button type="button" class="is-active" disabled>Armor</button>
<<else>>
<<button "Armor">><<replace "#gear-stall-ui">><<gearStallUI "armor">><</replace>><</button>>
<</if>>
</nav>
<div class="gear-stall-list">
<<for _gearItem range _gearItems>>
<<capture _gearItem _gearCategory>>
<<set _gearOwned to setup.ownsPlayerCombatItem(_gearCategory, _gearItem.name)>>
<<set _gearCost to setup.normalizeMoney(_gearItem.cost, 0, false)>>
<<set _gearBuyLabel to "Buy — c" + _gearCost>>
<article @class="'gear-stall-item' + (_gearOwned ? ' is-owned' : '')">
<div class="gear-stall-item-details">
<strong><<print _gearItem.name>></strong>
<<if _gearCategory is "weapon">>
<small>Level <<print _gearItem.level>> · Damage <<print _gearItem.damage>> · <<if setup.isRangedCombatWeapon(_gearItem)>>Ranged · Magazine <<print _gearItem.magazineSize>> · <<print _gearItem.ammoType>><<else>>Melee<</if>></small>
<<else>>
<small>Level <<print _gearItem.level>> · Defence <<print _gearItem.defence>>%</small>
<</if>>
</div>
<div class="gear-stall-item-purchase">
<<if _gearOwned>>
<button type="button" disabled>Owned</button>
<<elseif !setup.canAfford(_gearCost)>>
<button type="button" disabled title="Not enough credits"><<print _gearBuyLabel>></button>
<<else>>
<<button _gearBuyLabel>>
<<run setup.purchasePlayerCombatItem(_gearCategory, _gearItem.name)>>
<<run UIBar.update()>>
<<replace "#gear-stall-ui">><<gearStallUI _gearCategory>><</replace>>
<</button>>
<</if>>
</div>
</article>
<</capture>>
<</for>>
</div>
</div>
<</widget>>
<<widget "combatEquipmentUI">>
<<run setup.ensurePlayerCombatEquipmentState()>>
<div class="combat-loadout-interface">
<section class="combat-loadout-section">
<header>
<h3>Weapon</h3>
<span>Equipped: <<print $combatEquipment.weapon>></span>
</header>
<div class="combat-loadout-list">
<<for _combatLoadoutItem range setup.getOwnedPlayerCombatEquipment("weapon")>>
<<capture _combatLoadoutItem>>
<article @class="'combat-loadout-card' + ($combatEquipment.weapon === _combatLoadoutItem.name ? ' is-equipped' : '')">
<div>
<strong><<print _combatLoadoutItem.name>></strong>
<small>Damage: <<print _combatLoadoutItem.damage>> · <<if setup.isRangedCombatWeapon(_combatLoadoutItem)>>Ranged · Magazine: <<print _combatLoadoutItem.magazineSize>> · Ammo: <<print _combatLoadoutItem.ammoType>><<else>>Melee<</if>></small>
</div>
<<if $combatEquipment.weapon === _combatLoadoutItem.name>>
<button type="button" disabled>Equipped</button>
<<else>>
<<button "Equip">>
<<run setup.equipPlayerCombatItem("weapon", _combatLoadoutItem.name)>>
<<replace "#combat-loadout-ui">><<combatEquipmentUI>><</replace>>
<</button>>
<</if>>
</article>
<</capture>>
<</for>>
</div>
</section>
<section class="combat-loadout-section">
<header>
<h3>Armor</h3>
<span>Equipped: <<print $combatEquipment.armor>></span>
</header>
<div class="combat-loadout-list">
<<for _combatLoadoutItem range setup.getOwnedPlayerCombatEquipment("armor")>>
<<capture _combatLoadoutItem>>
<article @class="'combat-loadout-card' + ($combatEquipment.armor === _combatLoadoutItem.name ? ' is-equipped' : '')">
<div>
<strong><<print _combatLoadoutItem.name>></strong>
<small>Defence: <<print _combatLoadoutItem.defence>>%</small>
</div>
<<if $combatEquipment.armor === _combatLoadoutItem.name>>
<button type="button" disabled>Equipped</button>
<<else>>
<<button "Equip">>
<<run setup.equipPlayerCombatItem("armor", _combatLoadoutItem.name)>>
<<replace "#combat-loadout-ui">><<combatEquipmentUI>><</replace>>
<</button>>
<</if>>
</article>
<</capture>>
<</for>>
</div>
</section>
</div>
<</widget>><<widget "contractsUI">>
<<set _contractState to setup.ensureMercenaryContractState()>>
<<set _activeContract to setup.getActiveMercenaryContract()>>
<div class="contracts-interface">
<nav class="contracts-tabs" aria-label="Contract categories">
<button type="button" class="is-active" disabled>Takeout</button>
</nav>
<div class="contracts-grid">
<<for _contract range _contractState.offers>>
<<capture _contract>>
<article @class="'contract-card contract-card--' + _contract.status + (_contractState.active === _contract.id ? ' is-active' : '')">
<<if _contract.targetImage>>
<img @src="_contract.targetImage" @alt="_contract.targetName">
<</if>>
<div class="contract-card-details">
<strong><<print _contract.title>></strong>
<span>Payment: c<<print _contract.price>></span>
</div>
<div class="contract-card-actions">
<<if _contract.status === "done">>
<button type="button" class="contract-status-done" disabled>Done</button>
<<elseif _contract.status === "dropped">>
<button type="button" disabled>Dropped</button>
<<elseif _contract.status === "expired">>
<button type="button" disabled>Expired</button>
<<elseif _contractState.active === _contract.id>>
<button type="button" disabled>Active</button>
<<set _contractDropLabel to "Drop — penalty c" + setup.getMercenaryContractPenalty(_contract)>>
<<button _contractDropLabel>>
<<run setup.dropMercenaryContract("manual")>>
<<replace "#contracts-ui">><<contractsUI>><</replace>>
<</button>>
<<elseif _activeContract>>
<button type="button" disabled title="Only one contract may be active">Contract active</button>
<<else>>
<<button "Accept">>
<<run setup.acceptMercenaryContract(_contract.id)>>
<<replace "#contracts-ui">><<contractsUI>><</replace>>
<</button>>
<</if>>
</div>
</article>
<</capture>>
<</for>>
</div>
<<if !_contractState.offers.length>>
<p class="table-order-error">No Criminal targets are available for Takeout contracts.</p>
<</if>>
</div>
<</widget>><<widget "wardrobeUI">>
<<run setup.ensureWardrobeState()>>
<<set _activeCategory to _args[0] || "outfits">>
<<set _ownedStyles to setup.getOwnedWardrobeStyles(_activeCategory)>>
<<set _requestedStyle to _args.length > 1 ? _args[1] : null>>
<<if _requestedStyle is null || !_ownedStyles.includes(_requestedStyle)>>
<<set _activeStyle to _ownedStyles.length > 0 ? _ownedStyles[0] : null>>
<<else>>
<<set _activeStyle to _requestedStyle>>
<</if>>
<div class="wardrobe-tabs">
<<for _category range setup.wardrobeCategories>>
<<capture _category>>
<<button setup.wardrobeLabels[_category]>>
<<replace "#wardrobe-ui">>
<<wardrobeUI _category>>
<</replace>>
<</button>>
<</capture>>
<</for>>
</div>
<h3><<print setup.wardrobeLabels[_activeCategory]>></h3>
<<if _ownedStyles.length > 0>>
<div class="wardrobe-tabs wardrobe-subcategory-tabs">
<<for _style range _ownedStyles>>
<<capture _style _activeCategory>>
<<button setup.getWardrobeStyleLabel(_style)>>
<<replace "#wardrobe-ui">>
<<wardrobeUI _activeCategory _style>>
<</replace>>
<</button>>
<</capture>>
<</for>>
</div>
<<else>>
<p class="wardrobe-empty">No clothing owned in this category.</p>
<</if>>
<div class="wardrobe-grid">
<!-- The None option -->
<<capture _activeCategory _activeStyle>>
<div class="wardrobe-card">
<img
class="wardrobe-image wardrobe-none-image"
loading="lazy"
@src="setup.getWardrobeNoneImage(_activeCategory)"
alt="Nothing equipped"
>
<div class="wardrobe-item-name">
None
</div>
<<if $worn[_activeCategory] is null>>
<span class="wardrobe-equipped">
Equipped
</span>
<<else>>
<<button "Select">>
<<set $worn[_activeCategory] to null>>
<<run UIBar.update()>>
<<replace "#wardrobe-ui">>
<<wardrobeUI _activeCategory _activeStyle>>
<</replace>>
<</button>>
<</if>>
</div>
<</capture>>
<!-- Owned clothing items in the active subcategory -->
<<for _item range setup.getOwnedWardrobeItemsByStyle(_activeCategory, _activeStyle)>>
<<capture _item _activeCategory _activeStyle>>
<div class="wardrobe-card">
<img
class="wardrobe-image"
loading="lazy"
@src="_item.image"
@alt="_item.name"
>
<div class="wardrobe-item-name">
<<print _item.name>>
</div>
<<if $worn[_activeCategory] is _item.id>>
<span class="wardrobe-equipped">
Equipped
</span>
<<else>>
<<button "Wear">>
<<set $worn[_activeCategory] to _item.id>>
<<run UIBar.update()>>
<<replace "#wardrobe-ui">>
<<wardrobeUI _activeCategory _activeStyle>>
<</replace>>
<</button>>
<</if>>
</div>
<</capture>>
<</for>>
</div>
<div class="wardrobe-global-actions">
<<capture _activeCategory _activeStyle>>
<<button "Remove all clothes">>
<<for _category range setup.wardrobeCategories>>
<<set $worn[_category] to null>>
<</for>>
<<run UIBar.update()>>
<<replace "#wardrobe-ui">>
<<wardrobeUI _activeCategory _activeStyle>>
<</replace>>
<</button>>
<</capture>>
</div>
<</widget>>
<<widget "clothingShopUI">>
<<run setup.ensureWardrobeState()>>
<<set _shopId to _args[0] || "slums">>
<<set _shopCategories to setup.getClothingShopCategories(_shopId)>>
<<set _activeCategory to _args[1] || _shopCategories[0]>>
<<if !_shopCategories.includes(_activeCategory)>>
<<set _activeCategory to _shopCategories[0]>>
<</if>>
<<set _styles to setup.getClothingShopStyles(_shopId, _activeCategory)>>
<<set _requestedStyle to _args.length > 2 ? _args[2] : null>>
<<if _requestedStyle is null || !_styles.includes(_requestedStyle)>>
<<set _activeStyle to _styles[0] || "">>
<<else>>
<<set _activeStyle to _requestedStyle>>
<</if>>
<div class="wardrobe-tabs">
<<for _category range _shopCategories>>
<<capture _shopId _category>>
<<button setup.wardrobeLabels[_category]>>
<<replace "#clothing-shop-ui">>
<<clothingShopUI _shopId _category>>
<</replace>>
<</button>>
<</capture>>
<</for>>
</div>
<h3><<print setup.wardrobeLabels[_activeCategory]>></h3>
<div class="wardrobe-tabs wardrobe-subcategory-tabs">
<<for _style range _styles>>
<<capture _shopId _style _activeCategory>>
<<button `setup.getClothingShopStyleLabel(_shopId, _activeCategory, _style)`>>
<<replace "#clothing-shop-ui">>
<<clothingShopUI _shopId _activeCategory _style>>
<</replace>>
<</button>>
<</capture>>
<</for>>
</div>
<<if $shopNotice>>
<p class="shop-feedback">$shopNotice</p>
<</if>>
<div class="wardrobe-grid">
<<for _item range setup.getClothingShopItems(_shopId, _activeCategory, _activeStyle)>>
<<capture _shopId _item _activeCategory _activeStyle>>
<<set _purchaseLockMessage to setup.getWardrobePurchaseLockMessage(_item)>>
<div class="wardrobe-card">
<img
class="wardrobe-image"
loading="lazy"
@src="_item.image"
@alt="_item.name"
>
<div class="wardrobe-item-name">
<<print _item.name>>
</div>
<div class="shop-item-price">
c<<print _item.price>>
</div>
<<if $ownedClothes[_activeCategory].includes(_item.id)>>
<span class="wardrobe-equipped">Owned</span>
<<elseif _purchaseLockMessage>>
<span class="shop-buy-lock passage-link-disabled--tooltip" @data-tooltip="_purchaseLockMessage" @aria-label="_purchaseLockMessage" tabindex="0">
<button class="shop-buy-disabled" type="button" disabled aria-hidden="true">
Buy — c<<print _item.price>>
</button>
</span>
<<else>>
<<set _buyLabel to "Buy — c" + _item.price>>
<<button _buyLabel>>
<<set _purchase to setup.buyClothingShopItem(_shopId, _activeCategory, _item.id)>>
<<if _purchase.ok>>
<<set $shopNotice to "Purchased " + _item.name + " for c" + _item.price + ".">>
<<run UIBar.update()>>
<<elseif _purchase.reason is "funds">>
<<set $shopNotice to "Not enough credits for " + _item.name + ".">>
<<elseif _purchase.reason is "corruption">>
<<set $shopNotice to "Your Corruption is too high to buy " + _item.name + ".">>
<<else>>
<<set $shopNotice to "That item could not be purchased.">>
<</if>>
<<replace "#clothing-shop-ui">>
<<clothingShopUI _shopId _activeCategory _activeStyle>>
<</replace>>
<</button>>
<</if>>
</div>
<</capture>>
<</for>>
</div>
<</widget>>