70 static int Ship_anim_class = -1;
71 static int Ss_delta_x, Ss_delta_y;
147 #define SHIP_SELECT_X_COORD 0
148 #define SHIP_SELECT_Y_COORD 1
149 #define SHIP_SELECT_W_COORD 2
150 #define SHIP_SELECT_H_COORD 3
154 #define SHIP_ANIM_LOOP_FRAME 51
156 #define MAX_ICONS_ON_SCREEN 4
213 #define SS_ACTIVE_ITEM_USED (1<<0)
225 static int SS_active_list_start;
226 static int SS_active_list_size;
246 #define NUM_SS_BUTTONS 4
247 #define SS_BUTTON_SCROLL_UP 0
248 #define SS_BUTTON_SCROLL_DOWN 1
249 #define SS_BUTTON_RESET 2
250 #define SS_BUTTON_DUMMY 3 // needed to capture mouse for drag/drop icons
260 ss_buttons(
char *
name,
int x1,
int y1,
int xt1,
int yt1,
int h,
int s) : filename(name), x(x1), y(y1), xt(xt1), yt(yt1), hotspot(h), scrollable(s) {}
273 ss_buttons(
"2_ssb_39", 913, 556, -1, -1, 39,0),
279 #define SHIP_SELECT_NUM_TEXT 1
290 static bitmap* ShipSelectMaskPtr;
291 static ubyte* ShipSelectMaskData;
292 static int Shipselect_mask_w, Shipselect_mask_h;
293 static int ShipSelectMaskBitmap;
296 static int Num_mask_regions;
349 #define SHIP_DESC_X 445
350 #define SHIP_DESC_Y 273
360 }
else if (!
stricmp(str,
NOX(
"@ship_type"))) {
363 }
else if (!
stricmp(str,
NOX(
"@ship_maneuverability"))) {
366 }
else if (!
stricmp(str,
NOX(
"@ship_armor"))) {
369 }
else if (!
stricmp(str,
NOX(
"@ship_manufacturer"))) {
372 }
else if (!
stricmp(str,
NOX(
"@ship_desc"))) {
418 if ( Carried_ss_icon.
from_x != mx || Carried_ss_icon.
from_y != my) {
439 for ( i = 0; i < static_cast<int>(
Ship_info.size()); i++ ) {
441 SS_active_items[
i].
flags = 0;
446 SS_active_list_start = 0;
447 SS_active_list_size = 0;
455 for ( i = 0; i < static_cast<int>(
Ship_info.size()); i++ ) {
457 if ( SS_active_items[i].
flags == 0 ) {
459 return &SS_active_items[
i];
507 for ( i = 0; i < static_cast<int>(
Ship_info.size()); i++ ) {
513 SS_active_list_size++;
668 Ship_anim_class = -1;
673 nprintf((
"Alan",
"ship_select_init() returning without doing anything\n"));
677 nprintf((
"Alan",
"entering ship_select_init()\n"));
681 if (ShipSelectMaskBitmap < 0) {
689 Shipselect_mask_w = -1;
690 Shipselect_mask_h = -1;
694 ShipSelectMaskData = (
ubyte*)ShipSelectMaskPtr->
data;
695 bm_get_info(ShipSelectMaskBitmap, &Shipselect_mask_w, &Shipselect_mask_h);
699 Num_mask_regions = 0;
765 if ( count <= SS_active_list_start )
790 if ( ship_class != -1 ) {
803 if ( ship_class == -1 )
828 if ( Ss_wings[wb_num].wingnum < 0 ) {
920 int y_start, line_height;
945 y_start += line_height;
956 y_start += line_height;
961 y_start += line_height;
971 y_start+=line_height;
976 y_start += line_height;
999 y_start += line_height;
1004 y_start += line_height;
1008 y_start += line_height;
1013 y_start += line_height;
1042 y_start += line_height;
1047 y_start += line_height;
1061 else if(sum <= 1100)
1063 else if(sum <= 1300)
1065 else if(sum <= 2000)
1067 else if(sum <= 30000)
1069 else if(sum <= 75000)
1071 else if(sum <= 200000)
1073 else if(sum <= 800000)
1074 strcpy_s(str,
"Very Heavy Capital");
1076 strcpy_s(str,
"Ultra Heavy Capital");
1081 y_start += line_height;
1088 y_start += line_height;
1096 y_start += line_height;
1101 for(i = 0; i < pm->
n_guns; i++)
1114 y_start += line_height;
1126 y_start += line_height;
1131 y_start += line_height;
1148 y_start += line_height;
1152 int num_turrets = 0;
1185 y_start += line_height;
1187 sprintf(str,
"%d", num_turrets);
1189 y_start += line_height;
1196 y_start += line_height;
1205 y_start += line_height;
1210 if (sip->
desc == NULL)
1215 y_start += line_height;
1222 char Ship_select_ship_info_text[1500];
1224 int Ship_select_ship_info_line_count;
1228 if(Ship_select_ship_info_text[0] !=
'\0'){
1236 strncpy(Ship_select_ship_info_lines[
idx], p_str[idx], n_chars[idx]);
1237 Ship_select_ship_info_lines[
idx][n_chars[
idx]] = 0;
1242 Ship_select_ship_info_line_count = n_lines;
1245 Ship_select_ship_info_line_count = 0;
1250 for(
int idx=0;
idx<Ship_select_ship_info_line_count;
idx++){
1252 y_start += line_height;
1268 int k, ship_select_choice, snazzy_action;
1270 ship_select_choice =
snazzy_menu_do(ShipSelectMaskData, Shipselect_mask_w, Shipselect_mask_h, Num_mask_regions, Region, &snazzy_action, 0);
1285 if ( ship_select_choice > -1 ) {
1287 switch(ship_select_choice) {
1302 ship_select_choice = -1;
1306 ship_select_choice = -1;
1310 ship_select_choice = -1;
1314 ship_select_choice = -1;
1318 ship_select_choice = -1;
1322 ship_select_choice = -1;
1326 ship_select_choice = -1;
1330 ship_select_choice = -1;
1334 ship_select_choice = -1;
1338 ship_select_choice = -1;
1342 ship_select_choice = -1;
1346 ship_select_choice = -1;
1359 if ( ship_select_choice > -1 && snazzy_action ==
SNAZZY_CLICKED ) {
1360 switch (ship_select_choice) {
1434 Assert( Ss_icons != NULL );
1440 Ship_select_ui_window.
draw();
1494 int mouse_x, mouse_y, sx, sy;
1496 sx = mouse_x + Ss_delta_x;
1497 sy = mouse_y + Ss_delta_y;
1508 mprintf((
"SL WARNING: Had to attempt to page in model for %s paged in manually! Result: %d\n", sip->
name, Ss_icons[Carried_ss_icon.
ship_class].
model_index));
1566 nprintf((
"Alan",
"ship_select_close() returning without doing anything\n"));
1570 nprintf((
"Alan",
"Entering ship_select_close()\n"));
1578 Ship_select_ui_window.
destroy();
1580 Ship_anim_class = -1;
1595 Assert( Ss_icons != NULL );
1598 icon = &Ss_icons[
i];
1620 if ( count <= SS_active_list_start )
1641 color *color_to_draw = NULL;
1645 Assert( screen_offset >= 0 && screen_offset <= 3 );
1646 Assert( ship_class >= 0 );
1648 ss_icon = &Ss_icons[ship_class];
1682 if (
Ss_pool[ship_class] <= 0 ) {
1697 mprintf((
"SL WARNING: Had to attempt to page in model for %s paged in manually! Result: %d\n", sip->
name, ss_icon->
model_index));
1729 if (ship_class < 0) {
1730 mprintf((
"No ship class passed in to start_ship_animation\n"));
1742 if(Ship_anim_class > 0 && Ss_icons[Ship_anim_class].ss_anim.num_frames > 0) {
1744 Ship_anim_class = -1;
1754 mprintf((
"Couldn't load model file %s in missionshipchoice.cpp\n", sip->
pof_file));
1757 Assert( ship_class >= 0 );
1758 Assert( Ss_icons != NULL );
1760 if (Ship_anim_class == ship_class) {
1771 if(Ship_anim_class > 0 && Ss_icons[Ship_anim_class].ss_anim.num_frames > 0)
1774 p = strchr(
Ship_info[ship_class].anim_filename,
'.' );
1778 strcpy_s(animation_filename,
"2_");
1790 if(Ss_icons[ship_class].ss_anim.first_frame != -1) {
1795 Ship_anim_class = ship_class;
1805 Assert( Ss_icons != NULL );
1808 if ( Ss_icons[
i].ss_anim.num_frames ) {
1824 if (
Wss_slots[slot].wep_count[bank] > 0)
1826 if (
Wss_slots[slot].wep[bank] == weapon_index)
1841 int j, player_ship_info_index;
1871 int num_required_weapons = 0;
1872 int num_satisfied_weapons = 0;
1879 num_required_weapons++;
1880 if (num_required_weapons > 1)
1881 weapon_list.append(1,
EOLN);
1886 num_satisfied_weapons++;
1889 if (num_satisfied_weapons < num_required_weapons)
1891 if (num_required_weapons == 1)
1896 else if (num_required_weapons > 1)
1898 popup(
PF_USE_AFFIRMATIVE_ICON, 1,
POPUP_OK,
XSTR(
"The following weapons are required for this mission, but at least one of them has not been added to any ship loadout:\n\n%s", 1625), weapon_list.c_str());
1965 if (
Ss_pool[ship_class] > 0 ) {
1966 int mouse_x, mouse_y;
1994 wb = &Ss_wings[wb_num];
2032 int mouse_x, mouse_y;
2039 Carried_ss_icon.
from_x = mouse_x;
2040 Carried_ss_icon.
from_y = mouse_y;
2061 void draw_wing_block(
int wb_num,
int hot_slot,
int selected_slot,
int class_select,
bool ship_selection )
2067 int i,
w,
h, sx, sy, slot_index,
mask;
2068 int bitmap_to_draw = -1;
2069 color *color_to_draw = NULL;
2073 Assert( (Ss_wings != NULL) && (
Wss_slots != NULL) && (Ss_icons != NULL) );
2075 wb = &Ss_wings[wb_num];
2089 bitmap_to_draw = -1;
2091 slot_index = wb_num*MAX_WING_SLOTS +
i;
2093 if (
Wss_slots[slot_index].ship_class >= 0 ) {
2101 if (ship_selection) {
2108 switch(ws->
status & mask ) {
2114 if ( class_select >= 0 ) {
2115 if ( Carried_ss_icon.
from_slot == slot_index ) {
2119 bitmap_to_draw = -1;
2146 if ( selected_slot == slot_index || class_select ==
Wss_slots[slot_index].ship_class)
2153 else if ( hot_slot == slot_index )
2198 if ( bitmap_to_draw != -1 ) {
2202 else if(color_to_draw != NULL)
2215 int wing_num,slot_num;
2219 Assert( Ss_wings != NULL );
2226 wb = &Ss_wings[wing_num];
2237 int wing_num,slot_num;
2241 Assert( Ss_wings != NULL );
2248 wb = &Ss_wings[wing_num];
2259 if(ship_class == -1)
2266 Assert( Ss_icons != NULL );
2280 mprintf((
"SL WARNING: Had to attempt to page in model for %s paged in manually! Result: %d\n", sip->
name, icon->
model_index));
2326 int shipnum, objnum, slot_index;
2343 slot_index = i*MAX_WING_SLOTS+j;
2405 cleanup_ship_index[k] = -1;
2421 cleanup_ship_index[j] = shipnum;
2436 if ( cleanup_ship_index[k] != -1 ) {
2481 int player_ship_class=-1;
2485 if ( use_last_flown ) {
2491 player_ship_class = std::distance(
Ship_info.cbegin(), it);
2497 if (player_ship_class == -1)
2502 if (player_ship_class == -1) {
2504 "a valid last flown ship\n\nHave you played any missions since activating this mod/campaign?", 1619));
2526 Assert( Ss_wings != NULL );
2539 Assert( Ss_wings != NULL );
2574 Assert( Ss_wings != NULL );
2582 if ( Ss_wings[wing_block].wingnum < 0 ) {
2586 ws = &Ss_wings[wing_block].
ss_slots[wing_slot];
2594 Assert(*ship_index != -1);
2609 Assert( Ss_wings != NULL );
2611 ws = &Ss_wings[wing_block].
ss_slots[wing_slot];
2629 if(player_index != -1){
2630 strcpy(name,
Net_players[player_index].m_player->callsign);
2669 for ( i = 0; i < static_cast<int>(
Ship_info.size()); i++ ) {
2690 int i, j, k, ship_in_parse_player, list_size;
2694 p_team_data = tdata;
2695 ship_in_parse_player = 0;
2704 ship_in_parse_player = 0;
2709 ship_in_parse_player = 1;
2714 if ( !ship_in_parse_player ) {
2726 ship_in_parse_player = 0;
2731 ship_in_parse_player = 1;
2736 if ( !ship_in_parse_player ) {
2747 if ( list_size == 0 ) {
2749 ship_in_parse_player = 0;
2753 ship_in_parse_player = 1;
2757 if ( !ship_in_parse_player ) {
2793 Assert( Ss_icons != NULL );
2795 icon = &Ss_icons[ship_class];
2800 int first_frame, num_frames,
i;
2804 if (first_frame == -1)
2807 for ( i = 0; i < num_frames; i++ ) {
2851 Assert( Ss_wings != NULL );
2860 if (ship_selection) {
2876 Assert( Ss_wings != NULL );
2914 Assert( Ss_wings != NULL );
2930 Assert( Ss_wings != NULL );
2932 ss_wing = &Ss_wings[wing_num];
2974 int wingnum, slotnum;
2983 Assert( Ss_wings != NULL );
3004 ss_wing = &Ss_wings[
i];
3013 for ( j = 0; j < ss_wing->
num_slots; j++ ) {
3099 Ss_wings = Ss_wings_teams[
team];
3100 Ss_icons = Ss_icons_teams[
team];
3191 Assert( Ss_wings != NULL );
3193 int old_list_start = SS_active_list_start;
3197 if ( old_list_start < SS_active_list_size ) {
3198 SS_active_list_start = old_list_start;
3223 if ( from_slot == to_slot ) {
3229 if (
Wss_slots[from_slot].ship_class < 0 ) {
3276 if ( (slot->
wep[i] >= 0) && (slot->
wep_count[i] > 0) ) {
3298 if (
Ss_pool[from_list] <= 0 )
3315 slot->
wep[
i] = wep[
i];
3332 if (
Ss_pool[from_list] <= 0 )
3364 slot->
wep[
i] = wep[
i];
3372 void ss_apply(
int mode,
int from_slot,
int from_list,
int to_slot,
int to_list,
int player_index)
3393 if ( (sound >= 0) && (player_index == -1) ) {
3412 void ss_drop(
int from_slot,
int from_list,
int to_slot,
int to_list,
int player_index)
3417 mode =
wss_get_mode(from_slot, from_list, to_slot, to_list, -1);
3419 ss_apply(mode, from_slot, from_list, to_slot, to_list,player_index);
3437 Assert( Ss_wings != NULL );
3440 ss_wing = &Ss_wings[
i];
3447 for ( j = 0; j < ss_wing->
num_slots; j++ ) {
#define SF2_WEAPONS_LOCKED
void gr_rect(int x, int y, int w, int h, int resize_mode)
void ship_wing_cleanup(int shipnum, wing *wingp)
void ship_select_blit_ship_info()
int ss_return_saindex(int slot_num)
void bm_unlock(int handle)
Unlocks a bitmap.
void set_highlight_action(void(*_user_function)(void))
void hud_set_wingman_status_none(int wing_index, int wing_pos)
char Starting_wing_names[MAX_STARTING_WINGS][NAME_LENGTH]
int Wing_icon_coords[GR_NUM_RESOLUTIONS][MAX_WSS_SLOTS][2]
void mouse_set_pos(int xpos, int ypos)
#define WING_SLOT_IS_PLAYER
void add_XSTR(char *string, int _xstr_id, int _x, int _y, UI_GADGET *_assoc, int _color_type, int _font_id=-1)
ss_active_item * get_free_active_list_node()
GLfloat GLfloat GLfloat GLfloat h
brief_common_buttons Common_buttons[3][GR_NUM_RESOLUTIONS][NUM_COMMON_BUTTONS]
char Game_current_mission_filename[MAX_FILENAME_LEN]
polymodel * model_get(int model_num)
weapon_info Weapon_info[MAX_WEAPON_TYPES]
#define MOUSE_LEFT_BUTTON
char default_player_ship[255]
void draw_model_icon(int model_id, int flags, float closeup_zoom, int x, int y, int w, int h, const ship_info *sip, int resize_mode, const vec3d *closeup_pos)
void ss_set_carried_icon(int from_slot, int ship_class)
char icon_filename[MAX_FILENAME_LEN]
int ss_return_original_ship_class(int slot_num)
int Tech_ship_display_coords[GR_NUM_RESOLUTIONS][4]
int ss_grab_from_list(int from_list, int to_slot, int *sound)
SCP_vector< p_object > Parse_objects
drop a ship icon on a wing slot
void ss_reset_carried_icon()
int snazzy_menu_do(ubyte *data, int mask_w, int mask_h, int num_regions, MENU_REGION *regions, int *action, int poll_key, int *key)
void ss_blit_ship_icon(int x, int y, int ship_class, int bmap_num)
#define WING_SLOT_IGNORE_WEAPONS
void ship_add_exited_ship(ship *sp, int reason)
void _cdecl void void _cdecl void _cdecl Warning(char *filename, int line, SCP_FORMAT_STRING const char *format,...) SCP_FORMAT_STRING_ARGS(3
struct ss_icon_info ss_icon_info
char filename[MAX_FILENAME_LEN]
int pick_from_ship_list(int screen_offset, int ship_class)
#define GR_NUM_RESOLUTIONS
__inline void gr_string(int x, int y, const char *string, int resize_mode=GR_RESIZE_FULL)
#define list_append(head, elem)
general failure sound for any event
int ss_disabled_slot(int slot_num, bool ship_selection)
int bm_get_info(int handle, int *w, int *h, ubyte *flags, int *nframes, int *fps)
Gets info on the bitmap indexed by handle.
#define SHIP_SELECT_ICON_0
struct vec3d::@225::@227 xyz
UI_WINDOW Ship_select_ui_window
void pick_from_wing(int wb_num, int ws_num)
#define SHIP_SELECT_SHIP_INFO_MAX_LINE_LEN
#define SEF_PLAYER_DELETED
struct ss_active_item ss_active_item
#define Assertion(expr, msg,...)
void common_check_buttons()
#define END_OF_LIST(head)
#define GR_MAYBE_CLEAR_RES(bmap)
model_subsystem * subsystems
int common_scroll_up_pressed(int *start, int size, int max_show)
int do_mouse_over_wing_slot(int block, int slot)
int Ship_select_overlay_id
void help_overlay_set_state(int overlay_id, int resolution_index, int state)
#define P2_SF2_WEAPONS_LOCKED
void gr_set_color_fast(color *dst)
int ss_get_selected_ship()
void ss_synch_interface()
void common_buttons_maybe_reload(UI_WINDOW *ui_window)
std::basic_string< char, std::char_traits< char >, std::allocator< char > > SCP_string
void set_active_ui(UI_WINDOW *ui_window)
void mission_hotkey_validate()
void gr_set_bitmap(int bitmap_num, int alphablend_mode, int bitblt_mode, float alpha)
#define SS_ACTIVE_ITEM_USED
#define WSS_GRAB_FROM_LIST
#define COMMON_WEAPON_REGION
int Mouse_down_last_frame
GLenum GLuint GLenum GLsizei const GLchar * buf
const char *(* tooltip_handler)(const char *text)
int bm_release(int handle, int clear_render_targets)
Frees both a bitmap's data and it's associated slot.
void draw_ship_icon_with_number(int screen_offset, int ship_class)
void ss_return_name(int wing_block, int wing_slot, char *name)
void snazzy_menu_add_region(MENU_REGION *region, const char *text, int mask, int key, int click_sound)
char callsign[CALLSIGN_LEN+1]
int ss_valid_slot(int slot_num)
void do_mouse_over_list_slot(int index)
#define BMP_AABITMAP
antialiased bitmap
void generic_anim_unload(generic_anim *ga)
int bm_load_animation(const char *real_filename, int *nframes, int *fps, int *keyframe, int can_drop_frames, int dir_type)
Loads a bitmap sequance so we can draw with it.
void wl_update_parse_object_weapons(p_object *pobjp, wss_unit *slot)
anim * ss_load_individual_animation(int ship_class)
int mouse_get_pos_unscaled(int *xpos, int *ypos)
#define SHIP_SELECT_ICON_1
int wep_count[MAX_SHIP_WEAPONS]
int ship_count[MAX_SHIP_CLASSES]
ss_wing_info Ss_wings_teams[MAX_TVT_TEAMS][MAX_WING_BLOCKS]
#define SHIP_SELECT_Y_COORD
void common_reset_buttons()
void common_set_interface_palette(char *filename)
void common_flash_button_init()
void draw_forced(int frame_num)
int create_default_player_ship(int use_last_flown)
void wl_reset_to_defaults()
const char * ss_tooltip_handler(const char *str)
int ss_icon_being_carried()
player Players[MAX_PLAYERS]
int ss_carried_icon_moved()
void set_mask_bmap(char *fname)
#define MISSION_FLAG_NO_BRIEFING
int set_bmaps(char *ani_filename, int nframes=3, int start_frame=1)
char ship_select_background[GR_NUM_RESOLUTIONS][MAX_FILENAME_LEN]
char pof_file[MAX_FILENAME_LEN]
void mission_parse_fixup_players()
void common_redraw_pressed_buttons()
int common_select_do(float frametime)
ss_icon_info Ss_icons_teams[MAX_TVT_TEAMS][MAX_SHIP_CLASSES]
#define NETINFO_FLAG_AM_MASTER
int ss_wing_slot_is_console_player(int index)
void ship_select_buttons_init()
#define SHIP_SELECT_NUM_TEXT
#define SHIP_SELECT_SHIP_SCROLL_UP
int Ship_list_coords[GR_NUM_RESOLUTIONS][MAX_ICONS_ON_SCREEN][4]
int multi_ts_disabled_slot(int slot_num, int player_index)
#define POBJ_INDEX(pobjp)
void active_list_add(int ship_class)
void ss_restore_loadout()
int Cmdline_ship_choice_3d
#define MAX_STARTING_WINGS
int last_ship_flown_si_index
void active_list_remove(int ship_class)
#define ICON_FRAME_DISABLED_HIGH
void draw_wing_block(int wb_num, int hot_slot, int selected_slot, int class_select, bool ship_selection)
void generic_anim_render(generic_anim *ga, float frametime, int x, int y, bool menu)
sprintf(buf,"(%f,%f,%f)", v3->xyz.x, v3->xyz.y, v3->xyz.z)
void set_team_color(team_color &clr)
void toggle_player_object()
SCP_string default_team_name
int wl_update_ship_weapons(int objnum, wss_unit *slot)
void ship_select_redraw_pressed_buttons()
#define MAX_NUM_SHIP_DESC_LINES
#define SHIP_SELECT_RESET
float max_shield_strength
#define WING_SLOT_SHIPS_DISABLED
#define P2_SF2_SHIP_LOCKED
int ss_fixup_team_data(team_data *tdata)
void ai_post_process_mission()
void common_select_init()
int split_str(const char *src, int max_pixel_w, int *n_chars, const char **p_str, int max_lines, char ignore_char)
bitmap * bm_lock(int handle, ubyte bpp, ubyte flags, bool nodebug)
Locks down the bitmap indexed by bitmapnum.
void ss_make_slot_full(int slot_index)
void ss_maybe_drop_icon()
#define SHIP_SELECT_ICON_2
void common_set_team_pointers(int team)
#define NETINFO_FLAG_GAME_HOST
void maybe_change_selected_wing_ship(int wb_num, int ws_num)
void send_mission_sync_packet(int mode, int start_campaign)
#define ICON_FRAME_DISABLED
int wss_get_mode(int from_slot, int from_list, int to_slot, int to_list, int wl_ship_slot)
void ss_reset_team_pointers()
int model_load(char *filename, int n_subsystems, model_subsystem *subsystems, int ferror=1, int duplicate=0)
void start_ship_animation(int ship_class, int play_sound=0)
void model_page_in_textures(int modelnum, int ship_info_index=-1)
void ship_select_check_buttons()
#define SHIP_SELECT_ICON_3
void maybe_change_selected_ship(int offset)
void common_check_keys(int k)
void common_render_selected_screen_button()
object Objects[MAX_OBJECTS]
GLint GLint GLint GLint GLint x
void ship_select_do(float frametime)
int Wing_slot_disabled_bitmap
#define NUM_SHIP_SELECT_REGIONS
const char * XSTR(const char *str, int index)
int Ship_select_background_bitmap
void update_player_ship(int si_index)
#define MAX_ICONS_ON_SCREEN
char modified[DATE_TIME_LENGTH]
void ss_init_pool(team_data *pteam)
void ss_apply(int mode, int from_slot, int from_list, int to_slot, int to_list, int player_index)
int ss_swap_slot_slot(int from_slot, int to_slot, int *sound)
void ss_unload_all_anims()
bool end_string_at_first_hash_symbol(char *src)
void _cdecl void void _cdecl Error(const char *filename, int line, SCP_FORMAT_STRING const char *format,...) SCP_FORMAT_STRING_ARGS(3
#define P_OF_PLAYER_START
int Starting_wings[MAX_STARTING_WINGS]
int ss_swap_list_slot(int from_list, int to_slot, int *sound)
GLuint const GLchar * name
#define MULTI_TS_MAX_TVT_TEAMS
void common_buttons_init(UI_WINDOW *ui_window)
void ship_select_common_close()
#define COMMON_HELP_REGION
#define ICON_FRAME_SELECTED
void maybe_pick_up_list_icon(int offset)
int bm_load(const char *real_filename)
Loads a bitmap so we can draw with it later.
GLboolean GLboolean GLboolean b
struct ss_wing_info ss_wing_info
struct generic_anim::@239::@241 ani
struct ss_slot_info ss_slot_info
void ss_set_team_pointers(int team)
void ship_select_button_do(int i)
#define WING_INDEX(wingp)
char alt_name[NAME_LENGTH]
int common_scroll_down_pressed(int *start, int size, int max_show)
void obj_delete(int objnum)
scroll pressed (and scroll)
color Icon_colors[NUM_ICON_FRAMES]
#define SHIP_SELECT_SHIP_SCROLL_DOWN
void link_hotspot(int num)
char anim_filename[MAX_FILENAME_LEN]
void create(UI_WINDOW *wnd, char *_text, int _x, int _y, int _w, int _h, int do_repeat=0, int ignore_focus=0)
#define COMMON_COMMIT_REGION
int wep[MAX_SHIP_WEAPONS]
GLubyte GLubyte GLubyte GLubyte w
void draw_model_rotating(model_render_params *render_info, int model_id, int x1, int y1, int x2, int y2, float *rotation_buffer, vec3d *closeup_pos, float closeup_zoom, float rev_rate, int flags, int resize_mode, int effect)
#define SHIP_SELECT_X_COORD
void ss_reset_selected_ship()
void create(int _x, int _y, int _w, int _h, int _flags, int _f_id=-1)
loadout_data Player_loadout
float Hud_speed_multiplier
int Wing_slot_empty_bitmap
void ss_init_wing_info(int wing_num, int starting_wing_num)
#define MULTI_SYNC_POST_BRIEFING
int Ss_mouse_down_on_region
void gr_get_string_size(int *w, int *h, const char *text, int len=9999)
void generic_anim_init(generic_anim *ga)
void wl_get_default_weapons(int ship_class, int slot_num, int *wep, int *wep_count)
void ship_select_init_team_data(int team_num)
ship animation starts (ie text and ship first appear)
void ss_unload_all_icons()
void ss_reset_to_default()
#define MULTIPLAYER_MASTER
#define ICON_FRAME_PLAYER
#define COMMON_OPTIONS_REGION
#define WSS_SWAP_SLOT_SLOT
SCP_vector< ship_info > Ship_info
void common_play_highlight_sound()
SCP_vector< species_info > Species_info
ptr_u data
Pointer to data, or maybe offset into VRAM.
ss_carry_icon_info Carried_ss_icon
BM_TYPE bm_get_type(int handle)
Returns the image type of the given bitmap handle.
int ss_dump_to_list(int from_slot, int to_list, int *sound)
char * maneuverability_str
#define list_remove(head, elem)
#define CF_MAX_FILENAME_LENGTH
#define WSS_SWAP_LIST_SLOT
void wl_remove_weps_from_pool(int *wep, int *wep_count, int ship_class)
#define WING_SLOT_IGNORE_SHIPS
void drop_leading_white_space(char *str)
void change_ship_type(int n, int ship_type, int by_sexp)
void gr_bitmap(int _x, int _y, int resize_mode)
void ss_make_slot_empty(int slot_index)
p_object Ship_arrival_list
void ss_load_icons(int ship_class)
#define UI_XSTR_COLOR_GREEN
team_data Team_data[MAX_TVT_TEAMS]
void ship_select_common_init()
void ss_drop(int from_slot, int from_list, int to_slot, int to_list, int player_index)
int mission_ui_background_load(const char *custom_background, const char *single_background, const char *multi_background)
int ship_index[MAX_SHIPS_PER_WING]
int icon_bmaps[NUM_ICON_FRAMES]
int ss_get_ship_class_from_list(int index)
void gamesnd_play_iface(int n)
void ss_maybe_flash_button()
int multi_ts_disabled_high_slot(int slot_index, int player_index)
#define COMMON_BRIEFING_REGION
#define WING_SLOT_DISABLED
int common_flash_bright()
int multi_find_player_by_object(object *objp)
void ss_recalc_multiplayer_slots()
int help_overlay_get_index(const char *overlay_name)
int generic_anim_stream(generic_anim *ga)
float ShipSelectScreenShipRot
void draw_brackets_square(int x1, int y1, int x2, int y2, int resize_mode)
net_player Net_players[MAX_PLAYERS]
int timer_get_milliseconds()
void gameseq_post_event(int event)
drop a ship icon back to the list
void help_overlay_maybe_blit(int overlay_id, int resolution_index)
struct ss_carry_icon_info ss_carry_icon_info
int help_overlay_active(int overlay_id)
char ship_name[NAME_LENGTH]
#define ICON_FRAME_NORMAL
ss_slot_info ss_slots[MAX_WING_SLOTS]
void model_unload(int modelnum, int force=0)
char last_modified[DATE_TIME_LENGTH]
bool is_weapon_carried(int weapon_index)
int ship_list[MAX_SHIP_CLASSES]
#define WING_SLOT_WEAPONS_DISABLED
int ss_return_ship(int wing_block, int wing_slot, int *ship_index, p_object **ppobjp)
int ship_get_type(char *output, ship_info *sip)
UI_XSTR Ship_select_text[GR_NUM_RESOLUTIONS][SHIP_SELECT_NUM_TEXT]