Original Post
...I''m getting quite frusterated with DelphiX. I have read through lots of tutorials on it, and I have tried to make a stupid little graphic appear on the screen and I can''t get it to work, and its really ticking me off. I follow the directions in the tutorials, but when I run my program, all I get is a black screen... I''ve tried many different tutorials, and this is all I can get, a stupid black screen. I can run all the tutorials fine, they work like they are suppose to, but when I try to make my own.. Nothing. Here is what I''m using, and I check my components and they are all pointing to right DXDraw1 under the choices of the DXDraw surfaces. Someone Please HELP me.
unit game2;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, DXDraws, DXSprite;
type
TForm1 = class(TForm)
DXDraw1: TDXDraw;
DXImageList1: TDXImageList;
procedure FormKeyPress(Sender: TObject; var Key: Char);
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.DFM}
procedure TForm1.FormKeyPress(Sender: TObject; var Key: Char);
begin
if key = #27 then close;
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
DXImageList1.Items[0].Draw(DXDraw1.Surface,10,10,0);
//DXImageList1.Items[1].Draw(DXDraw1.Surface,300,300,0);
DXDraw1.Flip;
end;
end.