Pathing is kind of hard

A few things have come up:
Firstly, the game has a job system. This means that we can get certain players to do what we want them to do on a certain play. An example is a wide reciever on a slant. There’s not really any way to get this behaviour except to program it into him as a job. There are a few really hard issues with this, such as when and how to let more procedural coding take over. For example: if you have a guard pull, how do you code it so that he never does anything stupid (unless stupid is the goal) such as not engaging a man who’s engaging him and instead trying to move towards his goal.
Those are all hard problems. I’m dealing with an easier problem: how do you make the players run to a set of spots? Right now the solution I have is to, in the playcall file, set 16 spots on the field for every player. Each player has space reserved for these spots, although only a small number of players will use them for their job.
One of the positions that uses them all the time is wide reciever when they run routes. As of right now, I have them move to spot[0], and when they get really close, then they move to spot[1], and as of right now I only have the ability to move to two spots.
I think the solution is to also give players 16 Boolean variables that start out as false and then get made true as they go along. The other solution I’ve been contemplating is to have an index integer, which increments by one every time the reciever (or any player using his pathing) gets close to the spot.
The problem with the bool method is that I need more messy logic for which spot to go to next. I can’t find any problem with the integer “tracker”, so I’ll go with that and figure out the horrible consequences later.

Honestly, once I get that system up and running, which shouldn’t be too hard, it doesn’t even require me to change my text file system, I can truly focus on getting more jobs in and done. Once more jobs are in and done, I can focus on the next step, which could be any number of things that I talked about in the previous two posts.

Picture time: I changed the defense from yellow to black, I’m surprised how much I care about such a trivial detail.

takingThisOneForFun

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s