Hp, Lvl en Xp gameplay toegevoegt

This commit is contained in:
Aaldert
2016-06-21 12:25:38 +02:00
parent 7c4805d899
commit 35c21260e4
7 changed files with 76 additions and 10 deletions
+4 -4
View File
@@ -60,8 +60,8 @@ void Interface::draw()
glVertex2f(250, 965);
glColor4f(1.0f, 0.5f, 0.5f, 1.0);
glVertex2f(250 + (player->health / 100 * 500), 965);
glVertex2f(250 + (player->health / 100 * 500), 980);
glVertex2f(250 + (player->health / player->maxHp * 500), 965);
glVertex2f(250 + (player->health / player->maxHp * 500), 980);
glEnd();
//XP bar
@@ -79,8 +79,8 @@ void Interface::draw()
glVertex2f(250, 935);
glColor4f(1.0f, 1.0f, 0.5f, 1.0);
glVertex2f(250 + (player->xp / 100 * 500), 935);
glVertex2f(250 + (player->xp / 100 * 500), 950);
glVertex2f(250 + (player->xp / player->maxXp * 500), 935);
glVertex2f(250 + (player->xp / player->maxXp * 500), 950);
glEnd();
//Text: level