• Skip to content
  • Skip to link menu
KDE 4.0 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

kgoldrunner

kgrconsts.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *                       kgrconsts.h  -  description                       *
00003  *                           -------------------                           *
00004     Copyright 2003 Marco Krüger <grisuji@gmx.de>
00005     Copyright 2003 Ian Wadham <ianw2@optusnet.com.au>
00006  *                                                                         *
00007  *   This program is free software; you can redistribute it and/or modify  *
00008  *   it under the terms of the GNU General Public License as published by  *
00009  *   the Free Software Foundation; either version 2 of the License, or     *
00010  *   (at your option) any later version.                                   *
00011  ***************************************************************************/
00012 
00013 #ifndef KGRCONSTS_H
00014 #define KGRCONSTS_H
00015 
00016 enum Owner {SYSTEM, USER};
00017 
00018 const char FREE    = ' ';
00019 const char ENEMY   = 'E';
00020 const char HERO    = 'R';
00021 const char BETON   = 'X';
00022 const char BRICK   = 'M';
00023 const char FBRICK  = 'F';
00024 const char HLADDER = 'Z';
00025 const char LADDER  = 'H';
00026 const char NUGGET  = 'N';
00027 const char POLE    = 'T';
00028 const char HOLE    = 'O';
00029 const char USEDHOLE= 'U';
00030 
00031 const char CANWALKLEFT  = 0x1;
00032 const char CANWALKRIGHT = 0x2;
00033 const char CANWALKUP    = 0x4;
00034 const char CANWALKDOWN  = 0x8;
00035 const char VISITED      = 0x10;
00036 
00037 const char FIELDWIDTH   = 28;
00038 const char FIELDHEIGHT  = 20;
00039 
00040 const char VERTIKAL     = 0;
00041 const char HORIZONTAL   = 1;
00042 
00043 /* Action times ... */
00044 #define NSPEED      12
00045 #define MAXSPEED    NSPEED * 2
00046 #define MINSPEED    NSPEED / 4
00047 
00048 #define BEGINSPEED  NSPEED / 2
00049 #define NOVICESPEED (3 * NSPEED) / 4
00050 #define CHAMPSPEED  (3 * NSPEED) / 2
00051 
00052 typedef struct {
00053     int hwalk;
00054     int hfall;
00055     int ewalk;
00056     int efall;
00057     int ecaptive;
00058     int hole;
00059 } Timing;
00060 
00061 const int DIGDELAY = 200;
00062 
00063 const int STEP = 4;
00064 const int gameCycle = 4;        // Animation frames per playfield tile.
00065 const int graphicsCycle = 8;        // Animation frames per running cycle.
00066 
00067 const double DROPNUGGETDELAY = 70.0;    // Enemy holds gold for avg. 12.5 cells.
00068 
00069 enum Position       {RIGHTWALK1,RIGHTWALK2,RIGHTWALK3,RIGHTWALK4,RIGHTWALK5,RIGHTWALK6,RIGHTWALK7,RIGHTWALK8,
00070              LEFTWALK1,LEFTWALK2,LEFTWALK3,LEFTWALK4,LEFTWALK5,LEFTWALK6,LEFTWALK7,LEFTWALK8,
00071              RIGHTCLIMB1,RIGHTCLIMB2,RIGHTCLIMB3,RIGHTCLIMB4,RIGHTCLIMB5,RIGHTCLIMB6,RIGHTCLIMB7,RIGHTCLIMB8,
00072              LEFTCLIMB1,LEFTCLIMB2,LEFTCLIMB3,LEFTCLIMB4,LEFTCLIMB5,LEFTCLIMB6,LEFTCLIMB7,LEFTCLIMB8,
00073              CLIMB1,CLIMB2,
00074              FALL1,FALL2};
00075 enum Status     {STANDING,FALLING,WALKING,CLIMBING,CAPTIVE};
00076 enum Direction      {RIGHT,LEFT,UP,DOWN,STAND};
00077 enum SearchStrategy {LOW,MEDIUM,HIGH};
00078 
00079 // Keyboard action codes
00080 enum KBAction       {KB_UP, KB_DOWN, KB_LEFT, KB_RIGHT,
00081              KB_DIGLEFT, KB_DIGRIGHT, KB_STOP};
00082 
00083 // Action codes when selecting a level or game for play or editing.
00084 enum SelectAction   {SL_START, SL_ANY, SL_CREATE, SL_UPDATE, SL_SAVE,
00085              SL_MOVE, SL_DELETE, SL_CR_GAME, SL_UPD_GAME};
00086 
00087 #endif // KGRCONSTS_H

kgoldrunner

Skip menu "kgoldrunner"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members

API Reference

Skip menu "API Reference"
  • kblackbox
  • kgoldrunner
  • kmahjongg
  • ksquares
  • libkdegames
  •   highscore
  •   kgame
  •   kggzgames
  •   kggzmod
  •   kggznet
  • libkmahjongg
Generated for API Reference by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal