Introduction, Features and Updates

Status
Not open for further replies.

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
PlanetCricket Cricket Simulator (PCCS)

What is it?
It is (going to be) an intelligent and advanced cricket simulator for simulation of many different types of cricket matches, with a focus on development towards the PlanetCricket CricSim Leagues. The product will be developed to be customizable so that any user can simulate matches with it.

Feature List
- Local database stores all information and players can choose which database they want to play with
- Tweaked simulation engine for Test match cricket, 50-over OD games and Twenty20 games
- Simulation engine extensible to 3-4 day games, and any number of over 50-over games
- Customizable tournaments using XML (pre-provided with standard formats)
- Ability to add your own players/teams/tournaments (pre-provided with internationals)
- Statistics tracking on a pretty deep level--track by career, series, league, period, etc.
- Realistic pitches with five parameters: bounce, grip, speed, variation, deterioration... this will allow pitches to behave differently and to change over the course of a match
- Players can have special qualities assigned to them (such as "slogger" or "sheet anchor" which would make each player slightly more unique than just a batting average

Future Extensions
- Interface with a central database with authentication to support a "world" that would allow simulation communities to maintain a single "real" database for all their tournament play

Current Status: IMPLEMENTATION
I have finished preliminary database work and am currently designing the simulation engine. After design is complete, I will work on the Twenty20 engine, then the OD engine and finally the multi-day engine.
 
Last edited:

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 17 2008
I did a lot of work on the framework for the simulation engine today. A lot of it is reusable code. My aim is to get the first version of the Twenty20 engine done tomorrow.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 19 2008
I have got a Twenty20 simulation going... not much at the moment since it only simulates one innings, but I've gotten it to sim off of some basic probabilities. I'm working on adding batsmen aggression values as a factor and after that will add bowler aggression values, and the bowling team's aggression (for purposes of field setting). The final thing required will be to have a pacing handler, that'll re-evaluate pacing at the beginning of every over.

Sounds like a lot to do, but most of this will overlap with the OD engine, as well.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 20 2008
I have added batting and bowling skills and aggression as factors, as well as implemented a system wherein bowlers' and batsmen's rhythm and confidence increases based on the result of the delivery. I will work on the pacing system later today, which will include a lot of the code for implementing chases.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 20 2008, Update 2
I have written the pacing algorithm for a team batting first. There are currently 4 pacing algorithms for Twenty20:

Default
Default is to pretty much attack at a high aggression for the batting team and be quite defensive for the fielding team.

Consolidate
This decreases the aggression levels and is called into play when too many wickets have fallen for the batting team, or when the batsmen are scoring really quick for the bowling team.

Advantage
This increases aggression levels from Default, but not a lot. It is called into play when the batsmen have got off to a good start without losing too many wickets or when the bowlers have picked up a few wickets and are hunting for more.

Slog Overs
This pushes batsmen to optimum aggression levels. It is called into play in the last 20% of the overs (last 4 overs for Twenty20) cricket where batsmen are looking to smash everything and the bowlers are trying to keep down the damage.

The pacing is re-evaluated over-to-over. And to simulate a real-world scenario where most batsmen cannot just change gears suddenly, players adjust to the new aggression levels over the span of a couple of overs.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 21 2008
The first version of the Twenty20 engine is finally ready. Still needs some work on pacing issues while chasing and also needs a couple more factors. But it throws a pretty wide range of scores and some close games.

Oh, I just remembered that I haven't really coded intelligent bowling choices... I'll work on that now.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
December 23 2008
I have been tinkering with the Twenty20 engine and have added somewhat intelligent bowlers rotation (although it still leaves a lot to be desired). The things that remain to be added are extras (no balls, wides, free hits, leg byes, byes) and wicket generation.

I will soon be posting a thread where I will be posting results of running simulations on the engine (currently I only have two teams--Australia and India).
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
January 2 2009
Just an update to say not much has changed recently. I started getting into the GUI aspect so that I could start distributing the Twenty20 engine for testing, but ended up spending a lot of time trying to understand WPF. Hopefully this coming semester won't be too busy and I can get this done.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
January 28 2009
Short update to say there have been no updates. But do not stress! WPF has held me up. I am hoping to work on the GUI today a bit and hopefully I will have something out soon for people to test the T20 engine (without the commentary engine).
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 28 2009
Exactly 4 months after, I'm happy to say that I have finally started working on the UI. Took a bit of time to get my hands dirty on WPF but now I'm progressing smoothly. I'm building the database editing pages right now (creating/editing/deleting teams and players). After that I will work on creating a match from the GUI after which point I will be able to hand the EXE out to testers.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 28 2009, Update 2
You can now assign/remove players to and from teams through the UI. It took a while to code up but it is functional now. The following are the other items I want to get through today, all through the UI:

  • Save edited team info
  • Create new team
  • View player details
  • Edit/save player details
  • Create new player
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 28 2009, Update 3 (Screenshots)
Here are a few screenshots of what I've implemented so far, in case you think I'm taking you for a ride!

20090528_1_01.png

Main PCCS window (still under development)

20090528_1_02.png

The teams page (those containers for players work)

20090528_1_03.png

Creating a new team

20090528_1_04.png

Deleting Zimbabwe from international cricket
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 28 2009, Update 4
Integrated the WPF Toolkit DataGrid control for the players page. This saved me a lot of effort as it simply presents a datagrid (similar to Excel), which supports all the normal operations. May consider replacing Team with that, but will leave it like this for the first beta.

Took me a while to integrate DataGrid so I wasn't able to achieve the Create/Delete new player options. This will be done tomorrow and I'll have a few more screenies up.
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 29 2009
The Players section is done. Screenies follow.

20090529_1_01.png

Players page

20090529_1_02.png

Creating a new player

20090529_1_03.png

Editing a player is as easy as double-clicking and modifying

20090529_1_04.png

Lalit Modi deletes players who shun the IPL
 

sohum

Executive member
Joined
Aug 3, 2004
Location
San Francisco, CA
Profile Flag
India
May 29 2009, Update 2
Worked a lot on the Create Match and Lineup Selector pages. The latter took a lot of work, which is probably not evident from the simplicity of the UI (maybe).

20090529_2_01.png

Creating a new match

20090529_2_02.png

Line-up Editing Page

20090529_2_03.png

Sample lineups.... damn Australia has a long batting line-up

Next step is coding up a window for the simulation page and coding a matches page that allows one to view old matches and such.
 
Status
Not open for further replies.

Users who are viewing this thread

Top