Update bird menu
Also made some options dynamic.
This commit is contained in:
1 parent
200aaabf48
commit
0884d0b546
4 files changed
+70
-10
No files matched your search
+1
-1
@@ -537,7 +537,7 @@ consvar_t cv_respawnfademusicback = {"respawnfademusicback", "500", CV_SAVE, CV_
|
||||
consvar_t cv_resetspecialmusic = {"resetspecialmusic", "Yes", CV_SAVE, CV_YesNo, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
consvar_t cv_resume = {"resume", "Yes", CV_SAVE, CV_YesNo, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_fading = {"fading", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_fading = {"fading", "On", CV_SAVE|CV_CALL, CV_OnOff, Bird_menu_Onchange, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
#if MAXPLAYERS > 16
|
||||
#error "please update player_name table using the new value for MAXPLAYERS"
|
||||
|
||||
+64
-8
@@ -1654,20 +1654,44 @@ static menuitem_t OP_BirdMenu[] =
|
||||
static menuitem_t OP_TiltMenu[] =
|
||||
{
|
||||
{IT_STRING | IT_CVAR, NULL, "Camera Tilting", &cv_tilting, 0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Also Tilt During Quakes", &cv_actionmovie, 10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Tilt While Turning", &cv_quaketilt, 10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Smoothing Divisor", &cv_tiltsmoothing, 20},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "\x85" "Window Shaking During Quakes", &cv_windowquake, 30},
|
||||
{IT_STRING | IT_CVAR, NULL, "Also Tilt During Quakes", &cv_actionmovie, 40},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "\x85" "Window Shaking During Quakes", &cv_windowquake, 60},
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
tilting,
|
||||
tiltwturning,
|
||||
smoothening,
|
||||
tiltwquakes,
|
||||
windowshake,
|
||||
};
|
||||
|
||||
static menuitem_t OP_AdvancedBirdMenu[] =
|
||||
{
|
||||
{IT_STRING | IT_CVAR, NULL, "Resync Threshold", &cv_music_resync_threshold, 0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Resync Special Music Only", &cv_music_resync_powerups_only, 10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fading", &cv_fading, 0},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back from Invincibility", &cv_invincmusicfade, 10},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back from Grow", &cv_growmusicfade, 20},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Out Before Respawning", &cv_respawnfademusicout, 30},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back In While Respawning", &cv_respawnfademusicback, 40},
|
||||
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back from Invincibility", &cv_invincmusicfade, 30},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back from Grow", &cv_growmusicfade, 40},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Out Before Respawning", &cv_respawnfademusicout, 50},
|
||||
{IT_STRING | IT_CVAR, NULL, "Fade Back In While Respawning", &cv_respawnfademusicback, 60},
|
||||
{IT_STRING | IT_CVAR, NULL, "Resync Threshold", &cv_music_resync_threshold, 60},
|
||||
{IT_STRING | IT_CVAR, NULL, "Resync Special Music Only", &cv_music_resync_powerups_only, 70},
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
fading,
|
||||
fadeinvinc,
|
||||
fadegrow,
|
||||
respawnfadeout,
|
||||
respawnfadein,
|
||||
syncthreshold,
|
||||
syncspecialonly,
|
||||
};
|
||||
|
||||
// ==========================================================================
|
||||
@@ -2426,6 +2450,38 @@ void Addons_option_Onchange(void)
|
||||
(cv_addons_option.value == 3 ? IT_CVAR|IT_STRING|IT_CV_STRING : IT_DISABLED);
|
||||
}
|
||||
|
||||
void Bird_menu_Onchange(void)
|
||||
{
|
||||
UINT16 status;
|
||||
|
||||
if (cv_tilting.value)
|
||||
{
|
||||
status = IT_STRING | IT_CVAR;
|
||||
}
|
||||
else
|
||||
{
|
||||
status = IT_GRAYEDOUT;
|
||||
}
|
||||
|
||||
OP_TiltMenu[tiltwturning].status = status;
|
||||
OP_TiltMenu[smoothening].status = status;
|
||||
OP_TiltMenu[tiltwquakes].status = status;
|
||||
|
||||
if (cv_fading.value)
|
||||
{
|
||||
status = IT_STRING | IT_CVAR;
|
||||
}
|
||||
else
|
||||
{
|
||||
status = IT_GRAYEDOUT;
|
||||
}
|
||||
|
||||
OP_AdvancedBirdMenu[fadeinvinc].status = status;
|
||||
OP_AdvancedBirdMenu[fadegrow].status = status;
|
||||
OP_AdvancedBirdMenu[respawnfadeout].status = status;
|
||||
OP_AdvancedBirdMenu[respawnfadein].status = status;
|
||||
}
|
||||
|
||||
// ==========================================================================
|
||||
// END ORGANIZATION STUFF.
|
||||
// ==========================================================================
|
||||
|
||||
@@ -260,6 +260,9 @@ void Screenshot_option_Onchange(void);
|
||||
// Addons menu updating
|
||||
void Addons_option_Onchange(void);
|
||||
|
||||
// Bird menu updating
|
||||
void Bird_menu_Onchange(void);
|
||||
|
||||
void M_ReplayHut(INT32 choice);
|
||||
void M_SetPlaybackMenuPointer(void);
|
||||
|
||||
|
||||
+2
-1
@@ -48,6 +48,7 @@
|
||||
#include "m_cond.h" // M_UpdateUnlockablesAndExtraEmblems
|
||||
#include "k_kart.h"
|
||||
#include "console.h" // CON_LogMessage
|
||||
#include "m_menu.h"
|
||||
|
||||
#ifdef HW3SOUND
|
||||
#include "hardware/hw3sound.h"
|
||||
@@ -7116,7 +7117,7 @@ consvar_t cv_cam4_speed = {"cam4_speed", "0.4", CV_FLOAT|CV_SAVE, CV_CamSpeed, N
|
||||
consvar_t cv_cam4_rotate = {"cam4_rotate", "0", CV_CALL|CV_NOINIT, CV_CamRotate, CV_CamRotate4_OnChange, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_cam4_rotspeed = {"cam4_rotspeed", "10", CV_SAVE, rotation_cons_t, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
consvar_t cv_tilting = {"tilting", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_tilting = {"tilting", "On", CV_SAVE|CV_CALL, CV_OnOff, Bird_menu_Onchange, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_quaketilt = {"quaketilt", "On", CV_SAVE, CV_OnOff, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
consvar_t cv_tiltsmoothing = {"tiltsmoothing", "32", CV_SAVE, CV_Natural, NULL, 0, NULL, NULL, 0, 0, NULL};
|
||||
|
||||
|
||||
Reference in new issue
Block a user