Complexity Ensues. Frustration… Rising…

Argh. Day started off well enough. Ran some errands first thing in the morning, settled in to work a bit before lunch time. Fixed the previous night’s glitches pretty easily with a fresh head and a night of sleep to think on it, then started working on the next task I’d mentioned in my last blog, transfering routes that were still being entered. Had an idea, threw the code together, then flailed for a bit at a few glitches. I’d worked through lunch, just threw together a sammich and ate it at the computer, so I took a break then, watched an episode of Farscape, came back and found the problem easily. Started on the next task, exiting vehicles. This one was gonna use a lot of code from the vehicles, and I was expecting it to be straightforward. And it was – up to a point.

As an aside, if I’ve learned one thing so far in this project, it’s the importance of planning out the code more before diving in. Of course, I’ve learned this lesson the hard way before, but once again, I convinced myself that it would all be easy enough that more rigorous planning were unnecessary; the lack of same has been a contributing factor in most of the glitches that keep coming up. Anyway, back to the point…

There was one major difference I’d glossed over in my limited planning between getting into a vehicle and getting out. When getting in, the raw input path leads into the vehicle. Since actually hitting the vehicle would cause the path to abort, I implemented a system that tracked and stored collision data as the path was input. Then, if the last node was determined to be entering the vehicle, I could walk step back through the path dropping nodes until I arrived at the one just before the collision would’ve happened. Worked like a charm.

Doesn’t work at all for getting out of the vehicle. I was thinking I would just step forward the same way, until it stopped colliding with the car, on exiting from the vehicle. The problem being… the vehicle was not there at the time the path was drawn. So it’s not in path data.

Three main solutions I can see: one, crawl forward performing the collision checks all at once to find the first node that is outside the vehicle, and go there; two, initially disable rendering and have the character exiting the vehicle follow it’s path in a ghost state where it ignores collisions; only when it stops colliding, turn off ghost mode and appear, following the rest of the path normally; or three, insert a “ghost” collider for the car at the position it will be in when the LeaveCar action is executed, which does not block objects moving through it, but will register in the path collision checks, allowing my original idea of stepping through until the collision ends to work.

The last seems like the best, but there’s another hitch that I’ve been not thinking about – there might be other objects in the way. Do I cancel the route if there is another collision along the path? By this point I would already have ejected the passenger and replaced the car to a parked version again, so I’ll have to pick a place they can be put around the car that is not occupied. That’s not too terrible – I was going to be implementing that anyway, for the case where you give the exit car command when the car is already stationary, without any future path data to worry about. But if there is more path to follow, and the available space I put the passenger in is on the opposite side of the car from that path, they’ll promptly try to walk through the car, hit it, and cancel their route. Do I implement a full conventional pathfinding system to let the character find their way around the car and to the beginning of the input path they’re trying to follow? That seems unacceptable, given that manual pathing is one of the key gameplay elements.

I guess I’m going, for now, to go with the cancel in that case; #3 for the first problem – ghost car for colliding post-exit paths – using the open-space solver with a bias towards the side of the car where the first valid pathnode sits. If it’s forced to put them on the other side of the car, the route will just be cancelled by the collision and the player will have to redraw that route. In principle this will just become an aspect of the game that players will have to consider – long, elaborate routes are not going to be required anyway, but an advanced technique – but it might prove to be an element of frustration for the players that requries a better resolution later.

Oh well, enough winging about the problem. Onward!

Did you like this? Share it:
Posted in Geomys Games | Tagged , , | Leave a comment

Obstacles and Vehicles

After writing the last blog entry, I came up with a different approach than I originally had in mind for obstacle avoidance; got it knocked out yesterday with little difficulty, though overall the day still felt unproductive compared to Monday and Tuesday. Started working out the plan for driving, and that has turned out to be more complex than I had anticipated. The transition into the vehicle is working now, though I can’t help feeling like I’ve mucked up the code a bit by not having thought it out more completely up-front.

Where it stands now, you can path a character to a vehicle, and route the vehicle on after that; the set route transfers from the character to the vehicle, and all works quite smoothly. Got some code that’s implemented but not tested yet so it will be ready to handle passengers, when I get to implementing them, but first, I need to deal with the edge case of new path data that is still being entered when the actual transition into the vehicle occurs. Currently, an uncommitted path is simply cancelled, but it’s already clear that’s going to be frustrating to players, so despite the work involved, gonna have to rework and extend the code to allow it to carry over as well. Other than that, the main vehicle-related feature left to implement is exiting vehicles, but the same functions that handle entering vehicles should handle the reverse case with the same ease.

A bit disappointed with the progress since the last blog update; I think I’d let myself get cocky after the first two days, and I know I’d initially underestimated the complexity of the features I’ve implemented in the last two. Still, I think I’ll be able to have the playable prototype done by the end of the weekend, just in time for my free trail period with unity to expire early next week. After vehicles are finished up, the next big task is getting animations in to replace the primitive placeholders there now; then the baked-in pathing data for AI characters.

I’m starting to think the highly modular approach I took to the script designs may have been a mistake; it’s getting a bit complex as more features layer in over more features, and they’ve started becoming more interconnected than I’d ideally like, but there are still benefits that I think will pay off later; the Movable behavior, for example, will work the same way for the Autorouter behavior script I’ll implement for the AI as they do for the plain Router behavior now, and Selectable and Notable are already getting some use independent of the others.

Did some more testing on my iPhone, and the SelectionManager is going to need some tweaking; the way drag detection is handled now is too sensitive, and is interfering with identification of taps when touching instead of using the mouse.

With luck, by this time tomorrow the vehicle code will be 100% complete and I’ll be working on getting some animated sprites going. Would really like to have the animations working and the AI control scripts finished by Saturday night, so I’ve got all day Sunday to finish the misc. other bits, find and fix bugs, and generally polish the prototype up a bit.

Hmm. Put like that, I’m wondering if having the prototype finished by the end of Sunday isn’t still a bit optimistic, but if I don’t make it the goal, it’s guaranteed not to happen, so I’m just going to give it my best.

Did you like this? Share it:
Posted in Geomys Games, Uncategorized | Tagged , , , | Leave a comment

Another excellent day of progress!

The wave of awesome I caught yesterday continued, knocked out working prototypes of 4 of the main behavior modules for my current Unity game project today. Selectable works with a custom SelectionManager (which needs a new name, as it’s more of a general touch input manager now) to handle focus and a selection reticule; Notable allows custom notification icons to be attached to the objects with a quick function call; Movable allows objects to follow a vector path at a configurable speed; and the tricky one, Routable provides the means to create paths for their neighbor Movable.

Still in prototype mode, so trying not to worry about performance, but so far that’s been easy, as there’ve been no performance problems yet, despite liberal use of SendMessage to objects with many components. Most of the heavy lifting and continuous work happens in the SelectionManager script, which probably helps. Some of the code is just replicating things Unity could do for me – but unity’s methods are mouse-only, while mine are set up to work with the mouse or with touches on the iPhone.

On the agenda for tomorrow: implementing a system for imposing constraints and obstacles that are applied to Routable’s paths. That one’s a biggie, and I’ll be surprised if I finish it quickly, though I’ve got my game plan for how to tackle it already in mind, and it shouldn’t be too big a problem. From there it’s on to vehicles, and got a plan for the Drivable behavior that I expect will make that one go pretty easily.

The goal of having the prototype playable in a week isn’t seeming so overly ambitious¬† as I initially thought; well on track so far to do it!

Did you like this? Share it:
Posted in Geomys Games | Tagged , , | Leave a comment

Prototype underway!

Putting together a prototype of my next game project for the iPhone now. Had two primary work goals for today: getting myself set up to draw sprites in Unity (which isn’t hard, but it’s also a bit against the grain of it’s design), and setting up a system to draw paths with a finger or the mouse. Finished the first by lunch and the second before dinner, so by the time my brain was warmed up and I entered my evening shift, where brain function is optimal, I was into gravy time. Was inspired to slash half of the code section of my design doc and replace it with a much smarter and more flexible approach, which I think will save me a good bit of time in the long run; got the first manager and behavior scripts for the new design implemented as well, and all of it tested in web and iphone builds. In between all that, also improved my design notes for my mascot and logo, with some coaching from a friend who has extensive experience with such things. She will be doing the concept art and final assets for the company logo, assuming I can afford her globe-trotting, award-winning skills – and she can find time to squeeze me in!

For sprites in the prototype game, I’m trying out the free SpriteManager classes, developed and released free to the community by Above and Beyond Software. So far it’s lived up to expectations, but I’m looking at their new commercial plugin version, SpriteManager 2, which offers a lot more robust features, or the similar 2D Toolkit, which is slightly less robust but also quite a bit cheaper. Also considering trying out UniTile, from Mudloop, which provides robust tilemap rendering as well as an in-unity tilemap editor, which looks pretty slick. Since my tilemaps will be single-screens and few in number, I may just end up having an artist paint over the finished tilemaps, giving me more attractive and seamless screens. Artist seems to indicate it would take about the same time to do the screens I need that way as to do the complete tileset, it’d greatly reduce the rendering load, and I could still use tilemap metadata, so not seeing any real downside at present.

Continued talking to a couple of other artists I’d contacted Friday and Saturday. One that I’m really hoping to work with on the current project is unfortunately unavailable in December, when I’d ideally have wanted him, but I should be able to get the prototype to the point that I can confidently deliver final asset templates and specs in time to at least get started on the assets before then;¬† it might even be possible to get them finalized by the end of the month, but I’m not holding my breath on that happening.

All told, I’d say it was a good day.

Did you like this? Share it:
Posted in Geomys Games | Tagged , , , , | Leave a comment

The hunt for artists and other things I’ve been putting off

Finally started looking around for artists to collaborate with on my next project. Was hoping to start by finding someone willing to produce the extremely simple assets for the asteroids game, which I will not be making any money from; logically, seems like a natural extension of it’s purpose as a learning project, since I have not dealt directly with contracting out art assets before. I’m beginning to think this was an unreasonable expectation on my part, though.

There are plenty of quality artists out there looking for paid work, and there are plenty of artists who seem willing to work for free, at least on a limited basis, but I’m not sure there is a lot of intersection between those two groups. From reading their posts offering services, I get the impression many have been burned by daydreamers promising future payment and/or royalties for work done now, only to find it never materializes. Can’t say I blame them, frankly. So where does that leave Roid Rage?

I could just pay someone to do the work – the game only requires a handful of low-poly models, and only one, the ship, requires any sort of animation – and even that is an unrigged animation, just the ship fragmenting into parts when destroyed! The rest of the models are just asteroids – pleasingly irregular shapes I could pretty easily make myself, and am really not inclined to pay someone else to do, even if it will save me the frustration of diddling about in the unfamiliar realms of Blender or Maya. The rest is incredibly simple graphic design work, made even simpler by the incredibly low standards of this not-for-prime-time project.

The only other options are doing it myself, or just leaving the game as-is and focusing on my next project. Doing it myself would take a couple of days, and I can’t shake the feeling that it would not be a couple of days well-spent; even a relatively inexperienced graphic designer could likely make something more attractive in a couple of hours than I could in a day. Not making a decision yet, as I have not been looking for artists long, but if I don’t see some positive responses soon, I may just leave Roid Rage behind and focus on finishing the design document and coding up a prototype for my next project.

Taking my scattered notes and thoughts on that next project and starting to flesh them out into a design document occupied most of my day. The asset list is looking to be a fair bit longer than I was imagining in my head when I came up with the idea, but still fairly short and I think manageable. My enthusiasm for the idea has also grown as I fleshed out the mechanics of play; definitely potential in the idea.

There’s also a whole list of other things I need. Waiting to hear back from a few people – friends and other – about the company logo and mascot designs – which I’m keeping separate and distinct from the game asset production. Since I’ll be living with the company logo and mascot for a while, I’m trying to get the highest quality work I can afford. There’s also the matter of my website; need to update the layout of my wordpress blog, create pages for new projects, and will eventually want to move the blog itself off to geomys.com/blog or blog.geomys.com to make room for a professionally-designed home page that’s focused more on promoting and marketing my games and less about … well, me driveling off about whatever. And lastly, I’ve worked out all the steps I’ll need to take on the business end to start selling my games, but am still holding off on pulling the trigger there. I’m sure there’s other things I’m forgetting, as well. Probably some big ones.

Ah well. Press on!

Did you like this? Share it:
Posted in Geomys Games | Tagged , , , , | Leave a comment