Chaosforge Forum

  • November 09, 2024, 18:27
  • Welcome, Guest
Please login or register.



Login with username, password and session length
Pages: [1]

Author Topic: Weird stuff in Valkyrie  (Read 8826 times)

Igor Savin

  • Elder Chaos Guard
  • Second Lieutenant
  • *
  • *
  • Offline Offline
  • Posts: 180
    • View Profile
Weird stuff in Valkyrie
« on: January 24, 2008, 14:15 »

procedure TTextModeOutput.DrawChar(x,y : byte; atr : byte; chr : char; Color : TColor = 0);
begin
  VideoBuf^[(x-1)+(y-1)*ScreenSizeX] := Ord(chr)+(atr shl 8);
end;

\\\

What is the "Color" here for?


***


Also, maybe you should update

(vini)
type TINIFileCallbackProcedure = procedure (const nkey,nvalue : string);

and

(*ui)
function InputCommandParser(const Token : String) : byte;


(vinput)
TTokenReader = function(const Token : string) : byte;

(vini)
type TINIEntry = record
                   a : ShortString;




to use ShortStrings, in order to avoid error messages like

E:\Elwin\Yhacking\Pascal\Valk\vui.pas(836,47) Error: Incompatible type for arg no. 1: Got "<address of procedure(const ShortString,const ShortString);Register>", expected "<procedure variable type of procedure(const AnsiString,const AnsiString);Register>"
« Last Edit: January 24, 2008, 14:52 by Igor Savin »
Logged

Kornel Kisielewicz

  • God Hand
  • Apostle
  • *
  • *
  • Offline Offline
  • Posts: 4576
    • View Profile
    • http://chaosforge.org/
Re: Weird stuff in Valkyrie
« Reply #1 on: January 25, 2008, 02:08 »

Color is implemented only in those interfaces that support it :P. As for the second one, I need to competely rewrite vini anyway soon.
Logged
at your service,
Kornel Kisielewicz

Igor Savin

  • Elder Chaos Guard
  • Second Lieutenant
  • *
  • *
  • Offline Offline
  • Posts: 180
    • View Profile
Re: Weird stuff in Valkyrie
« Reply #2 on: January 25, 2008, 02:46 »

TTokenReader in vInput would still benefit from clarifying type of String used.
Logged
Pages: [1]