|
|
@ -1,11 +1,20 @@
|
|
|
|
/* $Id: help.c,v 1.2 2004/02/07 13:52:50 stpohle Exp $
|
|
|
|
/* $Id: help.c,v 1.3 2004/02/07 15:03:25 stpohle Exp $
|
|
|
|
* Display complex help text and information screen about the game
|
|
|
|
* Display complex help text and information screen about the game
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
#include "bomberclone.h"
|
|
|
|
#include "bomberclone.h"
|
|
|
|
#include "menu.h"
|
|
|
|
#include "menu.h"
|
|
|
|
|
|
|
|
|
|
|
|
#define HELP_MAXPAGES 3
|
|
|
|
enum _help_page {
|
|
|
|
|
|
|
|
HP_howto0 = 0,
|
|
|
|
|
|
|
|
HP_powerup0,
|
|
|
|
|
|
|
|
HP_powerup1,
|
|
|
|
|
|
|
|
HP_powerup2,
|
|
|
|
|
|
|
|
HP_keyboard0,
|
|
|
|
|
|
|
|
HP_credits0,
|
|
|
|
|
|
|
|
HP_max
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void help () {
|
|
|
|
void help () {
|
|
|
|
int page = 0, menuselect = 2, y = 0;
|
|
|
|
int page = 0, menuselect = 2, y = 0;
|
|
|
@ -17,10 +26,10 @@ void help () {
|
|
|
|
gfx_load_players (gfx.block.x, gfx.block.y);
|
|
|
|
gfx_load_players (gfx.block.x, gfx.block.y);
|
|
|
|
|
|
|
|
|
|
|
|
while (menuselect != -1 && menuselect != 1 && bman.state != GS_quit) {
|
|
|
|
while (menuselect != -1 && menuselect != 1 && bman.state != GS_quit) {
|
|
|
|
if (page == 0) {
|
|
|
|
if (page == HP_howto0) {
|
|
|
|
sprintf (title, "How To Play (%d/%d)", page + 1, HELP_MAXPAGES);
|
|
|
|
sprintf (title, "How To Play (%d/%d)", page + 1, HP_max);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
menu_create_text ("help", -1, 55, 53, 20,
|
|
|
|
menu_create_text ("help", 5, 55, 53, 20, COLOR_brown,
|
|
|
|
"The goal of the game is to be the last one, "
|
|
|
|
"The goal of the game is to be the last one, "
|
|
|
|
"who is alive. You can drop bombs which will explode after "
|
|
|
|
"who is alive. You can drop bombs which will explode after "
|
|
|
|
"a certain time and destroy everything in horizontal and vertical "
|
|
|
|
"a certain time and destroy everything in horizontal and vertical "
|
|
|
@ -30,13 +39,13 @@ void help () {
|
|
|
|
"running faster than your opponent and you have many bombs, you can catch "
|
|
|
|
"running faster than your opponent and you have many bombs, you can catch "
|
|
|
|
"him within lots of bombs and he has no chance to escape.");
|
|
|
|
"him within lots of bombs and he has no chance to escape.");
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", -1, 255, 53, 10,
|
|
|
|
menu_create_text ("help", 5, 255, 53, 10, COLOR_brown,
|
|
|
|
"You will get points for every player you have killed. "
|
|
|
|
"You will get points for every player you have killed. "
|
|
|
|
"If you win the game, you can earn additional points "
|
|
|
|
"If you win the game, you can earn additional points "
|
|
|
|
"depending on how many players played the game. ");
|
|
|
|
"depending on how many players played the game. ");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (page == 1) {
|
|
|
|
else if (page == HP_powerup0) {
|
|
|
|
sprintf (title, "Powerups (%d/%d)", page + 1, HELP_MAXPAGES);
|
|
|
|
sprintf (title, "Powerups (%d/%d)", page + 1, HP_max);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
y = 50;
|
|
|
@ -46,81 +55,191 @@ void help () {
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", -1, y, 53, 10,
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
"In the game you will find some diffend kind of powerups. "
|
|
|
|
"In the game you will find some diffend kind of powerups. "
|
|
|
|
"There are the powerups who give you more power for the whole game "
|
|
|
|
"There are the powerups who give you more power for the whole game "
|
|
|
|
"and the special powerups which will hold only for a certain time.");
|
|
|
|
"and the special powerups which will hold only for a certain time.");
|
|
|
|
y += 80;
|
|
|
|
y += 75;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_label ("Permanent Powerups", -1, y, 2);
|
|
|
|
menu_create_label ("Permanent Powerups", -1, y, 2, COLOR_brown);
|
|
|
|
y += (5 + font[2].size.y);
|
|
|
|
y += (5 + font[2].size.y);
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("bomb", 5, y, 1, gfx.field[FT_bomb].image, &rect);
|
|
|
|
menu_create_image ("bomb", 5, y, 1, gfx.field[FT_bomb].image, &rect);
|
|
|
|
menu_create_text ("help", 55, y, 45, 10,
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
"Give you another bomb to drop. Maximum number of bombs is %d.", MAX_BOMBS);
|
|
|
|
"Give you another bomb to drop. Maximum number of bombs is %d.", MAX_BOMBS);
|
|
|
|
y += 40;
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("fire", 5, y, 1, gfx.field[FT_fire].image, &rect);
|
|
|
|
menu_create_image ("fire", 5, y, 1, gfx.field[FT_fire].image, &rect);
|
|
|
|
menu_create_text ("help", 55, y, 45, 10,
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
"The range of your bombs will be increased. Maximum range is %d.", MAX_RANGE);
|
|
|
|
"The range of your bombs will be increased. Maximum range is %d.", MAX_RANGE);
|
|
|
|
y += 40;
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[0].image, &rect);
|
|
|
|
menu_create_image ("shoe", 5, y, 1, gfx.field[FT_shoe].image, &rect);
|
|
|
|
menu_create_image ("shoe", 5, y, 1, gfx.field[FT_shoe].image, &rect);
|
|
|
|
menu_create_text ("help", 55, y, 45, 10,
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
"This will make your player run faster. The maximum speed will be %1.2f.", MAX_SPEED);
|
|
|
|
"This will make your player run faster. The maximum speed will be %1.2f.", MAX_SPEED);
|
|
|
|
y += 40;
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", -1, y, 53, 10,
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
"Depends how the game is set up, you'll lose "
|
|
|
|
"Depends how the game is set up, you'll lose "
|
|
|
|
"these powerups if you die. Other players can collect them. "
|
|
|
|
"these powerups if you die. Other players can collect them. "
|
|
|
|
"In the deathmatch mode you can keep the powerups you collected, "
|
|
|
|
"In the deathmatch mode you can keep the powerups you collected, "
|
|
|
|
"but this depends on the Game if you drop them or not.");
|
|
|
|
"but this depends on the Game if you drop them or not.");
|
|
|
|
y += 40;
|
|
|
|
y += 40;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (page == 2) {
|
|
|
|
else if (page == HP_powerup1) {
|
|
|
|
sprintf (title, "Powerups (%d/%d)", page + 1, HELP_MAXPAGES);
|
|
|
|
sprintf (title, "Powerups (%d/%d)", page + 1, HP_max);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
y = 45;
|
|
|
|
|
|
|
|
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_label ("Special Powerups", -1, y, 2);
|
|
|
|
menu_create_label ("Special Powerups", -1, y, 2, COLOR_brown);
|
|
|
|
y += (10 + font[2].size.y);
|
|
|
|
y += (5 + font[2].size.y);
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
menu_create_image ("kick", 5, y, 1, gfx.field[FT_sp_kick].image, &rect);
|
|
|
|
menu_create_image ("kick", 5, y, 1, gfx.field[FT_sp_kick].image, &rect);
|
|
|
|
menu_create_text ("help", 55, y, 45, 10,
|
|
|
|
menu_create_text ("help", 55, y, 48, 10, COLOR_brown,
|
|
|
|
"Allowes you to kick some bombs around the level. This will hold "
|
|
|
|
"Allowes you to kick some bombs around the level. This will hold "
|
|
|
|
"just a short time of %d seconds. The maximum distance you can "
|
|
|
|
"just a short time of %d seconds. The maximum distance you can "
|
|
|
|
"kick the bombs is %d fields.", SPECIAL_KICK_TIME, SPECIAL_KICK_MAXDIST);
|
|
|
|
"kick the bombs is %d fields.", SPECIAL_KICK_TIME, SPECIAL_KICK_MAXDIST);
|
|
|
|
y += 40;
|
|
|
|
y += 70;
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
menu_create_image ("push", 5, y, 1, gfx.field[FT_sp_push].image, &rect);
|
|
|
|
menu_create_image ("push", 5, y, 1, gfx.field[FT_sp_push].image, &rect);
|
|
|
|
menu_create_text ("help", 55, y, 45, 10,
|
|
|
|
menu_create_text ("help", 55, y, 48, 10, COLOR_brown,
|
|
|
|
"Give you another bomb to drop. Maximum number of bombs is %d.", MAX_BOMBS);
|
|
|
|
"Push bombs one field, as long as nothing is behind this bomb.");
|
|
|
|
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
|
|
|
|
menu_create_image ("droprow", 5, y, 1, gfx.field[FT_sp_row].image, &rect);
|
|
|
|
|
|
|
|
menu_create_text ("help", 55, y, 48, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"You can drop a row of that many bombs you have still left to drop.");
|
|
|
|
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
|
|
|
|
menu_create_image ("dropliquid", 5, y, 1, gfx.field[FT_sp_liquid].image, &rect);
|
|
|
|
|
|
|
|
menu_create_text ("help", 55, y, 48, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"The bomb you push now won't stop moving untill they explode.");
|
|
|
|
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
|
|
|
|
menu_create_image ("dropliquid", 5, y, 1, gfx.field[FT_sp_moved].image, &rect);
|
|
|
|
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"The bomb you push will stop moving on the next border or bomb.");
|
|
|
|
y += 40;
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 5, y, 0, gfx.powerup[2].image, &rect);
|
|
|
|
|
|
|
|
menu_create_image ("dropltrigger", 5, y, 1, gfx.field[FT_sp_trigger].image, &rect);
|
|
|
|
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"You will be able to drop triggered bombs. Use "
|
|
|
|
|
|
|
|
"the special key to let all your bombs explode. "
|
|
|
|
|
|
|
|
"at the time where you want it.");
|
|
|
|
|
|
|
|
y += 40;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (page == HP_powerup2) {
|
|
|
|
|
|
|
|
sprintf (title, "Powerups (%d/%d)", page + 1, HP_max);
|
|
|
|
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"In the game you will find another type of item to collect. "
|
|
|
|
|
|
|
|
"This item is not a powerup at all. If you collect it you will "
|
|
|
|
|
|
|
|
"get a random illness. This illness will hold for %dseconds. "
|
|
|
|
|
|
|
|
"If you have contact to another player the other player will "
|
|
|
|
|
|
|
|
"get all the illnesses you have too.", ILL_TIMEOUT);
|
|
|
|
|
|
|
|
y += 100;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_image ("pwback", 12, y+8, 0, gfx.powerup[1].image, &rect);
|
|
|
|
|
|
|
|
menu_create_image ("pwdeath", 12, y+8, 1, gfx.field[FT_death].image, &rect);
|
|
|
|
|
|
|
|
menu_create_text ("help", 55, y, 45, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"This will make your player ill. We have at the moment %d diffrent "
|
|
|
|
|
|
|
|
"types of illnesses for you to collect. To make the game more", PI_max);
|
|
|
|
|
|
|
|
y += 3*font[0].size.y;
|
|
|
|
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"interesting we won't put here a list of all types there are.");
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (page == HP_keyboard0) {
|
|
|
|
|
|
|
|
sprintf (title, "Keyboard (%d/%d)", page + 1, HP_max);
|
|
|
|
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_label ("During a Game", -1, y, 2, COLOR_brown);
|
|
|
|
|
|
|
|
y += font[2].size.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"Arrow Keys - Moving of the Player\n"
|
|
|
|
|
|
|
|
"STRG/CTRL - Dropping bombs\n"
|
|
|
|
|
|
|
|
"Shift - Special Use Key\n"
|
|
|
|
|
|
|
|
"F4 - Start the Game (only Server)\n"
|
|
|
|
|
|
|
|
"F8 - Fullscreen (not in Windows)\n"
|
|
|
|
|
|
|
|
"Return - Send Entered Text Message\n"
|
|
|
|
|
|
|
|
"ESC - Exit Game\n");
|
|
|
|
|
|
|
|
y += 7*font[0].size.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_label ("Player Selection", -1, y, 2, COLOR_brown);
|
|
|
|
|
|
|
|
y += font[2].size.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
menu_create_text ("help", 5, y, 53, 10, COLOR_brown,
|
|
|
|
|
|
|
|
"Left/Right - Select and Deselect a Player\n"
|
|
|
|
|
|
|
|
"F1 - Mini Help Screen\n"
|
|
|
|
|
|
|
|
"F2 - Map and Game Settings\n"
|
|
|
|
|
|
|
|
"F3 - Create a AI Player\n"
|
|
|
|
|
|
|
|
"Shift-F3 - Delete a AI Player\n"
|
|
|
|
|
|
|
|
"F4 - Start the Game if at last 2 Players\n"
|
|
|
|
|
|
|
|
" are selected. (only Server)\n"
|
|
|
|
|
|
|
|
"ESC - Exit Game\n");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (page == HP_credits0) {
|
|
|
|
|
|
|
|
sprintf (title, "Credits (%d/%d)", page + 1, HP_max);
|
|
|
|
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if (page == HP_keyboard0) {
|
|
|
|
|
|
|
|
sprintf (title, "Keyboard (%d/%d)", page + 1, HP_max);
|
|
|
|
|
|
|
|
menu_new (title, 500, 400);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
y = 50;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
rect.x = rect.y = 0;
|
|
|
|
|
|
|
|
rect.w = gfx.block.x;
|
|
|
|
|
|
|
|
rect.h = gfx.block.y;
|
|
|
|
|
|
|
|
}
|
|
|
|
else break;
|
|
|
|
else break;
|
|
|
|
|
|
|
|
|
|
|
|
if (page > 0) menu_create_button ("Previous Page", 20, 370, 150, 0);
|
|
|
|
if (page > 0) menu_create_button ("Previous Page", 20, 370, 150, 0);
|
|
|
|
else if (menuselect == 0)
|
|
|
|
else if (menuselect == 0)
|
|
|
|
menuselect = 2;
|
|
|
|
menuselect = 2;
|
|
|
|
menu_create_button ("Main Menu", -1, 370, 150, 1);
|
|
|
|
menu_create_button ("Main Menu", -1, 370, 150, 1);
|
|
|
|
if (page < HELP_MAXPAGES-1) menu_create_button ("Next Page", 350, 370, 150, 2);
|
|
|
|
if (page < HP_max-1) menu_create_button ("Next Page", 350, 370, 150, 2);
|
|
|
|
|
|
|
|
|
|
|
|
menu_focus_id (menuselect);
|
|
|
|
menu_focus_id (menuselect);
|
|
|
|
menuselect = menu_loop ();
|
|
|
|
menuselect = menu_loop ();
|
|
|
|
if (menuselect == 0 && page > 0)
|
|
|
|
if (menuselect == 0 && page > 0)
|
|
|
|
page--;
|
|
|
|
page--;
|
|
|
|
if (menuselect == 2 && page < HELP_MAXPAGES - 1)
|
|
|
|
if (menuselect == 2 && page < HP_max - 1)
|
|
|
|
page++;
|
|
|
|
page++;
|
|
|
|
menu_delete ();
|
|
|
|
menu_delete ();
|
|
|
|
}
|
|
|
|
}
|
|
|
|