Sign in to follow this  
Erwan22

Soccer simulator

Recommended Posts

Hi everyone,

 

I'm making a soccer match simulator where each player has a unique attribute (or skill) which is a value between 1 and 20. A player can play as a goalkeeper, a defender, a midlfielder or a forward. In my program, at some moment, there's a battle between a player from the attacking team and the goalkeeper from the defending team. The result of this battle determines if a goal is scored or not. But, first of all, I need to compute which player from the attacking team is going to shot on goal. So, I would like to have some advise about the way to select the player who's going to take the shot. I've already thought about a weighted random generator where each player gets a weight depending on its position on the field but there're maybe other solutions.

Share this post


Link to post
Share on other sites
You should think up some rules for who takes the shot, then try them out and refine them based on whether or not the game feels good.

If weighted random feels fun and plays well, then stick with that. Only bother with more complicated solutions if you really need them.

Some basic play-testing should reveal weaknesses in whatever approach you have, and from there you can work to address those issues specifically. Specificity is good because it's very hard to design a solution to a vague problem.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this