mirror of
https://github.com/FWGS/xash3d-fwgs
synced 2024-11-25 11:19:59 +01:00
5e0a0765ce
The `.editorconfig` file in this repo is configured to trim all trailing whitespace regardless of whether the line is modified. Trims all trailing whitespace in the repository to make the codebase easier to work with in editors that respect `.editorconfig`. `git blame` becomes less useful on these lines but it already isn't very useful. Commands: ``` find . -type f -name '*.h' -exec sed --in-place 's/[[:space:]]\+$//' {} \+ find . -type f -name '*.c' -exec sed --in-place 's/[[:space:]]\+$//' {} \+ ```
51 lines
1.7 KiB
C
51 lines
1.7 KiB
C
/***
|
|
*
|
|
* Copyright (c) 1996-2002, Valve LLC. All rights reserved.
|
|
*
|
|
* This product contains software technology licensed from Id
|
|
* Software, Inc. ("Id Technology"). Id Technology (c) 1996 Id Software, Inc.
|
|
* All Rights Reserved.
|
|
*
|
|
* Use, distribution, and modification of this source code and/or resulting
|
|
* object code is restricted to non-commercial enhancements to products from
|
|
* Valve LLC. All other use, distribution, or modification is prohibited
|
|
* without written permission from Valve LLC.
|
|
*
|
|
****/
|
|
|
|
#ifndef SHAKE_H
|
|
#define SHAKE_H
|
|
|
|
// Screen / View effects
|
|
|
|
// screen shake
|
|
extern int gmsgShake;
|
|
|
|
// This structure is sent over the net to describe a screen shake event
|
|
typedef struct
|
|
{
|
|
unsigned short amplitude; // FIXED 4.12 amount of shake
|
|
unsigned short duration; // FIXED 4.12 seconds duration
|
|
unsigned short frequency; // FIXED 8.8 noise frequency (low frequency is a jerk,high frequency is a rumble)
|
|
} ScreenShake;
|
|
|
|
// Fade in/out
|
|
extern int gmsgFade;
|
|
|
|
#define FFADE_IN 0x0000 // Just here so we don't pass 0 into the function
|
|
#define FFADE_OUT 0x0001 // Fade out (not in)
|
|
#define FFADE_MODULATE 0x0002 // Modulate (don't blend)
|
|
#define FFADE_STAYOUT 0x0004 // ignores the duration, stays faded out until new ScreenFade message received
|
|
#define FFADE_LONGFADE 0x0008 // used to indicate the fade can be longer than 16 seconds (added for czero)
|
|
|
|
// This structure is sent over the net to describe a screen fade event
|
|
typedef struct
|
|
{
|
|
unsigned short duration; // FIXED 4.12 seconds duration
|
|
unsigned short holdTime; // FIXED 4.12 seconds duration until reset (fade & hold)
|
|
short fadeFlags; // flags
|
|
byte r, g, b, a; // fade to color ( max alpha )
|
|
} ScreenFade;
|
|
|
|
#endif // SHAKE_H
|