@@ -546,6 +546,7 @@ int MetagameGUI::Create(Controller *pController)
546
546
m_pGoldSlider = dynamic_cast <GUISlider *>(m_pGUIController->GetControl (" GoldSlider" ));
547
547
m_pLengthLabel = dynamic_cast <GUILabel *>(m_pGUIController->GetControl (" LengthLabel" ));
548
548
m_pLengthSlider = dynamic_cast <GUISlider *>(m_pGUIController->GetControl (" LengthSlider" ));
549
+
549
550
m_pErrorLabel = dynamic_cast <GUILabel *>(m_pGUIController->GetControl (" StartErrorLabel" ));
550
551
m_apPlayerControlButton[Players::PlayerOne] = dynamic_cast <GUIButton *>(m_pGUIController->GetControl (" P1ControlButton" ));
551
552
m_apPlayerControlButton[Players::PlayerTwo] = dynamic_cast <GUIButton *>(m_pGUIController->GetControl (" P2ControlButton" ));
@@ -1169,7 +1170,7 @@ bool MetagameGUI::StartNewGame()
1169
1170
1170
1171
// Set the starting brains for this player
1171
1172
// Start with the baseline setting
1172
- newPlayer.m_BrainPool = ceilf (BRAINPOOLMAX * (( float ) m_pLengthSlider->GetValue () / 100.0 ) );
1173
+ newPlayer.m_BrainPool = m_pLengthSlider->GetValue ();
1173
1174
// Baseline can never be 0
1174
1175
newPlayer.m_BrainPool = MAX (newPlayer.m_BrainPool , 1 );
1175
1176
// Apply the handicap!
@@ -6258,8 +6259,7 @@ void MetagameGUI::UpdateGameSizeLabels()
6258
6259
m_pGoldLabel->SetText (str);
6259
6260
6260
6261
// Set the length label also according to the game length slider
6261
- // TODO: don't hardcode the range of this
6262
- int brainCount = ceilf (BRAINPOOLMAX * ((float )m_pLengthSlider->GetValue () / 100.0 ));
6262
+ int brainCount = m_pLengthSlider->GetValue ();
6263
6263
brainCount = MAX (brainCount, 1 );
6264
6264
sprintf_s (str, sizeof (str), " Game Length: %c%c%d starting brains" , -48 , -36 , brainCount);
6265
6265
m_pLengthLabel->SetText (str);
0 commit comments