[Scummvm-git-logs] scummvm master -> b102e2d6b0fd61551f10ffc6f550ad4e16855abd
Strangerke
noreply at scummvm.org
Mon Jun 10 20:32:40 UTC 2024
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
b102e2d6b0 BAGEL: Remove unused nMaleMembers and nFemaleMembers counters as they are not useful
Commit: b102e2d6b0fd61551f10ffc6f550ad4e16855abd
https://github.com/scummvm/scummvm/commit/b102e2d6b0fd61551f10ffc6f550ad4e16855abd
Author: Strangerke (arnaud.boutonne at gmail.com)
Date: 2024-06-10T21:32:29+01:00
Commit Message:
BAGEL: Remove unused nMaleMembers and nFemaleMembers counters as they are not useful
Changed paths:
engines/bagel/spacebar/sraf_computer.cpp
diff --git a/engines/bagel/spacebar/sraf_computer.cpp b/engines/bagel/spacebar/sraf_computer.cpp
index 96a3a81d8fa..5e841faf2b8 100644
--- a/engines/bagel/spacebar/sraf_computer.cpp
+++ b/engines/bagel/spacebar/sraf_computer.cpp
@@ -667,15 +667,10 @@ bool SrafComputer::verifyDispatchTeam() {
}
// Make sure at least one staff member is sent on this mission
- int nMaleMembers = 0, nFemaleMembers = 0;
if (bValidTeam) {
for (int i = 0; i < NUM_STAFFERS; i++) {
if (g_staffers[i]._bOnCurrentTeam) {
nTeam |= (1 << (i + 3));
- if (g_staffers[i]._nFlags & mStafferMale)
- nMaleMembers++;
- else
- nFemaleMembers++;
}
}
@@ -743,15 +738,6 @@ bool SrafComputer::verifyDispatchTeam() {
pTeamItem->_nDispatchTime = pVar->getNumValue();
pTeamItem->_nMeetingTime = calculateMeetingTime(pTeamItem->_nFlags);
- // The spokesperson will be the majority of the sexes
- // If same number of each, then randomize it.
-
- if (nMaleMembers == nFemaleMembers) {
- // Get a random number to decide the spokesperson of even team
- int nRand = pTeamItem->_nDispatchTime;
- nMaleMembers += (nRand & 1 ? 1 : -1);
- }
-
// Pick a team captain, must be same sex as the announcer.
pTeamItem->_nTeamCaptain = getTeamCaptain(pTeamItem->_nFlags);
@@ -4273,7 +4259,7 @@ void SrafComputer::onButtonCodeWords(CBofButton *pButton, int nState) {
}
void SrafComputer::onButtonFinished(bool bVictorious) {
- CBagVar *pVar = nullptr;
+ CBagVar *pVar;
// Make sure the user selected two code words.
if (bVictorious == true) {
More information about the Scummvm-git-logs
mailing list