diff --git a/README.md b/README.md index 68315560..f88ff440 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,7 @@ You can make a shortcut to these .bat files for more convenience. # VERSION HISTORY # ### v2 ### - New Feature: Speech Recognition. Enable it in Audio Options +- New Feature: Disable initial dispatch. Enable it in Audio Options - You can now pick up guns through restrained suspects, and all hostages (except live, unrestrained ones) - AI-controlled officers will now automatically report suspects/hostages that they restrain - Fixed a bug that caused the Heavy Armor to have texture issues due to StaticLoadout.ini missing @@ -32,16 +33,18 @@ You can make a shortcut to these .bat files for more convenience. - MIRROR UNDER DOOR and CHECK FOR TRAPS now obeys the stack-up positioning and stacks up the squad on the door. - Fixed: Children of Taronne has traps bolted onto incorrect bones - Fixed: Children of Taronne has a trap on the wrong side +- Fixed: Missing drug rosters on Stetchkov Drug Lab - 'Show Subtitles' moved to Audio Options Files modified: -SP-Tenement.s4m -SpeechCommandGrammar.xml -CommandInterfaceMenus_SP.ini -PlayerInterface_Command_SP.ini -PlayerInterface_Use.ini -SoundEffects.ini -StaticLoadout.ini -SwatGui.ini +Content/Maps/SP-DrugLab.s4m +Content/Maps/SP-Tenement.s4m +System/SpeechCommandGrammar.xml +System/CommandInterfaceMenus_SP.ini +System/PlayerInterface_Command_SP.ini +System/PlayerInterface_Use.ini +System/SoundEffects.ini +System/StaticLoadout.ini +System/SwatGui.ini Generated code ### v1 ### @@ -180,6 +183,7 @@ Some of the changes are as follows. - Fixed a bug where the music would get glitched - 'Display Subtitles' moved to Audio Options - 'Use Speech Recognition' option added to Audio Options + - 'Disable Initial Dispatch' option added to Audio Options ## EQUIPMENT ## diff --git a/Source/Game/SwatGame/Classes/HUD/HUDPageBase.uc b/Source/Game/SwatGame/Classes/HUD/HUDPageBase.uc index 601bf19e..c9a61023 100644 --- a/Source/Game/SwatGame/Classes/HUD/HUDPageBase.uc +++ b/Source/Game/SwatGame/Classes/HUD/HUDPageBase.uc @@ -69,7 +69,7 @@ function OnConstruct(GUIController MyController) local int i; Super.OnConstruct(MyController); - + Feedback = GUIFeedback(AddComponent("SwatGame.GUIFeedback", "HUDPage_feedback")); AmmoStatus = GUIAmmoStatusBase(AddComponent("SwatGUI.GUIAmmoStatus", "HUDPage_ammostatus")); FireMode = GUIFireMode(AddComponent("SwatGame.GUIFireMode", "HUDPage_FireMode")); @@ -102,7 +102,7 @@ function InitComponent(GUIComponent MyOwner) local int i; Super.InitComponent(MyOwner); - + for( i = 0; i < SequenceComponents.Length; i++ ) { SequenceComponents[i].bRepeatCycling = false; @@ -142,7 +142,7 @@ event Hide() function PreLevelChangeCleanup() { - GraphicCommandInterface.SetLogic( None ); + GraphicCommandInterface.SetLogic( None ); } function OnGameInit() @@ -159,7 +159,7 @@ function OnGameStarted() // Set this to true early, to make sure we block out input during the // first 3 ticks. bInCinematic=true; - + NumTicks = 0; } @@ -172,7 +172,8 @@ function OnTick( float Delta ) if (NumTicks > 25/* && Controller.TopPage() == self*/) { if( SwatGUIControllerBase(Controller).GuiConfig.CurrentMission == None || - SwatGUIControllerBase(Controller).GuiConfig.CurrentMission.CustomScenario != None ) + SwatGUIControllerBase(Controller).GuiConfig.CurrentMission.CustomScenario != None || + SwatGUIControllerBase(Controller).GetDispatchDisabled() ) FinishStartRoundSequence(); else { @@ -224,7 +225,7 @@ function StartEndRoundSequence() RepositionComponents( MissionEndSequenceAName ); } -function FinishEndRoundSequence() +function FinishEndRoundSequence() { bInCinematic=false; RepositionComponents( MissionEndSequenceBName ); @@ -264,7 +265,7 @@ protected function OpenComponents() assert(false); //unexpected SwatGameRole break; } - + OpenGenericComponents(); } @@ -288,7 +289,7 @@ protected function CloseComponents() assert(false); //unexpected SwatGameRole break; } - + CloseGenericComponents(); } @@ -298,7 +299,7 @@ protected function CloseComponents() /////////////////////////////////////////////////////////////////////////////////////////////////////////// function OpenCinematicComponents() -{ +{ local int i; for( i = 0; i < SequenceComponents.Length; i++ ) @@ -308,9 +309,9 @@ function OpenCinematicComponents() } function CloseCinematicComponents() -{ +{ local int i; - + for( i = 0; i < SequenceComponents.Length; i++ ) { SequenceComponents[i].Hide(); @@ -381,23 +382,23 @@ function OpenGenericComponents() assert( Feedback != None ); Feedback.Show(); Feedback.RePosition('down', true); //ensure feedback always starts from down position - + assert( AmmoStatus != None ); //updated in UpdateFireMode, below - + assert( FireMode != None ); UpdateFireMode(); - + assert( DamageIndicator != None ); DamageIndicator.Reset(); DamageIndicator.Show(); - + assert( Overlay != None ); Overlay.Show(); - + assert( Progress != None ); Progress.Show(); - + assert( Reticle != None ); Reticle.Show(); @@ -431,13 +432,13 @@ function UpdateCIVisibility() CurrentCommandInterface = SwatGamePlayerController(PlayerOwner()).GetCommandInterface(); CurrentInterfaceIsEnabled = CurrentCommandInterface != None && CurrentCommandInterface.Enabled; - + CCIShown = SwatGUIControllerBase(Controller).GuiConfig.CurrentCommandInterfaceStyle == CommandInterface_Classic; //log( self$"::UpdateCIVisibility() ... CCIShown = "$CCIShown$", CurrentCommandInterface = "$CurrentCommandInterface$", CurrentInterfaceIsEnabled = "$CurrentInterfaceIsEnabled ); - + assertWithDescription(CurrentCommandInterface == None || CurrentCommandInterface.IsA('ClassicCommandInterface') == CCIShown, "[tcohen] HUDPageBase::UpdateCIVisibility() the GUIConfig and the GamePlayerController disagree about which CommandInterface is current."); - + assert(ClassicCommandInterface != None); ClassicCommandInterface.SetVisibility( CCIShown && CurrentInterfaceIsEnabled ); @@ -450,8 +451,8 @@ function UpdateCIVisibility() assert(CommandInterfaceMenuPage != None); CommandInterfaceMenuPage.SetVisibility( - CurrentInterfaceIsEnabled - && !CCIShown + CurrentInterfaceIsEnabled + && !CCIShown && ( SwatGUIControllerBase(Controller).GuiConfig.SwatGameRole == GAMEROLE_MP_Host || SwatGUIControllerBase(Controller).GuiConfig.SwatGameRole == GAMEROLE_MP_Client @@ -527,7 +528,7 @@ simulated function UpdateFireMode() // var private config array AvailableFireMode; //named in singular for simplicity of config file // //log("[FIRE MODE] The following FireModes are available for "$FiredWeapon.class.name$":"); - + CurrentFireMode = FiredWeapon.CurrentFireMode; //FireMode.HideFireModes(); @@ -537,7 +538,7 @@ simulated function UpdateFireMode() //} FireMode.SelectFireMode( CurrentFireMode ); - + //log("[FIRE MODE] FireMode for "$FiredWeapon.class.name$" is now "$GetEnum(FiredWeapon.FireMode, CurrentFireMode)); } } @@ -563,7 +564,7 @@ function ResetDamageIndicator() protected function RepositionComponents( name ToPos, optional bool Immediate ) { local int i; - + for( i = 0; i < Controls.Length; i++ ) { Controls[i].RePosition( ToPos, Immediate ); diff --git a/Source/Game/SwatGame/Classes/SwatGUIControllerBase.uc b/Source/Game/SwatGame/Classes/SwatGUIControllerBase.uc index ccac0a6e..507ac368 100644 --- a/Source/Game/SwatGame/Classes/SwatGUIControllerBase.uc +++ b/Source/Game/SwatGame/Classes/SwatGUIControllerBase.uc @@ -25,6 +25,8 @@ import enum EMPMode from Engine.Repo; // how long since we last polled var private Float CumulativeDelta; +function bool GetDispatchDisabled(); +function SetDispatchDisabled(bool newValue); ///////////////////////////////////////////////////////////////////////////// // Initialization @@ -32,23 +34,23 @@ var private Float CumulativeDelta; function InitializeController() { log("[dkaplan] >>> InitializeController of (SwatGUIControllerBase) "$self); - + Campaigns = new( None ) class'SwatGame.Campaigns'; AssertWithDescription( Campaigns != None, "Campaigns could not be loaded!"); UseCampaign( Campaigns.CurCampaignName ); -log("[dkaplan] ... ViewportOwner="$ViewportOwner$", ViewportOwner.Actor="$ViewportOwner.Actor$", ViewportOwner.Actor.GetEntryLevel()="$ViewportOwner.Actor.GetEntryLevel()$", ViewportOwner.Actor.GetEntryLevel().GetRepo()="$ViewportOwner.Actor.GetEntryLevel().GetRepo() ); +log("[dkaplan] ... ViewportOwner="$ViewportOwner$", ViewportOwner.Actor="$ViewportOwner.Actor$", ViewportOwner.Actor.GetEntryLevel()="$ViewportOwner.Actor.GetEntryLevel()$", ViewportOwner.Actor.GetEntryLevel().GetRepo()="$ViewportOwner.Actor.GetEntryLevel().GetRepo() ); - //set the repo + //set the repo Repo = SwatRepo(ViewportOwner.Actor.GetEntryLevel().GetRepo()); AssertWithDescription( Repo != None, "[dkaplan]: The repo could not be retrieved by "$self$" in InitializeController()"); - + //cache easy reference to the GuiConfig GuiConfig = Repo.GuiConfig; AssertWithDescription( GuiConfig != None, "[dkaplan]: The GuiConfig could not be retrieved by "$self$" in InitializeController()"); - + Super.InitializeController(); - + //if we are initing as a net client, display the loading menu if( Repo.bInitAsNetPlayer ) { @@ -82,9 +84,9 @@ event OnTick( float Delta ) PollCoopQMMGUI(); return; } - + CumulativeDelta += Delta; - + if( CumulativeDelta > GuiConfig.MPPollingDelay ) { CumulativeDelta = 0; @@ -252,14 +254,14 @@ final function OnDisconnected() function Quit() { //may need to add saving info routines here - ConsoleCommand( "quit" ); + ConsoleCommand( "quit" ); } function GameStart() { //start of game hook GuiConfig.SaveLastMissionPlayed(); - LoadLevel( GuiConfig.CurrentMission.MapName ); + LoadLevel( GuiConfig.CurrentMission.MapName ); } function GameAbort() @@ -339,7 +341,7 @@ function SetMPLoadOutPocketItem( Pocket Pocket, class Item ) //function NetGameCompleted() //{ - //send a message to the hud informing of the net game imminent completion + //send a message to the hud informing of the net game imminent completion //log("[dkaplan] Net Game Has Been Completed!"); //} @@ -353,7 +355,7 @@ function HudPageBase GetHUDPage() if (HudPage == None) { HudPage = HUDPageBase(CreateComponent("SwatGui.HUDPage")); - + if (!HudPage.bInited) HudPage.InitComponent(None); } @@ -365,9 +367,9 @@ function HudPageBase GetHUDPage() event SetProgress(string Message1, string Message2) { local int i; - + log(self$"::SetProgress("$Message1$", "$Message2$")"); - + if( Message1 == "LoadSplash" || Message1 == "WaitForConnection" || Message1 == "LoadMap" || @@ -376,8 +378,8 @@ event SetProgress(string Message1, string Message2) for (i = 0; i < MenuStack.Length; i++) MenuStack[i].OnProgress(Message2, Message1); } - else if( Message1 == "ConnectionFailed" || - Message1 == "Networking Failed" || + else if( Message1 == "ConnectionFailed" || + Message1 == "Networking Failed" || Message1 == "DemoLoadFailed" || Message1 == "UrlFailed" || Message1 == "Rejected By Server" || @@ -386,7 +388,7 @@ event SetProgress(string Message1, string Message2) Message1 == "PackageMD5ChecksumFailed" || Message1 == "GenericFailure" || ( Message1 == "ConnectingText" && Message2 == ConnectingURL ) || - ( Message1 == "" && Message2 == "" ) + ( Message1 == "" && Message2 == "" ) ) { ConnectingURL = ""; @@ -400,7 +402,7 @@ event SetProgress(string Message1, string Message2) ConnectingURL = Message2; return; } - + ConnectingURL = ""; } diff --git a/Source/Game/SwatGui/Classes/SwatAudioSettingsPanel.uc b/Source/Game/SwatGui/Classes/SwatAudioSettingsPanel.uc index f0d22091..115862cd 100644 --- a/Source/Game/SwatGui/Classes/SwatAudioSettingsPanel.uc +++ b/Source/Game/SwatGui/Classes/SwatAudioSettingsPanel.uc @@ -16,6 +16,7 @@ var(SWATGui) private EditInline Config GUISlider MyVoiceVolumeSlider; var(SWATGui) private EditInline Config GUISlider MyVOIPVolumeSlider; var(SWATGui) private EditInline Config GUICheckBoxButton RecognitionEnabled; var(SWATGui) private EditInline Config GUICheckBoxButton VOIPEnabled; +var(SWATGui) private EditInline Config GUICheckBoxButton DisableDispatch; #if IG_CAPTIONS var(SWATGui) private EditInline Config GUICheckBoxButton MyShowSubtitlesCheck; #endif @@ -43,6 +44,8 @@ function InitComponent(GUIComponent MyOwner) MyVoiceVolumeSlider.OnChange=OnVoiceVolumeChanged; MyVOIPVolumeSlider.OnChange=OnVOIPVolumeChanged; RecognitionEnabled.OnClick=OnRecognitionEnabledChanged; + DisableDispatch.OnClick=OnDispatchDisabledChanged; +// DisableDispatch.OnClick=OnDisableDispatchChanged; VOIPEnabled.OnClick=OnVOIPEnabledChanged; } @@ -55,6 +58,8 @@ function SaveSettings() GC.SaveConfig(); class'SpeechManager'.static.StaticSaveConfig(); + SwatGUIControllerBase(Controller).SetDispatchDisabled(DisableDispatch.bChecked); + SwatGUIControllerBase(Controller).SaveConfig(); } function LoadSettings() @@ -68,6 +73,7 @@ function LoadSettings() RecognitionEnabled.SetEnabled(PlayerOwner().Level.GetEngine().SpeechManager.IsInitialized()); RecognitionEnabled.SetChecked(PlayerOwner().Level.GetEngine().SpeechManager.IsInitialized() && PlayerOwner().Level.GetEngine().SpeechManager.IsEnabled()); + DisableDispatch.SetChecked(SwatGUIControllerBase(Controller).GetDispatchDisabled()); #if IG_CAPTIONS MyShowSubtitlesCheck.SetChecked( GC.bShowSubtitles ); @@ -171,6 +177,20 @@ private function OnVOIPEnabledChanged( GUIComponent Sender ) } } +private function OnDispatchDisabledChanged(GUIComponent Sender) { + if(DisableDispatch.bChecked) + { + log("Dispatch disabled"); + SwatGUIControllerBase(Controller).SetDispatchDisabled(true); + } + else { + log("Dispatch enabled"); + SwatGUIControllerBase(Controller).SetDispatchDisabled(false); + } + SwatGUIControllerBase(Controller).SaveConfig(); + SwatGUIControllerBase(Controller).StaticSaveConfig(); +} + // ISpeechClient implementation function OnSpeechPhraseStart() { diff --git a/Source/Game/SwatGui/Classes/SwatGUIController.uc b/Source/Game/SwatGui/Classes/SwatGUIController.uc index c7818d38..91ddbfac 100644 --- a/Source/Game/SwatGui/Classes/SwatGUIController.uc +++ b/Source/Game/SwatGui/Classes/SwatGUIController.uc @@ -83,6 +83,8 @@ var() bool bNetPlayerLoaded; var() string EnteredChatText; var() bool EnteredChatGlobal; +var() private config bool DispatchDisabled; + ///////////////////////////////////////////////////////////////////////////// // Initialization ///////////////////////////////////////////////////////////////////////////// @@ -126,6 +128,17 @@ function PollCoopQMMGUI() CoopPage.Poll(); } +///////////////////////////////////////////////////////////////////////////// +// Required to be here because the damn thing is native!! +///////////////////////////////////////////////////////////////////////////// +function bool GetDispatchDisabled() { + return DispatchDisabled; +} + +function SetDispatchDisabled(bool newValue) { + DispatchDisabled = newValue; +} + ///////////////////////////////////////////////////////////////////////////// // Game State / Game Systems Reference ///////////////////////////////////////////////////////////////////////////// diff --git a/System/GuiBase.ini b/System/GuiBase.ini index 129f2faf..86b92308 100644 --- a/System/GuiBase.ini +++ b/System/GuiBase.ini @@ -14,8 +14,8 @@ bHideMouseCursor=False JoyDeadZone=0.300000 GridSize=5 bSnapToGrid=False -ResolutionX=800 -ResolutionY=600 +ResolutionX=1440 +ResolutionY=900 bDontDisplayHelpText=False DblClickWindow=0.300000 WaitingString=Waiting for other players... @@ -74,6 +74,7 @@ TenSecWarning=10 Seconds! OneMinWarning=1 Minute left! SmashAndGrabTimerText=Time Remaining VoteYesNoKeys=Vote yes = %1, Vote no = %2 +DispatchDisabled=False FontNames=fntSwatLarge FontNames=fntSwat FontNames=fntSwatSmall diff --git a/System/MissionResults.ini b/System/MissionResults.ini index 14dc11f1..da482d9e 100644 --- a/System/MissionResults.ini +++ b/System/MissionResults.ini @@ -457,6 +457,6 @@ Played=True [Officer Default_SP-DrugLab_DIFFICULTY_Normal] Difficulty=DIFFICULTY_Normal Completed=False -Score=0 +Score=20 Played=True diff --git a/System/Swat4X.ini b/System/Swat4X.ini index 0e2c9b9b..e6ba7b0b 100644 --- a/System/Swat4X.ini +++ b/System/Swat4X.ini @@ -500,7 +500,7 @@ ScriptLog=(X=66,Y=88,XL=512,YL=256) VFToolbar=(X=3,Y=3,XL=1366,YL=24) PictureButton=(X=666,Y=3,XL=22,YL=20) Surface Properties=(X=-8,Y=-51,XL=437,YL=267) -WPropertyPage=(X=2620,Y=1080,XL=0,YL=0) +WPropertyPage=(X=0,Y=0,XL=486,YL=228) Terrain Editing=(X=-8,Y=-51,XL=577,YL=426) SubTools=(X=15,Y=208,XL=542,YL=211) Build Options=(X=-8,Y=-51,XL=368,YL=478) @@ -532,7 +532,7 @@ Replace Textures=(X=450,Y=216,XL=524,YL=326) UDN=(X=0,Y=0,XL=1,YL=1) Find/Replace=(X=310,Y=274,XL=458,YL=200) CodeFrame=(X=165,Y=-46,XL=811,YL=847) -InspectorProperties=(X=2,Y=2,XL=1131,YL=550) +InspectorProperties=(X=2,Y=2,XL=574,YL=452) ScriptProperties=(X=163,Y=118,XL=1151,YL=593) Inspector=(X=832,Y=101,XL=594,YL=495) EditorLog=(X=92,Y=49,XL=450,YL=450) @@ -557,7 +557,7 @@ Brush Builder=(X=26,Y=33,XL=345,YL=283) EditObject=(X=50,Y=50,XL=352,YL=512) [SwatEd.UnrealEdEngine] -AutoSaveIndex=9 +AutoSaveIndex=2 GridEnabled=False SnapVertices=True SnapDistance=10.000000 diff --git a/System/SwatGui.ini b/System/SwatGui.ini index be7d8d44..c73f5fbb 100644 Binary files a/System/SwatGui.ini and b/System/SwatGui.ini differ