|
|
|
@ -39,6 +39,7 @@ enum GAMESTATE{ |
|
|
|
|
GAMEWORLD, |
|
|
|
|
WAITING_FOR_CUTSCENE_3, |
|
|
|
|
GAME_OVER, |
|
|
|
|
COLLECTED_SILICON, |
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
namespace cutscene{ |
|
|
|
@ -80,6 +81,7 @@ namespace gameflag{ |
|
|
|
|
enum FLAG{ |
|
|
|
|
TUTORIAL_WALKED_OFF_FARM, |
|
|
|
|
VISIT_BROKEN_ROVER, |
|
|
|
|
COLLECTED_SILICON_1, |
|
|
|
|
}; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -1104,6 +1106,13 @@ public: |
|
|
|
|
performCropUpdate(8); |
|
|
|
|
displayPowerInfo(PETAL_STORM); |
|
|
|
|
} else |
|
|
|
|
if (obj->name.compare("SILICON_PIECE")==0&&collidesWithPlayer(obj)) { |
|
|
|
|
GAME_STATE=COLLECTED_SILICON; |
|
|
|
|
DisplayMessageBox(14); |
|
|
|
|
COLLECTED_ITEMS.push_back({obj->x,obj->y}); |
|
|
|
|
OBJECTS.erase(OBJECTS.begin()+i--); |
|
|
|
|
delete obj; |
|
|
|
|
} else |
|
|
|
|
if (obj->name.compare("EXIT")==0&&collidesWithPlayer(obj)) { |
|
|
|
|
fadeOut(); |
|
|
|
|
PlayCutscene(cutscene::TRANSITION_CUTSCENE); |
|
|
|
@ -1521,6 +1530,16 @@ public: |
|
|
|
|
GAME_STATE=CUTSCENE_3; |
|
|
|
|
} |
|
|
|
|
}break; |
|
|
|
|
case COLLECTED_SILICON:{ |
|
|
|
|
if (!messageBoxVisible) { |
|
|
|
|
if (!GAME_FLAGS[gameflag::COLLECTED_SILICON_1]) { |
|
|
|
|
GAME_FLAGS[gameflag::COLLECTED_SILICON_1]=true; |
|
|
|
|
DisplayMessageBox(15); |
|
|
|
|
} else { |
|
|
|
|
GAME_STATE=GAMEWORLD; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}break; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
if (PIXEL_EFFECT_TRANSPARENCY>0) { |
|
|
|
@ -1597,7 +1616,8 @@ public: |
|
|
|
|
GradientFillRectDecal({WIDTH/2,HEIGHT/2},{WIDTH/2,HEIGHT/2},{20, 28, 22,ALPHA_SCREEN2},{20, 28, 22,ALPHA_SCREEN1},{20, 28, 22,ALPHA_SCREEN1},{20, 28, 22,ALPHA_SCREEN1}); |
|
|
|
|
}break; |
|
|
|
|
case CUTSCENE_2: |
|
|
|
|
case GAMEWORLD:{ |
|
|
|
|
case GAMEWORLD: |
|
|
|
|
case COLLECTED_SILICON:{ |
|
|
|
|
DrawGameWorld(); |
|
|
|
|
int meterYOffset=2; |
|
|
|
|
if (CURRENT_CUTSCENE==cutscene::NONE) { |
|
|
|
|