Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to write logic for simulation a cricket match

 
shivang sarawagi
Ranch Hand
Posts: 157
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to develop cricket game which will simulate a match ball by ball depending on player stats (bowler's skill/experience, batsman's skill/exp, fielding/wicketkeeping stats, so on...) and other related variables. Plus user can provide inputs during the match & the result should alter according to the user inputs. The match is purely text based no graphics. I am to develop this in java.

For this I am not sure what do I need to learn to write this kind of logic. I read somewhere that Finite State Machine or AI might come in handy. I just need a little guidance. Can anyone help Thanks
 
fred rosenberger
lowercase baba
Bartender
Posts: 12081
29
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
as always..

1) turn off your computer
2) get some paper, pencils, and erasers
3) draw pictures. sketch things out. figure out how YOU would do it if all you had were the above tools (and possible some dice to generate random numbers).

When you can do the above, and explain it to a ten year old child, THEN start thinking about how to do it in java.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic