X-Git-Url: https://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Fgame%2Fg_panel.pas;h=abdb26d803ce88559ed170b957973e73aa703977;hb=8028f947967b9156e80eea51b7f8b50f3c5862b3;hp=9d08ba32f7e97d1f3a956ca2c72bbfae161b2f60;hpb=bf2b6c0e1c85ff864d7fe018903c372ee5d06abf;p=d2df-sdl.git diff --git a/src/game/g_panel.pas b/src/game/g_panel.pas index 9d08ba3..abdb26d 100644 --- a/src/game/g_panel.pas +++ b/src/game/g_panel.pas @@ -41,8 +41,6 @@ type const private mGUID: Integer; // will be assigned in "g_map.pas" - FTextureWidth: Word; - FTextureHeight: Word; FAlpha: Byte; FBlending: Boolean; FTextureIDs: ATextureID; @@ -195,8 +193,6 @@ type (* private state *) property Alpha: Byte read FAlpha; - property TextureWidth: Word read FTextureWidth; - property TextureHeight: Word read FTextureHeight; property Blending: Boolean read FBlending; property TextureIDs: ATextureID read FTextureIDs; @@ -367,15 +363,11 @@ begin if ({PanelRec.TextureNum}tnum > High(Textures)) then begin e_WriteLog(Format('WTF?! tnum is out of limits! (%d : %d)', [tnum, High(Textures)]), TMsgType.Warning); - FTextureWidth := 2; - FTextureHeight := 2; FAlpha := 0; FBlending := ByteBool(0); end else if not g_Map_IsSpecialTexture(Textures[{PanelRec.TextureNum}tnum].TextureName) then begin - FTextureWidth := Textures[{PanelRec.TextureNum}tnum].Width; - FTextureHeight := Textures[{PanelRec.TextureNum}tnum].Height; FAlpha := PanelRec.Alpha; FBlending := ByteBool(PanelRec.Flags and PANEL_FLAG_BLENDING); end; @@ -950,12 +942,12 @@ end; function TPanel.GetTextureID(): DWORD; begin Result := LongWord(TEXTURE_NONE); - if (FCurTexture >= 0) then - begin - if FTextureIDs[FCurTexture].Anim then - Result := Textures[FTextureIDs[FCurTexture].Texture].FramesID - else - Result := Textures[FTextureIDs[FCurTexture].Texture].TextureID +// if (FCurTexture >= 0) then +// begin +// if FTextureIDs[FCurTexture].Anim then +// Result := Textures[FTextureIDs[FCurTexture].Texture].FramesID +// else +// Result := Textures[FTextureIDs[FCurTexture].Texture].TextureID { // !!! old behavior if FTextureIDs[FCurTexture].Anim then @@ -963,7 +955,7 @@ begin else Result := FTextureIDs[FCurTexture].Tex; } - end +// end end; function TPanel.GetTextureCount(): Integer;