mirror of
https://github.com/perfect-dark-pc-port/perfect_dark.git
synced 2026-10-24 00:02:43 +02:00
port: net: experimental 8 player support
This commit is contained in:
1 parent
ee037c10ce
commit
04f95ed1d1
26 files changed
+191
-116
No files matched your search
+4
-4
@@ -175,9 +175,9 @@ extern u8 *g_BlurBuffer;
|
||||
extern s32 var8009dfc0;
|
||||
extern struct briefing g_Briefing;
|
||||
extern struct missionconfig g_MissionConfig;
|
||||
extern struct menu g_Menus[MAX_PLAYERS];
|
||||
extern struct menu g_Menus[MAX_LOCAL_PLAYERS];
|
||||
extern struct menudata g_MenuData;
|
||||
extern struct activemenu g_AmMenus[MAX_PLAYERS];
|
||||
extern struct activemenu g_AmMenus[MAX_LOCAL_PLAYERS];
|
||||
extern s32 g_AmIndex;
|
||||
extern u32 g_CheatsActiveBank0;
|
||||
extern u32 g_CheatsActiveBank1;
|
||||
@@ -196,7 +196,7 @@ extern struct covercandidate *g_CoverCandidates;
|
||||
extern u16 g_NumSpecialCovers;
|
||||
extern u16 *g_SpecialCoverNums;
|
||||
extern struct pak g_Paks[5];
|
||||
extern OSPfs g_Pfses[MAX_PLAYERS];
|
||||
extern OSPfs g_Pfses[MAX_LOCAL_PLAYERS];
|
||||
extern u32 g_SkyStageNum;
|
||||
extern bool g_SkyLightningActive;
|
||||
extern struct explosion *g_Explosions;
|
||||
@@ -285,7 +285,7 @@ extern struct chrdata *g_MpAllChrPtrs[MAX_MPCHRS];
|
||||
extern struct mpchrconfig *g_MpAllChrConfigPtrs[MAX_MPCHRS];
|
||||
extern s32 g_MpNumChrs;
|
||||
extern struct mpbotconfig g_BotConfigsArray[MAX_BOTS];
|
||||
extern u8 g_MpSimulantDifficultiesPerNumPlayers[MAX_BOTS][MAX_PLAYERS];
|
||||
extern u8 g_MpSimulantDifficultiesPerNumPlayers[MAX_BOTS][MAX_LOCAL_PLAYERS];
|
||||
extern struct mpplayerconfig g_PlayerConfigsArray[MAX_MPPLAYERCONFIGS];
|
||||
extern u8 g_AmBotCommands[9];
|
||||
extern struct mpsetup g_MpSetup;
|
||||
|
||||
@@ -23,7 +23,8 @@
|
||||
#define MAX_MPCHRS (MAX_PLAYERS + MAX_BOTS)
|
||||
#define MAX_MPPLAYERCONFIGS (MAX_PLAYERS + 2)
|
||||
#define MAX_OBJECTIVES 10
|
||||
#define MAX_PLAYERS 4
|
||||
#define MAX_LOCAL_PLAYERS 4
|
||||
#define MAX_PLAYERS 8
|
||||
#define MAX_PROPSPERROOMCHUNK 7
|
||||
#define MAX_ROOMPROPLISTCHUNKS 256
|
||||
#define MAX_SQUADRONS 16
|
||||
@@ -68,7 +69,9 @@
|
||||
#define SECSTOTIME60(secs) (secs * 60)
|
||||
#define PFS(device) (device == SAVEDEVICE_GAMEPAK ? NULL : &g_Pfses[device])
|
||||
|
||||
#if MAX_PLAYERS >= 4
|
||||
#if MAX_PLAYERS > 4
|
||||
#define PLAYERCOUNT() playerGetCount()
|
||||
#elif MAX_PLAYERS == 4
|
||||
#define PLAYERCOUNT() ((g_Vars.players[0] ? 1 : 0) + (g_Vars.players[1] ? 1 : 0) + (g_Vars.players[2] ? 1 : 0) + (g_Vars.players[3] ? 1 : 0))
|
||||
#elif MAX_PLAYERS >= 3
|
||||
#define PLAYERCOUNT() ((g_Vars.players[0] ? 1 : 0) + (g_Vars.players[1] ? 1 : 0) + (g_Vars.players[2] ? 1 : 0))
|
||||
|
||||
+4
-2
@@ -304,7 +304,7 @@ extern struct menudialogdef g_MpConfirmChallenge4MbMenuDialog;
|
||||
extern struct menudialogdef g_MainMenu4MbMenuDialog;
|
||||
extern struct menudialogdef g_MpEditSimulant4MbMenuDialog;
|
||||
extern struct menudialogdef g_AdvancedSetup4MbMenuDialog;
|
||||
extern struct filelist *g_FileLists[MAX_PLAYERS];
|
||||
extern struct filelist *g_FileLists[MAX_LOCAL_PLAYERS];
|
||||
extern bool var80075bd0[];
|
||||
extern struct headanim g_HeadAnims[2];
|
||||
extern s32 var80075d60;
|
||||
@@ -532,7 +532,7 @@ extern struct menudialogdef g_HangarListMenuDialog;
|
||||
|
||||
#ifndef PLATFORM_N64
|
||||
|
||||
extern struct extplayerconfig g_PlayerExtCfg[MAX_PLAYERS];
|
||||
extern struct extplayerconfig g_PlayerExtCfg[MAX_LOCAL_PLAYERS];
|
||||
|
||||
extern struct weathercfg g_WeatherConfig[WEATHERCFG_MAX_STAGES];
|
||||
extern const struct weathercfg g_DefaultWeatherConfig;
|
||||
@@ -559,6 +559,8 @@ extern s32 g_NetMode;
|
||||
#define TEX_FILTER_2D g_TexFilter2D
|
||||
#define ADJUST_ZOOM_FOV(x) ((x) * PLAYER_EXTCFG().fovzoommult)
|
||||
|
||||
s32 playerGetCount(void);
|
||||
|
||||
#else // PLATFORM_N64
|
||||
|
||||
#define TEX_FILTER_2D G_TF_BILERP
|
||||
|
||||
@@ -106,5 +106,6 @@ void playerSetCamPropertiesWithRoom(struct coord *pos, struct coord *up, struct
|
||||
void playerSetCamPropertiesWithoutRoom(struct coord *pos, struct coord *up, struct coord *look, s32 room);
|
||||
void playerSetCamProperties(struct coord *pos, struct coord *up, struct coord *look, s32 room);
|
||||
void playerClearMemCamRoom(void);
|
||||
s32 playerGetCount(void);
|
||||
|
||||
#endif
|
||||
+5
-5
@@ -230,7 +230,7 @@ struct g_vars {
|
||||
/*0x488*/ s32 totalkills;
|
||||
/*0x48c*/ bool useperimshoot;
|
||||
/*0x490*/ s32 mpsetupmenu;
|
||||
/*0x494*/ s8 waitingtojoin[MAX_PLAYERS];
|
||||
/*0x494*/ s8 waitingtojoin[MAX_LOCAL_PLAYERS];
|
||||
/*0x498*/ s32 unk000498;
|
||||
/*0x49c*/ bool usingadvsetup;
|
||||
/*0x4a0*/ s32 unk0004a0;
|
||||
@@ -251,7 +251,7 @@ struct g_vars {
|
||||
/*0x4d6*/ s8 autocutfinished; // true if cutscene reached natural end
|
||||
/*0x4d7*/ s8 autocutgroupskip; // true if pressed start during auto cutscene
|
||||
/*0x4d8*/ s32 joydisableframestogo;
|
||||
/*0x4dc*/ u8 playertojoymap[MAX_PLAYERS];
|
||||
/*0x4dc*/ u8 playertojoymap[MAX_LOCAL_PLAYERS];
|
||||
/*0x4e0*/ u8 fourmeg2player;
|
||||
/*0x4e1*/ u8 remakewallhitvtx;
|
||||
/*0x4e2*/ u8 cutsceneskip60ths;
|
||||
@@ -4162,7 +4162,7 @@ struct challenge {
|
||||
// Same structure as availability, however each byte determines how many
|
||||
// players it was completed with. So completions[0] is for completions with
|
||||
// a single player and completions[3] is for completions with 4 players.
|
||||
/*0x05*/ u8 completions[MAX_PLAYERS];
|
||||
/*0x05*/ u8 completions[MAX_LOCAL_PLAYERS];
|
||||
|
||||
// Array of features which will become unlocked once the challenge is
|
||||
// available. The array is automatically populated at runtime based on what
|
||||
@@ -4794,7 +4794,7 @@ struct menudata {
|
||||
/*0x014*/ u8 bg;
|
||||
/*0x015*/ u8 nextbg;
|
||||
/*0x016*/ u8 screenshottimer;
|
||||
/*0x017*/ u8 playerjoinalpha[MAX_PLAYERS];
|
||||
/*0x017*/ u8 playerjoinalpha[MAX_LOCAL_PLAYERS];
|
||||
/*0x01b*/ s8 bannernum;
|
||||
/*0x01c*/ struct menumodel hudpiece;
|
||||
/*0x5d4*/ u8 unk5d4;
|
||||
@@ -5007,7 +5007,7 @@ struct mpconfigsim {
|
||||
u8 mpheadnum;
|
||||
u8 mpbodynum;
|
||||
u8 team;
|
||||
u8 difficulties[MAX_PLAYERS];
|
||||
u8 difficulties[MAX_LOCAL_PLAYERS];
|
||||
};
|
||||
|
||||
struct mpconfig {
|
||||
|
||||
Reference in new issue
Block a user