Skip to content

Commit

Permalink
Merged pull request "Sync with Q2PRO: Cinematics": NVIDIA#325
Browse files Browse the repository at this point in the history
  • Loading branch information
apanteleev committed Oct 2, 2023
2 parents 71705ab + 023b890 commit 30d959e
Show file tree
Hide file tree
Showing 25 changed files with 525 additions and 499 deletions.
4 changes: 4 additions & 0 deletions doc/server.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ The latter will prevent MVD/GTV features from working.
*NOTE*: If `sv_password` is set, then game mod's `password` variable must be empty.
Otherwise clients will be unable to connect.

#### `sv_cinematics`
If set to 0, server will skip cinematics even if they exist. Default value
is 1.

#### `sv_reserved_slots`
Number of client slots reserved for clients who know `sv_reserved_password`
or `sv_password`. Must be less than `maxclients` value. Default value is 0
Expand Down
5 changes: 1 addition & 4 deletions inc/client/sound/sound.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,7 @@ void OGG_Shutdown(void);
void OGG_RecoverState(void);
void OGG_SaveState(void);

bool S_RawSamples(int samples, int rate, int width,
int channels, byte *data, float volume);

void S_UnqueueRawSamples(void);
void S_RawSamples(int samples, int rate, int width, int channels, const byte *data);

float S_GetLinearVolume(float perceptual);

Expand Down
3 changes: 2 additions & 1 deletion inc/common/protocol.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#define PROTOCOL_VERSION_Q2PRO_EXTENDED_LAYOUT 1020 // r1354
#define PROTOCOL_VERSION_Q2PRO_ZLIB_DOWNLOADS 1021 // r1358
#define PROTOCOL_VERSION_Q2PRO_CLIENTNUM_SHORT 1022 // r2161
#define PROTOCOL_VERSION_Q2PRO_CURRENT 1022 // r2161
#define PROTOCOL_VERSION_Q2PRO_CINEMATICS 1023 // r2263
#define PROTOCOL_VERSION_Q2PRO_CURRENT 1023 // r2263

#define PROTOCOL_VERSION_MVD_MINIMUM 2009 // r168
#define PROTOCOL_VERSION_MVD_CURRENT 2010 // r177
Expand Down
3 changes: 3 additions & 0 deletions inc/refresh/refresh.h
Original file line number Diff line number Diff line change
Expand Up @@ -324,9 +324,12 @@ extern int (*R_DrawString)(int x, int y, int flags, size_t maxChars,
bool R_GetPicSize(int *w, int *h, qhandle_t pic); // returns transparency bit
extern void (*R_DrawPic)(int x, int y, qhandle_t pic);
extern void (*R_DrawStretchPic)(int x, int y, int w, int h, qhandle_t pic);
extern void (*R_DrawStretchRaw)(int x, int y, int w, int h);
extern void (*R_TileClear)(int x, int y, int w, int h, qhandle_t pic);
extern void (*R_DrawFill8)(int x, int y, int w, int h, int c);
extern void (*R_DrawFill32)(int x, int y, int w, int h, uint32_t color);
extern void (*R_UpdateRawPic)(int pic_w, int pic_h, const uint32_t *pic);
extern void (*R_DiscardRawPic)(void);

// video mode and refresh state management entry points
extern void (*R_BeginFrame)(void);
Expand Down
3 changes: 2 additions & 1 deletion inc/server/server.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,14 @@ with this program; if not, write to the Free Software Foundation, Inc.,

#include "common/net/net.h"

// if this is changed, Q2PRO protocol version must be changed too!
typedef enum {
ss_dead, // no map loaded
ss_loading, // spawning level edicts
ss_game, // actively running
ss_pic, // showing static picture
ss_broadcast, // running MVD client
ss_cinematic,
ss_cinematic, // playing a cinematic
} server_state_t;

#if USE_ICMP
Expand Down
Loading

0 comments on commit 30d959e

Please sign in to comment.