| 1 | /* |
| 2 | * Descent 3 |
| 3 | * Copyright (C) 2024 Parallax Software |
| 4 | * |
| 5 | * This program is free software: you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation, either version 3 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | * |
| 15 | * You should have received a copy of the GNU General Public License |
| 16 | * along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 17 | */ |
| 18 | |
| 19 | #ifndef _MTCLIENT_HEADER |
| 20 | #define _MTCLIENT_HEADER |
| 21 | /* |
| 22 | * $Logfile: /DescentIII/Main/mtclient/mtclient.h $ |
| 23 | * $Revision: 1.1.1.1 $ |
| 24 | * $Date: 2003-08-26 03:58:40 $ |
| 25 | * $Author: kevinb $ |
| 26 | * |
| 27 | * Mastertracker client DLL |
| 28 | * |
| 29 | * $Log: not supported by cvs2svn $ |
| 30 | * |
| 31 | * 17 7/30/99 1:20p Kevin |
| 32 | * Fixed problems with sorted game list |
| 33 | * |
| 34 | * 16 7/06/99 5:52p Kevin |
| 35 | * PXO & multiplayer fixes for the patch |
| 36 | * |
| 37 | * 15 6/23/99 3:36p Samir |
| 38 | * took out #define uint8_t |
| 39 | * |
| 40 | * 14 3/02/99 5:50p Kevin |
| 41 | * Ouch. Duplicate structures existed and were conflicting. |
| 42 | * |
| 43 | * 13 2/19/99 5:21p Kevin |
| 44 | * Fixed some connection DLLs and a Direct Sound bug with threads. |
| 45 | * |
| 46 | * 12 11/03/98 9:29a Kevin |
| 47 | * Added pxo motd |
| 48 | * |
| 49 | * 11 9/16/98 8:06p Jason |
| 50 | * got mastertracker working with the dedicated server |
| 51 | * |
| 52 | * 10 8/19/98 11:50a Kevin |
| 53 | * Got DirectPlay IPX working, and localized connection DLLs |
| 54 | * |
| 55 | * 9 8/07/98 12:39p Jeff |
| 56 | * added "allowed ships" to multiplayer options |
| 57 | * |
| 58 | * 8 7/21/98 1:49p Kevin |
| 59 | * IPX support and peer-peer option for multi |
| 60 | * |
| 61 | * 7 7/20/98 2:34p Kevin |
| 62 | * Re-wrote the DLL wrapper, to allow for better expandability |
| 63 | * |
| 64 | * 5 6/24/98 6:40p Kevin |
| 65 | * Added help to main dll menu |
| 66 | * |
| 67 | * 4 6/24/98 3:24p Kevin |
| 68 | * Updated PXO screens with chat, etc. |
| 69 | * |
| 70 | * 3 6/18/98 4:49p Kevin |
| 71 | * Updated multiplayer menus |
| 72 | * |
| 73 | * 2 6/01/98 10:10a Kevin |
| 74 | * Added DLL connection interface and auto update DLL |
| 75 | * |
| 76 | * 1 5/18/98 12:47p Kevin |
| 77 | * |
| 78 | * $NoKeywords: $ |
| 79 | */ |
| 80 | |
| 81 | #include "ui.h" |
| 82 | |
| 83 | // Chat tracker |
| 84 | #define CHATTRACKERNAME "tracker.pxo.nottheeye.com" |
| 85 | #define CHATPORT 7170 |
| 86 | |
| 87 | #define TRACKER_MENU_W 256 |
| 88 | #define TRACKER_MENU_H 256 |
| 89 | #define TRACKER_MENU_X (320 - (TRACKER_MENU_W / 2)) |
| 90 | #define TRACKER_MENU_Y (240 - (TRACKER_MENU_H / 2)) |
| 91 | |
| 92 | #define MAXTEXTITEMS 100 |
| 93 | #define MAXNEWWINDOWS 5 |
| 94 | #define MAXNEWGAMEWINDOWS 5 |
| 95 | #define MAXUIBUTTONS 20 |
| 96 | #define MAXUITEXTS 20 |
| 97 | #define MAXEDITS 20 |
| 98 | #define MAXLISTS 20 |
| 99 | |
| 100 | #include "con_dll.h" |
| 101 | |
| 102 | #define MAX_GAME_NAME_LEN 100 |
| 103 | #define MAX_MISSION_NAME_LEN 100 |
| 104 | #define MAX_MISSION_FILE_LEN 40 |
| 105 | #define MAX_SCRIPT_LEN 40 |
| 106 | #define MAX_FORMAT_STRING 300 |
| 107 | |
| 108 | typedef struct s_pxo_game_list { |
| 109 | /* |
| 110 | char name[MAX_GAME_NAME_LEN]; |
| 111 | network_address address; |
| 112 | char mission_name[MAX_MISSION_NAME_LEN]; |
| 113 | char mission_file[MAX_MISSION_FILE_LEN]; |
| 114 | char script[MAX_SCRIPT_LEN]; |
| 115 | int16_t level; |
| 116 | int16_t curr_players; |
| 117 | int16_t max_players; |
| 118 | float ping; |
| 119 | uint32_t flags; |
| 120 | char format_string[MAX_FORMAT_STRING]; |
| 121 | |
| 122 | bool dedicated; |
| 123 | */ |
| 124 | bool used; |
| 125 | uint32_t handle; |
| 126 | void *ti; |
| 127 | int lb_no; |
| 128 | } pxo_game_list; |
| 129 | |
| 130 | int LoginMasterTracker(); |
| 131 | int MainMultiplayerMenu(); |
| 132 | int SearchMasterTrackerGameMenu(); |
| 133 | int StartMultiplayerGameMenu(); |
| 134 | void MultiplayerOptionsMenu(); |
| 135 | void DoMTFrame(); |
| 136 | void DoMTGameOver(); |
| 137 | int MTVersionCheck(); |
| 138 | int JoinNewLobby(const char *lobby); |
| 139 | const char *SendWhisper(const char *name); |
| 140 | int JoinPrivateLobby(); |
| 141 | int FindPilot(); |
| 142 | int GetPilotStats(const char *pilot); |
| 143 | void AutoLoginAndJoinGame(); |
| 144 | int ShowMessageOfTheDay(); |
| 145 | #endif |