diff --git a/DXRBalance/DeusEx/Classes/BalancePlayer.uc b/DXRBalance/DeusEx/Classes/BalancePlayer.uc index 9577aebd2..1921152a1 100644 --- a/DXRBalance/DeusEx/Classes/BalancePlayer.uc +++ b/DXRBalance/DeusEx/Classes/BalancePlayer.uc @@ -968,3 +968,17 @@ state PlayerWalking function PlayerPawnProcessMove(float DeltaTime, vector NewAccel, eDodgeDir DodgeMove, rotator DeltaRot) { } + +function PickupNanoKey(NanoKey newKey) +{ + local string msg; + if (newKey.keyID==''){ + msg = "You just picked up a key ("$newKey$") without a key ID ("$newKey.Description$")! Report this to the devs, we're looking for this! Where did you find me?"; + if (!class'DXRVersion'.static.VersionIsStable()){ + ClientMessage(msg); + } else { + log(msg); + } + } + Super.PickupNanoKey(newKey); +} diff --git a/DXRCore/DeusEx/Classes/DXRInfo.uc b/DXRCore/DeusEx/Classes/DXRInfo.uc index e78494132..733b33308 100644 --- a/DXRCore/DeusEx/Classes/DXRInfo.uc +++ b/DXRCore/DeusEx/Classes/DXRInfo.uc @@ -237,6 +237,14 @@ function bool OnTitleScreen() return dxr.LocalURL=="DX" || dxr.LocalURL=="DXONLY"; } +function bool OnEndgameMap() +{ + local DXRando dxr; + dxr = class'DXRando'.default.dxr; + if(dxr == None) return true; + return dxr.dxInfo.missionNumber == 99; +} + final function int SystemTime() { return _SystemTime(Level); diff --git a/DXRCore/DeusEx/Classes/DXRMenuSetupRando.uc b/DXRCore/DeusEx/Classes/DXRMenuSetupRando.uc index 8e53b6034..bf4cb567f 100644 --- a/DXRCore/DeusEx/Classes/DXRMenuSetupRando.uc +++ b/DXRCore/DeusEx/Classes/DXRMenuSetupRando.uc @@ -80,9 +80,9 @@ function BindControls(optional string action) NewMenuItem("Camera Mode", "What camera mode should be used"); EnumOption("First Person", 0, f.moresettings.camera_mode); EnumOption("Third Person", 1, f.moresettings.camera_mode); -#ifdef vanilla - EnumOption("Fixed Camera", 2, f.moresettings.camera_mode); -#endif + if(#defined(vanilla || revision)) { + EnumOption("Fixed Camera", 2, f.moresettings.camera_mode); + } NewMenuItem("Splits Overlay", "Splits and total game time overlay"); EnumOption("Don't Show", 0, f.moresettings.splits_overlay); diff --git a/DXRCore/DeusEx/Classes/DXRVersion.uc b/DXRCore/DeusEx/Classes/DXRVersion.uc index b5e1eb972..2683dd682 100644 --- a/DXRCore/DeusEx/Classes/DXRVersion.uc +++ b/DXRCore/DeusEx/Classes/DXRVersion.uc @@ -4,13 +4,13 @@ simulated static function CurrentVersion(optional out int major, optional out in { major=3; minor=3; - patch=0; - build=6;//build can't be higher than 99 + patch=1; + build=0;//build can't be higher than 99 } simulated static function bool VersionIsStable() { - return true; + return false; } simulated static function string VersionString(optional bool full) @@ -18,7 +18,7 @@ simulated static function string VersionString(optional bool full) local int major,minor,patch,build; local string status; - status = ""; + status = "Alpha"; if(status!="") { status = " " $ status; diff --git a/DXRFixes/DeusEx/Classes/Animal.uc b/DXRFixes/DeusEx/Classes/Animal.uc index 2c212dc05..87897970e 100644 --- a/DXRFixes/DeusEx/Classes/Animal.uc +++ b/DXRFixes/DeusEx/Classes/Animal.uc @@ -30,6 +30,10 @@ function EndPetting(optional bool bInterrupted) if (!bHasBeenPet && !bInterrupted){ bHasBeenPet=True; class'DXREvents'.static.MarkBingo("PetAnimal_"$Class.Name); + + if (BindName!=Default.BindName){ + class'DXREvents'.static.MarkBingo("PetAnimal_BindName_"$BindName); + } } camera.player().bBlockAnimations=False; camera.player().AnimEnd(); //Kicks the appropriate normal animations off again diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM02.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM02.uc index 5840f1ca1..45f189541 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM02.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM02.uc @@ -30,6 +30,10 @@ function PreFirstEntryMapFixes() local DynamicTeleporter dtel; local DynamicLight light; local DeusExDecoration s; + local Smuggler smug; +#ifdef revision + local JockHelicopter jockheli; +#endif #ifdef injections local #var(prefix)Newspaper np; @@ -49,6 +53,21 @@ function PreFirstEntryMapFixes() switch (dxr.localURL) { case "02_NYC_BATTERYPARK": + + foreach AllActors(class'DeusExMover', d) { + if( d.Name == 'DeusExMover19' ) { + d.KeyIDNeeded = 'ControlRoomDoor'; + } + } + + if(!dxr.flags.IsZeroRando()) { + k = Spawn(class'#var(prefix)NanoKey',,, vectm(1574.209839, -238.380142, 342)); + k.KeyID = 'ControlRoomDoor'; + k.Description = "Control Room Door Key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(k); + } + if (VanillaMaps){ foreach AllActors(class'BarrelAmbrosia', ambrosia) { foreach RadiusActors(class'Trigger', t, 16, ambrosia.Location) { @@ -56,27 +75,9 @@ function PreFirstEntryMapFixes() t.SetCollisionSize(t.CollisionRadius*2, t.CollisionHeight*2); } } - foreach AllActors(class'#var(prefix)MapExit',exit,'Boat_Exit'){break;} - foreach AllActors(class'NYPoliceBoat',b) { - b.BindName = "NYPoliceBoat"; - b.ConBindEvents(); - class'DXRTeleporterHoverHint'.static.Create(self, "", b.Location, b.CollisionRadius+5, b.CollisionHeight+5, exit,, true); - } - foreach AllActors(class'DeusExMover', d) { - if( d.Name == 'DeusExMover19' ) { - d.KeyIDNeeded = 'ControlRoomDoor'; - } - } foreach AllActors(class'Terrorist',nsf,'ShantyTerrorist'){ nsf.Tag = 'ShantyTerrorists'; //Restores voice lines when NSF still alive (still hard to have happen though) } - if(!dxr.flags.IsZeroRando()) { - k = Spawn(class'#var(prefix)NanoKey',,, vectm(1574.209839, -238.380142, 339.215179)); - k.KeyID = 'ControlRoomDoor'; - k.Description = "Control Room Door Key"; - if(dxr.flags.settings.keysrando > 0) - GlowUp(k); - } fg=Spawn(class'#var(prefix)FishGenerator',,, vectm(-1274,-3892,177));//Near Boat dock fg.ActiveArea=2000; @@ -93,6 +94,13 @@ function PreFirstEntryMapFixes() exit.DestMap="03_NYC_UNATCOIsland"; } + foreach AllActors(class'#var(prefix)MapExit',exit,'Boat_Exit'){break;} + foreach AllActors(class'NYPoliceBoat',b) { + b.BindName = "NYPoliceBoat"; + b.ConBindEvents(); + class'DXRTeleporterHoverHint'.static.Create(self, "", b.Location, b.CollisionRadius+5, b.CollisionHeight+5, exit,, true); + } + break; case "02_NYC_WAREHOUSE": //Warehouse is basically the same between Vanilla and Revision (Just some extra hallways and paths) @@ -127,16 +135,6 @@ function PreFirstEntryMapFixes() hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); hoverHint.SetBaseActor(jock); - foreach AllActors(class'#var(prefix)MapExit',exit,'ToStreet'){break;} - foreach AllActors(class'#var(prefix)Button1',button){ - if (button.Event=='ToStreet'){ - break; - } - } - - buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); - buttonHint.SetBaseActor(button); - //add a small light to the lower floor of the apartment. //This helps to just put a little bit of light on the generator location //in the case of 0 brightness boost @@ -159,6 +157,17 @@ function PreFirstEntryMapFixes() if(d.Event == 'BlewFence') break; } class'FillCollisionHole'.static.CreateLine(self, vectm(-2184, 1266.793335, 79.291428), vectm(-2050, 1266.793335, 79.291428), 10, 80, d); + } else { + //Revision + + //Add teleporter hint text to Jock + #ifdef revision + foreach AllActors(class'#var(prefix)MapExit',exit){break;} + foreach AllActors(class'JockHelicopter',jockheli){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif + } //Both vanilla and Revision: @@ -179,6 +188,15 @@ function PreFirstEntryMapFixes() npClass.static.SpawnInfoDevice(self,class'#var(prefix)NewspaperOpen',vectm(1700.929810,-519.988037,57.729870),rotm(0,0,0,0),'02_Newspaper06'); //Joe Greene article, table in room next to break room (near bathrooms) npClass.static.SpawnInfoDevice(self,class'#var(prefix)NewspaperOpen',vectm(-1727.644775,2479.614990,1745.724976),rotm(0,0,0,0),'02_Newspaper06'); //Next to apartment(?) door on rooftops, near elevator + foreach AllActors(class'#var(prefix)MapExit',exit,'ToStreet'){break;} + foreach AllActors(class'#var(prefix)Button1',button){ + if (button.Event=='ToStreet'){ + break; + } + } + buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); + buttonHint.SetBaseActor(button); + class'PlaceholderEnemy'.static.Create(self,vectm(782,-1452,48)); class'PlaceholderEnemy'.static.Create(self,vectm(1508,-1373,256)); class'PlaceholderEnemy'.static.Create(self,vectm(1814,-1842,48)); @@ -255,6 +273,11 @@ function PreFirstEntryMapFixes() l("hiding " $ c @ c.Tag @ c.Event); c.bHidden = true;// hide it so DXRSwapItems doesn't move it, this is supposed to be inside the plane that flies overhead } + + //Another store room with the same key as AugStore in the RevisionMaps + foreach AllActors(class'DeusExMover', d, 'SwankyStore') { + d.bFrobbable = true; + } } foreach AllActors(class'DeusExMover', d, 'AugStore') { d.bFrobbable = true; @@ -327,6 +350,11 @@ function PreFirstEntryMapFixes() oot.Event='botordertriggerDoor'; oot.Tag='botordertrigger'; + foreach AllActors(class'Smuggler', smug) { + smug.bImportant = true; + break; + } + SetAllLampsState(false, true, true); // smuggler has one table lamp, upstairs where no one is if (#defined(vanilla)) { class'MoverToggleTrigger'.static.CreateMTT(self, 'DXRSmugglerElevatorUsed', 'elevatorbutton', 1, 0, 0.0, 3); diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM03.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM03.uc index 4b10f2afa..8f060e752 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM03.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM03.uc @@ -135,61 +135,61 @@ function PreFirstEntryMapFixes() break; case "03_NYC_AirfieldHeliBase": - if (VanillaMaps){ - foreach AllActors(class'Mover',m) { - // call the elevator at the end of the level when you open the appropriate door - if (m.Tag == 'BasementDoorOpen') - { - m.Event = 'BasementFloor'; - } - else if (m.Tag == 'GroundDoorOpen') - { - m.Event = 'GroundLevel'; - } - // sewer door backtracking so we can make a switch for this - else if ( DeusExMover(m) != None && DeusExMover(m).KeyIDNeeded == 'Sewerdoor') - { - m.Tag = 'Sewerdoor'; - } + foreach AllActors(class'Mover',m) { + // call the elevator at the end of the level when you open the appropriate door + // Revision uses an ElevatorTrigger with more logic, maybe we can look at it later if needed + if (VanillaMaps && m.Tag == 'BasementDoorOpen') + { + m.Event = 'BasementFloor'; } - if(!dxr.flags.IsZeroRando()) { - foreach AllActors(class'Trigger', t) { - //disable the platforms that fall when you step on them - if( t.Name == 'Trigger0' || t.Name == 'Trigger1' ) { - t.Event = ''; - } - } + else if (VanillaMaps && m.Tag == 'GroundDoorOpen') + { + m.Event = 'GroundLevel'; } - foreach AllActors(class'#var(prefix)UNATCOTroop', unatco) { - unatco.bHateCarcass = false; - unatco.bHateDistress = false; + // sewer door backtracking so we can make a switch for this + else if ( DeusExMover(m) != None && DeusExMover(m).KeyIDNeeded == 'Sewerdoor') + { + m.Tag = 'Sewerdoor'; } + } + if(!dxr.flags.IsZeroRando()) { + foreach AllActors(class'Trigger', t) { + //disable the platforms that fall when you step on them + if( t.Event == 'firstplatform' || t.Event == 'platform2' ) { + t.Event = ''; + } + } + } + foreach AllActors(class'#var(prefix)UNATCOTroop', unatco) { + unatco.bHateCarcass = false; + unatco.bHateDistress = false; + } - // Sewerdoor backtracking - AddSwitch( vect(-6878.640137, 3623.358398, 150.903931), rot(0,0,0), 'Sewerdoor'); - - //stepping stone valves out of the water, I could make the collision radius a little wider even if it isn't realistic? - AddActor(class'Valve', vect(-3105,-385,-210), rot(0,0,16384)); - a = AddActor(class'DynamicBlockPlayer', vect(-3105,-385,-210)); - SetActorScale(a, 1.3); + // Sewerdoor backtracking + AddSwitch( vect(-6878.640137, 3623.358398, 150.903931), rot(0,0,0), 'Sewerdoor'); - AddActor(class'Valve', vect(-3080,-395,-170), rot(0,0,16384)); - a = AddActor(class'DynamicBlockPlayer', vect(-3080,-395,-170)); - SetActorScale(a, 1.3); + //stepping stone valves out of the water, I could make the collision radius a little wider even if it isn't realistic? + AddActor(class'Valve', vect(-3105,-385,-210), rot(0,0,16384)); + a = AddActor(class'DynamicBlockPlayer', vect(-3105,-385,-210)); + SetActorScale(a, 1.3); - AddActor(class'Valve', vect(-3065,-405,-130), rot(0,0,16384)); - a = AddActor(class'DynamicBlockPlayer', vect(-3065,-405,-130)); - SetActorScale(a, 1.3); + AddActor(class'Valve', vect(-3080,-395,-170), rot(0,0,16384)); + a = AddActor(class'DynamicBlockPlayer', vect(-3080,-395,-170)); + SetActorScale(a, 1.3); - if(!dxr.flags.IsZeroRando()) { - //rebreather because of #TOOCEAN connection - Spawn(class'Rebreather',,, vectm(1411.798950, 546.628845, 247.708572)); - } + AddActor(class'Valve', vect(-3065,-405,-130), rot(0,0,16384)); + a = AddActor(class'DynamicBlockPlayer', vect(-3065,-405,-130)); + SetActorScale(a, 1.3); - //Button to extend sewer platform from the other side - AddSwitch( vect(-5233.946289,3601.383545,161.851822), rot(0, 16384, 0), 'MoveableBridge'); + if(!dxr.flags.IsZeroRando()) { + //rebreather because of #TOOCEAN connection + //Bookshelf near pool tables + Spawn(class'Rebreather',,, vectm(1411.798950, 546.628845, 247.708572)); } + //Button to extend sewer platform from the other side + AddSwitch( vect(-5233.946289,3601.383545,161.851822), rot(0, 16384, 0), 'MoveableBridge'); + class'PlaceholderEnemy'.static.Create(self,vectm(1273,809,48),,'Shitting'); class'PlaceholderEnemy'.static.Create(self,vectm(1384,805,48),,'Shitting'); @@ -209,6 +209,12 @@ function PreFirstEntryMapFixes() Spawn(class'Rebreather',,, vectm(-2031.959473, 995.781067, 75.709816)); } + //Add teleporter hint text to Jock + foreach AllActors(class'#var(prefix)MapExit',exit){break;} + foreach AllActors(class'#var(prefix)BlackHelicopter',jock){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jock); + // fix collision with the static crates https://github.com/Die4Ever/deus-ex-randomizer/issues/665 class'FillCollisionHole'.static.CreateLine(self, vectm(792.113403, -1343.670166, 69), vectm(675, -1343.670166, 69), 32, 90); class'FillCollisionHole'.static.CreateLine(self, vectm(675, -1300, 69), vectm(675, -1093.477783, 69), 32, 90); @@ -267,12 +273,6 @@ function PreFirstEntryMapFixes() dt.SetCollisionSize(50.0, 40.0); dt.SetDestination("03_NYC_AirfieldHeliBase",, "BHElevatorEnt"); - //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); - hoverHint.SetBaseActor(jock); - class'PlaceholderEnemy'.static.Create(self,vectm(2994,3406,256),,'Shitting'); class'PlaceholderEnemy'.static.Create(self,vectm(2887,3410,256),,'Shitting'); @@ -396,13 +396,6 @@ function PreFirstEntryMapFixes() FixAlexsEmail(); MakeTurretsNonHostile(); //Revision has hostile turrets near jail - //Move weapon mod out of Manderley's secret (inaccessible) safe - foreach AllActors(class'#var(prefix)WeaponModRecoil',wmr){ - if (wmr.Name=='WeaponModRecoil0'){ - wmr.SetLocation(vectm(420.843567,175.866135,261.520447)); - } - } - if(!dxr.flags.IsZeroRando()) { k = Spawn(class'#var(prefix)NanoKey',,, vectm(965,900,-28)); k.KeyID = 'JaimeClosetKey'; @@ -419,6 +412,13 @@ function PreFirstEntryMapFixes() } if (VanillaMaps) { + //Move weapon mod out of Manderley's secret (inaccessible) safe + foreach AllActors(class'#var(prefix)WeaponModRecoil',wmr){ + if (wmr.Name=='WeaponModRecoil0'){ + wmr.SetLocation(vectm(420.843567,175.866135,261.520447)); + } + } + foreach AllActors(class'#var(prefix)ComputerPublic', compublic) { compublic.bCollideWorld = false; compublic.SetLocation(vectm(741.36, 1609.34, 298.0)); diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM04.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM04.uc index 20d9e8d07..5b76b7857 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM04.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM04.uc @@ -61,33 +61,35 @@ function PreFirstEntryMapFixes() local #var(prefix)ComputerPublic compublic; local #var(prefix)LaserTrigger lt; local #var(prefix)Datacube dc; + local Smuggler smug; VanillaMaps = class'DXRMapVariants'.static.IsVanillaMaps(player()); switch (dxr.localURL) { case "04_NYC_HOTEL": -#ifdef vanilla - foreach AllActors(class'OrdersTrigger', ot, 'PaulSafe') { - if( ot.Orders == 'Leaving' ) - ot.Orders = 'Seeking'; - } - foreach AllActors(class'#var(prefix)FlagTrigger', ft) { - if( ft.Event == 'PaulOutaHere' ) - ft.Destroy(); - } - foreach AllActors(class'SkillAwardTrigger', st) { - if( st.Tag == 'StayedWithPaul' ) { - st.skillPointsAdded = 100; - st.awardMessage = "Stayed with Paul"; - st.Destroy();// HACK: this trigger is buggy for some reason, just forget about it for now + if (#defined(vanilla)){ + foreach AllActors(class'OrdersTrigger', ot, 'PaulSafe') { + if( ot.Orders == 'Leaving' ) + ot.Orders = 'Seeking'; + } + foreach AllActors(class'#var(prefix)FlagTrigger', ft) { + if( ft.Event == 'PaulOutaHere' ) + ft.Destroy(); } - else if( st.Tag == 'PaulOutaHere' ) { - st.skillPointsAdded = 500; - st.awardMessage = "Saved Paul"; + foreach AllActors(class'SkillAwardTrigger', st) { + if( st.Tag == 'StayedWithPaul' ) { + st.skillPointsAdded = 100; + st.awardMessage = "Stayed with Paul"; + st.Destroy();// HACK: this trigger is buggy for some reason, just forget about it for now + } + else if( st.Tag == 'PaulOutaHere' ) { + st.skillPointsAdded = 500; + st.awardMessage = "Saved Paul"; + } } } -#endif + class'GilbertWeaponMegaChoice'.static.Create(Player()); foreach AllActors(class'#var(prefix)GilbertRenton',gilbert){ //Make sure he has ammo for Stealth Pistol(10mm), Pistol (10mm), @@ -106,19 +108,19 @@ function PreFirstEntryMapFixes() Spawn(class'#var(prefix)Binoculars',,, vectm(-610.374573,-3221.998779,94.160065)); //Paul's bedside table if(!dxr.flags.IsZeroRando()) { - key = Spawn(class'#var(prefix)NanoKey',,, vectm(-967,-1240,-74)); + key = Spawn(class'#var(prefix)NanoKey',,, vectm(-967,-1240,-74)); //In a mail nook key.KeyID = 'CrackRoom'; key.Description = "'Ton Hotel, North Room Key"; if(dxr.flags.settings.keysrando > 0) GlowUp(key); - key = Spawn(class'#var(prefix)NanoKey',,, vectm(-845,-2920,180)); + key = Spawn(class'#var(prefix)NanoKey',,, vectm(-845,-2920,180)); //Top shelf of Paul's closet key.KeyID = 'Apartment'; key.Description = "Apartment key"; if(dxr.flags.settings.keysrando > 0) GlowUp(key); - SpawnDatacubeTextTag(vectm(-840,-2920,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in closet + SpawnDatacubeTextTag(vectm(-840,-2920,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in bottom of closet } foreach RadiusActors(class'#var(DeusExPrefix)Mover', door, 1.0, vectm(-304.0, -3000.0, 64.0)) { @@ -135,6 +137,28 @@ function PreFirstEntryMapFixes() } else { Spawn(class'#var(prefix)Binoculars',,, vectm(-90,-3958,95)); //Paul's bedside table + if(!dxr.flags.IsZeroRando()) { + key = Spawn(class'#var(prefix)NanoKey',,, vectm(-900,-1385,-74)); //In a mail nook + key.KeyID = 'Hotelroom1'; //CrackRoom doesn't exist in Revision M04 - doesn't hurt to add a key to a different room instead + key.Description = "'Ton Hotel, South Room Key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(key); + + key = Spawn(class'#var(prefix)NanoKey',,, vectm(-900,-1415,-55)); //In a different mail nook + key.KeyID = 'Hotelroom2'; //CrackRoom doesn't exist in Revision M04 - doesn't hurt to add a key to a different room instead + key.Description = "'Ton Hotel, Northwest Room Key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(key); + + key = Spawn(class'#var(prefix)NanoKey',,, vectm(-300,-3630,180)); //Top shelf of Paul's closet + key.KeyID = 'Apartment'; + key.Description = "Apartment key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(key); + + SpawnDatacubeTextTag(vectm(-295,-3655,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in bottom of closet + } + Spawn(class'PlaceholderItem',,, vectm(-180,-3365,70)); //Actual closet Spawn(class'PlaceholderItem',,, vectm(-180,-3450,70)); //Actual closet Spawn(class'PlaceholderItem',,, vectm(480,-3775,125)); //Bathroom counter @@ -187,6 +211,7 @@ function PreFirstEntryMapFixes() k.bImportant = true; k.ChangeAlly('Player', -1, false); k.SetOrders('Standing'); + k.SetCollisionSize(k.CollisionRadius*0.3,k.CollisionHeight); //Make him more slim so he can squeeze through the doors better } //Button to open basement hatch from inside @@ -431,6 +456,11 @@ function PreFirstEntryMapFixes() oot.Event='botordertriggerDoor'; oot.Tag='botordertrigger'; + foreach AllActors(class'Smuggler', smug) { + smug.bImportant = true; + break; + } + SetAllLampsState(false, true, true); // smuggler has one table lamp, upstairs where no one is class'MoverToggleTrigger'.static.CreateMTT(self, 'DXRSmugglerElevatorUsed', 'elevatorbutton', 1, 0, 0.0, 5); @@ -550,6 +580,8 @@ function AnyEntryMapFixes() if (ces != None) ces.conSpeech.speech = "... too sick. Come back later."; // add a missing period after "sick" + GetConversation('DL_JockParkStart').AddFlagRef('PaulInjured_Played', false); // disable "Your brother's hurt pretty bad" infolink if you've already talked to him + break; } } diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM05.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM05.uc index bc4c8ae63..15b1cbeaa 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM05.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM05.uc @@ -292,6 +292,9 @@ function PreFirstEntryMapFixes() function PostFirstEntryMapFixes() { local RetinalScanner r; + local bool VanillaMaps; + + VanillaMaps = class'DXRMapVariants'.static.IsVanillaMaps(player()); switch(dxr.localURL) { case "05_NYC_UNATCOHQ": @@ -302,7 +305,11 @@ function PostFirstEntryMapFixes() r.hackStrength = 0; r.msgUsed = "Access De-/.&*% g r a n t e d"; } else if (r.Event == 'securitytrigger') { - r.Event = 'UNblastdoor'; + if (VanillaMaps){ + r.Event = 'UNblastdoor'; + } else { + r.Event = 'UN_blastdoor'; //Revision changed the tag name on the door + } r.bHackable = true; r.hackStrength = 0; r.msgUsed = "Access De-/.&*% g r a n t e d"; diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM06.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM06.uc index 33521a93e..5313a3cf2 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM06.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM06.uc @@ -70,7 +70,8 @@ function PreFirstEntryMapFixes() local #var(prefix)TriadRedArrow bouncer; local #var(prefix)MapExit exit; local #var(prefix)BlackHelicopter jock; - local #var(injectsprefix)Button1 button; + local #var(prefix)Button1 button; + local #var(injectsprefix)Button1 injbutton; local #var(prefix)BeamTrigger bt; local #var(prefix)LaserTrigger lt; local DXRButtonHoverHint buttonHint; @@ -123,23 +124,13 @@ function PreFirstEntryMapFixes() break; } - foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ - if (button.Event=='change_floors'){ - break; - } - } - buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); - buttonHint.SetBaseActor(button); - - - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if (button.tag == 'Weapons_Lock_broken' || button.tag == 'Weapons_lock' || button.event == 'missile_door') { - button.SetRotation(rotm(14400,16500,0,GetRotationOffset(button.class))); //A similar rotation to original that only rotates in two axes instead of all three - } else if (button.Event=='elevator_door' && button.ButtonType==BT_Blank){ + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if (injbutton.tag == 'Weapons_Lock_broken' || injbutton.tag == 'Weapons_lock' || injbutton.event == 'missile_door') { + injbutton.SetRotation(rotm(14400,16500,0,GetRotationOffset(injbutton.class))); //A similar rotation to original that only rotates in two axes instead of all three + } else if (injbutton.Event=='elevator_door' && injbutton.ButtonType==BT_Blank){ //Both the button inside and outside - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } } @@ -152,9 +143,21 @@ function PreFirstEntryMapFixes() } // nonsensical mover blocking jock's tail foreach AllActors(class'#var(DeusExPrefix)Mover',m,'jockweapons'){ + m.NumFragments=0; //So it isn't visible when it's destroyed + m.ExplodeSound1=None; //So you don't hear it get broken + m.ExplodeSound2=None; m.BlowItUp(None); } + foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} + foreach AllActors(class'#var(prefix)Button1',button){ //Button won't be replaced yet in non-vanilla, so just use regular Button1 + if (button.Event=='change_floors'){ + break; + } + } + buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); + buttonHint.SetBaseActor(button); + class'PlaceholderEnemy'.static.Create(self,vectm(769,-520,144)); class'PlaceholderEnemy'.static.Create(self,vectm(1620,-87,144)); class'PlaceholderEnemy'.static.Create(self,vectm(-844,-359,816)); @@ -188,10 +191,10 @@ function PreFirstEntryMapFixes() // button to get out of Tong's base // Revision already has a button in place (In WANCHAI_COMPOUND) AddSwitch( vect(1433.658936, 273.360352, -167.364777), rot(0, 16384, 0), 'Basement_door' ); - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if ((button.Event=='elevator_door' || button.Event=='elevator_door01') && button.ButtonType==BT_Blank){ //Helibase and Versalife elevators - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if ((injbutton.Event=='elevator_door' || injbutton.Event=='elevator_door01') && injbutton.ButtonType==BT_Blank){ //Helibase and Versalife elevators + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } } @@ -236,29 +239,37 @@ function PreFirstEntryMapFixes() } } //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit,'outro_trigger'){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); - hoverHint.SetBaseActor(jock); - if (VanillaMaps){ - //Elevator to Versalife - foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors01'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ - if (button.Event=='change_floors01'){ - break; - } + foreach AllActors(class'#var(prefix)MapExit',exit,'outro_trigger'){break;} + } else { + foreach AllActors(class'#var(prefix)MapExit',exit,'CameraExit'){break;} + } + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'chopper'){break;} + if (jock!=None){ + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jock); + } + + //Elevator to Versalife + foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors01'){break;} + foreach AllActors(class'#var(prefix)Button1',button){ //Button won't be replaced yet in non-vanilla, so just use regular Button1 + if (button.Event=='change_floors01'){ + break; } + } + if (button!=None){ buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); buttonHint.SetBaseActor(button); + } - //Elevator to Helibase - foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ - if (button.Event=='change_floors'){ - break; - } + //Elevator to Helibase + foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} + foreach AllActors(class'#var(prefix)Button1',button){ //Button won't be replaced yet in non-vanilla, so just use regular Button1 + if (button.Event=='change_floors'){ + break; } + } + if (button!=None){ buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); buttonHint.SetBaseActor(button); } @@ -282,7 +293,7 @@ function PreFirstEntryMapFixes() dts.bIsSecretGoal = true;// just in case you don't have DXRMissions enabled } if (VanillaMaps){ - foreach AllActors(class'#var(injectsprefix)Button1',button) + foreach AllActors(class'#var(prefix)Button1',button) { if (button.Event=='JockShaftTop') { @@ -313,10 +324,10 @@ function PreFirstEntryMapFixes() d.bFrobbable=True; } } - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if ((button.Event=='Eledoor01' || button.Event=='eledoor02') && button.ButtonType==BT_Blank){ //Penthouse and renovation elevators - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if ((injbutton.Event=='Eledoor01' || injbutton.Event=='eledoor02') && injbutton.ButtonType==BT_Blank){ //Penthouse and renovation elevators + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } @@ -335,17 +346,13 @@ function PreFirstEntryMapFixes() // alarm in MiB's overlook office Spawnm(class'#var(prefix)AlarmUnit',, 'SecurityRevoked', vect(253.179993,1055.714844,825.220764), rot(0,32768,0)); - ft= Spawn(class'#var(prefix)FlagTrigger',,, vectm(1.412384, 1658.755614, 190.711304)); // Inside the elvator to 06_HONGKONG_VERSALIFE - ft.Event='SecurityRevoked'; - ft.FlagName='Have_ROM'; - ft.bSetFlag=False; - ft.bTrigger=True; - - ft= Spawn(class'#var(prefix)FlagTrigger',,, vectm(-1432.140991, 860.576238, -87.899834)); // Inside the elvator to 06_HONGKONG_STORAGE - ft.Event='SecurityRevoked'; - ft.FlagName='Have_ROM'; - ft.bSetFlag=False; - ft.bTrigger=True; + //Trigger the alarm on first entry if the flag is already set (ie. a late HK start) + if (player().flagBase.GetBool('Have_ROM')){ + foreach AllActors(class'Actor', a,'SecurityRevoked') + { + a.Trigger(None,player()); //To match as originally triggered by ComputerScreenSpecialOptions + } + } foreach AllActors(class'#var(DeusExPrefix)Mover', m, 'security_doors') { m.bBreakable = false; @@ -391,7 +398,7 @@ function PreFirstEntryMapFixes() //Elevator to Versalife foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors01'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ + foreach AllActors(class'#var(prefix)Button1',button){ if (button.Event=='change_floors01'){ break; } @@ -401,7 +408,7 @@ function PreFirstEntryMapFixes() //Elevator to Level 2 foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ + foreach AllActors(class'#var(prefix)Button1',button){ if (button.Event=='change_floors'){ break; } @@ -409,10 +416,10 @@ function PreFirstEntryMapFixes() buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); buttonHint.SetBaseActor(button); - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if ((button.Event=='elevator_door' || button.Event=='elevator_door01' || button.Event=='eledoor02') && button.ButtonType==BT_Blank){ //Office, Level 2, and balcony elevators - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if ((injbutton.Event=='elevator_door' || injbutton.Event=='elevator_door01' || injbutton.Event=='eledoor02') && injbutton.ButtonType==BT_Blank){ //Office, Level 2, and balcony elevators + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } @@ -653,7 +660,7 @@ function PreFirstEntryMapFixes() //Elevator to Market foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors01'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ + foreach AllActors(class'#var(prefix)Button1',button){ if (button.Event=='change_floors01'){ break; } @@ -663,7 +670,7 @@ function PreFirstEntryMapFixes() //Elevator to MJ12 Lab foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ + foreach AllActors(class'#var(prefix)Button1',button){ if (button.Event=='change_floors'){ break; } @@ -671,10 +678,10 @@ function PreFirstEntryMapFixes() buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); buttonHint.SetBaseActor(button); - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if ((button.Event=='LobbyDoor' || button.Event=='elevator_door') && button.ButtonType==BT_Blank){ //Market and Level 1 elevators - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if ((injbutton.Event=='LobbyDoor' || injbutton.Event=='elevator_door') && injbutton.ButtonType==BT_Blank){ //Market and Level 1 elevators + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } @@ -727,7 +734,7 @@ function PreFirstEntryMapFixes() //Elevator to MJ12 Lab foreach AllActors(class'#var(prefix)MapExit',exit,'change_floors'){break;} - foreach AllActors(class'#var(injectsprefix)Button1',button){ + foreach AllActors(class'#var(prefix)Button1',button){ if (button.Event=='change_floors'){ break; } @@ -735,10 +742,10 @@ function PreFirstEntryMapFixes() buttonHint = DXRButtonHoverHint(class'DXRButtonHoverHint'.static.Create(self, "", button.Location, button.CollisionRadius+5, button.CollisionHeight+5, exit)); buttonHint.SetBaseActor(button); - foreach AllActors(class'#var(injectsprefix)Button1', button) { - if (button.Event=='elevator_door' && button.ButtonType==BT_Blank){ //Level 1 elevator - button.RandoButtonType=RBT_OpenDoors; - button.BeginPlay(); + foreach AllActors(class'#var(injectsprefix)Button1', injbutton) { + if (injbutton.Event=='elevator_door' && injbutton.ButtonType==BT_Blank){ //Level 1 elevator + injbutton.RandoButtonType=RBT_OpenDoors; + injbutton.BeginPlay(); } } @@ -772,6 +779,13 @@ function PreFirstEntryMapFixes() Spawn(class'PlaceholderItem',,, vectm(339.25,-2111.46,506.3)); //Near lasers Spawn(class'PlaceholderItem',,, vectm(1169,-1490,459)); //Water pool Spawn(class'PlaceholderItem',,, vectm(1079.73,-1068.17,842.4)); //Pipes above water + Spawn(class'PlaceholderItem',,, vectm(90,-666,1030)); //Under corner mirror + Spawn(class'PlaceholderItem',,, vectm(175,-2515,855)); //Pit near security computer + Spawn(class'PlaceholderItem',,, vectm(75,-1730,900)); //Lower hallway alcove + Spawn(class'PlaceholderItem',,, vectm(-90,-2320,1030)); //Upper Hallway near computer + Spawn(class'PlaceholderItem',,, vectm(-800,-650,1030)); //Upper Hallway near elevator + Spawn(class'PlaceholderItem',,, vectm(510,-1450,860)); //Lower Hallway near where you drop in + Spawn(class'PlaceholderItem',,, vectm(790,-1360,810)); //Another pipe in the water pool area Spawn(class'PlaceholderContainer',,, vectm(160.7,-1589.4,545)); //Robot alcove Spawn(class'PlaceholderContainer',,, vectm(-159.23,-1300.16,544.1)); //Robot alcove @@ -779,7 +793,11 @@ function PreFirstEntryMapFixes() Spawn(class'PlaceholderContainer',,, vectm(691.3,-358.4,-1007.9)); //Near UC Spawn(class'PlaceholderContainer',,, vectm(174,-2862,1057)); //Near upper security computer - Spawn(class'MJ12Clone1',,, vectm(819.992188, -0.852280, -67.399956)); + p=MJ12Clone1(Spawnm(class'MJ12Clone1',,, vect(635,0,-65),rot(0,32768,0))); //Should he just be a PlaceholderEnemy now? + p.InitializeAlliances(); + class'PlaceholderEnemy'.static.Create(self,vectm(0,0,-75)); //Middle of room with 4 containers + class'PlaceholderEnemy'.static.Create(self,vectm(0,0,565)); //Walkway over UC room + class'PlaceholderEnemy'.static.Create(self,vectm(75,-1515,1075)); //Upper hallway (to keep it likely for there to be enemies up there) break; case "06_HONGKONG_WANCHAI_CANAL": diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM08.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM08.uc index b572ed2f1..44fde15de 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM08.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM08.uc @@ -147,6 +147,9 @@ function PreFirstEntryMapFixes() local #var(prefix)PigeonGenerator pg; local #var(prefix)MapExit exit; local #var(prefix)BlackHelicopter jock; +#ifdef revision + local JockHelicopter jockheli; +#endif local OnceOnlyTrigger oot; local #var(DeusExPrefix)Mover d; local DXRHoverHint hoverHint; @@ -156,6 +159,7 @@ function PreFirstEntryMapFixes() local Teleporter tel; local DynamicTeleporter dtel; local RiotCop rc; + local Smuggler smug; #ifdef injections local #var(prefix)Newspaper np; @@ -212,9 +216,17 @@ function PreFirstEntryMapFixes() //Add teleporter hint text to Jock foreach AllActors(class'#var(prefix)MapExit',exit){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); - hoverHint.SetBaseActor(jock); + if (VanillaMaps){ + foreach AllActors(class'#var(prefix)BlackHelicopter',jock){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jock); + } else { + #ifdef revision + foreach AllActors(class'JockHelicopter',jockheli){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif + } if (#defined(vanilla)) { class'MoverToggleTrigger'.static.CreateMTT(self, 'DXRSmugglerElevatorUsed', 'elevatorbutton', 0, 1, 0.0, 9); @@ -234,15 +246,15 @@ function PreFirstEntryMapFixes() Spawn(class'#var(prefix)Binoculars',,, vectm(-610.374573,-3221.998779,94.160065)); //Paul's bedside table if(!dxr.flags.IsZeroRando()) { - SpawnDatacubeTextTag(vectm(-840,-2920,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in closet + SpawnDatacubeTextTag(vectm(-840,-2920,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in bottom of closet - k = Spawn(class'#var(prefix)NanoKey',,, vectm(-967,-1240,-74)); + k = Spawn(class'#var(prefix)NanoKey',,, vectm(-967,-1240,-74)); //In a mail nook k.KeyID = 'CrackRoom'; k.Description = "'Ton Hotel, North Room Key"; if(dxr.flags.settings.keysrando > 0) GlowUp(k); - k = Spawn(class'#var(prefix)NanoKey',,, vectm(-845,-2920,180)); + k = Spawn(class'#var(prefix)NanoKey',,, vectm(-845,-2920,180)); //Top shelf of Paul's closet k.KeyID = 'Apartment'; k.Description = "Apartment key"; if(dxr.flags.settings.keysrando > 0) @@ -269,6 +281,23 @@ function PreFirstEntryMapFixes() } else { Spawn(class'#var(prefix)Binoculars',,, vectm(-90,-3958,95)); //Paul's bedside table + if(!dxr.flags.IsZeroRando()) { + k = Spawn(class'#var(prefix)NanoKey',,, vectm(-900,-1385,-74)); //In a mail nook + k.KeyID = 'Hotelroom1'; + k.Description = "'Ton Hotel, South Room Key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(k); + + k = Spawn(class'#var(prefix)NanoKey',,, vectm(-300,-3630,180)); //Top shelf of Paul's closet + k.KeyID = 'Apartment'; + k.Description = "Apartment key"; + if(dxr.flags.settings.keysrando > 0) + GlowUp(k); + + SpawnDatacubeTextTag(vectm(-295,-3655,85), rotm(0,0,0,0), '02_Datacube07',False); //Paul's stash code, in bottom of closet + } + + Spawn(class'PlaceholderItem',,, vectm(-180,-3365,70)); //Actual closet Spawn(class'PlaceholderItem',,, vectm(-180,-3450,70)); //Actual closet Spawn(class'PlaceholderItem',,, vectm(480,-3775,125)); //Bathroom counter @@ -293,7 +322,15 @@ function PreFirstEntryMapFixes() oot.Event='botordertriggerDoor'; oot.Tag='botordertrigger'; - SetAllLampsState(false, true, true); // smuggler has one table lamp, upstairs where no one is + foreach AllActors(class'Smuggler', smug) { + smug.bImportant = true; + break; + } + + if (!dxr.flagbase.GetBool('FordSchickRescued')) { + SetAllLampsState(false, true, true); // smuggler has one table lamp, upstairs where no one is unless Ford was rescued + } + class'MoverToggleTrigger'.static.CreateMTT(self, 'DXRSmugglerElevatorUsed', 'elevatorbutton', 1, 0, 0.0, 9); break; diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM09.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM09.uc index 358cae80b..492fe60ad 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM09.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM09.uc @@ -42,6 +42,9 @@ function PreFirstEntryMapFixes() local #var(prefix)Trigger trig; local #var(prefix)MapExit exit; local #var(prefix)BlackHelicopter jock; +#ifdef revision + local JockHelicopter jockheli; +#endif local DXRHoverHint hoverHint; local bool VanillaMaps; @@ -184,6 +187,12 @@ function PreFirstEntryMapFixes() gas.Destroy(); } } + + foreach AllActors(class'#var(prefix)BeamTrigger', beam, 'SpiderBotDoorBeam') { + beam.bTriggerOnceOnly = true; + break; + } + break; case "09_NYC_DOCKYARD": @@ -195,6 +204,19 @@ function PreFirstEntryMapFixes() break; } + foreach AllActors(class'#var(prefix)BeamTrigger',beam){ + if (beam.Event=='BotDrop'){ + beam.Tag='TunnelTrigger'; + beam.Event='BotDropOnce'; + } + } + + oot=Spawn(class'OnceOnlyTrigger'); + oot.Event='BotDrop'; + oot.Tag='BotDropOnce'; + + AddSwitch( vect(4973.640137, 6476.444336, 1423.943848), rot(0,32768,0), 'Crane'); + if (VanillaMaps){ foreach AllActors(class'#var(prefix)GasGrenade',gasgren) { //This one has falling physics normally, so just fix it @@ -209,25 +231,6 @@ function PreFirstEntryMapFixes() } } - foreach AllActors(class'#var(prefix)BeamTrigger',beam){ - if (beam.Event=='BotDrop'){ - beam.Tag='TunnelTrigger'; - beam.Event='BotDropOnce'; - } - } - - oot=Spawn(class'OnceOnlyTrigger'); - oot.Event='BotDrop'; - oot.Tag='BotDropOnce'; - - //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit,'ToGraveyard'){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); - hoverHint.SetBaseActor(jock); - - AddSwitch( vect(4973.640137, 6476.444336, 1423.943848), rot(0,32768,0), 'Crane'); - foreach AllActors(class'#var(prefix)Teleporter', t) { // if you hug the wall, you can squeeze past the sewer teleporter if (t.url == "09_NYC_Ship#FromDockyardSewer") { @@ -237,6 +240,16 @@ function PreFirstEntryMapFixes() } } + //Add teleporter hint text to Jock + foreach AllActors(class'#var(prefix)MapExit',exit,'ToGraveyard'){break;} + if (VanillaMaps){ + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} + } else { + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'FakeHelicopter'){break;} + } + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); + hoverHint.SetBaseActor(jock); + //They put the key ID in the tag for some reason foreach AllActors(class'#var(prefix)NanoKey',key,'SupplyRoom'){ if (key.keyID==''){ @@ -337,9 +350,18 @@ function PreFirstEntryMapFixes() //Add teleporter hint text to Jock foreach AllActors(class'#var(prefix)MapExit',exit,'CopterCam'){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); - hoverHint.SetBaseActor(jock); + if (VanillaMaps){ + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jock); + } else { + #ifdef revision + foreach AllActors(class'JockHelicopter',jockheli){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif + } + if (#defined(vanilla) && InStr(dxr.dxInfo.startupMessage[0], "Cemetary") != -1) { dxr.dxInfo.startupMessage[0] = "New York City, Lower East Side Cemetery"; // fix "cemetery" misspelling diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupM15.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupM15.uc index abf3cccdf..0c056befa 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupM15.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupM15.uc @@ -281,6 +281,58 @@ function PreFirstEntryMapFixes_Final(bool isVanilla) local OnceOnlyTrigger oot; local int i; + //Increase the radius of the datalink that opens the sector 4 blast doors + foreach AllActors(class'DataLinkTrigger',dlt){ + if (dlt.datalinkTag=='DL_Helios_Door2'){ + dlt.SetCollisionSize(900,dlt.CollisionHeight); + } + } + + // make the Tong ending flag trigger not based on collision + foreach AllActors(class'FlagTrigger', ft, 'FlagTrigger') { + if(ft.event != 'Generator_overload') continue; + ft.Tag = 'Check_Generator_overload'; + ft.SetCollision(false,false,false); + } + + foreach AllActors(class'Dispatcher', disp) { + switch(disp.Tag) { + case 'button_3': + disp.OutEvents[6] = 'Check_Generator_overload'; + // fallthrough + case 'button_1': + case 'button_2': + if(dxr.flags.moresettings.splits_overlay > 0) {// also make Tong ending a little faster + for(i=0; i 0) { + foreach AllActors(class'DeusExMover', d) { + switch(d.Tag) { + case 'Generator_panel': + case 'injector2': + case 'injector3': + case 'Generator_overload': + d.MoveTime /= 2; + break; + } + } + } + + //Generator Failsafe buttons should spit out some sort of message if the coolant isn't cut + //start_buzz1 and start_buzz2 are the tags that get hit when the coolant isn't cut + se = Spawn(class'SpecialEvent',,'start_buzz1'); + se.Message = "Coolant levels normal - Failsafe cannot be disabled"; + se = Spawn(class'SpecialEvent',,'start_buzz2'); + se.Message = "Coolant levels normal - Failsafe cannot be disabled"; + + if (isVanilla) { AddSwitch( vect(-5112.805176, -2495.639893, -1364), rot(0, 16384, 0), 'blastdoor_final');// just in case the dialog fails AddSwitch( vect(-5112.805176, -2530.276123, -1364), rot(0, -16384, 0), 'blastdoor_final');// for backtracking @@ -323,57 +375,6 @@ function PreFirstEntryMapFixes_Final(bool isVanilla) } } - // make the Tong ending flag trigger not based on collision - foreach AllActors(class'FlagTrigger', ft, 'FlagTrigger') { - if(ft.event != 'Generator_overload') continue; - ft.Tag = 'Check_Generator_overload'; - ft.SetCollision(false,false,false); - } - - foreach AllActors(class'Dispatcher', disp) { - switch(disp.Tag) { - case 'button_3': - disp.OutEvents[6] = 'Check_Generator_overload'; - // fallthrough - case 'button_1': - case 'button_2': - if(dxr.flags.moresettings.splits_overlay > 0) {// also make Tong ending a little faster - for(i=0; i 0) { - foreach AllActors(class'DeusExMover', d) { - switch(d.Tag) { - case 'Generator_panel': - case 'injector2': - case 'injector3': - case 'Generator_overload': - d.MoveTime /= 2; - break; - } - } - } - - //Generator Failsafe buttons should spit out some sort of message if the coolant isn't cut - //start_buzz1 and start_buzz2 are the tags that get hit when the coolant isn't cut - se = Spawn(class'SpecialEvent',,'start_buzz1'); - se.Message = "Coolant levels normal - Failsafe cannot be disabled"; - se = Spawn(class'SpecialEvent',,'start_buzz2'); - se.Message = "Coolant levels normal - Failsafe cannot be disabled"; - - //Increase the radius of the datalink that opens the sector 4 blast doors - foreach AllActors(class'DataLinkTrigger',dlt){ - if (dlt.datalinkTag=='DL_Helios_Door2'){ - dlt.SetCollisionSize(900,dlt.CollisionHeight); - } - } - //There's a trigger for this at the top of the elevator, but it has collide actors false. //Easier to just spawn a new one near the elevator so you can actually hear it before //the game is over. @@ -405,6 +406,10 @@ function PreFirstEntryMapFixes_Final(bool isVanilla) class'PlaceholderEnemy'.static.Create(self,vectm(-4795,-1596,-1357)); } else { + AddSwitch( vect(-5073,-2432,-1330), rot(0, 32834, 0), 'blastdoor_final');// just in case the dialog fails + AddSwitch( vect(-5066,-2497,-1330), rot(0, -16384, 0), 'blastdoor_final');// for backtracking + AddSwitch( vect(-3712.5,-1085,-1935), rot(0,0,0), 'Page_Blastdoors' ); + Spawn(class'PlaceholderItem',,, vectm(-4151,-173,-1350)); //Helios storage room Spawn(class'PlaceholderItem',,, vectm(-4140,-632,-2000)); //Storage room near sector 4 door Spawn(class'PlaceholderItem',,, vectm(-5796,-393,-1480)); //Storage room on stairs to sector 4 @@ -431,29 +436,40 @@ function PreFirstEntryMapFixes_Entrance(bool isVanilla) local ComputerSecurity c; local #var(prefix)FlagTrigger ft; - if (isVanilla) { - foreach AllActors(class'DeusExMover', d, 'DeusExMover') { - if( d.Name == 'DeusExMover20' ) d.Tag = 'final_door'; + //Change break room security computer password so it isn't pre-known + //This code isn't written anywhere, so you shouldn't have knowledge of it + foreach AllActors(class'ComputerSecurity',c){ + if (c.UserList[0].UserName=="SECURITY" && c.UserList[0].Password=="SECURITY"){ + c.UserList[0].Password="TinFoilHat"; } + } + + foreach AllActors(class'DeusExMover', d, 'DeusExMover') { + if( d.KeyIDNeeded == 'Factory' ) d.Tag = 'final_door'; + } + + foreach AllActors(class'DeusExMover', d, 'doors_lower') { + d.bLocked = false; + d.bHighlight = true; + d.bFrobbable = true; + } + + //After Bob says "I'm sending up the man who did the job", the elevator call button will also open the doors + ft=Spawn(class'#var(prefix)FlagTrigger'); + ft.SetCollision(False,False,False); + ft.bSetFlag=False; + ft.bTrigger=True; + ft.FlagName='DL_elevator_Played'; + ft.flagValue=True; + ft.Tag='elevator_floor1'; + ft.Event='elevator_doors'; + + if (isVanilla) { AddSwitch( vect(-867.193420, 244.553101, 17.622702), rot(0, 32768, 0), 'final_door'); //Button to call elevator to bottom of shaft AddSwitch( vect(-1715.487427,493.516571,-1980.708008), rot(0, 32768, 0), 'elevator_floor2'); - foreach AllActors(class'DeusExMover', d, 'doors_lower') { - d.bLocked = false; - d.bHighlight = true; - d.bFrobbable = true; - } - - //Change break room security computer password so it isn't pre-known - //This code isn't written anywhere, so you shouldn't have knowledge of it - foreach AllActors(class'ComputerSecurity',c){ - if (c.UserList[0].UserName=="SECURITY" && c.UserList[0].Password=="SECURITY"){ - c.UserList[0].Password="TinFoilHat"; - } - } - //Make the floor hatch near Morgan easier to get into //If you make this breakable, the explosion right next //to it will destroy it every time. Maybe it could @@ -464,16 +480,6 @@ function PreFirstEntryMapFixes_Entrance(bool isVanilla) } } - //After Bob says "I'm sending up the man who did the job", the elevator call button will also open the doors - ft=Spawn(class'#var(prefix)FlagTrigger'); - ft.SetCollision(False,False,False); - ft.bSetFlag=False; - ft.bTrigger=True; - ft.FlagName='DL_elevator_Played'; - ft.flagValue=True; - ft.Tag='elevator_floor1'; - ft.Event='elevator_doors'; - Spawn(class'#var(prefix)Liquor40oz',,, vectm(4585,72,-174)); //Beers on the table in the sleeping quarters Spawn(class'#var(prefix)Liquor40oz',,, vectm(4611,27,-174)); @@ -504,6 +510,8 @@ function PreFirstEntryMapFixes_Entrance(bool isVanilla) class'PlaceholderEnemy'.static.Create(self,vectm(2977,2306,-176),,'Sitting'); } else { + AddSwitch( vect(-3043,180,-145), rot(0, 32768, 0), 'final_door'); + Spawn(class'PlaceholderItem',,, vectm(1584,-628,-350)); //Near karkians under Everett Spawn(class'PlaceholderItem',,, vectm(4078,-2469,10)); //Boxes right at entrance Spawn(class'PlaceholderItem',,, vectm(4022.8,-710.4,-149)); //Boxes near barracks @@ -548,6 +556,28 @@ function PreFirstEntryMapFixes_Page(bool isVanilla) local AmbientSound as; local DXRAmbientSoundTrigger ast; + if(!dxr.flags.IsZeroRando()) { + //Rather than duplicating the existing cubes, add new clone text so there are more possibilities + if (isVanilla){ + cloneCubeLoc[0]=vectm(6197.620117,-8455.201172,-5117.649902); //Weird little window near broken door (on Page side) + cloneCubeLoc[1]=vectm(5663.339355,-7955.502441,-5557.624512); //On boxes outside middle level UC door + cloneCubeLoc[2]=vectm(6333.112305,-7241.149414,-5557.636719); //On boxes right near middle level blue fusion reactor + cloneCubeLoc[3]=vectm(7687.463867,-8845.201172,-5940.627441); //On control panel that has flame button in coolant area + } else { + cloneCubeLoc[0]=vectm(275,1250,250); //Desk at entrance near page + cloneCubeLoc[1]=vectm(-500,1650,-185); //Boxes near middle level UC door + cloneCubeLoc[2]=vectm(270,2400,-185); //Boxes near middle level blue fusion reactor + cloneCubeLoc[3]=vectm(1440,800,-575); //On coolant area front desk + } + cloneCubeText[0]="SUBJECT MJID-5493OP2702|nINCEPT DATE: 3/19/65|nASSIGNED BIRTH DATE: 7/20/41|nASSIGNED BIRTH NAME: Stan Carnegie|nBASE GENETIC SAMPLE: SIMONSWALTON32A|nPROFILE: AABCAAB|nVITALS: 45/80/0.89/33/1.2|n|n [[[[[PENDING]]]]]"; + cloneCubeText[1]="SUBJECT MJID-2938BU3209|nINCEPT DATE: 7/30/66|nASSIGNED BIRTH DATE: 9/07/40|nASSIGNED BIRTH NAME: Greg Pequod|nBASE GENETIC SAMPLE: |nPAGEBOB86G|nPROFILE: BAABACA|nVITALS: 51/72/1.02/20/2.1|n|n [[[[[PENDING]]]]]"; + cloneCubeText[2]="SUBJECT MJID-3209FG2938|nINCEPT DATE: 7/30/66|nASSIGNED BIRTH DATE: 9/07/40|nASSIGNED BIRTH NAME: Jacob Queequeg|nBASE GENETIC SAMPLE: STRONGHOWARD52L|nPROFILE: CAAGATA|nVITALS: 52/73/1.01/20/2.2|n|n [[[[[PENDING]]]]]"; + cloneCubeText[3]="SUBJECT MJID-3209FG2938|nINCEPT DATE: 6/17/54|nASSIGNED BIRTH DATE: 11/30/35|nASSIGNED BIRTH NAME: Jason Frudnick|nBASE GENETIC SAMPLE: GARDNERKANE88J|nPROFILE: BABTAGA|nVITALS: 51/81/1.13/20/2.0|n|n [[[[[PENDING]]]]]"; + for(i=0;i<4;i++){ + SpawnDatacubePlaintext(cloneCubeLoc[i],rotm(0,0,0,0),cloneCubeText[i],"CloneCube"$string(i+1)); + } + } + if (isVanilla) { // fix in-fighting foreach AllActors(class'#var(prefix)ScriptedPawn', sp) { @@ -595,21 +625,6 @@ function PreFirstEntryMapFixes_Page(bool isVanilla) } } - if(!dxr.flags.IsZeroRando()) { - //Rather than duplicating the existing cubes, add new clone text so there are more possibilities - cloneCubeLoc[0]=vectm(6197.620117,-8455.201172,-5117.649902); //Weird little window near broken door (on Page side) - cloneCubeLoc[1]=vectm(5663.339355,-7955.502441,-5557.624512); //On boxes outside middle level UC door - cloneCubeLoc[2]=vectm(6333.112305,-7241.149414,-5557.636719); //On boxes right near middle level blue fusion reactor - cloneCubeLoc[3]=vectm(7687.463867,-8845.201172,-5940.627441); //On control panel that has flame button in coolant area - cloneCubeText[0]="SUBJECT MJID-5493OP2702|nINCEPT DATE: 3/19/65|nASSIGNED BIRTH DATE: 7/20/41|nASSIGNED BIRTH NAME: Stan Carnegie|nBASE GENETIC SAMPLE: SIMONSWALTON32A|nPROFILE: AABCAAB|nVITALS: 45/80/0.89/33/1.2|n|n [[[[[PENDING]]]]]"; - cloneCubeText[1]="SUBJECT MJID-2938BU3209|nINCEPT DATE: 7/30/66|nASSIGNED BIRTH DATE: 9/07/40|nASSIGNED BIRTH NAME: Greg Pequod|nBASE GENETIC SAMPLE: |nPAGEBOB86G|nPROFILE: BAABACA|nVITALS: 51/72/1.02/20/2.1|n|n [[[[[PENDING]]]]]"; - cloneCubeText[2]="SUBJECT MJID-3209FG2938|nINCEPT DATE: 7/30/66|nASSIGNED BIRTH DATE: 9/07/40|nASSIGNED BIRTH NAME: Jacob Queequeg|nBASE GENETIC SAMPLE: STRONGHOWARD52L|nPROFILE: CAAGATA|nVITALS: 52/73/1.01/20/2.2|n|n [[[[[PENDING]]]]]"; - cloneCubeText[3]="SUBJECT MJID-3209FG2938|nINCEPT DATE: 6/17/54|nASSIGNED BIRTH DATE: 11/30/35|nASSIGNED BIRTH NAME: Jason Frudnick|nBASE GENETIC SAMPLE: GARDNERKANE88J|nPROFILE: BABTAGA|nVITALS: 51/81/1.13/20/2.0|n|n [[[[[PENDING]]]]]"; - for(i=0;i<4;i++){ - SpawnDatacubePlaintext(cloneCubeLoc[i],rotm(0,0,0,0),cloneCubeText[i],"CloneCube"$string(i+1)); - } - } - if(!dxr.flags.IsZeroRando()) { //Add a switch to manually trigger the infolink that gives you the Helios computer password AddSwitch( vect(5635.609375,-5352.036133,-5240.890625), rot(0, 0, 0), 'PasswordCallReset', "Forgot your Password?"); diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupParis.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupParis.uc index 7281c1acf..cf3a5552f 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupParis.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupParis.uc @@ -40,8 +40,27 @@ function PreFirstEntryMapFixes() elevatortrig = Spawn(class'DXRMoverSequenceTrigger',, 'roof_elevator_call'); elevatortrig.Event = 'roof_elevator'; + if(!VanillaMaps){ + //Revision, entrance to closed Metro station (split to a separate map) + foreach AllActors(class'#var(prefix)MapExit',exit,'change_map'){break;} + foreach AllActors(class'DeusExMover', m) { + if (m.Event=='change_map'){ + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", m.Location-m.PrePivot, 40, 75,exit); + } + } + } + break; + case "10_PARIS_CATACOMBS_METRO": //Revision-only map, the little underground mall area + foreach AllActors(class'#var(prefix)MapExit',exit,'change_map'){break;} + foreach AllActors(class'DeusExMover', m) { + if (m.Event=='change_map'){ + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", m.Location-m.PrePivot, 40, 75,exit); + } + } + + break; case "10_PARIS_CATACOMBS_TUNNELS": if (VanillaMaps){ foreach AllActors(class'Trigger', t) @@ -64,7 +83,6 @@ function PreFirstEntryMapFixes() } } - class'PlaceholderEnemy'.static.Create(self,vectm(-362,-3444,-32)); class'PlaceholderEnemy'.static.Create(self,vectm(-743,677,-256)); } else { @@ -75,6 +93,12 @@ function PreFirstEntryMapFixes() } AddSwitch( vect(897.238892, -120.852928, -9.965580), rot(0,0,0), 'catacombs_blastdoor02' ); + foreach AllActors(class'ScriptedPawn', sp, 'hostage_female') { + sp.GroundSpeed = 200.0; // same speed as the male hostage + sp.walkAnimMult = 1.11; + break; + } + class'PlaceholderEnemy'.static.Create(self,vectm(-1573,-113,-64)); class'PlaceholderEnemy'.static.Create(self,vectm(781,1156,-32)); @@ -156,14 +180,14 @@ function PreFirstEntryMapFixes() // make the apartment stairs less hidden, not safe to have stairs without a light! CandleabraLight(vect(1825.758057, 1481.900024, 576.077698), rot(0, 16384, 0)); CandleabraLight(vect(1162.240112, 1481.900024, 879.068848), rot(0, 16384, 0)); - - //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit,'ChopperExit'){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); - hoverHint.SetBaseActor(jock); } + //Add teleporter hint text to Jock + foreach AllActors(class'#var(prefix)MapExit',exit,'ChopperExit'){break;} + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); + hoverHint.SetBaseActor(jock); + //If neither flag is set, JC never talked to Jaime, so he just didn't bother if (!dxr.flagbase.GetBool('JaimeRecruited') && !dxr.flagbase.GetBool('JaimeLeftBehind')){ //Need to pretend he *was* recruited, so that he doesn't spawn @@ -290,7 +314,7 @@ function PreFirstEntryMapFixes() //Add teleporter hint text to Jock foreach AllActors(class'#var(prefix)MapExit',exit,'CalledByDispatcher'){break;} foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); hoverHint.SetBaseActor(jock); SetAllLampsState(true, false, true); // Everett's bedroom @@ -457,6 +481,10 @@ function PostFirstEntryMapFixes() { local #var(prefix)WIB wib; local #var(prefix)NicoletteDuclare nico; + local #var(prefix)NanoKey k; + local #var(PlayerPawn) p; + + p = player(); switch(dxr.localURL) { case "10_PARIS_METRO": @@ -466,6 +494,18 @@ function PostFirstEntryMapFixes() break; } } + + k = None; + if (class'DXRMapVariants'.static.IsVanillaMaps(p)) { + k = Spawn(class'#var(prefix)NanoKey',,, vectm(2513.0, 2439.0, 458.0)); + } else if (class'DXRMapVariants'.static.IsRevisionMaps(p)) { + k = Spawn(class'#var(prefix)NanoKey',,, vectm(1225.0, 3005.0, 495.0)); + } + if (k != None) { + k.Description = "Hotel key"; + k.KeyID = 'hotel_roomdoor'; + } + break; case "11_PARIS_CATHEDRAL": AddBox(class'#var(prefix)CrateUnbreakableSmall', vectm(-3570.950684, 2238.034668, -783.901367));// right at the start diff --git a/DXRMapFixups/DeusEx/Classes/DXRFixupVandenberg.uc b/DXRMapFixups/DeusEx/Classes/DXRFixupVandenberg.uc index ceb02e03b..6849f13d9 100644 --- a/DXRMapFixups/DeusEx/Classes/DXRFixupVandenberg.uc +++ b/DXRMapFixups/DeusEx/Classes/DXRFixupVandenberg.uc @@ -42,6 +42,9 @@ function PreFirstEntryMapFixes() local #var(prefix)FishGenerator fg; local #var(prefix)MapExit exit; local #var(prefix)BlackHelicopter jock; +#ifdef revision + local JockHelicopter jockheli; +#endif local DXRHoverHint hoverHint; local ScriptedPawn pawn; local #var(prefix)ScriptedPawn sp; @@ -118,17 +121,24 @@ function PreFirstEntryMapFixes() if (VanillaMaps){ VandenbergCmdFixTimsDoor(); + FixCmdElevator(); + UnleashingBotsOpenCommsDoor(); + } else { + VandenbergCmdRevisionFixWatchtowerDoor(); + } - //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit,'mission_done'){break;} + //Add teleporter hint text to Jock + foreach AllActors(class'#var(prefix)MapExit',exit,'mission_done'){break;} + if (VanillaMaps){ foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'Helicopter'){break;} hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); hoverHint.SetBaseActor(jock); - - FixCmdElevator(); - UnleashingBotsOpenCommsDoor(); } else { - VandenbergCmdRevisionFixWatchtowerDoor(); + #ifdef revision + foreach AllActors(class'JockHelicopter',jockheli){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif } foreach AllActors(class'#var(prefix)Robot',bot,'enemy_bot') { @@ -154,20 +164,23 @@ function PreFirstEntryMapFixes() break; case "12_VANDENBERG_TUNNELS": + + foreach AllActors(class'ElevatorMover', e, 'Security_door3') { + e.BumpType = BT_PlayerBump; + e.BumpEvent = 'SC_Door3_opened'; + } + //Duplicate the dispatcher for both ends of the radioactive room that sets off the alarms and explosion + d = Spawn(class'Dispatcher',, 'SC_Door3_opened' ); + d.OutEvents[0]='Warning'; + d.OutDelays[0]=0; + d.OutEvents[1]='tnt'; + d.OutDelays[1]=3; + d.OutEvents[2]='Warning'; + d.OutDelays[2]=2; + if (VanillaMaps){ - foreach AllActors(class'ElevatorMover', e, 'Security_door3') { - e.BumpType = BT_PlayerBump; - e.BumpEvent = 'SC_Door3_opened'; - } + //Backtracking button next to security door 3 AddSwitch( vect(-396.634888, 2295, -2542.310547), rot(0, -16384, 0), 'SC_Door3_opened').bCollideWorld = false; - //Duplicate the dispatcher for both ends of the radioactive room that sets off the alarms and explosion - d = Spawn(class'Dispatcher',, 'SC_Door3_opened' ); - d.OutEvents[0]='Warning'; - d.OutDelays[0]=0; - d.OutEvents[1]='tnt'; - d.OutDelays[1]=3; - d.OutEvents[2]='Warning'; - d.OutDelays[2]=2; //Swap the beam triggers that set off this turret to LaserTrigger for clarity foreach AllActors(class'#var(prefix)BeamTrigger',bt){ @@ -184,6 +197,12 @@ function PreFirstEntryMapFixes() Spawn(class'PlaceholderItem',,, vectm(-3227,3679,-2599)); //floor near stairwell down to flooded area Spawn(class'PlaceholderItem',,, vectm(-1590,2796,-2599)); //airlock after spiderbot trap } else { + //Backtracking button next to security door 3 (Different X location in Revision) + AddSwitch( vect(2710, 2295, -2542), rot(0, -16384, 0), 'SC_Door3_opened').bCollideWorld = false; + + //Backtracking button on backside of end-of-tunnels forklift + AddSwitch( vect(2778,1371,-2550), rot(0, -10904, 0), 'waataaa'); + Spawn(class'PlaceholderItem',,, vectm(-3227,3679,-2520)); //boxes near stairwell down to flooded area Spawn(class'PlaceholderItem',,, vectm(-1640,2796,-2599)); //airlock after spiderbot trap } @@ -272,11 +291,19 @@ function PreFirstEntryMapFixes() //Add teleporter hint text to Jock foreach AllActors(class'#var(prefix)MapExit',exit,'ChopperExit'){break;} foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit); hoverHint.SetBaseActor(jock); } else { AddSwitch( vect(540,3890,-370), rot(0, 16384, 0), 'ShedDoor'); + //Add teleporter hint text to Jock + #ifdef revision + foreach AllActors(class'#var(prefix)MapExit',exit,'ChopperExit'){break;} + foreach AllActors(class'JockHelicopter',jockheli,'BlackHelicopter'){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif + Spawn(class'PlaceholderItem',,, vectm(718,3913,-355)); //Shed Spawn(class'PlaceholderItem',,, vectm(723,3972,-355)); //Shed Spawn(class'PlaceholderItem',,, vectm(726,4050,-365)); //Shed @@ -292,20 +319,19 @@ function PreFirstEntryMapFixes() // backtracking button for greasel lab AddSwitch( vect(1889.5, 491.932892, -1535.522339), rot(0, 0, 0), 'Glab'); + foreach AllActors(class'#var(DeusExPrefix)Mover',door){ + if(door.KeyIDNeeded=='crewkey'){ + door.Tag = 'crewkey'; + } + if(door.KeyIDNeeded=='Glab'){ + door.Tag = 'Glab'; + } + } if (VanillaMaps){ if(!#defined(vmd))// button to open the door heading towards the ladder in the water AddSwitch( vect(3077.360107, 497.609467, -1738.858521), rot(0, 0, 0), 'Access'); - foreach AllActors(class'#var(DeusExPrefix)Mover',door){ - if(door.KeyIDNeeded=='crewkey'){ - door.Tag = 'crewkey'; - } - if(door.KeyIDNeeded=='Glab'){ - door.Tag = 'Glab'; - } - } - foreach AllActors(class'ComputerSecurity', comp) { if( comp.UserList[0].userName == "Kraken" && comp.UserList[0].Password == "Oceanguard" ) { comp.UserList[0].userName = "Oceanguard"; @@ -449,17 +475,17 @@ function PreFirstEntryMapFixes() } } - //Add teleporter hint text to Jock - foreach AllActors(class'#var(prefix)MapExit',exit,'ExitPath'){break;} - foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} - hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); - hoverHint.SetBaseActor(jock); - class'FrictionTrigger'.static.CreateIce(self, vectm(28.63,-5129.48,-231.285), 1190, 650); class'PlaceholderEnemy'.static.Create(self,vectm(270,-6601,1500)); //This one is locked inside a fence in Revision, so only use it in Vanilla } + //Add teleporter hint text to Jock + foreach AllActors(class'#var(prefix)MapExit',exit,'ExitPath'){break;} + foreach AllActors(class'#var(prefix)BlackHelicopter',jock,'BlackHelicopter'){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jock.Location, jock.CollisionRadius+5, jock.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jock); + //The door closing behind you when the ambush starts sucks if you came in via the silo. //Just make it not close. foreach AllActors(class'SequenceTrigger', st, 'doorclose') { @@ -541,6 +567,14 @@ function PreFirstEntryMapFixes() Spawn(class'PlaceholderItem',,, vectm(909,-2474,-1551)); //Wrecked car Spawn(class'PlaceholderItem',,, vectm(-3152,-2780,-1364)); //Ledge near original key } else { + //Add teleporter hint text to Jock + #ifdef revision + foreach AllActors(class'#var(prefix)MapExit',exit,'exit'){break;} + foreach AllActors(class'JockHelicopter',jockheli,'Heli'){break;} + hoverHint = class'DXRTeleporterHoverHint'.static.Create(self, "", jockheli.Location, jockheli.CollisionRadius+5, jockheli.CollisionHeight+5, exit,, true); + hoverHint.SetBaseActor(jockheli); + #endif + class'PlaceholderEnemy'.static.Create(self,vectm(886,1044,-930)); Spawn(class'PlaceholderItem',,, vectm(-366,-2276,-1553)); //Under collapsed bridge diff --git a/DXRMissions/DeusEx/Classes/DXRMissionsM02.uc b/DXRMissions/DeusEx/Classes/DXRMissionsM02.uc index 5475ba002..c2bd4d2b4 100644 --- a/DXRMissions/DeusEx/Classes/DXRMissionsM02.uc +++ b/DXRMissions/DeusEx/Classes/DXRMissionsM02.uc @@ -20,12 +20,12 @@ function int InitGoals(int mission, string map) AddActorLocation(loc, PLAYER_LOCATION, vect(81.434570, -1123.060547, -384.397644), rot(0, 8000, 0)); AddGoalLocation("02_NYC_BATTERYPARK", "In the command room", NORMAL_GOAL, vect(650.060547, -989.234863, -160.095200), rot(0, 0, 0)); - AddGoalLocation("02_NYC_BATTERYPARK", "Behind the cargo", NORMAL_GOAL, vect(58.725319, -446.887207, -405.899323), rot(0, 0, 0)); - AddGoalLocation("02_NYC_BATTERYPARK", "By the desk", NORMAL_GOAL, vect(-615.152161, -665.281738, -397.581146), rot(0, 0, 0)); - AddGoalLocation("02_NYC_BATTERYPARK", "Walkway by the water", NORMAL_GOAL, vect(-420.000000, -2222.000000, -400), rot(0, 0, 0)); - loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway stairs", NORMAL_GOAL, vect(-5106.205078, 1813.453003, -82.239639), rot(0, 0, 0)); + AddGoalLocation("02_NYC_BATTERYPARK", "Behind the cargo", NORMAL_GOAL, vect(58.725319, -446.887207, -405.899323), rot(0, 32768, 0)); + AddGoalLocation("02_NYC_BATTERYPARK", "By the desk", NORMAL_GOAL, vect(-615.152161, -665.281738, -397.581146), rot(0, -24786, 0)); + AddGoalLocation("02_NYC_BATTERYPARK", "Walkway by the water", NORMAL_GOAL, vect(-420.000000, -2222.000000, -400), rot(0, 16436, 0)); + loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway stairs", NORMAL_GOAL, vect(-5106.205078, 1813.453003, -82.239639), rot(0, -16412, 0)); AddMutualExclusion(loc, shanty_start);// don't put ambrosia in the subway if you start right there in the shanty town, too easy - loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway", NORMAL_GOAL, vect(-4727.703613, 3116.336670, -321.900604), rot(0, 0, 0)); + loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway", NORMAL_GOAL, vect(-4727.703613, 3116.336670, -321.900604), rot(0, -49276, 0)); AddMutualExclusion(loc, shanty_start);// don't put ambrosia in the subway if you start right there in the shanty town, too easy if (dxr.flags.settings.starting_map > 20) @@ -95,11 +95,11 @@ function int InitGoalsRev(int mission, string map) AddGoalLocation("02_NYC_BATTERYPARK", "In the command room", NORMAL_GOAL, vect(650.060547, -989.234863, -160.095200), rot(0, 0, 0)); AddGoalLocation("02_NYC_BATTERYPARK", "Behind the cargo", NORMAL_GOAL, vect(185,-30,-405), rot(0, 32768, 0)); - AddGoalLocation("02_NYC_BATTERYPARK", "By the desk", NORMAL_GOAL, vect(-615.152161, -665.281738, -397.581146), rot(0, 0, 0)); - AddGoalLocation("02_NYC_BATTERYPARK", "Walkway by the water", NORMAL_GOAL, vect(-420.000000, -2222.000000, -400), rot(0, 0, 0)); - loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway stairs", NORMAL_GOAL, vect(-5106.205078, 1813.453003, -82.239639), rot(0, 0, 0)); + AddGoalLocation("02_NYC_BATTERYPARK", "By the desk", NORMAL_GOAL, vect(-615.152161, -665.281738, -397.581146), rot(0, -24786, 0)); + AddGoalLocation("02_NYC_BATTERYPARK", "Walkway by the water", NORMAL_GOAL, vect(-420.000000, -2222.000000, -400), rot(0, 16436, 0)); + loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway stairs", NORMAL_GOAL, vect(-5106.205078, 1813.453003, -82.239639), rot(0, -16412, 0)); AddMutualExclusion(loc, shanty_start);// don't put ambrosia in the subway if you start right there in the shanty town, too easy - loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway", NORMAL_GOAL, vect(-4727.703613, 3116.336670, -321.900604), rot(0, 0, 0)); + loc = AddGoalLocation("02_NYC_BATTERYPARK", "Subway", NORMAL_GOAL, vect(-4727.703613, 3116.336670, -321.900604), rot(0, -49276, 0)); AddMutualExclusion(loc, shanty_start);// don't put ambrosia in the subway if you start right there in the shanty town, too easy if (dxr.flags.settings.starting_map > 20) diff --git a/DXRMissions/DeusEx/Classes/DXRMissionsM03.uc b/DXRMissions/DeusEx/Classes/DXRMissionsM03.uc index 71ce0af21..0027456a2 100644 --- a/DXRMissions/DeusEx/Classes/DXRMissionsM03.uc +++ b/DXRMissions/DeusEx/Classes/DXRMissionsM03.uc @@ -214,7 +214,7 @@ function int InitGoalsRev(int mission, string map) AddGoalLocation("03_NYC_747", "Cargo", NORMAL_GOAL | VANILLA_GOAL, vect(-147.147064,-511.348846,158.870544), rot(0,15760,0)); AddGoalLocation("03_NYC_747", "Office", NORMAL_GOAL, vect(6,-736,339), rot(0,-32,0)); - AddGoalLocation("03_NYC_747", "Flight Deck", NORMAL_GOAL, vect(1339,-513,484), rot(0,16480,0)); + AddGoalLocation("03_NYC_747", "Flight Deck", NORMAL_GOAL, vect(1530,-505,484), rot(0,16480,0)); AddGoalLocation("03_NYC_747", "Bedroom", NORMAL_GOAL, vect(1594,-710,368), rot(0,0,0)); AddGoalLocation("03_NYC_HANGAR", "Near Trailers", NORMAL_GOAL, vect(1867,-1318,29), rot(0,0,0)); AddGoalLocation("03_NYC_HANGAR", "Near Engine", NORMAL_GOAL, vect(4140,-1554,29), rot(0,32776,0)); diff --git a/DXRModules/DeusEx/Classes/DXRBingoCampaign.uc b/DXRModules/DeusEx/Classes/DXRBingoCampaign.uc index 0e3a2c70c..a4e406ae6 100644 --- a/DXRModules/DeusEx/Classes/DXRBingoCampaign.uc +++ b/DXRModules/DeusEx/Classes/DXRBingoCampaign.uc @@ -6,6 +6,7 @@ function FirstEntry() local #var(prefix)FlagTrigger ft; local DeusExMover mover; local Vector loc; + local DXRHoverHint hoverHint; if (!dxr.flags.IsBingoCampaignMode()) return; @@ -69,7 +70,8 @@ function FirstEntry() if (loc != vect(0, 0, 0)) { loc = (loc + mover.Location) * 0.5; loc.z += 120.0; - class'DXRHoverHint'.static.Create(self, "", loc, 50.0, 96.0,,, true); + hoverHint = class'DXRHoverHint'.static.Create(self, "", loc, 50.0, 96.0,,, true); + hoverHint.tag = 'crypt_hint'; break; } loc = mover.Location; @@ -346,6 +348,7 @@ function AddBingoEventBlocker(name blockedTag, name bingoFlag) { function UpdateCryptDoors() { local #var(prefix)FlagTrigger ft; + local DXRHoverHint hoverHint; if ( dxr.localURL == "10_PARIS_CHATEAU" && @@ -358,6 +361,10 @@ function UpdateCryptDoors() ft.Trigger(None, None); break; } + foreach AllActors(class'DXRHoverHint', hoverHint, 'crypt_hint') { + hoverHint.Destroy(); + break; + } } } diff --git a/DXRModules/DeusEx/Classes/DXRCameraModes.uc b/DXRModules/DeusEx/Classes/DXRCameraModes.uc index e90fbe74c..d7f8354d1 100644 --- a/DXRModules/DeusEx/Classes/DXRCameraModes.uc +++ b/DXRModules/DeusEx/Classes/DXRCameraModes.uc @@ -116,16 +116,16 @@ function SetThirdPersonCamera() function SetFixedCamera() { -#ifdef vanilla - player().bBehindView=False; - player().bCrosshairVisible=False; - player().Style= STY_Normal; - if (reCam==None || reCam.bDeleteMe){ - SpawnRECam(); + if(#defined(vanilla || revision)){ + player().bBehindView=False; + player().bCrosshairVisible=False; + player().Style= STY_Normal; + if (reCam==None || reCam.bDeleteMe){ + SpawnRECam(); + } + } else { + err("Fixed camera not supported in this mod!"); } -#else - err("Fixed camera only supported in vanilla!"); -#endif } function SpawnRECam() diff --git a/DXRModules/DeusEx/Classes/DXRCrowdControl.uc b/DXRModules/DeusEx/Classes/DXRCrowdControl.uc index ceb4778d7..96f78c228 100644 --- a/DXRModules/DeusEx/Classes/DXRCrowdControl.uc +++ b/DXRModules/DeusEx/Classes/DXRCrowdControl.uc @@ -342,6 +342,24 @@ function InitStupidQuestions() { _StupidQuestions[numStupidQuestions].answers[0] = "Makeup"; _StupidQuestions[numStupidQuestions].answers[1] = "Shoes"; numStupidQuestions++; + + _StupidQuestions[numStupidQuestions].Question = "Does a straw have one hole or two?"; + _StupidQuestions[numStupidQuestions].numAnswers = 2; + _StupidQuestions[numStupidQuestions].answers[0] = "One"; + _StupidQuestions[numStupidQuestions].answers[1] = "Two"; + numStupidQuestions++; + + _StupidQuestions[numStupidQuestions].Question = "If a cyclops closes its eye, is it winking or blinking?"; + _StupidQuestions[numStupidQuestions].numAnswers = 2; + _StupidQuestions[numStupidQuestions].answers[0] = "Winking"; + _StupidQuestions[numStupidQuestions].answers[1] = "Blinking"; + numStupidQuestions++; + + _StupidQuestions[numStupidQuestions].Question = "If you stack lasagnas on top of each other, do you have one lasagna or two?"; + _StupidQuestions[numStupidQuestions].numAnswers = 2; + _StupidQuestions[numStupidQuestions].answers[0] = "One"; + _StupidQuestions[numStupidQuestions].answers[1] = "Two"; + numStupidQuestions++; } diff --git a/DXRModules/DeusEx/Classes/DXRDatacubes.uc b/DXRModules/DeusEx/Classes/DXRDatacubes.uc index 2ff6686a1..b218ce7e2 100644 --- a/DXRModules/DeusEx/Classes/DXRDatacubes.uc +++ b/DXRModules/DeusEx/Classes/DXRDatacubes.uc @@ -420,6 +420,28 @@ function vanilla_datacubes_rules() datacubes_rules[i].max_pos = vect(99999, 99999, 1345); //1345 is the top of the pipe datacubes_rules[i].allow = true; i++; + + //The datacube with the code for the door lock + //Don't allow in that alcove between the doors + datacubes_rules[i].item_name = '06_Datacube30'; + datacubes_rules[i].min_pos = vect(50, -1700, 875); + datacubes_rules[i].max_pos = vect(100, -1800, 925); + datacubes_rules[i].allow = false; + i++; + + //Don't allow at the bottom of the stairs + datacubes_rules[i].item_name = '06_Datacube30'; + datacubes_rules[i].min_pos = vect(300, -2050, 450); + datacubes_rules[i].max_pos = vect(400, -2150, 550); + datacubes_rules[i].allow = false; + i++; + + //Before the doors! + datacubes_rules[i].item_name = '06_Datacube30'; + datacubes_rules[i].min_pos = vect(-99999, -900, 800); //The items in the alcove in the lower hallway + datacubes_rules[i].max_pos = vect(99999, 99999, 1345); //1345 is the top of the pipe + datacubes_rules[i].allow = true; + i++; break; case "08_NYC_HOTEL": diff --git a/DXRModules/DeusEx/Classes/DXRDoors.uc b/DXRModules/DeusEx/Classes/DXRDoors.uc index 1673ff440..7b6af2d0e 100644 --- a/DXRModules/DeusEx/Classes/DXRDoors.uc +++ b/DXRModules/DeusEx/Classes/DXRDoors.uc @@ -227,6 +227,14 @@ function CheckConfig() door_fixes[i].bHighlight = false; i++; + //This is already the case in vanilla, but align Revision to it. + //Make sure the Helios door itself can't be interacted with (keypad is still viable, or computer) + door_fixes[i].tag = 'door_helios_room'; + door_fixes[i].bHighlight = false; + door_fixes[i].bBreakable = false; + door_fixes[i].bPickable = false; + i++; + break; } diff --git a/DXRModules/DeusEx/Classes/DXREvents.uc b/DXRModules/DeusEx/Classes/DXREvents.uc index e4db22d4d..19ad21f58 100644 --- a/DXRModules/DeusEx/Classes/DXREvents.uc +++ b/DXRModules/DeusEx/Classes/DXREvents.uc @@ -1170,6 +1170,7 @@ function SetWatchFlags() { bt = class'BingoTrigger'.static.Create(self,'TrainTracks',zone.Location,3000,1); break; case "12_VANDENBERG_GAS": + WatchFlag('TiffanyHeli'); bt = class'BingoTrigger'.static.Create(self,'support1',vectm(0,0,0)); //This gets hit when you blow up the gas pumps if (RevisionMaps){ bt = class'BingoTrigger'.static.Create(self,'GasStationCeiling',vectm(1222,1078,-700),150,10); @@ -2080,12 +2081,18 @@ function string RemapBingoEvent(string eventname) } -static function int GetBingoFailedEvents(string eventname, out string failed[5]) +static function int GetBingoFailedEvents(string eventname, out string failed[6]) { local int num_failed; local DXRando dxr; dxr = class'DXRando'.default.dxr; + if (Right(eventname, 12) == "_Unconscious") { + failed[num_failed++] = Left(eventname, Len(eventname) - 11) $ "Dead"; + } else if (Right(eventname, 5) == "_Dead") { + failed[num_failed++] = Left(eventname, Len(eventname) - 4) $ "Unconscious"; + } + // keep in mind that a goal can only be marked as failed if it isn't already marked as completed switch (eventname) { @@ -2100,28 +2107,36 @@ static function int GetBingoFailedEvents(string eventname, out string failed[5]) failed[num_failed++] = "AlleyBumRescued"; return num_failed; case "FordSchick_Dead": + case "FordSchick_Unconscious": failed[num_failed++] = "FordSchickRescued"; return num_failed; case "GeneratorBlown": failed[num_failed++] = "JockSecondStory"; return num_failed; case "SandraRenton_Dead": + case "SandraRenton_Unconscious": failed[num_failed++] = "FamilySquabbleWrapUpGilbertDead_Played"; + failed[num_failed++] = "MeetSandraRenton_Played"; return num_failed; case "GilbertRenton_Dead": + case "GilbertRenton_Unconscious": if (class'DXRando'.default.dxr.localURL != "04_NYC_HOTEL") { failed[num_failed++] = "FamilySquabbleWrapUpGilbertDead_Played"; } failed[num_failed++] = "GaveRentonGun"; // fallthrough case "FemaleHostage_Dead": + case "FemaleHostage_Unconscious": case "MaleHostage_Dead": + case "MaleHostage_Unconscious": failed[num_failed++] = "HotelHostagesSaved"; return num_failed; case "Josh_Dead": + case "Josh_Unconscious": failed[num_failed++] = "JoshFed"; return num_failed; case "Billy_Dead": + case "Billy_Unconscious": failed[num_failed++] = "M02BillyDone"; return num_failed; case "Don_Dead": @@ -2134,15 +2149,18 @@ static function int GetBingoFailedEvents(string eventname, out string failed[5]) failed[num_failed++] = "OverhearLebedev_Played"; return num_failed; case "JuanLebedev_Dead": + case "JuanLebedev_Unconscious": failed[num_failed++] = "LebedevLived"; return num_failed; case "JoJoFine_Dead": + case "JoJoFine_Unconscious": failed[num_failed++] = "GaveRentonGun"; return num_failed; case "NSFSignalSent": failed[num_failed++] = "M04PlayerLikesUNATCO_Played"; return num_failed; case "Miguel_Dead": + case "Miguel_Unconscious": failed[num_failed++] = "Terrorist_peeptime"; failed[num_failed++] = "Terrorist_ClassDead"; failed[num_failed++] = "Terrorist_ClassUnconscious"; @@ -2156,22 +2174,29 @@ static function int GetBingoFailedEvents(string eventname, out string failed[5]) failed[num_failed++] = "KnowsGuntherKillphrase"; return num_failed; case "M06Junkie_Dead": + case "M06Junkie_Unconscious": failed[num_failed++] = "M06PaidJunkie"; return num_failed; case "MarketBum1_Dead": // the guy who sells you the Versalife map and camo, isn't in the market, and looks nothing like a bum + case "MarketBum1_Unconscious": failed[num_failed++] = "M06BoughtVersaLife"; return num_failed; case "Canal_Bartender_Dead": + case "Canal_Bartender_Unconscious": failed[num_failed++] = "Canal_Bartender_Question4"; return num_failed; case "ClubBartender_Dead": + case "ClubBartender_Unconscious": failed[num_failed++] = "M06BartenderQuestion3"; return num_failed; case "MaggieChow_Dead": + case "MaggieChow_Unconscious": failed[num_failed++] = "MaggieLived"; return num_failed; case "Mamasan_Dead": + case "Mamasan_Unconscious": case "Date1_Dead": + case "Date1_Unconscious": failed[num_failed++] = "M06JCHasDate"; return num_failed; case "Raid_Underway": //Raid started @@ -2179,43 +2204,60 @@ static function int GetBingoFailedEvents(string eventname, out string failed[5]) failed[num_failed++] = "ClubEntryPaid"; return num_failed; case "ClubMercedes_Dead": + case "ClubMercedes_Unconscious": case "ClubTessa_Dead": + case "ClubTessa_Unconscious": if (!dxr.flagbase.GetBool('LDDPJCIsFemale')) { failed[num_failed++] = "ClubEntryPaid"; } return num_failed; case "LDDPRuss_Dead": + case "LDDPRuss_Unconscious": if (dxr.flagbase.GetBool('LDDPJCIsFemale')) { failed[num_failed++] = "ClubEntryPaid"; } return num_failed; case "Supervisor01_Dead": + case "Supervisor01_Unconscious": failed[num_failed++] = "Supervisor_Paid"; return num_failed; case "Aimee_Dead": + case "Aimee_Unconscious": case "LeMerchant_Dead": + case "LeMerchant_Unconscious": failed[num_failed++] = "AimeeLeMerchantLived"; return num_failed; case "hostage_female_Dead": + case "hostage_female_Unconscious": case "hostage_Dead": + case "hostage_Unconscious": failed[num_failed++] = "SilhouetteHostagesAllRescued"; return num_failed; case "Renault_Dead": + case "Renault_Unconscious": failed[num_failed++] = "SoldRenaultZyme"; failed[num_failed++] = "MeetRenault_Played"; return num_failed; case "Joshua_Dead": + case "Joshua_Unconscious": failed[num_failed++] = "JoshuaInterrupted_Played"; return num_failed; case "Camille_Dead": + case "Camille_Unconscious": failed[num_failed++] = "CamilleConvosDone"; return num_failed; case "drbernard_Dead": + case "drbernard_Unconscious": failed[num_failed++] = "MeetDrBernard_Played"; return num_failed; case "TimBaker_Dead": + case "TimBaker_Unconscious": failed[num_failed++] = "MeetTimBaker_Played"; return num_failed; + case "TiffanySavage_Dead": + case "TiffanySavage_Unconscious": + failed[num_failed++] = "TiffanyHeli"; + break; } return num_failed; @@ -2238,13 +2280,13 @@ static simulated function string GetBingoGoalHelpText(string event,int mission, case "SandraRenton_Dead": msg = "Kill Sandra Renton (or let her die). "; if (mission<=2){ - msg=msg$" She can be found in an alley next to the Underworld Tavern in New York"; + msg=msg$"She can be found in an alley next to the Underworld Tavern in New York"; } else if (mission<=4){ - msg=msg$" She can be found inside the hotel"; + msg=msg$"She can be found inside the hotel"; } else if (mission<=8){ - msg=msg$" She can be found in the Underworld Tavern"; + msg=msg$"She can be found in the Underworld Tavern"; } else if (mission<=12){ - msg=msg$" She can be found outside the gas station"; + msg=msg$"She can be found outside the gas station"; } return msg; case "GilbertRenton_Dead": @@ -2322,6 +2364,8 @@ static simulated function string GetBingoGoalHelpText(string event,int mission, return "Fix the fresh water supply in Brooklyn Bridge Station. The water valves are behind some collapsed rubble."; case "assassinapartment": return "Visit the apartment in Paris that has Starr the dog inside. This apartment is over top of the media store, but is accessed from the opposite side of the building near where Jock picks you up."; + case "PetAnimal_BindName_Starr": + return "Visit the apartment in Paris and pet Starr, the dog inside. This apartment is over top of the media store, but is accessed from the opposite side of the building near where Jock picks you up."; case "GaveRentonGun": return "Give Gilbert Renton a gun when he is trying to protect his daughter from JoJo Fine, before the ambush."; case "DXREvents_LeftOnBoat": @@ -3166,6 +3210,8 @@ static simulated function string GetBingoGoalHelpText(string event,int mission, return "Interview some of the locals around Hell's Kitchen to find out more information about the NSF generator."; case "MeetSandraRenton_Played": return "Rescue Sandra Renton from Johnny, the pimp who has her cornered in the alley beside the Underworld Tavern."; + case "TiffanyHeli": + return "Rescue Tiffany Savage at the abandoned gas station."; default: return "Unable to find help text for event '"$event$"'|nReport this to the developers!"; } @@ -3200,7 +3246,7 @@ defaultproperties bingo_options(5)=(event="GilbertRenton_Dead",desc="Kill Gilbert Renton",max=1,missions=20) //bingo_options()=(event="AnnaNavarre_Dead",desc="Kill Anna Navarre",max=1,missions=56) bingo_options(6)=(event="WarehouseEntered",desc="Enter the underground warehouse in Paris",max=1,missions=1024) - bingo_options(7)=(event="GuntherHermann_Dead",desc="Kill Gunther Hermann",max=1,missions=3072) + bingo_options(7)=(event="GuntherHermann_Dead",desc="Kill Gunther Hermann",max=1,missions=2048) bingo_options(8)=(event="JoJoFine_Dead",desc="Kill JoJo",max=1,missions=16) bingo_options(9)=(event="TobyAtanwe_Dead",desc="Kill Toby Atanwe",max=1,missions=2048) bingo_options(10)=(event="Antoine_Dead",desc="Kill Antoine",max=1,missions=1024) @@ -3230,7 +3276,11 @@ defaultproperties bingo_options(29)=(event="M10EnteredBakery",desc="Enter the bakery",max=1,missions=1024) //bingo_options()=(event="AlleyCopSeesPlayer_Played",desc="",max=1) bingo_options(30)=(event="FreshWaterOpened",desc="Fix the water",max=1,missions=8) + #ifdef injections + bingo_options(31)=(event="PetAnimal_BindName_Starr",desc="Pet Starr in Paris",max=1,missions=1024) + #else bingo_options(31)=(event="assassinapartment",desc="Visit Starr in Paris",max=1,missions=1024) + #endif bingo_options(32)=(event="GaveRentonGun",desc="Give Gilbert a weapon",max=1,missions=16) bingo_options(33)=(event="DXREvents_LeftOnBoat",desc="Take the boat out of Battery Park",max=1,missions=4) bingo_options(34)=(event="AlleyBumRescued",desc="Rescue the bum on the basketball court",max=1,missions=4) @@ -3396,9 +3446,7 @@ defaultproperties bingo_options(183)=(event="AdaptiveArmor_Activated",desc="Use %s Thermoptic Camos",desc_singular="Use 1 Thermoptic Camo",max=3,missions=55132) bingo_options(184)=(event="DrinkAlcohol",desc="Drink %s bottles of alcohol",desc_singular="Drink 1 bottle of alcohol",max=75) bingo_options(185)=(event="ToxicShip",desc="Enter the toxic ship",max=1,missions=64) -#ifdef injections bingo_options(186)=(event="ComputerHacked",desc="Hack %s computers",desc_singular="Hack 1 computer",max=10) -#endif bingo_options(187)=(event="TechGoggles_Activated",desc="Use %s tech goggles",desc_singular="Use tech goggles",max=3,missions=54346) bingo_options(188)=(event="Rebreather_Activated",desc="Use %s rebreathers",desc_singular="Use 1 rebreather",max=3,missions=55400) bingo_options(189)=(event="PerformBurder",desc="Hunt %s birds",desc_singular="Hunt 1 bird",max=10,missions=24446) @@ -3450,7 +3498,7 @@ defaultproperties bingo_options(231)=(event="DuClareKeys",desc="Collect 3 different keys around Chateau DuClare",max=3,missions=1024) bingo_options(232)=(event="ShipLockerKeys",desc="Collect %s locker keys inside the superfreighter",desc_singular="Collect 1 locker key inside the superfreighter",max=2,missions=512) bingo_options(233)=(event="VendingMachineEmpty",desc="All Sold Out! (%s)",max=18,missions=36734) - bingo_options(234)=(event="VendingMachineEmpty_Drink",desc="I Wanted Orange! (%s)",max=12,missions=36734) + bingo_options(234)=(event="VendingMachineEmpty_Drink",desc="I Wanted Orange! (%s)",max=12,missions=34686) bingo_options(235)=(event="VendingMachineDispense_Candy",desc="Ooh, a piece of candy! (%s)",max=100,missions=36478) bingo_options(236)=(event="M06JCHasDate",desc="Pay for some company",max=1,missions=64) bingo_options(237)=(event="Sailor_ClassDeadM6",desc="I SPILL %s DRINKS!",desc_singular="I SPILL 1 DRINK!",max=5,missions=64) @@ -3564,6 +3612,7 @@ defaultproperties bingo_options(338)=(event="MeetInjuredTrooper2_Played",desc="Cheer up an injured trooper",max=1,missions=8) bingo_options(339)=(event="InterviewLocals",desc="Interview locals about a generator",max=3,missions=4) bingo_options(340)=(event="MeetSandraRenton_Played",desc="Rescue Sandra Renton",max=1,missions=4) + bingo_options(341)=(event="TiffanyHeli",desc="Rescue Tiffany Savage",max=1,missions=4096); @@ -3631,4 +3680,5 @@ defaultproperties mutually_exclusive(58)=(e1="Karkian_ClassDead",e2="PetKarkians") mutually_exclusive(59)=(e1="PerformBurder",e2="PetBirds") mutually_exclusive(60)=(e1="PetRats",e2="PetBirds") + mutually_exclusive(61)=(e1="TiffanySavage_Dead"e2="TiffanyHeli") } diff --git a/DXRModules/DeusEx/Classes/DXREventsBase.uc b/DXRModules/DeusEx/Classes/DXREventsBase.uc index 57a2ca2de..82b2f9826 100644 --- a/DXRModules/DeusEx/Classes/DXREventsBase.uc +++ b/DXRModules/DeusEx/Classes/DXREventsBase.uc @@ -37,7 +37,7 @@ simulated function bool WatchGuntherKillSwitch(); function SetWatchFlags(); // for goals that can be detected as impossible by an event -static function int GetBingoFailedEvents(string eventname, out string failed[5]); +static function int GetBingoFailedEvents(string eventname, out string failed[6]); // for goals that can not be detected as impossible by an event function MarkBingoFailedSpecial(); @@ -734,8 +734,11 @@ function _AddPawnDeath(ScriptedPawn victim, optional Actor Killer, optional coer } } - // note that this treats both kills and knockouts the same - MarkBingoFailedEvents(victim.bindName $ "_Dead"); + if (!dead) { + MarkBingoFailedEvents(victim.bindName $ "_Unconscious"); + } else { + MarkBingoFailedEvents(victim.bindName $ "_Dead"); + } if(!victim.bImportant) return; @@ -1091,11 +1094,7 @@ function bool AddTestGoal( desc = bingo_options[bingoIdx].desc; if (max > 1 && InStr(desc, "%s") != -1) { - f = float(dxr.flags.bingo_scale)/100.0; - f = rngrange(f, 0.8, 1);// 80% to 100% - f *= MissionsMaskAvailability(starting_mission, missions, missions) ** 1.5; - max = Ceil(float(max) * f); - max = self.Max(max, 1); + max = ScaleBingoGoalMax(max,dxr.flags.bingo_scale,0.8,1.0,starting_mission,missions,missions); if (max == 1 && bingo_options[bingoIdx].desc_singular != "") { desc = bingo_options[bingoIdx].desc_singular; @@ -1243,11 +1242,7 @@ simulated function _CreateBingoBoard(PlayerDataItem data, int starting_map, int max = bingo_options[i].max; // dynamic scaling based on starting mission (not current mission due to leaderboard exploits) if(max > 1 && InStr(desc, "%s") != -1) { - f = float(dxr.flags.bingo_scale)/100.0; - f = rngrange(f, 0.8, 1);// 80% to 100% - f *= MissionsMaskAvailability(starting_mission, missions, end_mission_mask) ** 1.5; - max = Ceil(float(max) * f); - max = self.Max(max, 1); + max = ScaleBingoGoalMax(max,dxr.flags.bingo_scale,0.8,1.0,starting_mission,missions,end_mission_mask); if (max == 1 && bingo_options[i].desc_singular != "") { desc = bingo_options[i].desc_singular; @@ -1271,6 +1266,20 @@ simulated function _CreateBingoBoard(PlayerDataItem data, int starting_map, int data.ExportBingoState(); } +simulated function int ScaleBingoGoalMax(int max, int bingoScale, float randMin, float randMax, int starting_mission, int missions, int end_mission_mask) +{ + local float f; + + f = float(bingoScale)/100.0; + f = rngrange(f, randMin, randMax); + f *= MissionsMaskAvailability(starting_mission, missions, end_mission_mask); + f = f ** 1.3; + max = Ceil(float(max) * f); + max = self.Max(max, 1); + + return max; +} + simulated function int HandleMutualExclusion(MutualExclusion m, int options[ArrayCount(bingo_options)], int num_options) { local int a, b, overwrite; @@ -1295,6 +1304,7 @@ function bool CheckBingoWin(DXRando dxr, int numBingos, int oldBingos) { //Block this in HX for now if(#defined(hx)) return false; + if(dxr.flags.settings.bingo_win == 0) return false; if(numBingos <= 0) return false; if (numBingos >= dxr.flags.settings.bingo_win && dxr.LocalURL!="ENDGAME4" && dxr.LocalURL!="ENDGAME4REV"){ @@ -1385,13 +1395,13 @@ function _MarkBingoAsFailed(coerce string eventname) if (data.MarkBingoAsFailed(eventname)) { l(self$"._MarkBingoAsFailed("$eventname$") data: "$data); - if (class'MenuChoice_ShowBingoUpdates'.static.MessagesEnabled(dxr.flags) && dxr.localURL != "DX" && dxr.localURL != "DXONLY") { + if (class'MenuChoice_ShowBingoUpdates'.static.MessagesEnabled(dxr.flags) && !dxr.OnTitleScreen() && !dxr.OnEndgameMap()) { player().ClientMessage("Failed bingo goal: " $ data.GetBingoDescription(eventname)); } if ( Level.TimeSeconds >= nextBuzzTime && class'MenuChoice_ShowBingoUpdates'.static.SoundsEnabled(dxr.flags) && - dxr.localURL != "DX" && dxr.localURL != "DXONLY" + !dxr.OnTitleScreen() && !dxr.OnEndgameMap() ) { player().PlaySound(Sound'DeusExSounds.Generic.Buzz1', SLOT_None, 0.4); // volume is hopefully not easy to miss but also not annoying nextBuzzTime = Level.TimeSeconds + 0.1; @@ -1410,7 +1420,7 @@ static function MarkBingoAsFailed(coerce string eventname) static function MarkBingoFailedEvents(coerce string eventname) { - local string failed[5]; + local string failed[6]; local int i, num_failed; num_failed = GetBingoFailedEvents(eventname, failed); @@ -1476,7 +1486,10 @@ static function float MissionsMaskAvailability(int currentMission, int goalMissi { local int good, bad, i, t, playable; - if(goalMissions == 0) return 1.0 - float(currentMission-1) / 15.0; + if(goalMissions == 0) { + goalMissions = 57214; //All missions except for 7 and 13 + //Continue onwards with the regular logic otherwise + } for(i=1; i 0) { - AddHint("Viewers, you could've prevented this with Crowd Control.", "Or maybe you caused it."); - AddHint("Don't forget you (the viewer!) can", "use Crowd Control to influence the game!"); + if (dxr.flags.crowdcontrol!=3){ + AddHint("Viewers, you could've prevented this with Crowd Control.", "Or maybe you caused it.", true); + AddHint("Don't forget you (the viewer!) can", "use Crowd Control to influence the game!", true); + } else { + AddHint("RNG did not work in your favour today.", "You have been defeated by a computer.", true); + AddHint("Sometimes a computer can be more cruel than a human.", "(but not always!)", true); + } } if (dxr.flags.settings.goals > 0) { AddHint("Check the Deus Ex Randomizer wiki", "for information about randomized objective locations and more!"); + AddHint("Try the Goal Locations button on the Goals screen", "for a list of the randomized objective locations!"); + if (class'MenuChoice_GoalTextures'.static.IsEnabled(dxr.flags)){ + AddHint("Security Computers associated with randomized goals", "will have a green lid to make them stand out!"); + AddHint("Personal Computers associated with randomized goals", "will have a yellow screen to make them stand out!"); + } + } + + if (dxr.flags.IsBingoCampaignMode()){ + if (dxr.flags.settings.bingo_win>1) { + AddHint("You need to complete "$dxr.flags.settings.bingo_win$" lines on your bingo board", "in order to progress in the game!"); + } else if (dxr.flags.settings.bingo_win==1) { + AddHint("You need to complete one line on your bingo board", "in order to progress in the game!"); + } + } else { + if (dxr.flags.settings.bingo_win>0) { + if (dxr.flags.settings.bingo_win>1) { + AddHint("You'll finish this loop once you complete "$dxr.flags.settings.bingo_win$" lines", "on your bingo board!"); + } else { + AddHint("You'll finish this loop once you complete one line", "on your bingo board!"); + } + if (dxr.flags.bingo_duration==1){ + AddHint("All of your bingo goals can be", "completed within this mission!"); + } else if (dxr.flags.bingo_duration>1){ + AddHint("All of your bingo goals can be", "completed within "$dxr.flags.bingo_duration$" missions!"); + } + AddHint("Your health will be refilled when you finish this loop!", "Use it to its fullest!"); //Make sure this is in line with the decision made about NG+ energy refilling in issue #1065 + + //Technically not "WaltonWare" hints, but only really a concern if you've got bingo win enabled (for faster games): + if (dxr.flags.newgameplus_num_removed_weapons==1) { + AddHint("One weapon will be taken away when you finish this loop!", "Don't get too attached!"); + } else if (dxr.flags.newgameplus_num_removed_weapons>1) { + AddHint(dxr.flags.newgameplus_num_removed_weapons$" weapons will be taken away when you finish this loop!", "Don't get too attached!"); + } + + skills = DXRSkills(dxr.FindModule(class'DXRSkills')); + if( skills != None ) { + if (dxr.flags.newgameplus_num_skill_downgrades==1) { + AddHint("One skill will be downgraded when you finish this loop", "and you'll lose 25% of your unused skill points!"); + } else if (dxr.flags.newgameplus_num_skill_downgrades>1) { + AddHint(dxr.flags.newgameplus_num_skill_downgrades$" skills will be downgraded when you finish this loop", "and you'll lose 25% of your unused skill points!"); + } + } + + augs = DXRAugmentations(dxr.FindModule(class'DXRAugmentations')); + if( augs != None ) { + if (dxr.flags.newgameplus_num_removed_augs==1) { + AddHint("One aug will be removed when you finish this loop", "but you might get new ones to replace it!"); + } else if (dxr.flags.newgameplus_num_removed_augs>1) { + AddHint(dxr.flags.newgameplus_num_removed_augs$" augs will be removed when you finish this loop", "but you might get new ones to replace them!"); + } + } + + if (dxr.flags.newgameplus_max_item_carryover==1) { + AddHint("You can only carry one copy of non-stackable items between loops!", "Don't hoard too much!"); + } else if (dxr.flags.newgameplus_max_item_carryover>1) { + AddHint("You can only carry "$dxr.flags.newgameplus_max_item_carryover$" copies of non-stackable items between loops!", "Don't hoard too much!"); + } + } + } + + if (dxr.flags.moresettings.aug_loc_rando>0){ + AddHint("The body locations that augs can be installed in might be changed!", "Make sure to read the descriptions to find out!"); + } + + if (dxr.flags.clothes_looting>0) { + AddHint("Your selection of clothes is limited to those you've collected!", "Make sure to check bodies and clothes racks to get more!"); + } + + if (dxr.flags.moresettings.camera_mode==1) {//Third person + } else if (dxr.flags.moresettings.camera_mode==2) { //Fixed cameras + AddHint("The camera location will change once you're out of line of sight!", "Use this to your advantage to get better angles!"); + AddHint("Using a scope will make the camera look where you're aiming!", "Maybe you can actually see something far away like this!"); + AddHint("Have you tried shooting the camera?", "Maybe you can get a better view!"); + } + + if (dxr.flags.settings.spoilers>0) { + AddHint("Spoiler buttons are available on the Goals screen!", "Give them a shot if you get really stuck!"); + } + + if (dxr.flags.settings.menus_pause==0) { + AddHint("The game won't pause when you enter menus!", "Watch out!"); + } + + if (class'MenuChoice_RandomMusic'.static.IsEnabled(dxr.flags)){ + AddHint("You can skip or disable songs in the Rando Audio menu!", "Customize your vibe!"); + if (#defined(revision)){ + AddHint("You can switch between the original and Revision", "soundtracks in the Revision Sound menu!"); + } + } + + if (!class'MenuChoice_Epilepsy'.default.enabled){ + AddHint("Are the flickering lights too much for you? Disable Flickering", "Lights in the Rando Visuals menu to make them more gentle!"); + } + + if (class'MenuChoice_ShowHints'.static.IsEnabled(dxr.flags)){ + AddHint("Are the hints annoying when you enter a level?", "You can disable Level Start Hints in the Randomizer settings!"); + } + + if (#defined(vanilla)){ + AddHint("Check out the various options in the Rando Gameplay menu to decide", "how some types of items are looted from dead bodies!"); + AddHint("Use the Trash button in the Inventory menu to stop", "looting that type of item from dead bodies!"); + AddHint("The Aggressive Defense System aug can stop not only missiles", "and grenades, but also darts, throwing knives, plasma, and flames!"); } if( dxr.flags.settings.skills_reroll_missions == 1 ) { @@ -43,6 +155,8 @@ simulated function InitHints() AddHint("Use sabot shotgun rounds to kill the little spider bots."); AddHint("Sabot rounds can damage tough objects no matter the damage threshold.","Check the highlight text!"); AddHint("Grab a plasma rifle, blast everything in sight,", "then go get your items back."); + AddHint("Thermoptic Camo allows you to pass", "through lasers without being detected!"); + AddHint("Thermoptic Camo makes you invisible to people and bots", "but not to cameras or turrets!"); if(dxr.flags.settings.energy != 100) { AddHint("Your max energy is "$dxr.flags.settings.energy$" points.", "Your energy meter shows percent relative to this value."); } @@ -59,14 +173,29 @@ simulated function InitHints() if (class'MenuChoice_AutoWeaponMods'.default.enabled){ AddHint("Picking up a weapon mod while holding a weapon", "will automatically apply it to that weapon!"); } + AddHint("Try using the Quick Skill Menu to upgrade skills while moving!", "Look for the 'Activate Multiplayer Skill Menu' key binding!"); + AddHint("Try using the Quick Aug Menu to upgrade augs while moving!", "Look for the 'Activate Quick Aug Menu' key binding!"); + AddHint("You can upgrade augs without picking up the upgrade canister!", "Just highlight it before trying to upgrade!"); + if (!class'MenuChoice_AutoLaser'.default.enabled){ + AddHint("Look for the 'Auto Laser Sight' option in the Rando Gameplay menu", "to automatically activate laser mods when you draw your weapon!"); + } + AddHint("The Speed Enhancement aug now instantly burns 1 energy", "in order to prevent abuse. Just turn it on and off like normal!"); + AddHint("You will still pick up ammo from weapons even if you", "are unable to pick them up (or have them marked as trash)!"); + AddHint("The Vision Enhancement aug will now show characters, goals, items,", "datacubes, vehicles, crates, and electronic devices through walls!"); + AddHint("The Regeneration aug will no longer bring you to maximum health.", "Upgrade the aug to increase the healing cap!"); + AddHint("The inventory description of augmentation canisters will show", "the full description of the augs available within!"); } - if(dxr.flags.IsHalloweenMode()) + if(dxr.flags.IsHalloweenMode()) { AddHint("Mr. H cannot die but he will flee for a bit if you hurt him enough."); - if(dxr.flags.moresettings.reanimation > 0) - AddHint("Dead bodies will come back as zombies!", "You might want to destroy the bodies."); - if(dxr.flags.moresettings.reanimation > 0) + } + if(dxr.flags.moresettings.reanimation > 0) { AddHint("Dead bodies will come back as zombies!", "You might want to destroy the bodies."); + AddHint("Dead bodies will come back as zombies!", "Maybe a non-lethal approach would help?"); + } + if (dxr.flags.settings.enemyrespawn > 0) { + AddHint("Enemies will respawn once they've been killed or knocked out!", "Remember that you can leave enemies critically injured!"); + } if(dxr.flags.autosave == 3 && !dxr.flags.IsHordeMode()) { AddHint("You're not allowed to manually save,", "you only get an autosave when first entering a map."); } @@ -113,8 +242,10 @@ simulated function InitHints() AddHint("The medium and large metal crates are now destructible.", "They have 500 hp."); AddHint("Make sure to read the descriptions for skills, augs, and items.", "Randomizer adds some extra info."); } - if(dxr.flags.settings.min_weapon_dmg != dxr.flags.settings.max_weapon_dmg || dxr.flags.settings.min_weapon_shottime != dxr.flags.settings.max_weapon_shottime) + if(dxr.flags.settings.min_weapon_dmg != dxr.flags.settings.max_weapon_dmg || dxr.flags.settings.min_weapon_shottime != dxr.flags.settings.max_weapon_shottime) { AddHint("Each type of weapon gets randomized stats!", "Make sure to check one of each type."); + AddHint("Each type of weapon will have the same stats", "through the whole game. They won't change later!"); + } if(#defined(injections) || #defined(vmd) || #defined(gmdx)) { AddHint("You can left click on items to use them without picking them up.", "Great for eating to recover health or putting on armor!"); @@ -147,12 +278,20 @@ simulated function InitHints() if(dxr.flags.settings.medbots > 0) { AddHint("Medbots are randomized.", "Don't expect to find them in the usual locations."); + AddHint("Medbots are randomized.", "There will be a datacube nearby saying the delivery has been made."); } else if(dxr.flags.settings.medbots == 0) { AddHint("Medbots are disabled.", "Good luck."); } + + if(dxr.flags.moresettings.empty_medbots > 0) { + AddHint("You might find an augbot in maps where medbots didn't spawn.", "At least you can still install that aug canister!"); + AddHint("Augbots are blue. Medbots are white.", "Know the difference!"); + } + if(dxr.flags.settings.repairbots > 0) { AddHint("Repair bots are randomized.", "Don't expect to find them in the usual locations."); + AddHint("Repair bots are randomized.", "There will be a datacube nearby saying the delivery has been made."); } else if(dxr.flags.settings.repairbots == 0) { AddHint("Repair bots are disabled.", "Good luck."); @@ -224,6 +363,7 @@ simulated function InitHints() AddHint("Passwords have been randomized.", "Don't even try smashthestate!"); if(dxr.flags.settings.goals > 0){ AddHint("The locations of the terrorist commander and boat are randomized.", "Check the Goal Randomization page on our Wiki."); + AddHint("Your start location, the terrorist commander, and the boat won't", "be close. You might be able to skip some locations!"); if(#defined(injections)) { AddHint("The map of the island can show possible goal locations.", "Give it a try!"); } @@ -237,8 +377,10 @@ simulated function InitHints() AddHint("The location of the Ambrosia barrel is randomized.", "Check the Goal Randomization page on our Wiki."); } else if(map ~= "02_NYC_Warehouse") { - if(dxr.flags.settings.goals > 0) + if(dxr.flags.settings.goals > 0) { AddHint("The locations of the generator, computer, and Jock are randomized.", "Check the Goal Randomization page on our Wiki."); + AddHint("The Email Computer contains a hint about the generator location.", "Make sure to read your emails!"); + } AddHint("There are lots of enemies here!", "Look for thermoptic camo to help."); AddHint("There are lots of enemies here!", "Look for ballistic armor to help."); AddHint("There are lots of enemies here!", "Look for fire extinguishers to stun enemies."); @@ -278,13 +420,19 @@ simulated function InitHints() } else if(dxr.flags.settings.goals > 0) { AddHint("Anna Navarre's location is randomized.", "Check the Goal Randomization page on our Wiki."); } + + if (dxr.flags.settings.prison_pocket > 0) { + AddHint("You'll be able to keep your items when going to prison.", "JC has hidden pockets!"); + } break; case 5: if (map ~= "05_NYC_UnatcoMJ12Lab") { if(dxr.flags.settings.goals > 0) { AddHint("Paul's location in the lab is randomized.", "Check the Goal Randomization page on our Wiki."); + AddHint("The security computer in the command center has a", "camera that shows where Paul is located!"); AddHint("Your equipment could be in either", "the armory, or the surgery ward."); + AddHint("Your equipment will never be in the", "same wing of the lab as Paul!"); if(#defined(injections)) { AddHint("The map of the lab can show possible goal locations.", "Give it a try!"); } @@ -307,6 +455,7 @@ simulated function InitHints() if(dxr.flags.settings.goals > 0) AddHint("The location of the computer with the ROM Encoding is randomized.", "Check the Goal Randomization page on our Wiki."); } else if (map ~= "06_HongKong_WanChai_Street") { + AddHint("All that time JC spent practicing the piano...", "All wasted because of your choices.",true); if(dxr.flags.settings.goals > 0) AddHint("The Dragon Tooth Sword is randomized in Hong Kong.","Open the case in Maggie Chow's apartment for a hint."); } else if (map ~= "06_HongKong_VersaLife") { @@ -319,6 +468,7 @@ simulated function InitHints() break; case 8: + AddHint("Osgoode & Sons is the burned out", "building next to the hotel."); if(dxr.flags.settings.goals > 0){ AddHint("The locations of Filben, Greene, and Vinny are randomized.", "Check the Goal Randomization page on our Wiki."); AddHint("The start location of the raid has been randomized.", "Look for the black vans!"); @@ -357,8 +507,8 @@ simulated function InitHints() #else AddHint("There's wine everywhere in Paris,", "it can be a decent source of health."); #endif - if(map ~= "10_Paris_Catacombs") { - AddHint("If you need a Hazmat suit", "Le Merchant has one for sale."); + if(map ~= "10_Paris_Catacombs" || map~="10_Paris_Entrance") { //Le Merchant is in ENTRANCE in Revision + AddHint("If you need a Hazmat suit", "Le Merchant has one for sale.", true); AddHint("You can kill Le Merchant and loot him", "if you don't have enough money."); } if(dxr.flags.settings.goals > 0 && (map ~= "10_paris_metro" || map ~= "10_paris_club")) { @@ -382,7 +532,7 @@ simulated function InitHints() AddHint("The location of Gunther and the computer is randomized.", "Check the Goal Randomization page on our Wiki."); } #ifdef injections - if( dxr.FindModule(class'DXRBacktracking') != None && map != "11_PARIS_EVERETT" ) { + if( dxr.FindModule(class'DXRBacktracking') != None ) { AddHint("Randomizer has enabled extra backtracking.", "You will be able to go back to previous Paris levels."); } AddHint("There's wine everywhere in Paris,", "it can be a decent source of health and energy."); @@ -393,9 +543,13 @@ simulated function InitHints() case 12: if (map ~= "12_vandenberg_cmd") { + AddHint("The comms building will open once the friendly bots are released", "if you aren't equipped to deal with the bots yourself."); if(dxr.flags.settings.goals > 0) { AddHint("The locations of the power generator keypads and Jock are randomized.", "Check the Goal Randomization page on our Wiki."); } + } else if (map ~= "12_vandenberg_tunnels") { + AddHint("Looking for the Control Room key?", "Have you checked the flooded reactor room?"); + AddHint("It's possible to use the overhead pipes to bypass", "the radioactive area while travelling in either direction!"); } #ifdef injections if( dxr.FindModule(class'DXRBacktracking') != None ) { @@ -407,14 +561,16 @@ simulated function InitHints() case 14: if (map ~= "14_oceanlab_silo") { if(dxr.flags.settings.goals > 0) { - AddHint("Howard Strong is now on a random floor of the missile silo.", "Check the Goal Randomization page on our Wiki."); + AddHint("Howard Strong is now in a random location at the missile silo.", "Check the Goal Randomization page on our Wiki."); AddHint("Howard Strong will only show up if you've done your objectives!", "Been to the Ocean Lab UC and merged Helios?"); AddHint("Jock will pick you up at a random location.", "Check the Goal Randomization page on our Wiki."); } } else if (map ~= "14_OceanLab_UC") { - if(dxr.flags.settings.goals > 0) + if(dxr.flags.settings.goals > 0) { AddHint("The location of the UC schematics computer is randomized.", "Check the Goal Randomization page on our Wiki."); + AddHint("The Email Computer contains a hint about the UC Computer location.", "Make sure to read your emails!"); + } } if (map ~= "14_OCEANLAB_LAB" || map ~= "14_VANDENBERG_SUB" || map ~= "14_OCEANLAB_UC") { if(dxr.flags.settings.goals > 0) @@ -447,6 +603,28 @@ simulated function InitHints() else if (map ~= "15_Area51_Page") { AddHint("You are in Sector 4 with Bob Page. This is where the", "Aquinas Router, Coolant Controls, and Blue Fusion Reactors are."); AddHint("You are in Sector 4. The UCs will constantly spawn new enemies,", "but they can be closed off."); + + if(dxr.flagbase.GetBool('DL_Blue4_Played')) { + AddHint("All four Blue Fusion Reactors are disabled!", "Go to the Infusion Controls and destroy Bob Page!"); + } else { + AddHint("Look for four keypads to disable the blue fusion reactors", "in order to destroy Bob Page and let the Illuminati take over!"); + } + + if(dxr.flagbase.GetBool('coolantcut')) { + AddHint("The coolant has been cut!", "Go to the Antimatter Reactor room in Sector 3 and blow up Area 51!"); + } else { + AddHint("Look for a switch to deactivate the coolant", "in order to destroy Area 51 and start a new Dark Age!"); + } + + if(dxr.flagbase.GetBool('HeliosFree')) { + AddHint("The uplink locks have been disabled!", "Go see Helios in Sector 3 so you can merge with him!"); + } else { + AddHint("Look for a security computer to open the Aquinas Router Control Room", "in order to merge with Helios!"); + } + + if (dxr.flagbase.GetBool('DL_Blue4_Played') && dxr.flagbase.GetBool('coolantcut') && dxr.flagbase.GetBool('HeliosFree')) { + AddHint("You're doing all three endings?", "It's time to make up your mind!"); + } } #ifdef injections if( dxr.FindModule(class'DXRBacktracking') != None ) { @@ -457,17 +635,23 @@ simulated function InitHints() } } -simulated function AddHint(string hint, optional string detail) +simulated function AddHint(string hint, optional string detail, optional bool deathOnly) { - hints[numHints] = hint; - details[numHints] = detail; + hintList[numHints].line1=hint; + hintList[numHints].line2=detail; + hintList[numHints].deathOnly=deathOnly; + numHints++; + + if (numHints > ArrayCount(hintList)){ + err("Death hint list length exceeded! Now "$numHints); + } } simulated function PlayerAnyEntry(#var(PlayerPawn) player) { local int i; - local string msg; + local string msg, hint, detail; Super.PlayerAnyEntry(player); _player = player; @@ -475,25 +659,46 @@ simulated function PlayerAnyEntry(#var(PlayerPawn) player) if(dxr.localURL ~= "00_Training") { for(i=0;i 0) { - msg = msg $ "|n" $ details[i]; + msg = hintList[i].line1; + if(Len(hintList[i].line2) > 0) { + msg = msg $ "|n" $ hintList[i].line2; } player.AddNote(msg, false, i==numHints-1); } player.ClientMessage("Press G or F2 to check your Goals/Notes screen!",, true); } + + if (class'MenuChoice_ShowHints'.static.IsEnabled(dxr.flags)) { + GetHint(false,hint,detail); + player.ClientMessage("Hint: "$hint@detail); + } } -simulated function int GetHint() +simulated function int GetHint(bool isDeath, out string hint, out string detail) { + local GameHint actList[100]; + local int numActHints, i, hintNum; + + numActHints=0; + for (i=0;i= 66; // can technically be done still by carrying her body out of VersaLife but it's not really sensible to have as a goal at this point case "M06JCHasDate": - return start_map > 65; + case "ClubEntryPaid": + return start_map > 65; //Impossible after the raid starts } break; diff --git a/DXRModules/DeusEx/Classes/DXRStats.uc b/DXRModules/DeusEx/Classes/DXRStats.uc index 93faba9b6..17f2b1a77 100644 --- a/DXRModules/DeusEx/Classes/DXRStats.uc +++ b/DXRModules/DeusEx/Classes/DXRStats.uc @@ -664,9 +664,11 @@ function AddDXRCredits(CreditsWindow cw) if(dxr.dxInfo.missionNumber == 99) cw.PrintHeader("Score: " $ IntCommas(ScoreRun())); cw.PrintText("Flagshash: " $ ToHex(dxr.flags.FlagsHash())); +#ifdef injections cw.PrintText("Shots Fired: "$fired); cw.PrintText("Weapon Swings: "$swings); cw.PrintText("Jumps: "$jumps); +#endif cw.PrintText("Nano Keys: "$player().KeyRing.GetKeyCount()); cw.PrintText("Skill Points Earned: "$player().SkillPointsTotal); @@ -674,8 +676,10 @@ function AddDXRCredits(CreditsWindow cw) cw.PrintText("NPCs Knocked Out by JC: "$kos); cw.PrintText("Total NPC Deaths: "$(kills + killsByOther)); cw.PrintText("Total NPCs Knocked Out: "$(kos + kosByOther)); +#ifdef injections cw.PrintText("Total NPCs Burned to Death: "$burnkills); cw.PrintText("Total NPCs Gibbed: "$gibbedkills); +#endif cw.PrintText("Maps Visited: "$mapcoverage$" (" $ class'DXRInfo'.static.TruncateFloat(mappercent,1) $ "%)"); cw.PrintText("Deaths: "$deaths); cw.PrintText("Saves: "$saves$" ("$autosaves$" Autosaves)"); diff --git a/DXRNonVanilla/DeusEx/Classes/DXRComputerPersonal.uc b/DXRNonVanilla/DeusEx/Classes/DXRComputerPersonal.uc index e954ac1ad..a99635134 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRComputerPersonal.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRComputerPersonal.uc @@ -5,6 +5,25 @@ class DXRComputerPersonal extends #var(prefix)ComputerPersonal; var int knownAccount[8]; +#ifdef revision +function bool Facelift(bool bOn) +{ + local DXRando dxr; + + dxr = class'DXRando'.default.dxr; + + if (dxr!=None && class'MenuChoice_GoalTextures'.static.IsEnabled(dxr)){ + mesh = Default.Mesh; + return false; + } else if (dxr==None && Skin==Texture'GoalComputerPersonalYellow'){ + mesh = Default.Mesh; + return false; //On a load, DXR may not be there yet + } + + return Super.Facelift(bOn); +} +#endif + function bool GetAccountKnown(int userIndex) { if ((userIndex >= 0) && (userIndex < ArrayCount(userList))) diff --git a/DXRNonVanilla/DeusEx/Classes/DXRComputerSecurity.uc b/DXRNonVanilla/DeusEx/Classes/DXRComputerSecurity.uc index a8a31f917..94845b247 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRComputerSecurity.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRComputerSecurity.uc @@ -5,6 +5,23 @@ class DXRComputerSecurity extends #var(prefix)ComputerSecurity; var int knownAccount[8]; +#ifdef revision +function bool Facelift(bool bOn) +{ + local DXRando dxr; + + dxr = class'DXRando'.default.dxr; + + if (dxr!=None && class'MenuChoice_GoalTextures'.static.IsEnabled(dxr)){ + return false; + } else if (dxr==None && Skin==Texture'GoalSecurityComputerGreen'){ + return false; //On a load, DXR may not be there yet + } + + return Super.Facelift(bOn); +} +#endif + function bool GetAccountKnown(int userIndex) { if ((userIndex >= 0) && (userIndex < ArrayCount(userList))) diff --git a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalATM.uc b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalATM.uc index 1c5dbc4cc..96bbfae47 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalATM.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalATM.uc @@ -127,3 +127,10 @@ event InitWindow() class'DXRNetworkTerminal'.static.InitWindow(self); #endif } + +function ComputerHacked() +{ + Super.ComputerHacked(); + + class'DXREvents'.static.MarkBingo("ComputerHacked"); +} diff --git a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPersonal.uc b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPersonal.uc index d3902467a..06eb007fa 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPersonal.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPersonal.uc @@ -121,3 +121,10 @@ event InitWindow() class'DXRNetworkTerminal'.static.InitWindow(self); #endif } + +function ComputerHacked() +{ + Super.ComputerHacked(); + + class'DXREvents'.static.MarkBingo("ComputerHacked"); +} diff --git a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPublic.uc b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPublic.uc index b4bfe8766..b8c1cd008 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPublic.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalPublic.uc @@ -13,3 +13,10 @@ event InitWindow() class'DXRNetworkTerminal'.static.InitWindow(self); #endif } + +function ComputerHacked() +{ + Super.ComputerHacked(); + + class'DXREvents'.static.MarkBingo("ComputerHacked"); +} diff --git a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalSecurity.uc b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalSecurity.uc index 859582cb2..cdea1b499 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalSecurity.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRNetworkTerminalSecurity.uc @@ -121,3 +121,10 @@ event InitWindow() class'DXRNetworkTerminal'.static.InitWindow(self); #endif } + +function ComputerHacked() +{ + Super.ComputerHacked(); + + class'DXREvents'.static.MarkBingo("ComputerHacked"); +} diff --git a/DXRNonVanilla/DeusEx/Classes/DXRandoGameInfo.uc b/DXRNonVanilla/DeusEx/Classes/DXRandoGameInfo.uc index a37850332..aa8d689f2 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRandoGameInfo.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRandoGameInfo.uc @@ -32,6 +32,26 @@ function DXRando GetDXR() return dxr; } +//To determine whether the player class is allowed in that mode or not +//Vanilla forces you to JCDentonMale if this is false +//Revision forces you to RevJCDentonMale if false +function bool ApproveClass( class SpawnClass) +{ + log("DXRandoGameInfo ApproveClass "$SpawnClass); + #ifdef revision + if (SpawnClass==class'#var(PlayerPawn)') return true; + #endif + return false; +} + +event playerpawn Login(string Portal, string Options, out string Error, class SpawnClass) +{ + #ifdef revision + SpawnClass=class'#var(PlayerPawn)'; //Force the player to the rando player class + #endif + + return Super.Login(Portal,Options,Error,SpawnClass); +} event InitGame( String Options, out String Error ) { Super.InitGame(Options, Error); diff --git a/DXRNonVanilla/DeusEx/Classes/DXRandoHUD.uc b/DXRNonVanilla/DeusEx/Classes/DXRandoHUD.uc index b6b90e5d7..ee74d5114 100644 --- a/DXRNonVanilla/DeusEx/Classes/DXRandoHUD.uc +++ b/DXRNonVanilla/DeusEx/Classes/DXRandoHUD.uc @@ -12,5 +12,16 @@ event InitWindow() frobDisplay.Destroy(); frobDisplay = FrobDisplayWindow(NewChild(Class'DXRFrobDisplayWindow')); frobDisplay.SetWindowAlignments(HALIGN_Full, VALIGN_Full); + + activeItems.Destroy(); + activeItems = HUDActiveItemsDisplay(NewChild(Class'DXRHUDActiveItemsDisplay')); + activeItems.SetWindowAlignments(HALIGN_Full, VALIGN_Full); +#endif + +#ifndef vmd||hx + augDisplay.Destroy(); + augDisplay = AugmentationDisplayWindow(NewChild(Class'DXRAugDisplayWindow')); + augDisplay.SetWindowAlignments(HALIGN_Full, VALIGN_Full); #endif + } diff --git a/DXRNonVanilla/DeusEx/Classes/DXRandoHUDActiveItemsDisplay.uc b/DXRNonVanilla/DeusEx/Classes/DXRandoHUDActiveItemsDisplay.uc new file mode 100644 index 000000000..4f5189ddd --- /dev/null +++ b/DXRNonVanilla/DeusEx/Classes/DXRandoHUDActiveItemsDisplay.uc @@ -0,0 +1,7 @@ +class DXRHUDActiveItemsDisplay extends HUDActiveItemsDisplay; + +function CreateContainerWindows() +{ + winAugsContainer = HUDActiveAugsBorder(NewChild(Class'HUDActiveAugsBorder')); + winItemsContainer = HUDActiveItemsBorder(NewChild(Class'DXRHUDActiveItemsBorder')); +} diff --git a/DXRNonVanilla/DeusEx/Classes/RevRandoPlayer.uc b/DXRNonVanilla/DeusEx/Classes/RevRandoPlayer.uc new file mode 100644 index 000000000..0a17332b1 --- /dev/null +++ b/DXRNonVanilla/DeusEx/Classes/RevRandoPlayer.uc @@ -0,0 +1,1087 @@ +#compileif revision +class RevRandoPlayer extends RevJCDentonMale; + +var travel bool bZeroRando, bReducedRando, bCrowdControl; +var laserEmitter aimLaser; +var bool bDoomMode; +var bool bOnLadder; +var Rotator ShakeRotator; + +function TakeDamage(int Damage, Pawn instigatedBy, Vector hitlocation, Vector momentum, name damageType) +{ + local float augLevel; + + if(Level.LevelAction != LEVACT_None) return; + + if(damageType == 'NanoVirus') { + augLevel = -1; + if (AugmentationSystem != None) + augLevel = AugmentationSystem.GetAugLevelValue(class'AugEMP'); + if(augLevel == -1) { + RandomizeAugStates(); + } + else { + AddDamageDisplay('NanoVirus', vect(0,0,0)); + SetDamagePercent(1); + } + } else if (damageType=='Shot' || damageType=='AutoShot'){ + if (WineBulletsActive()){ + drugEffectTimer+=3.0; + } + } + Super.TakeDamage(Damage, instigatedBy, hitlocation, momentum, damageType); +} + +function RandomizeAugStates() +{ + local Augmentation aug; + local DXRBase dxrb; + + for(aug = AugmentationSystem.FirstAug; aug!=None; aug = aug.next){ + + //Skip synthetic heart since deactivating it turns off all your augs + //(Maybe this could only skip it for deactivation?) + if (aug.bHasIt && !aug.bAlwaysActive && (AugHeartLung(aug)==None)) { + if (rand(2)==0){ + if (aug.bIsActive){ + aug.Deactivate(); + } else { + aug.Activate(); + } + } + } + } + AugmentationSystem.RefreshAugDisplay(); +} + +function bool WineBulletsActive() +{ + local DataStorage datastorage; + + if (!bCrowdControl) return False; + + datastorage = class'DataStorage'.static.GetObjFromPlayer(self); + return bool(datastorage.GetConfigKey('cc_WineBullets')); +} + +// ---------------------------------------------------------------------- +// DXReduceDamage() +// +// Calculates reduced damage from augmentations and from inventory items +// Also calculates a scalar damage reduction based on the mission number +// ---------------------------------------------------------------------- +function bool DXReduceDamage(int Damage, name damageType, vector hitLocation, out int adjustedDamage, bool bCheckOnly) +{ + local float newDamage, oldDamage; + local float augLevel, skillLevel; + local float pct; + local HazMatSuit suit; + local BallisticArmor armor; + local bool bReduced; + local float damageMult; + + augLevel = -1; + + bReduced = False; + newDamage = Float(Damage); + newDamage = AdjustCritSpots(newDamage, damageType, hitLocation); + oldDamage = newDamage; + + newDamage = ReduceEnviroDamage(newDamage, damageType); + + if ((damageType == 'Shot') || (damageType == 'Sabot') || (damageType == 'Exploded') || (damageType == 'AutoShot')) + { + newDamage = ArmorReduceDamage(newDamage); + } + + if (damageType == 'HalonGas') + { + if (bOnFire && !bCheckOnly) + ExtinguishFire(); + } + + if ((damageType == 'Shot') || (damageType == 'AutoShot')) + { + if (AugmentationSystem != None) + augLevel = AugmentationSystem.GetAugLevelValue(class'AugBallistic'); + + if (augLevel >= 0.0) + newDamage *= augLevel; + } + + if (damageType == 'EMP') + { + if (AugmentationSystem != None) + augLevel = AugmentationSystem.GetAugLevelValue(class'AugEMP'); + + if (augLevel >= 0.0) + newDamage *= augLevel; + } + + if ((damageType == 'Burned') || (damageType == 'Flamed') || + (damageType == 'Exploded') || (damageType == 'Shocked')) + { + if (AugmentationSystem != None) + augLevel = AugmentationSystem.GetAugLevelValue(class'AugShield'); + + if (augLevel >= 0.0) + newDamage *= augLevel; + } + + //Apply damage multiplier + //This gets tweaked from DXRandoCrowdControlLink, but will normally just be 1.0 + damageMult = GetDamageMultiplier(); + if (damageMult!=0) { + newDamage*=damageMult; + } + + // show resistance, don't factor in the random rounding, so the numbers are stable and easier to read + pct = 1.0 - (newDamage / oldDamage); + if (!bCheckOnly) + { + SetDamagePercent(pct); + } + if( pct > 0 ) { + bReduced = True; + ClientFlash(0.01, vect(0, 0, 50)); + } + + // + // Reduce or increase the damage based on the combat difficulty setting, do this before SetDamagePercent for the UI display + // because we don't want to show 100% damage reduction but then do the minimum of 1 damage + if ((damageType == 'Shot') || (damageType == 'AutoShot') || + damageType == 'Flamed' || damageType == 'Burned') + { + newDamage *= CombatDifficulty; + oldDamage *= CombatDifficulty; + } + else if (damageType != 'fell' && damageType != 'Drowned') { + damageMult = CombatDifficultyMultEnviro(); + newDamage *= damageMult; + oldDamage *= damageMult; + } + + if(frand() < (newDamage%1.0)) {// DXRando: random rounding, 1.9 is more likely to round up than 1.1 is + newDamage += 0.999; + oldDamage += 0.999; + } + + adjustedDamage = Int(newDamage);// adjustedDamage is our out param + + if(damageType == 'TearGas' && adjustedDamage*2 >= HealthTorso) { + // TearGas can't kill you + adjustedDamage = 0; + HealthTorso = 1; + } + + return bReduced; +} + +function float CombatDifficultyMultEnviro() +{ + return (CombatDifficulty*0.25) + 0.75;// 25% wet / 75% dry +} + +function float GetDamageMultiplier() +{ + local DataStorage datastorage; + + if (!bCrowdControl) return 0; + + datastorage = class'DataStorage'.static.GetObjFromPlayer(self); + return float(datastorage.GetConfigKey('cc_damageMult')); +} + +function float AdjustCritSpots(float Damage, name damageType, vector hitLocation) +{ + local vector offset; + local float headOffsetZ, headOffsetY, armOffset; + + // EMP attacks drain BE energy + if (damageType == 'EMP') + return Damage; + + // use the hitlocation to determine where the pawn is hit + // transform the worldspace hitlocation into objectspace + // in objectspace, remember X is front to back + // Y is side to side, and Z is top to bottom + offset = (hitLocation - Location) << Rotation; + + // calculate our hit extents + headOffsetZ = CollisionHeight * 0.78; + headOffsetY = CollisionRadius * 0.35; + armOffset = CollisionRadius * 0.35; + + // We decided to just have 3 hit locations in multiplayer MBCODE + if (( Level.NetMode == NM_DedicatedServer ) || ( Level.NetMode == NM_ListenServer )) + { + // leave it vanilla + return Damage; + } + + // Normal damage code path for single player + if (offset.z > headOffsetZ) // head + { + // narrow the head region + if ((Abs(offset.x) < headOffsetY) || (Abs(offset.y) < headOffsetY)) + { + if(!bZeroRando) { + // do 1.7x damage instead of the 2x damage in DeusExPlayer.uc::TakeDamage() + return Damage * 0.85; + } + } + } + else if (offset.z < 0.0) // legs + { + } + else // arms and torso + { + if (offset.y > armOffset) + { + // right arm + } + else if (offset.y < -armOffset) + { + // left arm + } + else if(!bZeroRando) + { + // and finally, the torso! do 1.4x damage instead of the 2x damage in DeusExPlayer.uc::TakeDamage() + return Damage * 0.7; + } + } + + return Damage; +} + +function float ReduceEnviroDamage(float damage, name damageType) +{ + local float skillLevel, augLevel; + local HazmatSuit suit; + + augLevel = -1; + + if (damageType != 'TearGas' && damageType != 'PoisonGas' && damageType != 'Radiation' + && damageType != 'HalonGas' && damageType != 'PoisonEffect' && damageType != 'Poison' + && damageType != 'Flamed' && damageType != 'Burned' && damageType != 'Shocked' ) { + return damage; + } + + if (AugmentationSystem != None) + augLevel = AugmentationSystem.GetAugLevelValue(class'AugEnviro'); + + if (augLevel >= 0.0) + damage *= augLevel; + + // get rid of poison if we're maxed out + if (damage ~= 0.0) + { + StopPoison(); + drugEffectTimer -= 4; // stop the drunk effect + if (drugEffectTimer < 0) + drugEffectTimer = 0; + } + + if(damageType == 'PoisonEffect' || damageType == 'Poison') { + return damage; + } + + skillLevel = SkillSystem.GetSkillLevelValue(class'SkillEnviro'); + skillLevel = FClamp(skillLevel, 0, 1.1); + + if (UsingChargedPickup(class'HazMatSuit')) + { + damage *= 0.75 * skillLevel; + if (UsingBiomod()){ + //Biomod makes hazmat charge only decrease when protecting against damage + foreach AllActors(class'HazMatSuit',suit) { + if (suit.owner==Self && suit.bActive) { + suit.charge -= damage * skillLevel; //Calculation yoinked from Biomod/DeusEx.u + } + } + + } + } + else // passive enviro skill still gives some damage reduction + { + damage *= 1.1 * skillLevel + 0.3; + } + + return damage; +} + +function float ArmorReduceDamage(float damage) +{ + local float skillLevel; + local BallisticArmor ba; + + // go through the actor list looking for owned BallisticArmor + // since they aren't in the inventory anymore after they are used + if (UsingChargedPickup(class'BallisticArmor')) + { + skillLevel = SkillSystem.GetSkillLevelValue(class'SkillEnviro'); + if(skillLevel < 0) + skillLevel = 0; + + if (UsingBiomod()){ + //Biomod makes ballistic armour charge only decrease when protecting against damage + foreach AllActors(class'BallisticArmor',ba) { + if (ba.owner==Self && ba.bActive) { + ba.charge -= damage * 2 * skillLevel; //Calculation yoinked from Biomod/DeusEx.u + break; + } + } + } + return damage * 0.5 * skillLevel; + } + return damage; +} + +function bool UsingBiomod() +{ + local string PathsString; + + PathsString = ConsoleCommand( "GET LaunchSystem Paths" ); + + return InStr(PathsString,"Biomod")!=-1; +} + +function bool UsingShifter() +{ + local string PathsString; + + PathsString = ConsoleCommand( "GET LaunchSystem Paths" ); + + return InStr(PathsString,"Shifter")!=-1; +} + +function CatchFire( Pawn burner ) +{ + local bool doSetTimer; + if (bOnFire==false && Region.Zone.bWaterZone==false) + doSetTimer = true; + + Super.CatchFire(burner); + + // set the burn timer, tick the burn every 4 seconds instead of 1 so that the player can actually survive it + if(doSetTimer) + SetTimer(4.0, True); +} + +simulated function DrugEffects(float deltaTime) +{ + local float olddrugEffectTimer; + local DeusExRootWindow root; + local bool wasActive; + + // set a cap on the effect strength separately from the duration + olddrugEffectTimer = drugEffectTimer; + drugEffectTimer = FMin( drugEffectTimer, 120.0 ); + Super.DrugEffects(deltaTime); + + // calculate duration myself + drugEffectTimer = FMin(olddrugEffectTimer, 120.0 ); + wasActive = (drugEffectTimer>0); + drugEffectTimer -= deltaTime * 1.5; + if (drugEffectTimer < 0) { + drugEffectTimer = 0; + if (wasActive){ + //This theoretically fixes the issue where the game stays zoomed in + //after being drunk until you switch what's in your hands + root = DeusExRootWindow(rootWindow); + if ((root != None) && (root.hud != None)) + { + if (root.hud.background != None) + { + root.hud.SetBackground(None); + root.hud.SetBackgroundStyle(DSTY_Normal); + DesiredFOV = Default.DesiredFOV; + } + } + } + } +} + + +// ---------------------------------------------------------------------- +// HealPlayer() +// ---------------------------------------------------------------------- + +//"Source" is added by Revision, for tracking healing from different sources (for cheevos? so we can mostly ignore for now) +function int HealPlayer(int baseHealPoints, optional Bool bUseMedicineSkill, optional String source) +{ + local int adjustedHealAmount; + local bool fixLegs; + + //Alcohol fixes broken legs, as long as it isn't zero rando + if (source=="Forty" || source=="Liquor" || source=="Wine") fixLegs=!bZeroRando; + + adjustedHealAmount = _HealPlayer(baseHealPoints, bUseMedicineSkill, fixLegs); + + if (adjustedHealAmount == 1) + ClientMessage(Sprintf(HealedPointLabel, adjustedHealAmount)); + else if(adjustedHealAmount != 1)// we want messages for healing 0 so you know it could've healed you + ClientMessage(Sprintf(HealedPointsLabel, adjustedHealAmount)); + + return adjustedHealAmount; +} + +function int _HealPlayer(int baseHealPoints, optional Bool bUseMedicineSkill, optional bool bFixLegs) +{ + local float mult; + local int adjustedHealAmount, aha2, tempaha; + local int origHealAmount; + local float dividedHealAmount; + + if (bUseMedicineSkill) + adjustedHealAmount = CalculateSkillHealAmount(baseHealPoints); + else + adjustedHealAmount = baseHealPoints; + + origHealAmount = adjustedHealAmount; + + if (adjustedHealAmount > 0) + { + if (bUseMedicineSkill) + PlaySound(sound'MedicalHiss', SLOT_None,,, 256); + + // Heal by 3 regions via multiplayer game + if (( Level.NetMode == NM_DedicatedServer ) || ( Level.NetMode == NM_ListenServer )) + { + // DEUS_EX AMSD If legs broken, heal them a little bit first + if (HealthLegLeft == 0) + { + aha2 = adjustedHealAmount; + if (aha2 >= 5) + aha2 = 5; + tempaha = aha2; + adjustedHealAmount = adjustedHealAmount - aha2; + HealPart(HealthLegLeft, aha2); + HealPart(HealthLegRight,tempaha); + mpMsgServerFlags = mpMsgServerFlags & (~MPSERVERFLAG_LostLegs); + } + HealPart(HealthHead, adjustedHealAmount); + + if ( adjustedHealAmount > 0 ) + { + aha2 = adjustedHealAmount; + HealPart(HealthTorso, aha2); + aha2 = adjustedHealAmount; + HealPart(HealthArmRight,aha2); + HealPart(HealthArmLeft, adjustedHealAmount); + } + if ( adjustedHealAmount > 0 ) + { + aha2 = adjustedHealAmount; + HealPart(HealthLegRight, aha2); + HealPart(HealthLegLeft, adjustedHealAmount); + } + } + else + { + // balanced healing, issue #406 + if( adjustedHealAmount >= 18 ) { + aha2 = adjustedHealAmount / 10;// use most of it for the balanced heal, the rest for normal healing behavior + aha2 = Max(aha2, 3); + _HealPart(HealthHead, adjustedHealAmount, aha2); + _HealPart(HealthTorso, adjustedHealAmount, aha2); + _HealPart(HealthLegRight, adjustedHealAmount, aha2); + _HealPart(HealthLegLeft, adjustedHealAmount, aha2); + _HealPart(HealthArmRight, adjustedHealAmount, aha2); + _HealPart(HealthArmLeft, adjustedHealAmount, aha2); + } + else if( bUseMedicineSkill || bFixLegs ) { + HealBrokenPart(HealthLegRight, adjustedHealAmount); + HealBrokenPart(HealthLegLeft, adjustedHealAmount); + } + HealPart(HealthHead, adjustedHealAmount); + HealPart(HealthTorso, adjustedHealAmount); + HealPart(HealthLegRight, adjustedHealAmount); + HealPart(HealthLegLeft, adjustedHealAmount); + HealPart(HealthArmRight, adjustedHealAmount); + HealPart(HealthArmLeft, adjustedHealAmount); + } + + GenerateTotalHealth(); + + adjustedHealAmount = origHealAmount - adjustedHealAmount; + } + + return adjustedHealAmount; +} + +function int HealBrokenPart(out int points, out int amt) +{ + local int heal; + heal = 1; + if( points > 0 || amt < heal ) return 0; + amt -= heal; + return _HealPart(points, heal, 1); +} + +function int _HealPart(out int points, out int amt, int max) +{ + local int spill, healed; + + max = Min(amt, max); + + points += max; + spill = points - default.HealthTorso; + if (spill > 0) + points = default.HealthTorso; + else + spill = 0; + + healed = max - spill; + amt -= healed; + return healed; +} + +function HealPart(out int points, out int amt) +{ + // override the original function, we can't change the function signature when overriding + _HealPart(points, amt, amt); +} + +function PickupNanoKey(NanoKey newKey) +{ + local string msg; + if (newKey.keyID==''){ + msg = "You just picked up a key ("$newKey$") without a key ID ("$newKey.Description$")! Report this to the devs, we're looking for this! Where did you find me?"; + if (!class'DXRVersion'.static.VersionIsStable()){ + ClientMessage(msg); + } else { + log(msg); + } + } + Super.PickupNanoKey(newKey); +} + + + +event PlayerCalcView(out actor ViewActor, out vector CameraLocation, out rotator CameraRotation ) +{ + local CCResidentEvilCam reCam; + + reCam = CCResidentEvilCam(ViewTarget); + + if (reCam!=None){ + CameraRotation = reCam.Rotation; + CameraLocation = reCam.Location; + return; + } else { + Super.PlayerCalcView(ViewActor,CameraLocation,CameraRotation); + if (bDoomMode){ + CameraRotation.Pitch=0; + ViewRotation.Pitch=0; + } + } +} + +function CalcBehindView(out vector CameraLocation, out rotator CameraRotation, float Dist) +{ + local vector View,HitLocation,HitNormal; + local float ViewDist; + + Dist = Dist/1.25; //Bring the camera in a bit closer than normal + + CameraRotation = ViewRotation; + CameraLocation.Z+=BaseEyeHeight; //Adjust camera center to eye height + View = vect(1,-0.2,0) >> CameraRotation; //Slightly offset the view to the right (so it's over the shoulder) + if( Trace( HitLocation, HitNormal, CameraLocation - (Dist + 30) * vector(CameraRotation), CameraLocation ) != None ) + ViewDist = FMin( (CameraLocation - HitLocation) Dot View, Dist ); + else + ViewDist = Dist; + CameraLocation -= (ViewDist - 30) * View; +} + + +function HighlightCenterObject() +{ + if (IsInState('Dying')) + return; + + HighlightCenterObjectMain(); + HighlightCenterObjectLaser(); +} + +function HighlightCenterObjectMain() +{ + local Actor target, t; + local int fails; + local float dist, dist2; + + target = HighlightCenterObjectRay(vect(0,0,0), dist); + + if(LevelInfo(target) != None) target = None; + + if(target != None && Brush(target) == None && class'MenuChoice_FixGlitches'.default.enabled) { + t = HighlightCenterObjectRay(vect(0,-0.2,1.5), dist2); + fails += int(t!=target && dist2 < dist && (LevelInfo(t)!=None || Brush(t)!=None)); + + t = HighlightCenterObjectRay(vect(0,-1,-1), dist2); + fails += int(t!=target && dist2 < dist && (LevelInfo(t)!=None || Brush(t)!=None)); + + t = HighlightCenterObjectRay(vect(0,1.5,-0.5), dist2); + fails += int(t!=target && dist2 < dist && (LevelInfo(t)!=None || Brush(t)!=None)); + + if(fails > 1) target = None; + } + + // DXRando: if we already have a frob target, and the player looks away such as that no item is being + // traced, we still wait for the full 100ms vanilla duration before clearing the frob + // target. + // + // note that this means we don't wait for the full 100ms vanilla duration if the player is + // rapidly changing frob target. + if (FrobTime < 0.1 && FrobTarget != None && target == None && !FrobTarget.bDeleteMe) + { + return; + } + + FrobTarget = target; + FrobTime = 0; // reset our frob timer +} + +function Actor HighlightCenterObjectRay(vector offset, out float smallestTargetDist) +{ + local Actor target, smallestTarget; + local DeathMarker dm; + local Vector HitLoc, HitNormal, StartTrace, EndTrace; + local float minSize; + local bool bFirstTarget, biomodDroneFrob; + + + // DXRando: we do the trace every frame, unlike the vanilla behaviour of doing it every 100ms + biomodDroneFrob=false; + if (UsingBiomod() && bSpyDroneActive){ //Biomod allows frobbing some objects with spy drone + biomodDroneFrob=true; + } + if (biomodDroneFrob){ + StartTrace = aDrone.Location + (offset >> ViewRotation); + EndTrace = aDrone.Location + (Vector(ViewRotation) * MaxFrobDistance); + } else { + // figure out how far ahead we should trace + StartTrace = Location + (offset >> ViewRotation); + EndTrace = StartTrace + (Vector(ViewRotation) * MaxFrobDistance); + + // adjust for the eye height + StartTrace.Z += BaseEyeHeight; + EndTrace.Z += BaseEyeHeight; + } + + smallestTarget = None; + minSize = 99999; + smallestTargetDist = 99999; + bFirstTarget = True; + + // find the object that we are looking at + // make sure we don't select the object that we're carrying + // use the last traced object as the target...this will handle + // smaller items under larger items for example + // ScriptedPawns always have precedence, though + foreach TraceActors(class'Actor', target, HitLoc, HitNormal, EndTrace, StartTrace) + { + if (biomodDroneFrob){ + if (IsFrobbable(target) && (target != CarriedDecoration)) + { + if (!(target.IsA('Computers') && spyDroneLevel >= 3) && !((target.IsA('Button1') || target.IsA('Switch1') || target.IsA('Switch2') || target.IsA('LightSwitch')) && spyDroneLevel >= 2) && !(target.IsA('InformationDevices') && spyDroneLevel >= 1)) + break; + else if (target.CollisionRadius < minSize) + { + minSize = target.CollisionRadius; + smallestTarget = target; + bFirstTarget = False; + } + } + } else { + if(DeathMarker(target) != None) { + if(dm == None && target.CollisionRadius < minSize) { + dm = DeathMarker(target); + if(bFirstTarget) smallestTargetDist = VSize(Location-HitLoc); + } + continue; + } + + if (UsingBiomod() || UsingShifter()){ + //With Biomod or Shifter, you can give weapons to certain characters, like Gunther, Gilbert, and Miguel + ShowGiveNPCWeaponDisplay(); + } + + if (IsFrobbable(target) && (target != CarriedDecoration)) + { + if (target.IsA('ScriptedPawn')) + { + smallestTarget = target; + smallestTargetDist = VSize(Location-HitLoc); + break; + } + else if (target.IsA('Mover')) + { + if(bFirstTarget) { + smallestTarget = target; + smallestTargetDist = VSize(Location-HitLoc); + } + break; + } + else if (target.CollisionRadius < minSize) + { + minSize = target.CollisionRadius; + smallestTarget = target; + bFirstTarget = False; + smallestTargetDist = VSize(Location-HitLoc); + } + } + else if(LevelInfo(target) != None || Brush(target) != None) { + if(bFirstTarget && dm==None) { + smallestTargetDist = VSize(Location-HitLoc); + smallestTarget = Level; + } + minSize = -1; // don't allow any actors after this, but do allow Movers + } + } + } + + if(smallestTarget == None || LevelInfo(target) != None) { + return dm; + } + + return smallestTarget; +} + +function HighlightCenterObjectLaser() +{ + local Vector loc; + + //Activate the aim laser any time you aren't seeing through your eyes + if (class'DXRAimLaserEmitter'.static.AimLaserShouldBeOn(self)){ + if (aimLaser==None){ + aimLaser = Spawn(class'DXRAimLaserEmitter', Self, , Location, Pawn(Owner).ViewRotation); + if (aimLaser == None) { + ClientMessage("Failed to spawn aim laser?"); + } + } + + loc = Location; + loc.Z+=BaseEyeHeight; + loc = loc + vector(ViewRotation) * (CollisionRadius/2); + aimLaser.SetLocation(loc); + aimLaser.SetRotation(ViewRotation); + aimLaser.proxy.DistanceFromPlayer=0; //Make sure the laser doesn't get frozen + + aimLaser.TurnOn(); + + } else { + if (aimLaser!=None){ + aimLaser.TurnOff(); + } + } +} + +//Biomod and Shifter only - shows text when you can give a weapon to an NPC (Gunther, Gilbert, Miguel) +//Duplicated from RevJCDentonMale::HighlightCenterObject +function ShowGiveNPCWeaponDisplay() +{ + local DeusExRootWindow root; + root = DeusExRootWindow(rootWindow); + + if(ScriptedPawn(FrobTarget) != None) + { + if(ScriptedPawn(FrobTarget).bCanGiveWeapon && ScriptedPawn(FrobTarget).CheckPawnAllianceType(Self) != ALLIANCE_Hostile) + { + if(VSize(FrobTarget.Location - Location) <= 64 && + root != None && + DeusExWeapon(inHand) != None) + { + if(!root.hud.startDisplay.bTickEnabled) + { + root.hud.startDisplay.message = ""; + root.hud.startDisplay.charIndex = 0; + root.hud.startDisplay.winText.SetText(""); + root.hud.startDisplay.winTextShadow.SetText(""); + + if(DeusExWeapon(inHand) != None) + root.hud.startDisplay.AddMessage(GivePawnString @ ScriptedPawn(FrobTarget).FamiliarName @ TheString @ inHand.ItemName $ "."); + + if(root.hud.startDisplay.message != "") + root.hud.startDisplay.StartMessage(); + } + + root.hud.startDisplay.DisplayTime = 0.15; + } + } + } +} + +event WalkTexture( Texture Texture, vector StepLocation, vector StepNormal ) +{ + if ( Texture!=None && Texture.Outer!=None && Texture.Outer.Name=='Ladder' ) { + bOnLadder = True; + } + else + bOnLadder = False; +} + +function bool CanInstantLeftClick(DeusExPickup item) +{ + if (inHand!=None) return false; + + if (item==None) return false; + if (item.bActivatable==False) return false; + if (item.GetStateName()=='Activated') return false; + if (item.Owner == self) return false;// we already own the item? + if (item.bDeleteMe) return false;// just in case! + + if (Binoculars(item)!=None) return false; //Unzooming requires left clicking the binocs again + return true; +} + +exec function ParseLeftClick() +{ + local DeusExPickup item; + + Super.ParseLeftClick(); + item = DeusExPickup(FrobTarget); + if (item != None && CanInstantLeftClick(item)) + { + InstantlyUseItem(item); + FrobTarget = None; + } +} + +function InstantlyUseItem(DeusExPickup item) +{ + local Actor A; + local DeusExPickup p; + local int i; + + if(item == None) return; + + //Only consume one of the things if it's in a stack. + //Spawn an individual one to split it from the stack before using it. + if (item.NumCopies>1){ + p = Spawn(item.Class,,,item.Location,item.Rotation); + p.NumCopies=1; + item.NumCopies--; + InstantlyUseItem(p); + return; + } + + foreach item.BasedActors(class'Actor', A) + A.SetBase(None); + // So that any effects get applied to you + item.SetOwner(self); + item.SetBase(self); + // add to the player's inventory, so ChargedPickups travel across maps + item.BecomeItem(); + item.bDisplayableInv = false; + item.Inventory = Inventory; + Inventory = item; + if(FireExtinguisher(item) != None) { + // this was buggy with multiple, but it doesn't make sense and wouldn't be useful to use multiple at once anyways + // this shouldn't get hit anymore, but still do this, just in case + item.NumCopies = 1; + } + + //In theory this should only be one, but just in case we slipped through the case above... + for(i=item.NumCopies; i > 0; i--) { + item.Activate(); + } +} + + + +function bool HandleItemPickup(Actor FrobTarget, optional bool bSearchOnly) +{ + local bool bCanPickup; + local #var(DeusExPrefix)Weapon weap,ownedWeapon; + local int ammoAvail,ammoToAdd,ammoRemaining; + local class defAmmoClass; + local #var(DeusExPrefix)Ammo ownAmmo; + local bool isThrown, isMelee; + local #var(DeusExPrefix)Pickup pickup,ownedPickup; + local #var(prefix)WeaponMod mod; + + //TODO: Loadout logic from vanilla not ported over (yet) + + //Try to apply the mod being picked up to the currently held weapon + if (class'MenuChoice_AutoWeaponMods'.default.enabled){ + mod = #var(prefix)WeaponMod(FrobTarget); + weap = #var(DeusExPrefix)Weapon(inHand); + + //Revision hits this from looting a carcass, but we don't want to auto apply in that case + if (mod!=None && weap!=None && DeusExCarcass(mod.Owner)==None){ + if (mod.CanUpgradeWeapon(weap)){ + mod.ApplyMod(weap); + ClientMessage(mod.ItemName$" applied to "$weap.ItemName,, true); + if (mod.IsA('WeaponModLaser') && class'MenuChoice_AutoLaser'.default.enabled){ + weap.LaserOn(); + } + mod.DestroyMod(); + return true; + } + } + } + + bCanPickup = Super.HandleItemPickup(FrobTarget, bSearchOnly); + + //Ammo Looting + weap = #var(DeusExPrefix)Weapon(FrobTarget); + if (bCanPickup==False && weap!=None && weap.PickUpAmmoCount!=0){ + ownedWeapon=#var(DeusExPrefix)Weapon(FindInventoryType(FrobTarget.Class)); + //You can't pick up the weapon, but let's yoink the ammo + if (ownedWeapon==None){ + ammoAvail = weap.PickUpAmmoCount; + if (weap.AmmoNames[0]==None){ + defAmmoClass=weap.AmmoName; + } else { + defAmmoClass=weap.AmmoNames[0]; + } + + isThrown = ClassIsChildOf(weap.ProjectileClass,class'ThrownProjectile') || weap.ProjectileClass==class'Shuriken'; + isMelee = weap.bHandToHand; //Biomod allows you to throw various melee weapons (knives, crowbars, etc) + + if (defAmmoClass!=class'#var(prefix)AmmoNone' && !isThrown && !isMelee){ + ownAmmo = #var(DeusExPrefix)Ammo(FindInventoryType(defAmmoClass)); + + if (ownAmmo==None){ + ownAmmo = #var(DeusExPrefix)Ammo(Spawn(defAmmoClass)); + AddInventory(ownAmmo); + ownAmmo.BecomeItem(); + ownAmmo.AmmoAmount=0; + ownAmmo.GotoState('Idle2'); + } + + ammoRemaining=0; + ammoToAdd = ammoAvail; + if (ownAmmo.AmmoAmount+ammoAvail > ownAmmo.MaxAmmo) { + ammoToAdd = ownAmmo.MaxAmmo - ownAmmo.AmmoAmount; + ammoRemaining = ammoAvail - ammoToAdd; + } + + ownAmmo.AddAmmo(ammoToAdd); + weap.PickUpAmmoCount=ammoRemaining; + ClientMessage("Took "$ammoToAdd$" "$ownAmmo.ItemName$" from "$weap.ItemName,, true); + UpdateBeltText(weap); + } + } + } + + + + //Looting partial stacks of items (eg 1 out of 3 in a stack of multitools) + pickup = #var(DeusExPrefix)Pickup(FrobTarget); + if (pickup!=None && pickup.Owner!=Self && pickup.maxCopies>1){ + //Pickup failed + ownedPickup=#var(DeusExPrefix)Pickup(FindInventoryType(FrobTarget.Class)); + if (ownedPickup!=None && (ownedPickup.NumCopies+pickup.NumCopies)>ownedPickup.maxCopies){ + ammoToAdd=ownedPickup.maxCopies - ownedPickup.NumCopies; + if (ammoToAdd!=0){ + pickup.NumCopies = (ownedPickup.NumCopies+pickup.NumCopies)-ownedPickup.maxCopies; + ownedPickup.NumCopies = ownedPickup.maxCopies; + UpdateBeltText(ownedPickup); + ClientMessage("Picked up "$ammoToAdd$" of the "$pickup.ItemName,, true); + } + } + + } + + return bCanPickup; +} + +function bool IsThemeAdded(Class themeClass) +{ + local ColorTheme curTheme; + local ColorTheme prevTheme; + local Bool bDeleted; + + bDeleted = False; + curTheme = ThemeManager.FirstColorTheme; + + while(curTheme != None) + { + if ((curTheme.GetThemeName() == themeClass.default.themeName) && (curTheme.IsSystemTheme() == themeClass.default.bSystemTheme) && curTheme.themeType == themeClass.default.themeType) + { + return True; + } + + curTheme = curTheme.next; + } + return False; + +} + +function AddColorTheme(Class themeClass) +{ + if(IsThemeAdded(themeClass)==False){ + ThemeManager.AddTheme(themeClass); + } +} + +function CreateColorThemeManager() +{ + local ColorTheme theme; + Super.CreateColorThemeManager(); + + AddColorTheme(Class'ColorThemeHUD_HotDogStand'); + AddColorTheme(Class'ColorThemeMenu_HotDogStand'); + AddColorTheme(Class'ColorThemeHUD_Black'); + AddColorTheme(Class'ColorThemeMenu_Black'); + AddColorTheme(Class'ColorThemeHUD_Rando'); + AddColorTheme(Class'ColorThemeMenu_Rando'); + AddColorTheme(Class'ColorThemeHUD_Swirl'); + AddColorTheme(Class'ColorThemeMenu_Swirl'); + AddColorTheme(Class'ColorThemeHUD_Health'); + AddColorTheme(Class'ColorThemeMenu_Health'); +} + +function UpdateRotation(float DeltaTime, float maxPitch) +{ + local DataStorage datastorage; + local int rollAmount; + datastorage = class'DataStorage'.static.GetObjFromPlayer(self); + if(datastorage != None) rollAmount = int(datastorage.GetConfigKey('cc_cameraRoll')); + + if(rollAmount == 0) { + Super.UpdateRotation(DeltaTime,maxPitch); + return; + } + + //Track and handle shake rotation as though we are always right-ways up + //Carry the Yaw over, since the shake doesn't adjust that, so it resets you + //to Yaw 0 when a roll starts otherwise (Issue #608) + ShakeRotator.Yaw = ViewRotation.Yaw; + ViewRotation = ShakeRotator; + Super.UpdateRotation(DeltaTime,maxPitch); + ShakeRotator = ViewRotation; + + //Apply any roll after figuring out (and storing) the current shake state + ViewRotation.Roll += rollAmount; +} + +exec function ToggleScope() +{ + local DeusExWeapon W; + local Inventory inv; + + if (RestrictInput()) + return; + + W = DeusExWeapon(Weapon); + if (W != None) + { + W.ScopeToggle(); + } + else + { + for(inv = Inventory; inv != None; inv = inv.Inventory) + { + if ( Binoculars(inv) != None ) + { + PutInHand(inv); + inv.Activate(); + break; + } + } + } +} diff --git a/DXRVanilla/DeusEx/Classes/Player.uc b/DXRVanilla/DeusEx/Classes/Player.uc index 15808df51..7e2ec0bf0 100644 --- a/DXRVanilla/DeusEx/Classes/Player.uc +++ b/DXRVanilla/DeusEx/Classes/Player.uc @@ -1537,22 +1537,22 @@ function Bool IsFiring() function bool IsThemeAdded(Class themeClass) { - local ColorTheme curTheme; - local ColorTheme prevTheme; - local Bool bDeleted; + local ColorTheme curTheme; + local ColorTheme prevTheme; + local Bool bDeleted; - bDeleted = False; - curTheme = ThemeManager.FirstColorTheme; + bDeleted = False; + curTheme = ThemeManager.FirstColorTheme; - while(curTheme != None) - { - if ((curTheme.GetThemeName() == themeClass.default.themeName) && (curTheme.IsSystemTheme() == themeClass.default.bSystemTheme) && curTheme.themeType == themeClass.default.themeType) - { - return True; - } + while(curTheme != None) + { + if ((curTheme.GetThemeName() == themeClass.default.themeName) && (curTheme.IsSystemTheme() == themeClass.default.bSystemTheme) && curTheme.themeType == themeClass.default.themeType) + { + return True; + } - curTheme = curTheme.next; - } + curTheme = curTheme.next; + } return False; } @@ -1579,8 +1579,6 @@ function CreateColorThemeManager() AddColorTheme(Class'ColorThemeMenu_Swirl'); AddColorTheme(Class'ColorThemeHUD_Health'); AddColorTheme(Class'ColorThemeMenu_Health'); - - } // ---------------------------------------------------------------------- @@ -2139,6 +2137,9 @@ function PreTravel() root = DeusExRootWindow(rootWindow); + //Opening URLs triggers pretravel, but we aren't actually traveling, so don't + if (class'DXRando'.default.dxr.bIsOpeningURL) return; + //Don't clear the stack if the top of the stack is the Credits. //We're pretraveling as part of the DestroyWindow call chain if (root!=None && CreditsWindow(root.GetTopWindow())==None){ @@ -2212,6 +2213,11 @@ function CompleteBingoGoal(PlayerDataItem data, int x, int y) } } +exec function BingoGoal(int x, int y) +{ + CompleteBingoGoal(class'PlayerDataItem'.static.GiveItem(self), x, y); +} + exec function Bingo(int line) { local PlayerDataItem data; @@ -2224,11 +2230,11 @@ exec function Bingo(int line) CompleteBingoGoal(data, line, 3); CompleteBingoGoal(data, line, 4); } else if (line >= 5 && line < 10) { - CompleteBingoGoal(data, 0, line); - CompleteBingoGoal(data, 1, line); - CompleteBingoGoal(data, 2, line); - CompleteBingoGoal(data, 3, line); - CompleteBingoGoal(data, 4, line); + CompleteBingoGoal(data, 0, line - 5); + CompleteBingoGoal(data, 1, line - 5); + CompleteBingoGoal(data, 2, line - 5); + CompleteBingoGoal(data, 3, line - 5); + CompleteBingoGoal(data, 4, line - 5); } else if (line == 10) { CompleteBingoGoal(data, 0, 0); CompleteBingoGoal(data, 1, 1); diff --git a/DXRando/DeusEx/Classes/CCResidentEvilCam.uc b/DXRando/DeusEx/Classes/CCResidentEvilCam.uc index d317c3205..140b229a0 100644 --- a/DXRando/DeusEx/Classes/CCResidentEvilCam.uc +++ b/DXRando/DeusEx/Classes/CCResidentEvilCam.uc @@ -30,9 +30,9 @@ function bool FindNewCameraPosition() aimTarget = p; if (DeusExRootWindow(p.rootWindow).scopeView.bViewVisible){ -#ifdef vanilla - if (Human(p).aimLaser.spot[0]!=None){ - aimTarget = Human(p).aimLaser.spot[0]; +#ifdef vanilla||revision + if (#var(PlayerPawn)(p).aimLaser.spot[0]!=None){ + aimTarget = #var(PlayerPawn)(p).aimLaser.spot[0]; } #endif } @@ -136,9 +136,9 @@ function CheckPlayerVisibility(DeusExPlayer player) aimTarget = player; if (DeusExRootWindow(player.rootWindow).scopeView.bViewVisible){ -#ifdef vanilla - if (Human(player).aimLaser.spot[0]!=None){ - aimTarget = Human(player).aimLaser.spot[0]; +#ifdef vanilla||revision + if (#var(PlayerPawn)(player).aimLaser.spot[0]!=None){ + aimTarget = #var(PlayerPawn)(player).aimLaser.spot[0]; player.DesiredFOV = Player.Default.DefaultFOV; } #endif diff --git a/DXRando/DeusEx/Classes/ClothesRack.uc b/DXRando/DeusEx/Classes/ClothesRack.uc index 8eebe0e59..ebec423cb 100644 --- a/DXRando/DeusEx/Classes/ClothesRack.uc +++ b/DXRando/DeusEx/Classes/ClothesRack.uc @@ -12,7 +12,7 @@ function Timer() break; if (p!=None && camera!=None) { - if(#defined(injections) && camera.GetExpectedCameraMode() == camera.CM_ThirdPerson) { + if(#defined(injections||revision) && camera.GetExpectedCameraMode() == camera.CM_ThirdPerson) { camera.EnableTempFixedCamera(true); SetTimer(0.75,False); } else { diff --git a/DXRando/DeusEx/Classes/DXRAimLaserEmitter.uc b/DXRando/DeusEx/Classes/DXRAimLaserEmitter.uc index 201467391..b406e25fd 100644 --- a/DXRando/DeusEx/Classes/DXRAimLaserEmitter.uc +++ b/DXRando/DeusEx/Classes/DXRAimLaserEmitter.uc @@ -1,5 +1,5 @@ class DXRAimLaserEmitter extends LaserEmitter; -#compileif injections +#compileif injections || revision //Mostly copied from LaserEmitter, but modified so it doesn't even try to reflect the laser function CalcTrace(float deltaTime) @@ -107,11 +107,15 @@ static function bool AimLaserShouldBeOn(PlayerPawn p) return False; } + if (player.bSpyDroneActive){ + return False; + } + if ((player.IsInState('Dying')) || (player.IsInState('Paralyzed')) || (player.IsInState('Interpolating'))){ return False; } -#ifdef injections +#ifdef injections||revision if (player.aimLaser!=None && player.aimLaser.Owner==None){ return False; } diff --git a/DXRando/DeusEx/Classes/DXRBioelectricCell.uc b/DXRando/DeusEx/Classes/DXRBioelectricCell.uc new file mode 100644 index 000000000..8d27d1e0a --- /dev/null +++ b/DXRando/DeusEx/Classes/DXRBioelectricCell.uc @@ -0,0 +1,29 @@ +class DXRBioelectricCell injects BioelectricCell; + +state Activated +{ + function BeginState() + { + local DeusExPlayer player; + local int energy; + + Super(DeusExPickup).BeginState(); + + player = DeusExPlayer(Owner); + if (player != None) + { + energy = player.Energy; + player.Energy += rechargeAmount; + if (player.Energy > player.EnergyMax) + player.Energy = player.EnergyMax; + energy = player.Energy - energy; + + player.ClientMessage(Sprintf(msgRecharged, energy)); + + player.PlaySound(sound'BioElectricHiss', SLOT_None,,, 256); + } + + UseOnce(); + } +Begin: +} diff --git a/DXRando/DeusEx/Classes/DXRHoverHint.uc b/DXRando/DeusEx/Classes/DXRHoverHint.uc index 44dafee6c..e6597b836 100644 --- a/DXRando/DeusEx/Classes/DXRHoverHint.uc +++ b/DXRando/DeusEx/Classes/DXRHoverHint.uc @@ -30,6 +30,17 @@ static function DXRHoverHint Create(Actor a, String hint, vector loc, float rad, return hoverHint; } +function ReplaceActor(Actor old, Actor newA) +{ + if (Base==old){ + SetBaseActor(newA); + } + + if (target==old){ + target=newA; + } +} + function AttachTarget(name targetName) { local Actor targetActor; diff --git a/DXRando/DeusEx/Classes/DXRMarble.uc b/DXRando/DeusEx/Classes/DXRMarble.uc index a3893f786..46449ddf4 100644 --- a/DXRando/DeusEx/Classes/DXRMarble.uc +++ b/DXRando/DeusEx/Classes/DXRMarble.uc @@ -2,8 +2,11 @@ class DXRMarble extends #var(injectsprefix)Poolball; //Reduce drawscale to look more like marbles, but leave //the collision the same for more slipperiness +//Revision sets bCanBeBase to true for poolballs for some reason +//make sure they can't be, so they stay slippery defaultproperties { + bCanBeBase=False bInvincible=False ItemName="Marble" DrawScale=0.5 diff --git a/DXRando/DeusEx/Classes/DXRReplacedActors.uc b/DXRando/DeusEx/Classes/DXRReplacedActors.uc new file mode 100644 index 000000000..861207040 --- /dev/null +++ b/DXRando/DeusEx/Classes/DXRReplacedActors.uc @@ -0,0 +1,44 @@ +class DXRReplacedActors extends Info; + +struct ReplacedActor { + var name origName; + var name replacedName; +}; + +var int numReplacedActors; +var ReplacedActor replacedActors[200]; + +function AddReplacement(Actor orig, Actor replaced) +{ + //Do we need to theoretically think about HX's PrecessorName? It can't be saved and reloaded at the moment, so maybe not? + replacedActors[numReplacedActors].origName=orig.Name; + replacedActors[numReplacedActors].replacedName=replaced.Name; + numReplacedActors++; +} + +function Name GetReplacementName(name origName){ + local int i; + + for (i=0;i= VSize(a.Location - backwards) ) return; - class'FrobDisplayWindow'.static.GetActorBoundingBox(a, centerLoc, radius); - class'FrobDisplayWindow'.static.BoxToWindowCoords(self, 0, centerLoc, radius, boxTLX, boxTLY, boxBRX, boxBRY); + class'#var(injectsprefix)FrobDisplayWindow'.static.GetActorBoundingBox(a, centerLoc, radius); + class'#var(injectsprefix)FrobDisplayWindow'.static.BoxToWindowCoords(self, 0, centerLoc, radius, boxTLX, boxTLY, boxBRX, boxBRY); + width = boxBRX - boxTLX; height = boxBRY - boxTLY; gc.DrawPattern(boxTLX, boxTLY, width, height, 0, 0, Texture'Virus_SFX'); @@ -171,7 +177,8 @@ function _DrawActor(GC gc, Actor A, float DrawGlow) { local Texture oldSkins[9]; local #var(prefix)Containers c; - local class i; + local class i; //Revision changed "Contents"/"Content2"/"Content3" to Actor instead of Inventory + //local class i; local Mesh oldMesh; if(A.Mesh == None) { diff --git a/DXRVanilla/DeusEx/Classes/DXRHUDActiveItemsBorderBase.uc b/GUI/DeusEx/Classes/DXRHUDActiveItemsBorder.uc similarity index 94% rename from DXRVanilla/DeusEx/Classes/DXRHUDActiveItemsBorderBase.uc rename to GUI/DeusEx/Classes/DXRHUDActiveItemsBorder.uc index 2504d8594..6f4b98537 100644 --- a/DXRVanilla/DeusEx/Classes/DXRHUDActiveItemsBorderBase.uc +++ b/GUI/DeusEx/Classes/DXRHUDActiveItemsBorder.uc @@ -1,4 +1,4 @@ -class DXRHUDActiveItemsBorderBase injects HUDActiveItemsBorderBase; +class DXRHUDActiveItemsBorder injects HUDActiveItemsBorder; //Just adding timer-specific objects function AddIcon(Texture newIcon, Object saveObject) diff --git a/GUI/DeusEx/Classes/FrobDisplayWindow.uc b/GUI/DeusEx/Classes/FrobDisplayWindow.uc index 90b2bb453..e9d3a0e24 100644 --- a/GUI/DeusEx/Classes/FrobDisplayWindow.uc +++ b/GUI/DeusEx/Classes/FrobDisplayWindow.uc @@ -19,13 +19,30 @@ function DrawWindow(GC gc) { frobTarget = player.FrobTarget; if (frobTarget != None) - if (!player.IsHighlighted(frobTarget)) + if (!CheckHighlighted(frobTarget)) frobTarget = None; } if( frobTarget != None ) DrawWindowBase(gc, frobTarget); } +function bool CheckHighlighted(Actor frobTarget) +{ + local bool wasBehind,highlighted; + if (player==None) return false; + +#ifdef injections + highlighted = player.IsHighlighted(frobTarget); +#else + //This is handled in the injected player class normally + wasBehind=player.bBehindView; + player.bBehindView=False; + highlighted=player.IsHighlighted(frobTarget); + player.bBehindView=wasBehind; +#endif + return highlighted; +} + function CheckSettings() { @@ -279,6 +296,10 @@ function bool KeyAcquired(Mover m) return False; } + if (dxMover.KeyIDNeeded==''){ + return False; + } + if (player!=None && Player.KeyRing.HasKey(dxMover.KeyIDNeeded)){ return True; } @@ -372,13 +393,7 @@ function string MoverStrInfo(Mover m, out int numLines) dxMover = DeusExMover(m); if (dxMover != None && dxMover.bLocked) { - if (dxMover.KeyIDNeeded != ''){ - if (keyAcquired(m)){ - keyAcq = true; - } else { - keyAcq = false; - } - } + keyAcq=KeyAcquired(m); if((BreakableWall(m)!=None || BreakableGlass(m)!=None) && dxMover.KeyIDNeeded == '' && !dxMover.bPickable) { strInfo = "Breakable"; } @@ -676,10 +691,10 @@ function string OtherStrInfo(Actor frobTarget, out int numLines) strInfo = Inventory(frobTarget).itemName $ " (" $ Pickup(frobTarget).NumCopies $ ")"; else if (frobTarget.IsA('Weapon') && Weapon(frobTarget).AmmoName != Class'DeusEx.AmmoNone' ) strInfo = Inventory(frobTarget).itemName $ " (" $ Weapon(frobTarget).PickupAmmoCount $ ")"; -#ifdef injections - else if (frobTarget.IsA('ChargedPickup') && Human(player).CanInstantLeftClick(DeusExPickup(frobTarget))) +#ifdef injections||revision + else if (frobTarget.IsA('ChargedPickup') && #var(PlayerPawn)(player).CanInstantLeftClick(DeusExPickup(frobTarget))) strInfo = Inventory(frobTarget).itemName $ " (Left Click to Activate)"; - else if (Human(player).CanInstantLeftClick(DeusExPickup(frobTarget))) + else if (#var(PlayerPawn)(player).CanInstantLeftClick(DeusExPickup(frobTarget))) strInfo = Inventory(frobTarget).itemName $ " (Left Click to Consume)"; else if (WeaponModAutoApply(WeaponMod(frobTarget))) strInfo = Inventory(frobTarget).itemName $ CR() $ "Auto applies to current weapon"; @@ -688,6 +703,9 @@ function string OtherStrInfo(Actor frobTarget, out int numLines) #ifdef injections else if (frobTarget.IsA('WHPiano')) strInfo = player.GetDisplayName(frobTarget) $ CR() $ "Songs Played: " $ WHPiano(frobTarget).numSongsPlayed $ DXDecoStrInfo(#var(DeusExPrefix)Decoration(frobTarget),numLines); +#else + else if (frobTarget.IsA('DXRPiano')) + strInfo = player.GetDisplayName(frobTarget) $ CR() $ "Songs Played: " $ DXRPiano(frobTarget).numSongsPlayed $ DXDecoStrInfo(#var(DeusExPrefix)Decoration(frobTarget),numLines); #endif else if (frobTarget.IsA('#var(injectsprefix)ClothesRack')) strInfo = player.GetDisplayName(frobTarget) $ CR() $ "Right Click to change clothing " $ DXDecoStrInfo(#var(DeusExPrefix)Decoration(frobTarget),numLines); @@ -845,7 +863,7 @@ function DeviceDrawBars(GC gc, HackableDevices device, float infoX, float infoY, } } - if (GetAutoCodes() && k!=None){ + if (GetAutoCodes() && k!=None && k.hackStrength != 0.0){ gc.SetStyle(DSTY_Translucent); col.r = 0; col.g = 0; diff --git a/DXRVanilla/DeusEx/Classes/HUDActiveItemTimer.uc b/GUI/DeusEx/Classes/HUDActiveItemTimer.uc similarity index 100% rename from DXRVanilla/DeusEx/Classes/HUDActiveItemTimer.uc rename to GUI/DeusEx/Classes/HUDActiveItemTimer.uc diff --git a/GUI/DeusEx/Classes/MenuChoice_ShowHints.uc b/GUI/DeusEx/Classes/MenuChoice_ShowHints.uc new file mode 100644 index 000000000..70222570f --- /dev/null +++ b/GUI/DeusEx/Classes/MenuChoice_ShowHints.uc @@ -0,0 +1,28 @@ +//============================================================================= +// MenuChoice_ShowHints +//============================================================================= + +class MenuChoice_ShowHints extends DXRMenuUIChoiceInt; + +// ---------------------------------------------------------------------- +// SaveSetting() +// ---------------------------------------------------------------------- + +static function bool IsEnabled(DXRFlags f) +{ + // + return (default.value==2) || (default.value==1 && !f.IsZeroRando() && !f.IsSpeedrunMode()); +} + +defaultproperties +{ + value=1 + defaultvalue=1 + defaultInfoWidth=243 + defaultInfoPosX=203 + HelpText="Show hints when a level loads. This is automatically disabled for Zero Rando." + actionText="Level Start Hints" + enumText(0)="No Hints Shown" + enumText(1)="According to Game Mode" + enumText(2)="Hints Shown" +} diff --git a/GUI/DeusEx/Classes/MenuScreenRandoOptionsRandomizer.uc b/GUI/DeusEx/Classes/MenuScreenRandoOptionsRandomizer.uc index 80de69dc7..1a8e61b13 100644 --- a/GUI/DeusEx/Classes/MenuScreenRandoOptionsRandomizer.uc +++ b/GUI/DeusEx/Classes/MenuScreenRandoOptionsRandomizer.uc @@ -17,6 +17,7 @@ function CreateChoices() CreateChoice(class'MenuChoice_ToggleMemes'); CreateChoice(class'MenuChoice_OctoberCosmetics'); + CreateChoice(class'MenuChoice_ShowHints'); } diff --git a/GUI/DeusEx/Classes/MenuScreenRandoOptionsVisuals.uc b/GUI/DeusEx/Classes/MenuScreenRandoOptionsVisuals.uc index 6dce3c69a..b157218cc 100644 --- a/GUI/DeusEx/Classes/MenuScreenRandoOptionsVisuals.uc +++ b/GUI/DeusEx/Classes/MenuScreenRandoOptionsVisuals.uc @@ -14,10 +14,11 @@ function CreateChoices() CreateChoice(class'MenuChoice_ShowKeys'); CreateChoice(class'MenuChoice_Epilepsy'); CreateChoice(class'MenuChoice_BarrelTextures'); - CreateChoice(class'MenuChoice_GoalTextures'); CreateChoice(class'MenuUIChoiceVisionTint'); } - + if (#defined(vanilla||revision)){ + CreateChoice(class'MenuChoice_GoalTextures'); + } CreateChoice(class'MenuChoice_ShowTeleporters'); } diff --git a/GUI/DeusEx/Classes/NewGamePlusCreditsWindow.uc b/GUI/DeusEx/Classes/NewGamePlusCreditsWindow.uc index aa254ffd3..b82c03c31 100644 --- a/GUI/DeusEx/Classes/NewGamePlusCreditsWindow.uc +++ b/GUI/DeusEx/Classes/NewGamePlusCreditsWindow.uc @@ -1,4 +1,8 @@ +#ifdef revision +class NewGamePlusCreditsWindow injects RevCreditsWindow; +#else class NewGamePlusCreditsWindow injects CreditsWindow; +#endif event DestroyWindow() { diff --git a/GUI/DeusEx/Classes/PersonaScreenGoals.uc b/GUI/DeusEx/Classes/PersonaScreenGoals.uc index 77031afea..feb52d13a 100644 --- a/GUI/DeusEx/Classes/PersonaScreenGoals.uc +++ b/GUI/DeusEx/Classes/PersonaScreenGoals.uc @@ -240,8 +240,8 @@ event bool BoxOptionSelected(Window msgBoxWindow, int buttonNumber) switch(action) { case "wiki": OpenGoalRandoWikiPage(); - // Destroy the msgbox! - root.PopWindow(); + // Destroy the msgbox (later)! + PopLater(); return true; case "entspoilers": @@ -260,6 +260,16 @@ event bool BoxOptionSelected(Window msgBoxWindow, int buttonNumber) return Super.BoxOptionSelected(msgBoxWindow,buttonNumber); } +function PopLater() +{ + AddTimer(0.001,,,'LateWindowPop'); +} + +function LateWindowPop(int timerID, int invocations, int clientData) +{ + root.PopWindow(); +} + function OpenGoalRandoWikiPage() { local string url,missionNum; diff --git a/HXRandomizer.u b/HXRandomizer.u index 4108b7f01..5266476cd 100644 Binary files a/HXRandomizer.u and b/HXRandomizer.u differ diff --git a/Pawns/DeusEx/Classes/BlackCat.uc b/Pawns/DeusEx/Classes/BlackCat.uc index ec7fff7d0..0cab6b7c2 100644 --- a/Pawns/DeusEx/Classes/BlackCat.uc +++ b/Pawns/DeusEx/Classes/BlackCat.uc @@ -1,10 +1,16 @@ class BlackCat extends #var(prefix)Cat; +function bool Facelift(bool bOn) +{ + return false; +} + static function ConvertNormalCat(#var(prefix)Cat cat) { if (cat.CarcassType==class'BlackCat'.Default.CarcassType) return; //This is already a black cat cat.MultiSkins[0]=class'BlackCat'.Default.MultiSkins[0]; + cat.Mesh=class'BlackCat'.Default.Mesh; //Black Cats always use the vanilla mesh cat.CarcassType=class'BlackCat'.Default.CarcassType; cat.Fatness=class'BlackCat'.Default.Fatness; cat.ScaleGlow=class'BlackCat'.Default.ScaleGlow; //To help their eyes shine in dark areas diff --git a/Pawns/DeusEx/Classes/BlackCatCarcass.uc b/Pawns/DeusEx/Classes/BlackCatCarcass.uc index 539cfc4be..8ecc775c4 100644 --- a/Pawns/DeusEx/Classes/BlackCatCarcass.uc +++ b/Pawns/DeusEx/Classes/BlackCatCarcass.uc @@ -1,9 +1,14 @@ class BlackCatCarcass extends #var(prefix)CatCarcass; +function bool Facelift(bool bOn) +{ + return false; +} static function ConvertNormalCat(#var(prefix)CatCarcass cat) { cat.MultiSkins[0]=class'BlackCatCarcass'.Default.MultiSkins[0]; + cat.Mesh=class'BlackCatCarcass'.Default.Mesh; //Black Cats always use the vanilla mesh cat.Fatness=class'BlackCatCarcass'.Default.Fatness; cat.ScaleGlow=class'BlackCatCarcass'.Default.ScaleGlow; //To help their eyes shine in dark areas cat.bUnlit=class'BlackCatCarcass'.Default.bUnlit; diff --git a/DXRVanilla/DeusEx/Classes/LuciusDeBeers.uc b/Pawns/DeusEx/Classes/LuciusDeBeers.uc similarity index 97% rename from DXRVanilla/DeusEx/Classes/LuciusDeBeers.uc rename to Pawns/DeusEx/Classes/LuciusDeBeers.uc index 2997e4242..9b4ae64c2 100644 --- a/DXRVanilla/DeusEx/Classes/LuciusDeBeers.uc +++ b/Pawns/DeusEx/Classes/LuciusDeBeers.uc @@ -1,7 +1,7 @@ //============================================================================= // LuciusDeBeers. //============================================================================= -class DXRLuciusDeBeers injects LuciusDeBeers; +class DXRLuciusDeBeers injects #var(prefix)LuciusDeBeers; //From DeusExCarcass function ChunkUp() diff --git a/Pawns/DeusEx/Classes/MedicalBot.uc b/Pawns/DeusEx/Classes/MedicalBot.uc index 54cecbabb..4c092d7e9 100644 --- a/Pawns/DeusEx/Classes/MedicalBot.uc +++ b/Pawns/DeusEx/Classes/MedicalBot.uc @@ -49,10 +49,10 @@ function int HealPlayer(DeusExPlayer PlayerToHeal) local int healedPoints, uses; local string msg; -#ifdef injections +#ifdef injections||revision // vanilla HealPlayer but with a different client message - if (Human(PlayerToHeal) != None) { - healedPoints = Human(PlayerToHeal)._HealPlayer(healAmount); + if (#var(PlayerPawn)(PlayerToHeal) != None) { + healedPoints = #var(PlayerPawn)(PlayerToHeal)._HealPlayer(healAmount); numUses++; lastHealTime = Level.TimeSeconds; diff --git a/Pawns/DeusEx/Classes/Merchant.uc b/Pawns/DeusEx/Classes/Merchant.uc index 807ffe11e..002e57c57 100644 --- a/Pawns/DeusEx/Classes/Merchant.uc +++ b/Pawns/DeusEx/Classes/Merchant.uc @@ -47,16 +47,8 @@ function EnterConversationState(bool bFirstPerson, optional bool bAvoidState) if(hints != None) { for(i=0; i<100; i++) { - newHint = hints.GetHint(); - hint = hints.hints[newHint]; - details = hints.details[newHint]; - if( - newHint != lastHint && - hint != "Viewers, you could've prevented this with Crowd Control." && - hint != "Don't forget you (the viewer!) can" && - details != "We just shared your death publicly, go retweet it!" && - !(CarcassType == Class'LeMerchantCarcass' && hint == "If you need a Hazmat suit") - ) break; + newHint = hints.GetHint(false,hint,details); + if(newHint != lastHint) break; } if(i>=100) hint = ""; } diff --git a/RevRandomizer.u b/RevRandomizer.u index 5754a3afa..0bfd3713b 100644 Binary files a/RevRandomizer.u and b/RevRandomizer.u differ diff --git a/VMDRandomizer.u b/VMDRandomizer.u index daca51a27..81363b89f 100644 Binary files a/VMDRandomizer.u and b/VMDRandomizer.u differ diff --git a/compiler_settings.default.json b/compiler_settings.default.json index c6db5ab04..1b00c30f0 100644 --- a/compiler_settings.default.json +++ b/compiler_settings.default.json @@ -52,7 +52,7 @@ "out_dir": "C:/Program Files (x86)/Steam/steamapps/common/Deus Ex Revision/", "preproc_definitions": { "revision":1, "singeplayer":1, "mapfixes":1, "flags":1, "prefix":"", - "DeusExPrefix":"DeusEx", "PlayerPawn":"Human", "flagvarprefix": "", "package": "RevRandomizer", "injectsprefix": "DXR", "allfeatures": false + "DeusExPrefix":"DeusEx", "PlayerPawn":"RevRandoPlayer", "flagvarprefix": "", "package": "RevRandomizer", "injectsprefix": "DXR", "allfeatures": false }, "mods_paths": [ "./" ], "packages": [ "RevRandomizer" ],