Unit Scenes of NineteenEightyFour
by Dom with pixel graphics by Luke: both Y9 Age ~14
In order to compile this code with Version 3.0 of Smart Mobile Studio, change all instances of Canvas.Font to Canvas.FontStyle.
unit Scenes; { Copyright (c) 2017 Dom with pixel art by Luke Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License, as described at http://www.apache.org/licenses/ and http://www.pp4s.co.uk/licenses/ } interface uses System.Types, SmartCL.System, SmartCL.Components, SmartCL.Application, SmartCL.Game, SmartCL.GameApp, SmartCL.Graphics, SmartCL; procedure Intro(Canvas : TW3Canvas); procedure VictMA(Canvas : TW3Canvas); procedure VictMAIn(Canvas : TW3Canvas); procedure Lift(Canvas : TW3Canvas); procedure BB(Canvas : TW3Canvas); procedure Flat(Canvas : TW3Canvas); procedure Diary(Canvas : TW3Canvas); procedure Hangings(Canvas : TW3Canvas); procedure Work(Canvas : TW3Canvas); procedure WorkForever(Canvas : TW3Canvas); procedure Corridor(Canvas : TW3Canvas); procedure Bush(Canvas : TW3Canvas); procedure Shop(Canvas : TW3Canvas); procedure Street(Canvas : TW3Canvas); procedure HighParty(Canvas : TW3Canvas); procedure Capture(Canvas : TW3Canvas); procedure MiniLuv(Canvas : TW3Canvas); procedure Room101(Canvas : TW3Canvas); procedure Text(Canvas : TW3Canvas); //add text screen with timer and using NextScene procedure Hung(Canvas : TW3Canvas); procedure Shot(Canvas : TW3Canvas); procedure Tortured(Canvas : TW3Canvas); implementation uses Main; procedure Text(Canvas : TW3Canvas); begin if Bypass = False then begin if Insanity <= 0 then begin Insanity := 0; NextScene := "Shot"; Ln1 := "The thought police are"; Ln2 := "alerted of your insanity."; Ln3 := ""; Ln4 := ""; end else if Suspicion <= 0 then begin Suspicion := 0; NextScene := "Tortured"; Ln1 := "The thought police capture"; Ln2 := "you, you should have further concealed"; Ln3 := "your actions of rebellion."; Ln4 := ""; end; end; if NextScene = "End" then begin Ln1 := "Thanks for playing!"; Ln2 := "Refresh the page to"; Ln3 := "try again!"; Ln4 := ""; end; if Insanity >=100 then begin Insanity := 100; end; if Suspicion >=100 then begin Suspicion := 100; end; InsanityAdd := 0; SuspicionAdd := 0; Canvas.FillStyle := "black"; Canvas.FillRectF(0,0,ScreenW,ScreenH); Canvas.FillStyle := 'white'; Canvas.Font := '40px Visitor'; Canvas.FillText(Ln1,HalfW - 300,HalfH - 40); Canvas.FillText(Ln2,HalfW - 300,HalfH); Canvas.FillText(Ln3,HalfW - 300,HalfH + 40); Canvas.FillText(Ln4,HalfW - 300,HalfH + 80); if MouseClickedElsewhere = True then begin if NextScene = "End" then else begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; end; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := NextScene; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure VictMAIn(Canvas : TW3Canvas); begin Canvas.DrawImageF(VictoryMansionsInside.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("After going inside you are",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("presented with a lift [A] and a stairwell [B].",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Lift"; Ln1 := "You decide your"; Ln2 := "varicose ulcer will not"; Ln3 := "manage the climb."; Ln4 := ""; InsanityAdd := -10; SuspicionAdd := -10; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "BB"; Ln1 := "The stairs it is. The"; Ln2 := "lift is always off"; Ln3 := "anyway."; Ln4 := ""; InsanityAdd := 10; SuspicionAdd := 10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure VictMA(Canvas : TW3Canvas); begin Canvas.DrawImageF(VictoryMansions.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("You arrive at the Victory Mansions,",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("Press either [A] or [B] to go in.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "VictMAIn"; Ln1 := "When you enter you notice"; Ln2 := "the strong stench of"; Ln3 := "cabbage and old rag mats."; Ln4 := ""; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); //fix this end; end; procedure Intro(Canvas : TW3Canvas); begin Canvas.FillStyle := 'white'; Canvas.Font := '40px Visitor'; Canvas.FillText("1984 Inspired Game",HalfW - 300,HalfH - 40); Canvas.FillText("Game developed by Dom",HalfW - 300,HalfH); Canvas.FillText("Pixel Art by Luke",HalfW - 300,HalfH + 40); Canvas.FillText("Click anywhere to continue",HalfW - 300,HalfH + 80); if MouseClickedElsewhere = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "VictMA"; TransitionWidthOut := 0; TransitionOut := False; end; end; procedure Lift(Canvas : TW3Canvas); begin Canvas.DrawImageF(Elevator.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("The lift is off as usual...",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("The thought police are bound to note down this",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("behavior. Press [A] or [B] to use the stairs.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "BB"; Ln1 := "Back to the stairs"; Ln2 := "it is. You take your"; Ln3 := "time, resting on each"; Ln4 := "floor."; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure BB(Canvas : TW3Canvas); begin Canvas.DrawImageF(BigB.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A Big Brother poster looms in front of you.",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("Press [A] to spit or [B] to continue.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Shot"; Ln1 := "That was an unwise"; Ln2 := "action. You are a"; Ln3 := "dead man."; Ln4 := ""; Bypass := True; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Flat"; Ln1 := "With a small nod"; Ln2 := "you hurry on"; Ln3 := "up to your flat."; Ln4 := ""; InsanityAdd := -10; SuspicionAdd := 10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Flat(Canvas : TW3Canvas); begin Canvas.DrawImageF(DiaryEmpt.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("Writing a diary is illegal",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("but you feel the urge to express your thoughts.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("Start writing [A] or attend the hangings [B].",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Diary"; Ln1 := "You take out a"; Ln2 := "leaking fountain pen"; Ln3 := "and spill your thoughts"; Ln4 := "onto the rough pages."; InsanityAdd := 10; SuspicionAdd := -20; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Hangings"; Ln1 := "Political criminals"; Ln2 := "are getting hanged in the town"; Ln3 := "center... It cant be good for"; Ln4 := "your sanity to attend..."; InsanityAdd := -20; SuspicionAdd := 10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Diary(Canvas : TW3Canvas); begin Canvas.DrawImageF(DiaryFull.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("Time to head back to work",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("press [A] or [B] to proceed to the",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("Ministry of Truth.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Work"; Ln1 := "The 'Ministry of Truth'"; Ln2 := "such satirical humour"; Ln3 := "the party has."; Ln4 := ""; InsanityAdd := -10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Hangings(Canvas : TW3Canvas); begin Canvas.DrawImageF(AtHangings.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("Over 350 prisoners are being hanged today.",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("you only have the stomach to watch 2. Press",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("[A] or [B] to head to work.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Work"; Ln1 := "The 'Ministry of Truth'"; Ln2 := "such satirical humour"; Ln3 := "the party has."; Ln4 := ""; InsanityAdd := -10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Work(Canvas : TW3Canvas); //MINIGAME TIIIIIIIIIIIIIIIIIMMMMMMMMMMMEEEEE begin Canvas.DrawImageF(Office.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A mound of paper has arrived at your desk.",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("Censor media you deem inapropriate. Press [A] or [B]",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("to contine with your job.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Corridor"; Ln1 := "Finally your break arrives and"; Ln2 := "you head for the toilet."; Ln3 := ""; Ln4 := ""; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure WorkForever(Canvas : TW3Canvas); //MINIGAME TIIIIIIIIIIIIIIIIIMMMMMMMMMMMEEEEE begin Canvas.DrawImageF(Office.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("^&*D^Sfhsfisyf8sfhsdfhs8ffsdf",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("fbisgfyusdgfyufgYGFYUSGuydsgbyfgsud",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if Timer > 10 then begin Insanity -=1; Timer := 0; end else Timer +=1; if Insanity <= 0 then begin Bypass := True; Insanity := 0; TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Hung"; Ln1 := "You vandalize your office,"; Ln2 := "smashing up the desk and"; Ln3 := "beating up anyone that comes in."; Ln4 := "Eventually they slip a noose around you."; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Corridor(Canvas : TW3Canvas); begin Canvas.DrawImageF(Hallway.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("The woman you've spotted following",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("you gives you a note: 'I love you'.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("Either report her [A] or meet [B].",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "WorkForever"; Ln1 := "Months pass, nothing changes."; Ln2 := "You slowly go insane."; Ln3 := ""; Ln4 := ""; SuspicionAdd := 20; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Bush"; Ln1 := "You organise a secret trip"; Ln2 := "to the country."; Ln3 := ""; Ln4 := ""; InsanityAdd := 10; SuspicionAdd := -20; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Bush(Canvas : TW3Canvas); begin Canvas.DrawImageF(InBush.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("Things proceed quickly, do the",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("deed for the rebellion [A] or back out [B].",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Shop"; Ln1 := "You head back to the"; Ln2 := "city by train."; Ln3 := ""; Ln4 := ""; InsanityAdd := 10; SuspicionAdd := -20; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Shop"; Ln1 := "You head back to the"; Ln2 := "city by train."; Ln3 := ""; Ln4 := ""; InsanityAdd := -10; SuspicionAdd := 10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Shop(Canvas : TW3Canvas); begin Canvas.DrawImageF(ShopRoom.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A shop is advertising a room to rent",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("use it as a safe house [A] or [B] just",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("meet in your flat.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Street"; Ln1 := "After reasearch, you"; Ln2 := "find links to the"; Ln3 := "'Brotherhood', a secret"; Ln4 := "organization against the party."; InsanityAdd := 10; SuspicionAdd := -10; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Street"; Ln1 := "After reasearch, you"; Ln2 := "find links to the"; Ln3 := "'Brotherhood', a secret"; Ln4 := "organization against the party."; InsanityAdd := -10; SuspicionAdd := 10; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn += 20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Street(Canvas : TW3Canvas); begin if RandomImg <= 0 then begin if ImgBool = True then ImgBool := False else ImgBool := True; RandomImg := RandomInt(100); end; RandomImg -=1; if ImgBool = True then Canvas.DrawImageF(Street2.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height) else Canvas.DrawImageF(Street1.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("You arrive at the location of",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("the 'Brotherhood', knock on the door [A]",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("or back out [B].",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if MouseClickedOne = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "HighParty"; Ln1 := "You knock and O'Brien, a"; Ln2 := "high party member in the"; Ln3 := "'Brotherhood' ushers you"; Ln4 := "inside."; InsanityAdd := 10; SuspicionAdd := -20; end; if MouseClickedTwo = True then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "MiniLuv"; Ln1 := "You begin to walk away,"; Ln2 := "Julia follows. As soon as you step"; Ln3 := "into the main street you are blinded."; Ln4 := "Arms drag you to the MiniLuv"; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Insanity := Insanity + InsanityAdd; Suspicion := Suspicion + SuspicionAdd; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure HighParty(Canvas : TW3Canvas); begin Canvas.DrawImageF(HPH.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("O'Brien turns off his telescreen and explains",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("the Brotherhood. A book is promised to arrive in the",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("coming days. Press [A] or [B] to leave.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Capture"; Ln1 := "You return to your"; Ln2 := "room, you sense a strange"; Ln3 := "feeling that you are being"; Ln4 := "watched."; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; RandomImg := 500; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Capture(Canvas : TW3Canvas); begin if RandomImg >= 0 then begin Canvas.DrawImageF(Room1.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("You lie waiting for the 'book to arrive",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("admiring the art on the wall.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); end else begin Canvas.DrawImageF(Room2.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); PlayCrash += 1; Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("The painting crashes to the floor,",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("showing the telescreen that was concealed all",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("along. Press [A] or [B] to continue.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); end; if PlayCrash = 1 then begin Crash.currentTime := 0; Crash.Play; end; RandomImg -=1; Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); //Canvas.FillText("",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "MiniLuv"; Ln1 := "You are dragged into a small"; Ln2 := "cell with other political"; Ln3 := "criminals, they are all rather"; Ln4 := "quiet."; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure MiniLuv(Canvas : TW3Canvas); begin Canvas.DrawImageF(MiniLuvCell.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("You are locked in a dark cell below the",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("Ministry of Love for Days... Weeks... Months...",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("Press [A] or [B] to continue.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "Room101"; Ln1 := ""; Ln2 := "2 + 2 = 5"; Ln3 := ""; Ln4 := ""; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Room101(Canvas : TW3Canvas); begin Canvas.DrawImageF(Room1oh1.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A door stands alone, embossed with",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("the number 101. You can hear the screams.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("from the previous inhabitant.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "End"; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Hung(Canvas : TW3Canvas); begin Canvas.DrawImageF(Hanged.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("With a crack your useless life",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("comes to an entertaining end.",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "End"; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Bypass := True; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Shot(Canvas : TW3Canvas); begin Canvas.DrawImageF(Gun.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A gun swings out while you",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("are walking down a back street. You don't",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("stand a chance.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "End"; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Bypass := True; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; procedure Tortured(Canvas : TW3Canvas); begin Canvas.DrawImageF(Room1oh1.Handle, HalfW - Width div 2, HalfH - Height div 2, Width, Height); Canvas.FillStyle := 'grey'; Canvas.FillRectF(650 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Insanity); Canvas.FillRectF(740 + (HalfW - Width div 2),50 + (HalfH - Height div 2),40,Suspicion); Canvas.Font := '25px Visitor'; Canvas.FillStyle := 'black'; Canvas.FillText("A high party member is given the",185 + (HalfW - Width div 2), 460+ (HalfH - Height div 2)); Canvas.FillText("job of torturing you. He overestimates your",100 + (HalfW - Width div 2), 480+ (HalfH - Height div 2)); Canvas.FillText("chance of survival.",115 + (HalfW - Width div 2), 500+ (HalfH - Height div 2)); if (MouseClickedOne = True) or (MouseClickedTwo = True) then begin TransitionOut := True; Shwoosh.currentTime := 0; Shwoosh.Play; NextScene := "End"; end; if TransitionOut = True then begin TransitionWidthOut +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(0,0,TransitionWidthOut,ScreenH); end; if TransitionWidthOut > ScreenW then begin Scene := "Text"; TransitionWidthIn := 0; TransitionWidthOut := 0; TransitionOut := False; Bypass := True; end; if TransitionWidthIn < ScreenW then begin TransitionWidthIn +=20; Canvas.FillStyle := 'black'; Canvas.FillRectF(TransitionWidthIn,0,ScreenW,ScreenH); end; end; end.