Lib for the game characters of robozoec era

Revision:
3:704821ea028f
Parent:
2:d9440b3314bb
--- a/gameCharacters.h	Wed May 04 10:12:42 2016 +0000
+++ b/gameCharacters.h	Thu May 05 14:57:41 2016 +0000
@@ -1,61 +1,64 @@
-/* Library referencing all the arrays needed in the game
-
+/**
+@file gameCharacters.h
+@brief Revision 1.0.
+@author Robin Milward Cooney
+@date   May 2015
 */
 
-int g_g1;         //global vaiable that is is 1 when the players gun is upgraded
-int g_g2;         //global vaiable that is is 1 when the players gun is upgraded for the second time
+//Library referencing all the arrays needed in the game
 
-int g_recks_still_gun[10][10]= {            //global array for the main charachter (recks) when he is still
+
+const int g_recks_still_gun[10][10]= {  
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
-    {0,0,0,0,1,0,1,1,g_g1,g_g2},
+    {0,0,0,0,1,0,1,1,0,0},
     {0,0,0,0,1,1,1,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0}
-};
+};  /*!<Global array for the main charachter (recks) when he is still*/
 
-int g_recks_moving_gun[10][10]= {      //global array for the main charachter (recks) when he is moving
+const int g_recks_moving_gun[10][10]= {      
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
-    {0,0,0,0,1,0,1,1,g_g1,g_g2},
+    {0,0,0,0,1,0,1,1,0,0},
     {0,0,0,0,1,1,1,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,1,0,1,0,0,0,0},
     {0,0,1,0,0,0,1,0,0,0},
     {0,1,0,0,0,0,0,1,0,0}
-};
+};      /*!<Global array for the main charachter (recks) when he is moving*/
 
-int g_recks_crouch_gun[10][10]= {      //global array for the main charachter (recks) when he is crouching
+const int g_recks_crouch_gun[10][10]= {  
     {0,0,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
-    {0,0,0,0,1,0,1,1,g_g1,g_g2},
+    {0,0,0,0,1,0,1,1,0,0},
     {0,0,0,0,1,1,1,0,0,0},
     {0,0,0,0,1,0,0,0,0,0},
     {0,0,0,0,0,1,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0}
-};
+};      /*!<Global array for the main charachter (recks) when he is crouching*/
 
-int g_recks_jump_gun[10][10]= {          //global array for the main charachter (recks) when he is in the jumbing position
+const int g_recks_jump_gun[10][10]= {   
     {0,0,1,1,1,0,0,0,0,0},
     {0,0,1,1,1,0,0,0,0,0},
     {0,0,1,1,1,0,0,0,0,0},
-    {0,0,0,1,0,1,1,g_g1,g_g2},
+    {0,0,0,1,0,1,1,0,0,0},
     {0,0,0,1,1,1,0,0,0,0},
     {0,0,0,1,0,0,1,0,0,0},
     {0,0,0,1,0,1,0,1,0,0},
     {0,0,0,0,1,0,0,0,1,0},
     {0,0,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0}
-};
+};      /*!<Global array for the main charachter (recks) when he is in the jumping position*/
 
 const int g_recks_shield[15][15]= {
     {0,0,0,0,1,1,1,1,1,1,1,0,0,0,0},
@@ -75,19 +78,19 @@
     {0,0,0,1,0,0,0,0,0,0,0,1,0,0,0}
 };
 
-const int g_mob_rat_p1[3][8]= {           //global array for a rat
+const int g_mob_rat_p1[3][8]= {           
     {0,0,0,0,0,0,0,1},
     {0,1,1,1,0,0,1,0},
     {1,1,1,1,1,1,0,0}
-};
+};  /*!<Global array for a rat (position 1)*/
 
-const int g_mob_rat_p2[3][8]= {           //second global array for a rat
+const int g_mob_rat_p2[3][8]= {          
     {0,0,0,0,0,0,1,0},
     {0,1,1,1,0,0,1,0},
     {1,1,1,1,1,1,0,0}
-};
+};      /*!<Global array for a rat (position 2)*/
 
-const int g_mob_hound_p1[8][13]= {        //global array for a hound
+const int g_mob_hound_p1[8][13]= {        
     {0,0,0,1,0,0,0,0,0,0,0,0,0},
     {0,1,1,1,0,0,0,0,0,0,0,1,0},
     {1,1,1,1,0,0,0,0,0,0,0,1,0},
@@ -96,9 +99,9 @@
     {0,0,0,1,0,0,0,0,0,0,1,0,0},
     {0,0,0,1,0,0,0,0,0,0,1,0,0},
     {0,0,0,1,0,0,0,0,0,0,1,0,0}
-};
+};  /*!<Global array for a still hound*/
 
-const int g_mob_hound_p2[8][13]= {        //global array for a moving hound
+const int g_mob_hound_p2[8][13]= {       
     {0,0,0,1,0,0,0,0,0,0,0,0,0},
     {0,1,1,1,0,0,0,0,0,0,0,0,1},
     {1,1,1,1,0,0,0,0,0,0,0,1,0},
@@ -107,9 +110,9 @@
     {0,0,1,0,0,0,0,0,0,0,0,1,0},
     {0,1,0,0,0,0,0,0,0,0,0,0,1},
     {1,0,0,0,0,0,0,0,0,0,0,0,1}
-};
+};      /*!<Global array for a moving hound*/
 
-const int g_mob_hound_dead[8][13]= {        //global array for a moving hound
+const int g_mob_hound_dead[8][13]= {        
     {0,0,0,0,0,0,0,0,0,0,1,0,1},
     {0,0,1,0,0,1,0,1,0,1,0,0,1},
     {0,1,0,1,0,0,0,0,0,0,0,1,0},
@@ -118,9 +121,9 @@
     {0,0,0,0,0,1,0,0,0,0,0,0,0},
     {0,1,0,0,0,0,1,0,0,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0,0,0,0}
-};
+};      /*!<Global array for a destroyed hound*/
 
-const int g_mob_bear_p1[10][19]= {        //global array for a still bear
+const int g_mob_bear_p1[10][19]= {      
     {0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
     {0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,1,1,0},
     {0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0},
@@ -131,9 +134,9 @@
     {0,0,0,1,1,1,0,0,0,0,0,0,0,0,1,1,1,0,0},
     {0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,1,1,0,0},
     {0,0,1,1,1,0,0,0,0,0,0,0,0,0,1,1,1,0,0}
-};
+};  /*!<Global array for a still bear*/
 
-const int g_mob_bear_p2[10][19]= {        //global array for a moving bear
+const int g_mob_bear_p2[10][19]= {  
     {0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
     {0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,1,1,0},
     {0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0},
@@ -144,9 +147,9 @@
     {0,0,1,1,1,1,0,0,0,0,0,0,0,0,1,1,1,0,0},
     {0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0},
     {1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1}
-};
+};  /*!<Global array for a moveing bear*/
 
-const int g_mob_bear_dead[10][19]= {        //global array for a still bear
+const int g_mob_bear_dead[10][19]= {      
     {0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0},
     {0,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,1,1,0},
     {0,0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,0,0},
@@ -157,7 +160,7 @@
     {0,0,0,1,1,0,0,0,0,1,0,0,0,0,1,1,1,0,0},
     {0,0,0,0,1,0,0,0,1,0,0,0,0,0,0,1,0,0,0},
     {0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0}
-};
+};  /*!<Global array for a destroyed bear*/
 
 
 const int g_mob_bird_p1 [10][10]= {
@@ -171,7 +174,7 @@
     {0,0,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0}
-};
+};  /*!<Global array for a bird (position 1)*/
 
 const int g_mob_bird_p2 [10][10]= {
     {0,0,0,0,0,0,0,0,0,0},
@@ -184,7 +187,7 @@
     {0,0,0,0,1,1,1,0,0,0},
     {0,0,0,0,1,1,0,0,0,0},
     {0,0,0,0,1,0,0,0,0,0}
-};
+};  /*!<Global array for a bird (position 2)*/
 
 const int g_mob_bird_dead [10][10]= {
     {0,0,0,0,0,0,0,0,0,0},
@@ -197,9 +200,9 @@
     {0,1,0,0,0,1,0,1,0,0},
     {0,0,0,1,0,0,0,0,0,1},
     {0,0,0,0,0,0,0,0,0,0}
-};
+};  /*!<Global array for a destroyed bird*/
 
-const int cactus[12][5]= {
+const int g_cactus[12][5]= {
     {0,0,1,0,0},
     {0,0,1,0,0},
     {0,0,1,0,1},
@@ -212,7 +215,7 @@
     {0,0,1,0,0},
     {0,0,1,0,0},
     {0,0,1,0,0}
-};
+};      /*!<Global array for a cactus*/
 
 const int g_t_rex[28][25]= {
     {0,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
@@ -243,7 +246,8 @@
     {0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,1,1,1,0,1,1,1,0,0,0,0,0,0,0,0,0}
-};
+};      /*!<Global array for a still T Rex*/
+
 const int g_t_rex_moving[28][25]= {
     {0,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
     {1,1,1,1,1,1,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
@@ -273,7 +277,7 @@
     {0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0},
     {0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0},
     {0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,1,1,1,0,0,0,0}
-};
+};           /*!<Global array for a moving T Rex*/
 
 const int g_t_rex_attack[28][25]= {
     {0,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
@@ -304,7 +308,7 @@
     {0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,1,1,0,0,0,0,0,0,0,0},
     {0,0,0,0,0,0,0,0,0,1,1,1,0,1,1,1,0,0,0,0,0,0,0,0}
-};
+};       /*!<Global array for an attacking T Rex*/
 
 const int g_fire_ball_p1[9][9]= {
     {0,0,0,1,0,1,0,0,0},
@@ -316,7 +320,7 @@
     {0,1,0,0,1,0,0,1,0},
     {0,0,0,0,0,0,0,0,0},
     {0,0,0,1,0,1,0,0,0}
-};
+};      /*!<Global array for a fire ball (position 1)*/
 
 const int g_fire_ball_p2[9][9]= {
     {0,0,0,0,1,0,0,0,0},
@@ -328,13 +332,13 @@
     {0,0,0,0,1,0,0,0,0},
     {0,0,1,0,0,0,1,0,0},
     {0,0,0,0,1,0,0,0,0}
-};
+};          /*!<Global array for a fire ball (position 2)*/
 
 const int g_clouds[3][342]= {
     {0,0,0,0,0,0,0,0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,1,1,1,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,0,0,0,0,0,0,1,1,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,0,1,1,1,1,0,0,0,0, 0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0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,1,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,0,1,0,0,0,0,1,1,1,1,0,0,0,0,0, 1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,1,1,1,0,0,0,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,0,0,1,1,0,0,0,0,0,0,0,1,1,0,1,1,1,1,0,0, 0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,1,0,0,0,1,1,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,0,1,0,0,0,0,1,1,1,1,0,0,1, 1,1,1,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,1,0,0,0,1,1,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,0,1,0,0,0,0,1,1,1,1,0,0,0,0,0}
-};
+};          /*!<Global array for clouds, they loop round when it reaches the end*/
 
 const int g_score[5][19]= {
     {1,1,1,0,1,1,1,0,1,1,1,0,1,1,1,0,1,1,1},
@@ -342,14 +346,15 @@
     {1,1,1,0,1,0,0,0,1,0,1,0,1,1,0,0,1,1,0},
     {0,0,1,0,1,0,0,0,1,0,1,0,1,0,1,0,1,0,0},
     {1,1,1,0,1,1,1,0,1,1,1,0,1,0,1,0,1,1,1}
-};
+};  /*!<Global array for the word "SCORE" in a smaller font than the deffault 6x6*/
+
 const int g_ammo[5][15]= {
     {1,1,1,0,1,0,1,0,1,0,1,0,1,1,1},
     {1,0,1,0,1,1,1,0,1,1,1,0,1,0,1},
     {1,1,1,0,1,0,1,0,1,0,1,0,1,0,1},
     {1,0,1,0,1,0,1,0,1,0,1,0,1,0,1},
     {1,0,1,0,1,0,1,0,1,0,1,0,1,1,1}
-};
+};  /*!<Global array for the word "AMMO" in a smaller font than the deffault 6x6*/
 
 const int g_speed_boost[7][14]= {
     {1,0,0,0,0,1,0,0,0,0,1,0,0,0},
@@ -359,7 +364,7 @@
     {0,0,1,0,0,0,0,1,0,0,0,0,1,0},
     {0,1,0,0,0,0,1,0,0,0,0,1,0,0},
     {1,0,0,0,0,1,0,0,0,0,1,0,0,0}
-};
+};  /*!<Global array for the speed boost pickup*/
 
 const int g_heart[5][5]= {
     {0,1,0,1,0},
@@ -367,7 +372,7 @@
     {1,1,1,1,1},
     {0,1,1,1,0},
     {0,0,1,0,0}
-};
+};    /*!<Global array for the heart pickup*/
 
 const int g_ammo_pickUp[8][7]= {
     {1,1,1,1,1,1,1},
@@ -378,7 +383,7 @@
     {1,0,1,0,1,0,1},
     {1,0,0,0,0,0,1},
     {1,1,1,1,1,1,1}
-};
+};    /*!<Global array for the ammo pickup*/
 
 const int g_padlock_p1[6][4]= {
     {0,1,1,0},
@@ -387,7 +392,7 @@
     {1,1,1,1},
     {1,1,1,1},
     {1,1,1,1}
-};
+};       /*!<Global array for a closed padlock. To use as a locked icon for story mode*/
 
 const int g_padlock_p2[6][4]= {
     {0,1,1,0},
@@ -396,7 +401,7 @@
     {1,1,1,1},
     {1,1,1,1},
     {1,1,1,1}
-};
+};      /*!<Global array for a open padlock. To use as a unlocked icon for story mode*/
 
 const int zero[5][3]= {
     {1,1,1},
@@ -404,7 +409,7 @@
     {1,0,1},
     {1,0,1},
     {1,1,1}
-};
+};   /*!<Global array for the number 0 in a smaller font than the standard 6x6*/
 
 const int one [5][3]= {
     {0,1,0},
@@ -412,7 +417,7 @@
     {0,1,0},
     {0,1,0},
     {1,1,1}
-};
+};  /*!<Global array for the number 1 in a smaller font than the standard 6x6*/
 
 const int two [5][3]= {
     {1,1,1},
@@ -420,7 +425,7 @@
     {1,1,1},
     {1,0,0},
     {1,1,1}
-};
+};  /*!<Global array for the number 2 in a smaller font than the standard 6x6*/
 
 const int three [5][3]= {
     {1,1,1},
@@ -428,7 +433,7 @@
     {0,1,1},
     {0,0,1},
     {1,1,1}
-};
+};  /*!<Global array for the number 3 in a smaller font than the standard 6x6*/
 
 const int four [5][3]= {
     {1,0,1},
@@ -436,7 +441,7 @@
     {1,1,1},
     {0,0,1},
     {0,0,1}
-};
+};  /*!<Global array for the number 4 in a smaller font than the standard 6x6*/
 
 const int five [5][3]= {
     {1,1,1},
@@ -444,7 +449,7 @@
     {1,1,1},
     {0,0,1},
     {1,1,1}
-};
+};  /*!<Global array for the number 5 in a smaller font than the standard 6x6*/
 
 const int six [5][3]= {
     {1,1,1},
@@ -452,7 +457,7 @@
     {1,1,1},
     {1,0,1},
     {1,1,1}
-};
+};  /*!<Global array for the number 6 in a smaller font than the standard 6x6*/
 
 const int seven [5][3]= {
     {1,1,1},
@@ -460,7 +465,7 @@
     {0,0,1},
     {0,0,1},
     {0,0,1}
-};
+};/*!<Global array for the number 7 in a smaller font than the standard 6x6*/
 
 const int eight [5][3]= {
     {1,1,1},
@@ -468,7 +473,7 @@
     {1,1,1},
     {1,0,1},
     {1,1,1}
-};
+};  /*!<Global array for the number 8 in a smaller font than the standard 6x6*/
 
 const int nine [5][3]= {
     {1,1,1},
@@ -476,7 +481,7 @@
     {1,1,1},
     {0,0,1},
     {0,0,1}
-};
+};  /*!<Global array for the number 9 in a smaller font than the standard 6x6*/
 
 const float song1[]= {
     0.108,
@@ -502,7 +507,9 @@
     0,0,1760,0,0,0,1760,0,2093,0,1976,0,0,0,0,0,
     1319,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
     1319,1319,0,1319,0,1319,1175,1047,988,1319,0,0,0,0,0,0
-};
+};  /*!<Global 1D array representing the notes in the song that is played during the game
+    the first element of the array is the quater beats per second all the other elements
+    represent the frequancies of the notes needed for the song*/
 
 
 
@@ -511,3 +518,5 @@
 
 
 
+
+