File: tips.cc

package info (click to toggle)
enemylines3 1.2-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,380 kB
  • ctags: 1,444
  • sloc: cpp: 16,323; makefile: 74; sh: 52
file content (52 lines) | stat: -rw-r--r-- 1,134 bytes parent folder | download | duplicates (6)
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


#include "tips.h"


#include "random.h"
#include "font_ogl.h"

namespace el3 {



static int seed;

void Tips::roll() {
	seed=Random::sget();
}

void Tips::cycle() {
	seed++;
}


void Tips::draw() {

	std::string str;

	switch (seed%10) {
		default:
		case 0: str="Tip 1: Black spheres hurt you when picked up."; break;
		case 1: str="Tip 2: There is a way to affect the level type selection."; break;
		case 2: str="Tip 3: Start with -offline if you don't want the game to phone home."; break;
		case 3: str="Tip 4: Pressing 't' shows you the next tip."; break;
		case 4: str="Tip 5: Try starting with '-help' for an overview of commandline options."; break;
		case 5: str="Tip 6: You can set your online hiscore name and league with '-name' and '-league'."; break;
		case 6: str="Tip 7: The indicator on the weapon shows laser energy levels."; break;
		case 7: str="Tip 8: Extras may have sideeffects."; break;
		case 8: str="Tip 9: Want more/better games? Give feedback!"; break;
		case 9: str="Thanks for playing!"; break;
	}


	glColor3ub(250,250,250);
	Font_ogl::write(
		C3(320,300),
		str,
		FA_CENTER
	);
}


} //namespace