From 1f9fd791bbe68741b8273a64eb5c0abe928e431c Mon Sep 17 00:00:00 2001 From: whiteshark0 Date: Sun, 23 Sep 2007 14:00:46 +0000 Subject: New class for score management -Scores are raised when PopUp slides under the scorebg -1 to 6 Player support (even 5 Players(not supported by Core atm)) -Display 3 Players instead of 2 when 4 Players are set in the Options and Screens=2 Ratingbar is not drawn by class atm. Have to be done git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@430 b956fd51-792f-4845-bead-9b4dfca2ff2c --- Game/Code/Classes/UGraphic.pas | 53 ++++++++++++++++++++++++++++++++---------- 1 file changed, 41 insertions(+), 12 deletions(-) (limited to 'Game/Code/Classes/UGraphic.pas') diff --git a/Game/Code/Classes/UGraphic.pas b/Game/Code/Classes/UGraphic.pas index f350d0d2..6ea89c0f 100644 --- a/Game/Code/Classes/UGraphic.pas +++ b/Game/Code/Classes/UGraphic.pas @@ -156,6 +156,9 @@ var Tex_SingLineBonusBack: array[0..8] of TTexture; //End PhrasenBonus - Line Bonus Mod + //ScoreBG Texs + Tex_ScoreBG: array [0..5] of TTexture; + const Skin_BGColorR = 1; Skin_BGColorG = 1; @@ -315,22 +318,48 @@ begin //Line Bonus PopUp for P := 0 to 8 do begin - Tex_SingLineBonusBack[P] := Texture.LoadTexture(pchar(Skin.GetTextureFileName('LineBonusBack')), 'PNG', 'Colorized', $FFFFFF); + Case P of + 0: begin + R := 1; + G := 0; + B := 0; + end; + 1..3: begin + R := 1; + G := (P * 0.25); + B := 0; + end; + 4: begin + R := 1; + G := 1; + B := 0; + end; + 5..7: begin + R := 1-((P-4)*0.25); + G := 1; + B := 0; + end; + 8: begin + R := 0; + G := 1; + B := 0; + end; + End; + + Col := $10000 * Round(R*255) + $100 * Round(G*255) + Round(B*255); + Tex_SingLineBonusBack[P] := Texture.LoadTexture(pchar(Skin.GetTextureFileName('LineBonusBack')), 'PNG', 'Colorized', Col); end; + + //Score BG Textures + for P := 0 to 5 do begin + LoadColor(R, G, B, 'P' + IntToStr(P+1) + 'Light'); + Col := $10000 * Round(R*255) + $100 * Round(G*255) + Round(B*255); + Tex_ScoreBG[P] := Texture.LoadTexture(pchar(Skin.GetTextureFileName('ScoreBG')), 'PNG', 'Colorized', Col); + end; + {$ENDIF} - - - {//Set Texture to Font High - Tex_SingLineBonusL.H := 32; Tex_SingLineBonusL.W := 8; - Tex_SingLineBonusM.H := 32; //Tex_SingLineBonusM.TexW := Tex_SingLineBonusM.TexW/2; - Tex_SingLineBonusR.H := 32; Tex_SingLineBonusR.W := 8; } - //PhrasenBonus - Line Bonus Mod End Log.LogStatus('Loading Textures - D', 'LoadTextures'); - - // tworzenie czcionek -// Log.LogStatus('Building Fonts', 'LoadTextures'); -// BuildFont; end; procedure Initialize3D (Title: string); -- cgit v1.2.3