-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDemoGC.cpp
More file actions
32 lines (25 loc) · 1.06 KB
/
DemoGC.cpp
File metadata and controls
32 lines (25 loc) · 1.06 KB
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
#include "DemoGC.h"
DemoGC::DemoGC() {
}
DemoGC::~DemoGC() {
}
void DemoGC::render(Container* c, Uint32 time) {
Texture msg0(c->getGame()->getRenderer(),
"This is just a demo",
*(c->getGame()->getServiceLocator()->getFonts()->getFont(
Resources::ARIAL24)), { COLOR(0x0022ffff) });
msg0.render(c->getGame()->getRenderer(),
c->getGame()->getWindowWidth() / 2 - msg0.getWidth() / 2, c->getGame()->getWindowHeight()-150);
Texture msg1(c->getGame()->getRenderer(),
"Press C to reset the ball",
*(c->getGame()->getServiceLocator()->getFonts()->getFont(
Resources::ARIAL24)), { COLOR(0x00ff22ff) });
msg1.render(c->getGame()->getRenderer(),
c->getGame()->getWindowWidth() / 2 - msg1.getWidth() / 2, c->getGame()->getWindowHeight()-100);
Texture msg2(c->getGame()->getRenderer(),
"Press ESC to exit",
*(c->getGame()->getServiceLocator()->getFonts()->getFont(
Resources::ARIAL24)), { COLOR(0xff1122ff) });
msg2.render(c->getGame()->getRenderer(),
c->getGame()->getWindowWidth() / 2 - msg2.getWidth() / 2, c->getGame()->getWindowHeight()-50);
}