From cc06446d0a651113083478fda94dfaa9a25d1d7e Mon Sep 17 00:00:00 2001 From: whiteshark0 Date: Sun, 29 Apr 2007 18:29:42 +0000 Subject: Commented some Debuging Outputs in ULog Fixed a Bug in ButtonCollection that causes a Crash when UpButton is Pressed at the Last Button Added ShortCut E in MainMenu for Editor git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@150 b956fd51-792f-4845-bead-9b4dfca2ff2c --- Game/Code/Classes/ULog.pas | 10 +++++----- Game/Code/Menu/UMenu.pas | 2 +- Game/Code/Screens/UScreenMain.pas | 6 ++++++ 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/Game/Code/Classes/ULog.pas b/Game/Code/Classes/ULog.pas index 6bffa04e..0b492cb3 100644 --- a/Game/Code/Classes/ULog.pas +++ b/Game/Code/Classes/ULog.pas @@ -139,7 +139,7 @@ var Miliseconds: integer; ValueText: string; begin - if Ini.Debug = 1 then begin + //if Ini.Debug = 1 then begin if not FileAnalyzeO then begin AssignFile(FileAnalyze, LogPath + 'Analyze.log'); @@ -154,7 +154,7 @@ begin Flush(FileAnalyze); // try to speed up end; - end; + //end; end; procedure TLog.LogError(Text: string); @@ -202,8 +202,9 @@ end; procedure TLog.LogStatus(Log1, Log2: string); begin -//asd - LogError (Log2 + ': ' + Log1); + //Just for Debugging + //Comment for Release + //LogAnalyze (Log2 + ': ' + Log1); end; procedure TLog.LogError(Log1, Log2: string); @@ -224,4 +225,3 @@ begin end; end. - \ No newline at end of file diff --git a/Game/Code/Menu/UMenu.pas b/Game/Code/Menu/UMenu.pas index fc217dba..c30b5c5c 100644 --- a/Game/Code/Menu/UMenu.pas +++ b/Game/Code/Menu/UMenu.pas @@ -1367,7 +1367,7 @@ begin begin InteractPrev; //If ButtonCollection with more than 1 Entry then Select Last Entry - if (ButtonCollection[Button[Interactions[Interaction].Num].Parent-1].CountChilds > 1) then + if (Button[Interactions[Interaction].Num].Parent <> 0) AND (ButtonCollection[Button[Interactions[Interaction].Num].Parent-1].CountChilds > 1) then begin //Select Last Child For Num := High(Button) downto 1 do diff --git a/Game/Code/Screens/UScreenMain.pas b/Game/Code/Screens/UScreenMain.pas index 49bd98ee..78c98218 100644 --- a/Game/Code/Screens/UScreenMain.pas +++ b/Game/Code/Screens/UScreenMain.pas @@ -84,6 +84,12 @@ begin FadeTo(@ScreenStatMain); end; + SDLK_E: + begin + Music.PlayStart; + FadeTo(@ScreenEdit); + end; + SDLK_RETURN: begin //Solo -- cgit v1.2.3