sm64coopdx/src/pc/configfile.h
Sunk 947ce9f080
Rework PvP Balance (#357)
* PvP Rework

This rearranges the damages of last PR. The underused attacks should still see some buffs.

* Adjust how punches apply invincibility

Also increase punch invincibility timer to 12

* EmeraldLoc's easy suggestions

* Rework punching pvp

Punching no longer reduces invincibility frames. Instead, punches can ignore knockback invincibility and the full punch punch kick combo can be done.

* Adjust numbers

Breakdances should not deal 3 damage

* Potential fix for more common tripping

"Trip" here refers to 1 damage kicks

* Add temporary invincibility to rollouts

This is a test to see how different pvp feels with this change. Suggestion by sausrelics.

* Fix invincibility

* Prevent low damage/low knockback kicks altogether

* Update ignored attack list

* Allow dives to be attacked by most actions

A lot of people don't want dives to be entirely invincible and some suggested to make dives be able to only pierce through jump kicks

* Slightly nerf kick knockback

Suggestion by emily

* Rework dive piercing

Instead of all actions being able to hit dives other than jumpkicks, now only slidekicks (and ground pounds) can hit dives.

* Mild kick knockback increase from nerf

* Change direct equality to checking flag

* Decrease dive and punch knockback

* Prevent trades against dives with slidekicks

* Revert "Prevent trades against dives with slidekicks"

This reverts commit 2a2c3266a7.

* Allow ground pounds to always hit a sliding player

* Add server setting to change pvp

* Add pvp settings to config

* Add selection to menu

* Fix issues + autogen

* Rewrite goto statement to not use goto
2024-11-25 20:48:40 +10:00

151 lines
5.2 KiB
C

#ifndef CONFIGFILE_H
#define CONFIGFILE_H
#include <stdbool.h>
#include <PR/ultratypes.h>
#include "game/player_palette.h"
#define CONFIGFILE_DEFAULT "sm64config.txt"
#define CONFIGFILE_BACKUP "sm64config-backup.txt"
#define MAX_BINDS 3
#define MAX_VOLUME 127
#define MAX_CONFIG_STRING 64
#define MAX_SAVE_NAME_STRING 32
#define DEFAULT_PORT 7777
#define DEFAULT_COOPNET_IP "net.coop64.us"
#define DEFAULT_COOPNET_PORT 34197
typedef struct {
unsigned int x, y, w, h;
bool vsync;
bool reset;
bool fullscreen;
bool exiting_fullscreen;
bool settings_changed;
unsigned int msaa;
} ConfigWindow;
extern char configSaveNames[4][MAX_SAVE_NAME_STRING];
// display settings
extern ConfigWindow configWindow;
extern unsigned int configFiltering;
extern bool configShowFPS;
extern bool configUncappedFramerate;
extern unsigned int configFrameLimit;
extern unsigned int configInterpolationMode;
extern unsigned int configDrawDistance;
// sound settings
extern unsigned int configMasterVolume;
extern unsigned int configMusicVolume;
extern unsigned int configSfxVolume;
extern unsigned int configEnvVolume;
extern bool configFadeoutDistantSounds;
extern bool configMuteFocusLoss;
// control binds
extern unsigned int configKeyA[MAX_BINDS];
extern unsigned int configKeyB[MAX_BINDS];
extern unsigned int configKeyX[MAX_BINDS];
extern unsigned int configKeyY[MAX_BINDS];
extern unsigned int configKeyStart[MAX_BINDS];
extern unsigned int configKeyL[MAX_BINDS];
extern unsigned int configKeyR[MAX_BINDS];
extern unsigned int configKeyZ[MAX_BINDS];
extern unsigned int configKeyCUp[MAX_BINDS];
extern unsigned int configKeyCDown[MAX_BINDS];
extern unsigned int configKeyCLeft[MAX_BINDS];
extern unsigned int configKeyCRight[MAX_BINDS];
extern unsigned int configKeyStickUp[MAX_BINDS];
extern unsigned int configKeyStickDown[MAX_BINDS];
extern unsigned int configKeyStickLeft[MAX_BINDS];
extern unsigned int configKeyStickRight[MAX_BINDS];
extern unsigned int configKeyChat[MAX_BINDS];
extern unsigned int configKeyPlayerList[MAX_BINDS];
extern unsigned int configKeyDUp[MAX_BINDS];
extern unsigned int configKeyDDown[MAX_BINDS];
extern unsigned int configKeyDLeft[MAX_BINDS];
extern unsigned int configKeyDRight[MAX_BINDS];
extern unsigned int configKeyConsole[MAX_BINDS];
extern unsigned int configKeyPrevPage[MAX_BINDS];
extern unsigned int configKeyNextPage[MAX_BINDS];
extern unsigned int configKeyDisconnect[MAX_BINDS];
extern unsigned int configStickDeadzone;
extern unsigned int configRumbleStrength;
extern unsigned int configGamepadNumber;
extern bool configBackgroundGamepad;
extern bool configDisableGamepads;
extern bool configUseStandardKeyBindingsChat;
// free camera settings
extern bool configEnableCamera;
extern bool configCameraAnalog;
extern bool configCameraMouse;
extern bool configCameraInvertX;
extern bool configCameraInvertY;
extern unsigned int configCameraXSens;
extern unsigned int configCameraYSens;
extern unsigned int configCameraAggr;
extern unsigned int configCameraPan;
extern unsigned int configCameraDegrade;
// debug
extern bool configLuaProfiler;
extern bool configDebugPrint;
extern bool configDebugInfo;
extern bool configDebugError;
#ifdef DEVELOPMENT
extern bool configCtxProfiler;
#endif
// player settings
extern char configPlayerName[MAX_CONFIG_STRING];
extern unsigned int configPlayerModel;
extern struct PlayerPalette configPlayerPalette;
// coop settings
extern unsigned int configAmountofPlayers;
extern bool configBubbleDeath;
extern unsigned int configHostPort;
extern unsigned int configHostSaveSlot;
extern char configJoinIp[MAX_CONFIG_STRING];
extern unsigned int configJoinPort;
extern unsigned int configNetworkSystem;
extern unsigned int configPlayerInteraction;
extern unsigned int configPlayerKnockbackStrength;
extern unsigned int configStayInLevelAfterStar;
extern bool configNametags;
extern unsigned int configBouncyLevelBounds;
extern bool configSkipIntro;
extern bool configPauseAnywhere;
extern bool configMenuStaffRoll;
extern unsigned int configMenuLevel;
extern unsigned int configMenuSound;
extern bool configMenuRandom;
extern bool configMenuDemos;
extern bool configDisablePopups;
extern char configLanguage[MAX_CONFIG_STRING];
extern bool configDynosLocalPlayerModelOnly;
extern unsigned int configPvpMode;
// CoopNet settings
extern char configCoopNetIp[MAX_CONFIG_STRING];
extern unsigned int configCoopNetPort;
extern char configPassword[MAX_CONFIG_STRING];
extern char configDestId[MAX_CONFIG_STRING];
// DJUI settings
extern unsigned int configDjuiTheme;
extern bool configDjuiThemeCenter;
extern unsigned int configDjuiThemeFont;
extern unsigned int configDjuiScale;
// other
extern unsigned int configRulesVersion;
extern bool configCompressOnStartup;
// secrets
extern bool configExCoopTheme;
void enable_queued_mods(void);
void enable_queued_dynos_packs(void);
void configfile_load(void);
void configfile_save(const char *filename);
const char *configfile_name(void);
const char *configfile_backup_name(void);
#endif // CONFIGFILE_H