2 * $Logfile: /Freespace2/code/Starfield/Supernova.h $
7 * Include file for nebula stuff
10 * Revision 1.1 2002/05/03 03:28:12 root
14 * 4 9/09/99 11:40p Dave
15 * Handle an Assert() in beam code. Added supernova sounds. Play the right
16 * 2 end movies properly, based upon what the player did in the mission.
18 * 3 9/03/99 1:32a Dave
19 * CD checking by act. Added support to play 2 cutscenes in a row
20 * seamlessly. Fixed super low level cfile bug related to files in the
21 * root directory of a CD. Added cheat code to set campaign mission # in
24 * 2 7/21/99 8:10p Dave
25 * First run of supernova effect.
31 #ifndef __FS2_SUPERNOVA_FUN_HEADER_FILE
32 #define __FS2_SUPERNOVA_FUN_HEADER_FILE
34 // --------------------------------------------------------------------------------------------------------------------------
35 // SUPERNOVA DEFINES/VARS
41 // supernova timing stuff
42 #define SUPERNOVA_MIN_TIME 15.0f // must be at least 15 seconds out
43 #define SUPERNOVA_CUT_TIME 5.0f // note this is also the minimum time for the supernova sexpression
44 #define SUPERNOVA_CAMERA_MOVE_TIME 2.0f // this is the amount of time the camera will cut from the sun to the player
45 #define SUPERNOVA_FADE_TO_WHITE_TIME 1.0f // fade to white over this amount of time
47 // how much bigger the sun will be when the effect hits
48 #define SUPERNOVA_SUN_SCALE 3.0f
50 // status for the supernova this mission
51 #define SUPERNOVA_NONE 0 // nothing happened in this mission
52 #define SUPERNOVA_STARTED 1 // started, but the player never got hit by it
53 #define SUPERNOVA_HIT 2 // started and killed the player
54 extern int Supernova_status;
56 // --------------------------------------------------------------------------------------------------------------------------
57 // SUPERNOVA FUNCTIONS
61 void supernova_level_init();
64 void supernova_start(int seconds);
66 // call once per frame
67 void supernova_process();
69 // is there a supernova active
71 // 1 : player still in control. shockwave approaching.
72 // 2 : camera cut. player controls locked. letterbox
73 // 3 : tooltime. lots of particles
74 // 4 : player is effectively dead. fade to white. stop simulation
75 // 5 : give dead popup
76 int supernova_active();
78 // time left before the supernova hits
79 float supernova_time_left();
81 // pct complete the supernova (0.0 to 1.0)
82 float supernova_pct_complete();
84 // if the camera should cut to the "you-are-toast" cam
85 int supernova_camera_cut();
87 // get view params from supernova
88 void supernova_set_view(vector *eye_pos, matrix *eye_orient);