Nature of Code Midterm
For the past few weeks I’ve actually been spending a lot of my time learning Obj-C’s Cocos2D library and converting what I have been learning in Nature of Code into what Obj-C understands. From understanding NS structuring to working with the the prestablished libraries Cocos2D has to offer, it’s been quite a process to make that transition and not everything has been perfect. Fortunately, Cocos2D does a lot of the work (hence my earlier NoC hw assignments being in Processing) to the point where a lot of what we were doing in class was automated by CCActions and later on the Box2D library which we covered in class.
The issue is that most of my thesis is not really comprised of physics engines, and actually a lot of what I’ve just been wrapping my head around has been structuring. I’ve actually never built a tile-based game, though I’ve looked at the concept through the tile-based final I did for ICM some time back, so I still had a semblance of understanding, but it was a rather roundabout sort of way.
So it’s been a long treck through comprehending the details, reorganizing and iterating on structure as I learn more about the traditional infrastructe for existing games in order to develop my own.
What it looks like currently:
Non-NoC but vital to development, I learned about how cocoas2d organizes menu systems and tweens between animations etc. It has a beautiful structure for naturally creating scenes and building a framework for both generating sound through several frames and having transitional animations automatically down was great in helping me conceptualize less straight forward elements.
The next portion that I’ve been really focusing on is map building, A* Pathfinding, Collisions Detection, intelligence for AI, etc. I’ll be building this out over the next few weeks as well, especially when I get into developing the Chimeras (the main gaming infrastructure and also the most complex – which will be what I will present for the final). I have begun coding the infrastructure but apart from classes with some basic associated functions, nothing is visible. I’m still talking to a few people who’ve worked in Obj-C before for the way to build the best class infrastructure for it.
While collision detections are actually rather beautiful as developed through ‘Titled’, it is sort of a great cheap way to do collision detection. While I’d love to do something more dynamic than tile-based collision detection, for right now it’s been great and for the initial prototype will be what I default to.
A* Pathfinding algorithms was something I’ve never played with before and really helped developing it beyond key-controls and adapting it to touch input. The character animates in all 4 directions (though I don’t have all the sprites which is why it may seem disjointed, but it is grasping left-right-front-back) and they intelligently decipher the most sensible path based on the values given to individual tiles. This is also later in part of developing an eventual minigame which will branch out of the main development of the game. I’ll admit that I’m still going through it and have to
I haven’t applied it to the NPCs yet nor have i created locations of friction entirely though it’s overall easy enough.
With the chimera’s here, right now their movement is simple. They have SpawnPoints which they generate from and track your characters motion and chase them once they are in a leve l of proximity. As detailed above
What I last left off on, and what I will be moving onto next is XML file parsing for loading and saving game information and loading different ‘levels’, character interactions, etc. Right now I have the different sprites and their animations set up within their individual classes
Categorised as: Nature of Code