-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgamestateunit.pas
56 lines (47 loc) · 957 Bytes
/
gamestateunit.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
unit GameStateUnit;
{$mode objfpc}{$H+}
{
Since game's main code will be fairly long, especially update and draw methods
I've come to conclusion it needs its own unit. -Dariusz "Darkhog" G. Jagielski.
}
interface
uses
Classes, SysUtils,states,sprites,allegro,al_ogg;
type
TGameState = class(TState)
public
constructor Create;override;
destructor Destroy;override;
procedure Update;override;
procedure BeforeDraw;override;
procedure Draw;override;
procedure Main;override;
private
end;
implementation
constructor TGameState.Create;
var bmp:AL_BITMAPptr;
begin
inherited Create;
end;
destructor TGameState.Destroy;
begin
inherited Destroy;
end;
procedure TGameState.Update;
begin
inherited Update;
end;
procedure TGameState.BeforeDraw;
begin
inherited BeforeDraw;
end;
procedure TGameState.Draw;
begin
inherited Draw;
end;
procedure TGameState.Main;
begin
inherited Main;
end;
end.