Global Game Jam..

Over 30h without sleep.. and loads things to do..

tired.. no exhausted.. but excited.. we almost reached 2nd stage for a game development.. all relationships, behaviours are set up and ready to go.. now.. level modelling tweaking and balancing game play..
it is kind a hard to manage and catch up with 8people team.. really. but we are doing pretty well!

pictures and demo tomorrow!

Day 11: Well I have done the textures

I cannot admit.. I wanted to finish couple more things..
well so now we have space to render divided to quads.. increase performance, texture, lighting, info about graphic card and memory left on card.

Now I am ready to do game logic.

what should I start with?
random placing objects on a map?
word!

I need to think of a build name for this project.. any suggestions?

Day 10: Height Map

I am satisfied with that height map – no multi textures, blending, water or even trees.. I need to concentrate on logic now, polishing details will be last thing.

plan for today/tomorrow.

picking + adding objects on the map..

good luck Luke..

thanks Luke.

edit:
ok 2 more thing left before I ll be ready to go with picking and objects,

1. need to set up camera in 45 degree
2. I need to think of optimisation.. some sort of quad tree or so..

Day 9: Motivation Kick

I need to figured out what I want/have to do with University and work.. need to find a balance,

Today after chat with my Program Leader I have decided to start going forward and developing stuff that I actually will need and polish small things at the end, that’s why today I have managed to create 1024 by 1024 grid map which will be base for my 3D hight map based strategy game, decisions has been made. nothing else left than developing..

Element Covered Tonight:

  • movement class
  • terrain class
  • grid helper

Tomorrow – Height map.

Day7: Quick overview

Just quick overview for end of day 7.

  • Input handler gets mouse position and escape button
  • Drawing 3D maya objects
  • Sound player
  • drawing 2D over 3d object
  • Font engine – well subsystem but..
  • High precision timing
  • FPS
  • CPU usage
  • Lighting

Still loads left to do but as for one week it is fairly enough!

Maya Converter Created v 0.1

I made this!

I have developed simple file that converts .obj file format exported from Maya to format that can be in easy way imported to my framework, processed and displayed! current version allows to import whole object with texture! This simple but really flexible script allows me to import any model exported to .Obj to the framework/engine.. how cool is that?!

some code below:

loading file and counts
[cc lang=”cpp”]
ifstream fin;
char input;

// counts.
vertexCount = 0;
textureCount = 0;
normalCount = 0;
faceCount = 0;

// open the file.
fin.open(filename);

// was successful in opening the file?
if(fin.fail() == true)
{
return false;
}

// beginning of the vertices section.
fin.get(input);
while(input != ‘v’)
{
// remainder of the line.
while(input != ‘\n’)
{
fin.get(input);
}

// start reading next line.
fin.get(input);
}

// vertices, texture coord, and normals counts
while(input == ‘v’)
{
fin.get(input);

if(input == ‘ ‘) { vertexCount++; }
if(input == ‘t’) { textureCount++; }
if(input == ‘n’) { normalCount++; }

// the line.
while(input != ‘\n’)
{
fin.get(input);
}

fin.get(input);
}

// number faces.
while(!fin.eof())
{
if(input == ‘f’) { faceCount++; }

// the line.
while(input != ‘\n’)
{
fin.get(input);
}

fin.get(input);
}

// Close the file.
fin.close();
[/cc]

now file processor:
[cc lang=”cpp”]
VertexType *vertices, *texcoords, *normals;
FaceType *faces;
ifstream fin;
int vertexIndex, texcoordIndex, normalIndex, faceIndex, vIndex, tIndex, nIndex;
char input, input2;
ofstream fout;

// Init the data structures.
vertices = new VertexType[vertexCount];
if(!vertices)
{
return false;
}

texcoords = new VertexType[textureCount];
if(!texcoords)
{
return false;
}

normals = new VertexType[normalCount];
if(!normals)
{
return false;
}

faces = new FaceType[faceCount];
if(!faces)
{
return false;
}

// the indexes.
vertexIndex = 0;
texcoordIndex = 0;
normalIndex = 0;
faceIndex = 0;

// open the file.
fin.open(filename);

// opened?
if(fin.fail() == true)
{
return false;
}

// parse of the vertices section.
fin.get(input);
while(input != ‘v’)
{
// the line.
while(input != ‘\n’)
{
fin.get(input);
}

// read the next line.
fin.get(input);
}

// Read vertices, texture coordinates, and normals into the data structures.
// + convert to left hand coordinate system.
while(input == ‘v’)
{
fin.get(input);

// read in the vertices.
if(input == ‘ ‘)
{
fin >> vertices[vertexIndex].x >> vertices[vertexIndex].y >> vertices[vertexIndex].z;

// Invert the Z vertex to left hand system.
vertices[vertexIndex].z = vertices[vertexIndex].z * -1.0f;

vertexIndex++;
}

// Read texture coords.
if(input == ‘t’)
{
fin >> texcoords[texcoordIndex].x >> texcoords[texcoordIndex].y;

// change the V texture coordinates to left hand system.
texcoords[texcoordIndex].y = 1.0f – texcoords[texcoordIndex].y;

texcoordIndex++;
}

// read normals.
if(input == ‘n’)
{
fin >> normals[normalIndex].x >> normals[normalIndex].y >> normals[normalIndex].z;

// normal to left hand system.
normals[normalIndex].z = normals[normalIndex].z * -1.0f;

normalIndex++;
}

// read line.
while(input != ‘\n’)
{
fin.get(input);
}

// next line.
fin.get(input);
}

//number of face indexes.
while(!fin.eof())
{
if(input == ‘f’)
{
// Read backwards – to a left hand system.
fin >> faces[faceIndex].vIndex3 >> input2 >> faces[faceIndex].tIndex3 >> input2 >> faces[faceIndex].nIndex3
>> faces[faceIndex].vIndex2 >> input2 >> faces[faceIndex].tIndex2 >> input2 >> faces[faceIndex].nIndex2
>> faces[faceIndex].vIndex1 >> input2 >> faces[faceIndex].tIndex1 >> input2 >> faces[faceIndex].nIndex1;
faceIndex++;
}

// the line.
while(input != ‘\n’)
{
fin.get(input);
}

// next line.
fin.get(input);
}

// close.
fin.close();

// output file.
fout.open(“model.txt”);

// header.
fout << "Vertex Count: " << (faceCount * 3) << endl; fout << endl; fout << "Data:" << endl; fout << endl; for(int i=0; i