arthurprs
11-09-2007, 09:15 PM
procedure GameINIT(const Size, bombs: Word);
var
a, b: Cardinal;
begin
a := GetTickCount;
BASSinit;
SDLinit; // SDL loaded, icon loaded and screen initialized here
minefield := TMineField.create(Size, bombs);
Loadresources; // files loaded from zip here
b := GetTickCount;
minefield.create2;
Writeln(Format('%ums for minefield create2', [GetTickCount - b]));
b := GetTickCount;
font := Tbitmapfont.Create('font\monospac821a.xml');
Writeln(Format('%ums for font loading', [GetTickCount - b]));
Writeln(Format('%ums to gameINIT', [GetTickCount - a]));
end;
//...
GameINIT(15, 40);
//...
Compiled with FPC 2.2.0
http://img502.imageshack.us/img502/4557/capture11092007180936tz0.th.png (http://img502.imageshack.us/img502/4557/capture11092007180936tz0.png)
Compiled with D7
http://img502.imageshack.us/img502/6185/capture11092007180931dh3.th.png (http://img502.imageshack.us/img502/6185/capture11092007180931dh3.png)
Game including a bin from FPC and D7 here ~550kb (http://www.mediafire.com/?9ihicjjypjf)
Look the HUGE misterious load time :? :?
This is a study game, im making it for learning {i already learned a lot},
i will try make it multiplayer
A very test release and
don't expect good graphics yet :P
var
a, b: Cardinal;
begin
a := GetTickCount;
BASSinit;
SDLinit; // SDL loaded, icon loaded and screen initialized here
minefield := TMineField.create(Size, bombs);
Loadresources; // files loaded from zip here
b := GetTickCount;
minefield.create2;
Writeln(Format('%ums for minefield create2', [GetTickCount - b]));
b := GetTickCount;
font := Tbitmapfont.Create('font\monospac821a.xml');
Writeln(Format('%ums for font loading', [GetTickCount - b]));
Writeln(Format('%ums to gameINIT', [GetTickCount - a]));
end;
//...
GameINIT(15, 40);
//...
Compiled with FPC 2.2.0
http://img502.imageshack.us/img502/4557/capture11092007180936tz0.th.png (http://img502.imageshack.us/img502/4557/capture11092007180936tz0.png)
Compiled with D7
http://img502.imageshack.us/img502/6185/capture11092007180931dh3.th.png (http://img502.imageshack.us/img502/6185/capture11092007180931dh3.png)
Game including a bin from FPC and D7 here ~550kb (http://www.mediafire.com/?9ihicjjypjf)
Look the HUGE misterious load time :? :?
This is a study game, im making it for learning {i already learned a lot},
i will try make it multiplayer
A very test release and
don't expect good graphics yet :P