VDEngine (DirectX, C++, Win32)
by Varkalas D`Lonovan



TODO List
~~~~~~~~~

* refine the ability to test a map out (no errors, and uses current map)
* Item Editor - usable, weapon, accessory, quest
* Item Editor - (later) use a sprite sheet like in Object Editor, and another display next to the list
* Item Editor - (much later) have tabs for item types
* NPC Editor - use a sprite sheet like in Object Editor (the selection should cover the whole width of the sheet)
* Creature Editor - image, stats, A.I., potential items, we'll set reloadItems value to TRUE once we save in Item Editor
                    and VDEngine will reupdate the list (like what happens with NPC Editor and Map Editor)
* alternative to clicking "Remove <Item><Object><etc>" see if user presses Delete key
* Object Editor - we may want to add items to objects (potential containers)
* CreateTexture functions, ItemEditor & NPCEditor & maybe others are nearly the same (different source rectangle
  dimensions for different sized textures)
* MAYBE: change the new area tile to another section in the editor "NEW AREA" that will insert
  a new area provided with the datawhen user creates a new area, also draw some sort of indication
  of this new area on the map
* MAYBE: setup a swap chain system for rendering the engine
* ensure copy constructors are in place
* implement battle mode
* set it up so that no matter what resolution we use, the sprites stay the
  same size -- I guess that means changing internal resolution of the textures
  somehow (maybe presentation parameters... back buffer stuff??)
* change to unicode
* Implement/add sound
* Use something like Live or FruityLoops and create music
* Implement/add music
* Game Options (FINAL STEP)
* OpenGL (optional)
* NOTE: Maximum texture height = 8192 <- likely depends on graphics card capabilities

Constant TODOs
~~~~~~~~~~~~~~

* Alpha Testing:  Look for bugs and new functionality possibilities.
* Memory Leaks:  Don't forget to free memory if an error produces.
* Rendering Speed:  Optimize the rendering process.
* Computational Speed:  Minimize the use of loops and function calls.
* Cleaning:  Check for crappy abstract solutions and make them more understandable & concise.
* TODOs:  Do them.
* Comments:  Make sure all function comments have proper #params and #returns.



*************
* Main Loop *
*************

(wiki)
check for user input
run AI
move enemies
resolve collisions
draw graphics
play sounds

(one version)
Get elapsed time
Handle lost/reset graphics devices
Get player input
Perform A.I. and game logic
Handle sound
Render
Synchronize display

**************
* Data Types *
**************

		signed						unsigned			size
char	-128 to 127					0 to 255			1 byte
short	-32768 to 32767				0 to 65535			2 bytes
int		-2147483648 to 2147483647	0 to 4294967295		4 bytes
long	-2147483648 to 2147483647	0 to 4294967295		4 bytes

**********************
* Important Keywords *
**********************

private:	accessed only by that class
public:		accessed by all code
protected:	accessed by that class and its subclasses
inline:		calls to an inline function will be replaced with the actual code (thus making it faster, but taking up more space)
virtual:	used to denote polymorphism (use on destructors with classes that have subclasses!! otherwise, subclass's destructors won't get called)

class A, class B : A
both have functions X
if function X is called from a B object, it still uses A's function X
unless!  we have class A make it a virtual X

*********************
* Memory Management *
*********************

What's the difference in speed and memory allocation (RAM, hard disk, etc.)
with the following two instances:

1.  Creature aCreature;
2.  Creature *aCreature = new Creature();

1.  An instance
2.  This is allocated, uses constructor/destructor, and needs to be deallocated