Small comments.

This commit is contained in:
Jonathan Bernard 2010-08-27 03:13:23 -05:00
parent 1dc9bb2a4a
commit cb724eaf51
2 changed files with 12 additions and 7 deletions

View File

@ -1,7 +1,7 @@
#Wed, 25 Aug 2010 09:05:51 -0500
#Fri, 27 Aug 2010 03:12:12 -0500
#Mon Jul 05 23:10:39 CDT 2010
app.version=0.4.0
build.number=2
build.number=3
src.dir=src
lib.dir=lib
build.dir=build

View File

@ -18,13 +18,14 @@ public class TeamMaker {
public static def swing = new SwingBuilder()
public static final String version = "0.4"
def frame
def team1List
def team2List
// GUI Components
def frame // main frame
def team1List // JList for team 1
def team2List // JList for team 2
def team1WinsButton
def team2WinsButton
def newGameButton
def sittingList
def sittingList // JList for sitting players
def inGamePlayerDropMenu
def sittingPlayerDropMenu
@ -34,6 +35,7 @@ public class TeamMaker {
PlayerChooser playerChooser = new WeightedChooser(hardLimit: 2)
OddsCalculator oddsCalculator = new OddsCalculator()
// Data components
class Observables {
@Bindable List team1Players = []
@Bindable List team2Players = []
@ -197,6 +199,9 @@ public class TeamMaker {
init()
}
/**
* @return the number of players needed to round out even teams.
*/
public int getSpotsOpen() {
def spots = (model.teamSize - model.team1Players.size()) +
(model.teamSize - model.team2Players.size())