source: trunk/mrpigeon/mrpigeon.cpp @ 1198

Last change on this file since 1198 was 1198, checked in by sam, 9 years ago

core: allow each blitted tile to be stretched differently.

  • Property svn:keywords set to Id
File size: 1.1 KB
Line 
1//
2// MrPigeon
3//
4// Copyright: (c) 2012 Various People
5//
6
7#if defined HAVE_CONFIG_H
8#   include "config.h"
9#endif
10
11#if USE_SDL && defined __APPLE__
12#   include <SDL_main.h>
13#endif
14
15#include "core.h"
16#include "debug/fps.h"
17
18using namespace std;
19using namespace lol;
20
21#include "mrpigeon.h"
22
23MrPigeon::MrPigeon()
24{
25    hudprogress = Tiler::Register("mrpigeon/gfx/HUD_timeline.png", ivec2(160,16), ivec2(0));
26    hudarrow = Tiler::Register("mrpigeon/gfx/HUD_timelineArrow.png", ivec2(16,16), ivec2(0));
27}
28
29void MrPigeon::TickGame(float deltams)
30{
31    WorldEntity::TickGame(deltams);
32}
33
34void MrPigeon::TickDraw(float deltams)
35{
36    WorldEntity::TickDraw(deltams);
37
38    Scene::GetDefault()->AddTile(hudarrow, 0, ivec3(30, 8, 0), 0, vec2(3.0f));
39    Scene::GetDefault()->AddTile(hudprogress, 0, ivec3(0, 0, 0), 0, vec2(3.0f));
40}
41
42MrPigeon::~MrPigeon()
43{
44    Tiler::Deregister(hudprogress);
45    Tiler::Deregister(hudarrow);
46}
47
48int main(int argc, char **argv)
49{
50    Application app("MrPigeon", ivec2(512,384), 60.0f);
51    new DebugFps(20, 20);
52    new MrPigeon();
53    app.ShowPointer(false);
54    app.Run();
55
56    return EXIT_SUCCESS;
57}
58
Note: See TracBrowser for help on using the repository browser.