Soccer Demo
This is a quick experiment
in using Naked Objects.
We have written a soccer program.
You can download it
and run it at your own risk.
It is an executable JAR.
Instructions
Run it with java -jar soccerdemo.jar
.
You might also be able to pipe the log to an editor.
e.g. java -jar soccerdemo.jar | vi -
.
Events like substitution, goals, and cards will be printed to stdout.
You can then capture them in an editor for later analysis.
Upon start up you will see a window with three icons
for teams, games, and set plays.
Right click on the Teams icon to get a pop up menu.
Select "Teams..." from that menu to get a list of teams.
Do the same for the Set Plays.
This will open another box with the types of set plays in it.
The mini windows in the application have a right border that allows maximizing and minimizing.
Near the top there is also an X for closing the mini window.
Drag one team onto another to set up a game.
The team being dragged becomes the visitor.
You can drag players from a team onto either home or visitor of the game.
They will get added to the bench.
Dragging them directly onto the bench will not work.
Once in the game (on the field or on the bench)
players become competitors.
Competitors can be dragged from the field to the bench
or vice versa.
They can be dragged onto the goal when they score.
They can be dragged to the red card if the ref gives them a red card.
When there is a set play, drag a competitor onto the type of set play.
To Do
- Drag competitor off bench to rid.
- When a game is created, add all team members as competitors on bench.
Then put first 11 on field? This will speed up set up.
- Game Clock (drag kickoff to game clock to reset and start?)
- Yellow Card (competitor needs flag in title, maybe a NaughtyCompetitor?)
- Read Teams, Games from a file. (Name from command line)
(Better yet would be persistence to local files. JWS sandbox?)
- Other teams.
- Schedule of games.
- Upon startup open "today's game" if there is one.
- Icon for set plays.
- Auto red upon second yellow.
- Cards can be dropped on a competitor, or competitor on card.
- Other Fouls
- Player Clocks
- Limit Field to 11 players minus red cards.
- Assists
- Other Restart (drop ball, throws?)
- Saves?
- Positions (at least goalie)
- Shape (4 4 2, 4 3 3, etc.)
- Positions (other than goalie)
- Better logging. (now to stdout can be piped to Edit0). Can log4j help? Homegrown Log.java might be enough.
- Nick's Icons.
- End Half
- Stats for Competitors: minutes, goals, assists? etc. ( can be culled from log for now )
- Persistence
- Time of possession ( might be too hard to work )
- Ball in our half or theirs
- Shots
- Photograph game cards to get other rosters.
- Competitors dropped on a set play must be on field.
- Set play dropped on competitor same as inverse.
- JNLP Version
- URL for Startup file.
- Package simple editor with this?
- Better (sortable) time stamp format yyyy-mm-dd hh:mm:ss
- Allow dragging of competitor from one bench to the other side.
- Queue up substitutions ahead of time. (someday baby)
- Injuries. (add note in log for now) add collection like bench?
2005-09-29