Add new Preference, Maximum Number of Credits
Grant users the ability to change the maximum amount of credits available rather than the constant cap at 20. (cherry picked from commit 2ec2355d7a7d9fec9410cf6b7d2b5c31a4406074) (cherry picked from commit 48245ab51600ede16096e70e27c94345918eaed7)
This commit is contained in:
@@ -369,6 +369,7 @@ Clear Machine Stats=Clear all scores saved to this machine.
|
|||||||
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
||||||
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
||||||
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
||||||
|
MaxNumCredits=The maximum number of credits for coin mode.
|
||||||
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
||||||
CourseSortOrder=Determines how courses are sorted.
|
CourseSortOrder=Determines how courses are sorted.
|
||||||
CreateNew=
|
CreateNew=
|
||||||
@@ -981,6 +982,7 @@ Clear clipboard=Zwischenablage löschen
|
|||||||
CoinMode=Münzen Modus
|
CoinMode=Münzen Modus
|
||||||
CoinModeNoHome=Münzen Modus
|
CoinModeNoHome=Münzen Modus
|
||||||
CoinsPerCredit=Münzen pro Credit
|
CoinsPerCredit=Münzen pro Credit
|
||||||
|
MaxNumCredits=Max Credits
|
||||||
ComboContinuesBetweenSongs=Carry Combo
|
ComboContinuesBetweenSongs=Carry Combo
|
||||||
Combo segments=Combo-Segmente
|
Combo segments=Combo-Segmente
|
||||||
Convert pause to beats=Convert stop to beats
|
Convert pause to beats=Convert stop to beats
|
||||||
|
|||||||
@@ -370,6 +370,7 @@ Clear Machine Stats=Clear all scores saved to this machine.
|
|||||||
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
||||||
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
||||||
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
||||||
|
MaxNumCredits=The maximum number of credits for coin mode.
|
||||||
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
||||||
CourseSortOrder=Determines how courses are sorted.
|
CourseSortOrder=Determines how courses are sorted.
|
||||||
CustomSongsEnable=Custom songs are loaded from USB profiles.
|
CustomSongsEnable=Custom songs are loaded from USB profiles.
|
||||||
@@ -1004,6 +1005,7 @@ Clear timing in region=Clear timing in region
|
|||||||
CoinMode=Coin Mode
|
CoinMode=Coin Mode
|
||||||
CoinModeNoHome=Coin Mode
|
CoinModeNoHome=Coin Mode
|
||||||
CoinsPerCredit=Coins Per Credit
|
CoinsPerCredit=Coins Per Credit
|
||||||
|
MaxNumCredits=Max Credits
|
||||||
ComboContinuesBetweenSongs=Carry Combo
|
ComboContinuesBetweenSongs=Carry Combo
|
||||||
Combo segments=Combo segments
|
Combo segments=Combo segments
|
||||||
Convert pause to beats=Convert stop to beats
|
Convert pause to beats=Convert stop to beats
|
||||||
|
|||||||
@@ -362,6 +362,7 @@ Clear Machine Edits=Guardar todas las ediciones de pasos a esta máquina.
|
|||||||
Clear USB edits=Descartar ediciones en USB.
|
Clear USB edits=Descartar ediciones en USB.
|
||||||
Clear Machine Stats=Descartar todas las puntuaciones guardadas en esta máquina.
|
Clear Machine Stats=Descartar todas las puntuaciones guardadas en esta máquina.
|
||||||
CoinsPerCredit=Número de monedas que se deben insertar para que un jugador pueda unirse (cuando está activado el modo Pagar).
|
CoinsPerCredit=Número de monedas que se deben insertar para que un jugador pueda unirse (cuando está activado el modo Pagar).
|
||||||
|
MaxNumCredits=The maximum number of credits for coin mode.
|
||||||
CourseSortOrder=Determina cuántos cursos se organizan.
|
CourseSortOrder=Determina cuántos cursos se organizan.
|
||||||
CreateNew=
|
CreateNew=
|
||||||
Create New Course=Crear un curso nuevo.
|
Create New Course=Crear un curso nuevo.
|
||||||
@@ -962,6 +963,7 @@ Clear clipboard=Descartar portapapeles
|
|||||||
CoinMode=Modo monedas
|
CoinMode=Modo monedas
|
||||||
CoinModeNoHome=Modo monedas
|
CoinModeNoHome=Modo monedas
|
||||||
CoinsPerCredit=Mon. por crédito
|
CoinsPerCredit=Mon. por crédito
|
||||||
|
MaxNumCredits=Max Credits
|
||||||
Convert pause to beats=Convertir parada en compases
|
Convert pause to beats=Convertir parada en compases
|
||||||
Convert delay to beats=Convertir latencia en compases
|
Convert delay to beats=Convertir latencia en compases
|
||||||
Convert selection to attack=Convertir selección en ataque
|
Convert selection to attack=Convertir selección en ataque
|
||||||
|
|||||||
@@ -367,6 +367,7 @@ Clear Machine Stats=Clear all scores saved to this machine.
|
|||||||
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
CoinMode=&oq;Home&cq;: Options are shown on the Title Menu. &oq;Pay&cq;: Title Menu choices are hidden; must insert coins before playing. &oq;Free Play&cq;: Title Menu choices are hidden; Play without inserting coins.
|
||||||
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
CoinModeNoHome=When set to PAY you must insert coins before joining in. When set to FREE you can join in without inserting coins.
|
||||||
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
CoinsPerCredit=The number of coins that must be inserted before a player can join. (when Coin Mode = Pay)
|
||||||
|
MaxNumCredits=The maximum number of credits for coin mode.
|
||||||
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
ComboContinuesBetweenSongs=If turned on, the combo will not be reset to 0 after every song.
|
||||||
CourseSortOrder=Détermine comment les parcours sont triés.
|
CourseSortOrder=Détermine comment les parcours sont triés.
|
||||||
CreateNew=
|
CreateNew=
|
||||||
@@ -937,6 +938,7 @@ GetRankingName=Afficher les Noms
|
|||||||
CoinMode=Mode Jeton
|
CoinMode=Mode Jeton
|
||||||
SongsPerPlay=Chansons Par Partie
|
SongsPerPlay=Chansons Par Partie
|
||||||
CoinsPerCredit=Jetons Par Crédit
|
CoinsPerCredit=Jetons Par Crédit
|
||||||
|
MaxNumCredits=Max Credits
|
||||||
Premium=Premium
|
Premium=Premium
|
||||||
EventMode=Mode Évènement
|
EventMode=Mode Évènement
|
||||||
AllowMultipleHighScoreWithSameName=Mode Compétition
|
AllowMultipleHighScoreWithSameName=Mode Compétition
|
||||||
|
|||||||
@@ -3183,23 +3183,24 @@ Fallback="ScreenOptionsServiceChild"
|
|||||||
NextScreen="ScreenOptionsService"
|
NextScreen="ScreenOptionsService"
|
||||||
PrevScreen="ScreenOptionsService"
|
PrevScreen="ScreenOptionsService"
|
||||||
# stuff tied to arcade features
|
# stuff tied to arcade features
|
||||||
LineNames="1,2,3,4,5,6,7,8,AMT,9,HHLP,10,11,12,13,14"
|
LineNames="1,2,3,4,5,6,7,8,9,AMT,10,HHLP,11,12,13,14,15"
|
||||||
Line1="conf,GetRankingName"
|
Line1="conf,GetRankingName"
|
||||||
Line2="conf,CoinMode"
|
Line2="conf,CoinMode"
|
||||||
Line3="conf,SongsPerPlay"
|
Line3="conf,SongsPerPlay"
|
||||||
Line4="conf,CoinsPerCredit"
|
Line4="conf,CoinsPerCredit"
|
||||||
Line5="conf,Premium"
|
Line5="conf,MaxNumCredits"
|
||||||
Line6="conf,EventMode"
|
Line6="conf,Premium"
|
||||||
Line7="conf,AllowMultipleHighScoreWithSameName"
|
Line7="conf,EventMode"
|
||||||
Line8="conf,ComboContinuesBetweenSongs"
|
Line8="conf,AllowMultipleHighScoreWithSameName"
|
||||||
|
Line9="conf,ComboContinuesBetweenSongs"
|
||||||
LineAMT="conf,AllowMultipleToasties"
|
LineAMT="conf,AllowMultipleToasties"
|
||||||
Line9="conf,Disqualification"
|
Line10="conf,Disqualification"
|
||||||
LineHHLP="conf,HarshHotLifePenalty"
|
LineHHLP="conf,HarshHotLifePenalty"
|
||||||
Line10="conf,FailOffForFirstStageEasy"
|
Line11="conf,FailOffForFirstStageEasy"
|
||||||
Line11="conf,FailOffInBeginner"
|
Line12="conf,FailOffInBeginner"
|
||||||
Line12="conf,LockCourseDifficulties"
|
Line13="conf,LockCourseDifficulties"
|
||||||
Line13="conf,MaxHighScoresPerListForMachine"
|
Line14="conf,MaxHighScoresPerListForMachine"
|
||||||
Line14="conf,MaxHighScoresPerListForPlayer"
|
Line15="conf,MaxHighScoresPerListForPlayer"
|
||||||
|
|
||||||
[ScreenOptionsTheme]
|
[ScreenOptionsTheme]
|
||||||
Fallback="ScreenOptionsServiceChild"
|
Fallback="ScreenOptionsServiceChild"
|
||||||
|
|||||||
+1
-1
@@ -127,7 +127,7 @@ void Bookkeeper::ReadFromDisk()
|
|||||||
|
|
||||||
if ( numCoins < 0 )
|
if ( numCoins < 0 )
|
||||||
numCoins = 0;
|
numCoins = 0;
|
||||||
else if ( numCoins / PREFSMAN->m_iCoinsPerCredit > MAX_NUM_CREDITS )
|
else if ( numCoins / PREFSMAN->m_iCoinsPerCredit > PREFSMAN->m_iMaxNumCredits )
|
||||||
numCoins = 0;
|
numCoins = 0;
|
||||||
|
|
||||||
LOG->Trace("Number of Coins to Load on boot: %i", numCoins);
|
LOG->Trace("Number of Coins to Load on boot: %i", numCoins);
|
||||||
|
|||||||
@@ -208,6 +208,7 @@ PrefsManager::PrefsManager() :
|
|||||||
m_AllowW1 ( "AllowW1", ALLOW_W1_EVERYWHERE ),
|
m_AllowW1 ( "AllowW1", ALLOW_W1_EVERYWHERE ),
|
||||||
m_bEventMode ( "EventMode", true ),
|
m_bEventMode ( "EventMode", true ),
|
||||||
m_iCoinsPerCredit ( "CoinsPerCredit", 1 ),
|
m_iCoinsPerCredit ( "CoinsPerCredit", 1 ),
|
||||||
|
m_iMaxNumCredits ( "MaxNumCredits", 20 ),
|
||||||
m_iSongsPerPlay ( "SongsPerPlay", 3, ValidateSongsPerPlay ),
|
m_iSongsPerPlay ( "SongsPerPlay", 3, ValidateSongsPerPlay ),
|
||||||
m_bDelayedCreditsReconcile ( "DelayedCreditsReconcile", false ),
|
m_bDelayedCreditsReconcile ( "DelayedCreditsReconcile", false ),
|
||||||
m_bComboContinuesBetweenSongs ( "ComboContinuesBetweenSongs", false ),
|
m_bComboContinuesBetweenSongs ( "ComboContinuesBetweenSongs", false ),
|
||||||
|
|||||||
@@ -209,6 +209,7 @@ public:
|
|||||||
Preference<AllowW1> m_AllowW1; // this should almost always be on, given use cases. -aj
|
Preference<AllowW1> m_AllowW1; // this should almost always be on, given use cases. -aj
|
||||||
Preference<bool> m_bEventMode;
|
Preference<bool> m_bEventMode;
|
||||||
Preference<int> m_iCoinsPerCredit;
|
Preference<int> m_iCoinsPerCredit;
|
||||||
|
Preference<int> m_iMaxNumCredits;
|
||||||
Preference<int> m_iSongsPerPlay;
|
Preference<int> m_iSongsPerPlay;
|
||||||
Preference<bool> m_bDelayedCreditsReconcile; // zuh?
|
Preference<bool> m_bDelayedCreditsReconcile; // zuh?
|
||||||
Preference<bool> m_bComboContinuesBetweenSongs;
|
Preference<bool> m_bComboContinuesBetweenSongs;
|
||||||
|
|||||||
@@ -456,6 +456,12 @@ static void CoinsPerCredit( int &sel, bool ToSel, const ConfOption *pConfOption
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void MaxNumCredits( int &sel, bool ToSel, const ConfOption *pConfOption )
|
||||||
|
{
|
||||||
|
int const mapping[]= {20, 40, 60, 80, 100};
|
||||||
|
MoveMap(sel, pConfOption, ToSel, mapping, ARRAYLEN(mapping));
|
||||||
|
}
|
||||||
|
|
||||||
static void JointPremium( int &sel, bool ToSel, const ConfOption *pConfOption )
|
static void JointPremium( int &sel, bool ToSel, const ConfOption *pConfOption )
|
||||||
{
|
{
|
||||||
const Premium mapping[] = { Premium_DoubleFor1Credit, Premium_2PlayersFor1Credit };
|
const Premium mapping[] = { Premium_DoubleFor1Credit, Premium_2PlayersFor1Credit };
|
||||||
@@ -847,6 +853,7 @@ static void InitializeConfOptions()
|
|||||||
ADD( ConfOption( "CoinModeNoHome", CoinModeNoHome, "Pay","Free Play" ) );
|
ADD( ConfOption( "CoinModeNoHome", CoinModeNoHome, "Pay","Free Play" ) );
|
||||||
g_ConfOptions.back().m_sPrefName = "CoinMode";
|
g_ConfOptions.back().m_sPrefName = "CoinMode";
|
||||||
ADD( ConfOption( "CoinsPerCredit", CoinsPerCredit, "|1","|2","|3","|4","|5","|6","|7","|8","|9","|10","|11","|12","|13","|14","|15","|16" ) );
|
ADD( ConfOption( "CoinsPerCredit", CoinsPerCredit, "|1","|2","|3","|4","|5","|6","|7","|8","|9","|10","|11","|12","|13","|14","|15","|16" ) );
|
||||||
|
ADD( ConfOption( "MaxNumCredits", MaxNumCredits, "|20","|40","|60","|80","|100" ) );
|
||||||
|
|
||||||
ADD( ConfOption( "SongsPerPlay", SongsPerPlay, "|1","|2","|3","|4","|5" ) );
|
ADD( ConfOption( "SongsPerPlay", SongsPerPlay, "|1","|2","|3","|4","|5" ) );
|
||||||
ADD( ConfOption( "SongsPerPlayOrEvent", SongsPerPlayOrEventMode,"|1","|2","|3","|4","|5","Event" ) );
|
ADD( ConfOption( "SongsPerPlayOrEvent", SongsPerPlayOrEventMode,"|1","|2","|3","|4","|5","Event" ) );
|
||||||
@@ -861,6 +868,7 @@ static void InitializeConfOptions()
|
|||||||
ADD( ConfOption( "ProgressiveNonstopLifebar", MovePref<int>, "Off","|1","|2","|3","|4","|5","|6","|7","|8","Insanity") );
|
ADD( ConfOption( "ProgressiveNonstopLifebar", MovePref<int>, "Off","|1","|2","|3","|4","|5","|6","|7","|8","Insanity") );
|
||||||
ADD( ConfOption( "DefaultFailType", DefaultFailType, DefaultFailChoices ) );
|
ADD( ConfOption( "DefaultFailType", DefaultFailType, DefaultFailChoices ) );
|
||||||
ADD( ConfOption( "CoinsPerCredit", CoinsPerCredit, "|1","|2","|3","|4","|5","|6","|7","|8","|9","|10","|11","|12","|13","|14","|15","|16" ) );
|
ADD( ConfOption( "CoinsPerCredit", CoinsPerCredit, "|1","|2","|3","|4","|5","|6","|7","|8","|9","|10","|11","|12","|13","|14","|15","|16" ) );
|
||||||
|
ADD( ConfOption( "MaxNumCredits", MaxNumCredits, "|20","|40","|60","|80","|100" ) );
|
||||||
ADD( ConfOption( "Premium", MovePref<Premium>, "Off","Double for 1 Credit","2 Players for 1 Credit" ) );
|
ADD( ConfOption( "Premium", MovePref<Premium>, "Off","Double for 1 Credit","2 Players for 1 Credit" ) );
|
||||||
ADD( ConfOption( "JointPremium", JointPremium, "Off","2 Players for 1 Credit" ) );
|
ADD( ConfOption( "JointPremium", JointPremium, "Off","2 Players for 1 Credit" ) );
|
||||||
g_ConfOptions.back().m_sPrefName = "Premium";
|
g_ConfOptions.back().m_sPrefName = "Premium";
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ namespace
|
|||||||
sCredits += ssprintf(" %d", iCredits);
|
sCredits += ssprintf(" %d", iCredits);
|
||||||
if( PREFSMAN->m_iCoinsPerCredit > 1 )
|
if( PREFSMAN->m_iCoinsPerCredit > 1 )
|
||||||
sCredits += ssprintf(" %d/%d", iCoins, PREFSMAN->m_iCoinsPerCredit.Get() );
|
sCredits += ssprintf(" %d/%d", iCoins, PREFSMAN->m_iCoinsPerCredit.Get() );
|
||||||
if( iCredits >= MAX_NUM_CREDITS )
|
if( iCredits >= PREFSMAN->m_iMaxNumCredits )
|
||||||
sCredits += " " + CREDITS_MAX.GetValue();
|
sCredits += " " + CREDITS_MAX.GetValue();
|
||||||
return sCredits;
|
return sCredits;
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -1113,10 +1113,10 @@ void StepMania::InsertCoin( int iNum, bool bCountInBookkeeping )
|
|||||||
}
|
}
|
||||||
|
|
||||||
int iCredits = GAMESTATE->m_iCoins / PREFSMAN->m_iCoinsPerCredit;
|
int iCredits = GAMESTATE->m_iCoins / PREFSMAN->m_iCoinsPerCredit;
|
||||||
bool bMaxCredits = iCredits >= MAX_NUM_CREDITS;
|
bool bMaxCredits = iCredits >= PREFSMAN->m_iMaxNumCredits;
|
||||||
if( bMaxCredits )
|
if( bMaxCredits )
|
||||||
{
|
{
|
||||||
GAMESTATE->m_iCoins.Set( MAX_NUM_CREDITS * PREFSMAN->m_iCoinsPerCredit );
|
GAMESTATE->m_iCoins.Set( PREFSMAN->m_iMaxNumCredits * PREFSMAN->m_iCoinsPerCredit );
|
||||||
}
|
}
|
||||||
|
|
||||||
LOG->Trace("%i coins inserted, %i needed to play", GAMESTATE->m_iCoins.Get(), PREFSMAN->m_iCoinsPerCredit.Get() );
|
LOG->Trace("%i coins inserted, %i needed to play", GAMESTATE->m_iCoins.Get(), PREFSMAN->m_iCoinsPerCredit.Get() );
|
||||||
|
|||||||
Reference in New Issue
Block a user