River Nyxx

A development blog for FFVI3D, the fan-made Final Fantasy VI remake in 3D.

平成19年12月11日火曜日

What's difficult in game programming?

IMHO, the "game-mechanics" portion is the EASY stuff (it's just simple math..). Especially in regards to an RPG type game, where the most complicated math you have to deal with is multiplying or dividing by 4, heh heh Regardless tho, I already have a good portion of that done already, but I decided I wanted something more visual for me to debug with, so I'm trying to get a simple viewable version of the game functioning to view things with, instead of lurking in the debugger, sifting thru variables;;

I've actually found that the hardest parts of programming the game are:

1) The 3d math for ... well, anything 3d, really. Heh. dotProducts, crossProducts, rotational trig, quaternions... a little more advanced than the [generally] adding/subtracting/multiplying/dividing required by the calculations of stats/damages/etc.. Really, mathematically speaking, I'm pretty confident that FFVI is incredibly simple.

2) The "behind-the-scenes" classes & objects that allow the game to run properly, and efficiently, fully encapsulated in their own little black boxes (or at least, that's how I like my code to be...). Things such as a game state manager (it changes the rendering mode, input allowed, etc.. depending on the state you're in, such as title screen, world map, battle, town, menu, etc..), an input stack with bindable keys (so when you press a keyboard key, it checks to see if the user has changed the use of the key, then asks a stack of items what to do with it, and each item in the stack checks to see if they can use it-- if not, they pass it on to the next item in the stack), and finite state machines (typically for AI, you change variables in each "machine" as the game runs, and the machine calls an "update" every frame, and calculates what it'll do based on how the variables in it have changed).

I'm willing to go into more detail about how these things work, if anybody's interested, but I just thought I'd point out [what I consider to be] some of the more complicated parts of programming a game.

The lighting on the model in the world currently is screwed, because I don't have lights in the world yet, and the default brightness for the model & the terrain are completely different values. So Terra appears to be -way- too dark right now. I'll get around to those lights later.. probably much later- but I might change the default brightness level, cause that's been bugging me..

0 件のコメント:

コメントを投稿

登録 コメントの投稿 [Atom]

<< ホーム