As November fires up it's engines, the end line looks exceptionally close, which is good and bad. On one hand, it will be good to see an end to this project, on the other there is nowhere near enough time left!
Here is how the last two weeks went:
- AI. Getting the first two players to try to mark properly has been kind of tough, and I'm not even sure I'm going to fully get it by release either. I've spent about 2 weeks working through some physics/AI/animation issues here, and it's a slow process. When there are problems that don't make sense, you goto to debug the problem. Here, I've had a big problem, as the debugging often freezes up after a little while, restarting Unity and VS are sometimes needed. I'd say in every dev session, this has happened at least 5 times, and it's realistically 10 minutes gone once you finally give up on it, restart everything, get the code back to the same break point. It's also just generally slow to get your head around these issues. You can have a few triggers that might end up affecting a case, and if a certain code doesn't get hit, it could be because of something wrong in 3 different files, so knowing which part is not correct can cause problems. A few big AI issues around contests have been looked at. Right now, the player can decide if they have time to go for a big mark, or just run to a place where the ball will be lower to the ground. If they get there in time they can pause and wait, if they don't get there in time they don't try to jump. It looks pretty good so far, but there are a few really obvious missing entries.
- Animation. I've been meaning to have a little crack at animation editing, and yesterday did some. I had a good AFL like marking animation, but it was too slow, so the player goes from running full speed, to stop, to slowly build up to the jump. To fix this, I duplicated the mark animation, and set the starting point of the animation to be as he's about to lead into the jump. Now he runs toward the contest, and just launches into the jump, it looks and works well. The animation controller allows him to go from idle or running to jumping, and has kicking etc too. So far so good for animation, there is a tonne more to do.
- Physics. I say AI a lot, but really a lot of it is physics. Most bugs are physics bugs not AI bugs right now, like right now when the player completes a mark, they make a crazy looking semi-arc back to where they launched for the mark. This will be easy enough to fix, but there are random crazy looking things everywhere. A big thing I've looked at is timing the player to meet the ball. This is definitely a science, and the problem is a ball approaching really quickly, and a player jumping at the same time, the timing is not quite there for me to perfect this unfortunately, but I have it pretty close now. I've managed to find the players hand object, so part of a mark is getting that hand close enough to the ball object, and claiming it, which I do by making the hands it's parent object. I got the code to a really good place yesterday.
- IOS. I got a mac, and ordered a dev license, so have nothing but a little pain in front of me before I can develop on ipad.
- Other. I did get a couple of other things in. Grass. This has been a pain, and at this point, I think I've ditched it, and gone with my weird looking terrain. One of the big problems is getting the grass short enough. Unitys built in grass looked fine at 1m high (in my game), but when 10cm high got an extremely blotchy field. I found a couple of good examples of better things to try, a tree stripped down to look like grass and then use the tree option on terrain. This worked fine, but again was near impossible to get looking right for low grass. I had a rest on this, and a breakthrough the next day to use an image with just a small height grass, ie lots of space above it. This worked for both methods, but... using the grass terrain, it looked fine from below but just looked awful from above, and chewed through my frame rate once you tried to display the whole field. The tree method wasn't much better. In the meantime I'd been learning a bit about shading the grass to look more realistic tone, and essentially just kept the same field I had, but toned it better, as well as toning some other elements better. This gave me a decent result, and I can still get my high frame rate, so this is pretty much me for now. If the project goes well enough, I may need to invest in a grass asset from the asset store. Other things were minor. Got some advertising boards done, needs to be finished off though.
Overall, the leading for the ball, running, jumping, marking all looks good in a very simple example. Of course AFL is not simple, and thus the big problem I'll have going forward. I was watching an 80's game on TV, and just noticed some things that you really can't get an AI to do, as an example, the ball was kicked to a contest, and two guys wrestled near the target point, as my game will hopefully do. Another couple waited patiently in case it wasn't marked. Then a player from the other direction ran back with the flight and took an amazing mark over the two guys wrestling. This is where AI gets really interesting. Now lets say I see that, and say, yes I guess that is a possible move someone could make. It can't happen every time a player is there, it would spoil the game. Yet it was mark of the day, and what fans really love watching about the sport, the one off big moves. I need to think about this somewhat. Perhaps I could chamber 5 or 6 "exciting" moves, and when a chance to use them comes up, I randomly pick it like 1 of 5 times the situation is possible the player goes for it, and maybe 2 in 3 they stuff it up anyway. Food for thought.
But way back here in current reality, I have a release to work towards, and a lot of much bigger problems. This week I'll be aiming to:
- Add non-jumping marks, eg player just puts there hands up and marks without jumping
- Add spoils. The worse off player should try to spoil the marking player
- Add more physics logic to a mark. Right now it's just proximaty to right hand, but it should be the spot in between both hands, and given I don't have crazy good animations, probably need to accept marks if it's slightly under the hands, but exclude marks if they are too high or low
- Bug fixes in those general areas
- If I get sick of AI/physics, probably time to start working on the player uniforms too, finish off the advertising banners, finish off the stands properly.
Weeks to go!
No comments:
Post a Comment