Go to the documentation of this file.00001
00002
00003
00004
00005 #ifndef __prototypes_h__
00006 #define __prototypes_h__
00007
00008 #include <gccore.h>
00009 #include "menu.h"
00010 #include "Powerup.h"
00011
00012
00013 #define MAX_ACQUIRED_POWERUPS 3 // remove later
00014
00015 class TetrisPiece;
00016
00017 void Reset();
00018 void InitPieces();
00019 void NewPiece(int player);
00020 void NewPieceAll();
00021 void DrawPiece(int player, TetrisPiece* cp = NULL, u8 alpha = 255);
00022 void DrawPieceAll();
00023 void DrawPieceShadow(int player);
00024 void DrawPieceShadowAll();
00025 void DrawNextPiece(int player);
00026 void DrawNextPieceAll();
00027 void DrawBase(int player);
00028 void DrawBaseAll();
00029 void DrawSquare(int x, int y, u8 gfx, int player, u8 alpha = 255);
00030 void DrawMap(int player);
00031 void DrawMapAll();
00032 void rotate(int way,int player);
00033
00034 void TCYC_Draw();
00035 void TCYC_SetUp2D();
00036 void TCYC_DrawPlayfieldBoundary();
00037 void TCYC_DrawText();
00038 void TCYC_DrawPowerups();
00039
00040 void TCYC_DrawPowerupBorders();
00041 void TCYC_DrawPowerupTexture(int upperLeftX, int upperLeftY, GuiImageData *imgData, u8 alpha);
00042 void TCYC_DrawPowerupTextures();
00043 int TCYC_GetTargetPlayer(int x);
00044 int TCYC_GetTargetPowerupSlot(int player, int x, int y);
00045
00046 void DrawBlockAsCube(int player, float x, float y, int colorIdx, u8 alpha = 255, GuiImageData *imgData = NULL);
00047 void GX_Cube(int colorIdx, u8 alpha = 255, GuiImageData *imgData = NULL);
00048
00049 void InitPieceDescriptions();
00050
00051 int RemoveLines(int player);
00052 void RemoveLine(int line,int player);
00053 int TestRotate(int way,int player);
00054 void DoInput();
00055 void DoMovement(int player);
00056 void TCYC_Update();
00057 void TCYC_ProcessInput();
00058 void Pause(const char *pauseTxt = NULL, GXColor *txtColor = NULL);
00059 void TCYC_ProcessEditModeInput();
00060
00061 extern "C"
00062 {
00063 void sgenrand(unsigned long seed);
00064 double genrand();
00065 }
00066
00067 void RootMenu();
00068 void OptionsMenu();
00069 void winner(int player);
00070 void FadeOutMusicAndStop();
00071
00072 void TetriCycle_main();
00073 void game();
00074 void TCYC_Render();
00075
00076 void editPlayfield();
00077 void TCYC_DrawEditMode();
00078 void TCYC_DrawTetriCycleEditMode();
00079 void TCYC_DrawEditPlayfieldMenu();
00080
00081 bool canPlace(int player, TetrisPiece* cp = NULL);
00082 bool MoveBlock(int type, int player, TetrisPiece* cp = NULL);
00083 bool MovePlayfield(int type, int player);
00084
00085 void SetBaseColor(GXColor &c);
00086
00087 #endif