The Untitled Project v0.2 and source – PS3 & Windows

Here is an update to The Untitled Project.

The world is slightly larger.
There are 500 somethings scattered around for you to collect.
The game now saves everything the first time you start it up and again any time that you find one of the collectibles.
It loads that save file when you return to the game.
Every building now has at minimum one door on the ground floor.
Every building now has an elevator.
There are now skywalks connecting even buildings that are immediately next to each other.
There is a mini map of the city (it doesn’t rotate or zoom or show your position on it or do anything like that yet).
There is a ghost mode added for testing purposes in which you can fly forward with collision detection and gravity turned off (press down to enable/disable it).

I think that is everything aside from some less noticeable tweaks (turning is faster for example and sewer manholes are slightly wider and I removed some unnecessary polygons from the walls).

Download the signed PS3 version
Alternate links

Download the unsigned PS3 version
Alternate links

Download the Windows version + Source Code
Alternate links

I would appreciate it if any other coders would be willing to take a look at why such bad things happen when when I don’t #ifdef out the stuff relating to loading ms3d (Milkshape 3D) files when compiling for PS3. It returns some messages about failed inlining which I’ve never encountered before and don’t know how to correct. I doesn’t help that didn’t write that loader myself (its from the MilkShape 3D Binary Model Viewer) so I’m not particularly familiar with how it works. I’ll give correcting it myself another try later.

If I end up needing to make my own 3d model loader from scratch (in addition to the one I already wrote and am currently using for Wavefront .obj files) does anybody have any recommendations for what format I should use? I need something that supports bone based animation. Just stick with ms3d? Or maybe smd?

The Untitled Project v0.1 and source – PS3 & Windows

[youtube=http://www.youtube.com/watch?v=_sZGYLU180k]

I haven’t been posting as much lately but here is something new I’ve been working on. I know I start too many new things but new is interesting and I assure you that I will eventually be going back and updating That Other Space Shooter, Neo Race, Cubicle Shooter, Neo Tanks and all my other stuff. I’ve actually already made a few improvements to That Other Space Shooter and I’ll probably post that sometime soon.

The Untitled Project is (or will be) a sandbox (massive and open ended streaming city) science fiction (think cyberpunk not space opera) RPG.

The setting and a few other things are different but it is in a way a spiritual successor to what The world Drowns would have been. This time around though I’m just doing all the art assets myself.

Use the left analog stick to move
right analog stick to move
X to jump
left/right on the directional pad to turn on/off a test texture
up/downt on the directional pad to increase/decrease the draw distance

The demo will occasionally freeze when loading. I know why it does this and will be correcting it soon.

Download the signed PS3 version
Alternate links

Download the unsigned PS3 version
Alternate links

Download the Windows version + Source Code
Alternate links

Cubicle Shooter v0.5 and source code – PS3

Another update for Cubicle Shooter.

Notable changes:
Improved frame rate.
The enemy count has been raised from 25 to 100.
Added movable chairs.
Added a loading screen.
Added running. Just hold down the left analog stick well moving forward to enable it. The camera does a nice wobble from side to side when your running.
Added camera zoom. Hold down L1 to enable the scope. Turning speed is a bit slower when zoomed in which makes it easier to aim at things in the distance.
Added a little bit of momentum / smoothing on the camera rotation. Its faster and more responsive then it is in Killzone 2 but it enough to make it feel smoother and it makes it a bit easier to make slight aiming adjustments.
Increased rate of fire again.
Corrected the width of the 2D elements (the on screen text and the reticule) to take into account the screens aspect ratio. The scope for the newly added camera zoom disregards this and stretches to fit the screen.
Once again game saving/loading has been updated to work with the new additions so your old game save wont work correctly.
By holding down triangle you can split the screen in two with the bottom half displaying whats behind you. Its a feature that I don’t really intend to leave it but its a test and a small first step towards split screen multiplayer.

Controls:
Move – Left analog stick
Run – L3
Aim – Right analog stick
Shoot – R1
Zoom – L1
Jump – X
Save – Select
Load – Start
split screen backwards view – Triangle

Download the PS3 version
Alternate links

Download the Source Code
Alternate links

Neo Tanks v0.1 and source code – PS3 & Windows

[youtube=http://www.youtube.com/watch?v=TyDXZM1uoKs]

Here is an update/remake of that tank thing I posted a few days ago. Now you can take control of a randomly selected tank but its still at this point in time primarily a glorified screensaver. The gameplay is mostly an afterthought.

I want to thank Themaister for pointing out what I was doing wrong yesterday with TGA loading and PuppetMaster for reposting my request for guidance on the psx-scene forum. As a result of your awesomeness I will never need to use those self made toif files ever again.

PS3 Controls:
Move – Left analog stick
Aim – Right analog stick
Shoot – R1

PC Controls:
Move – WASD
Aim – Mouse move
Shoot – Space

Download the PS3 version
Alternate links

Download the Windows version
Alternate links

Download the Source Code
Alternate links

Loading TGA files in C++ for use with OpenGL

Among the many samples and examples in the leaked PS3 SDK there is a function for recording screenshots in tga format. After finding it I decided to simply rewrite it to essentially work in reverse so that I could load TGA files and use them as textures for PSGL games. It was simple to do and works beautifully on PC. But for some reason it fails to correctly read the width and height of the images when I run it on PS3. It seems to work fine if I hard code in what width and height to use but it refuses to correctly read that from the tga files despite it doing so on Windows. I’ve wasted away the last two days trying to get it to work and have failed to do so. Can anyone see anything wrong with the bellow source code that could explain the failure?


GLuint loadtga(char* filename,bool mipmap){

unsigned char header[12] = { 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
unsigned char bpp = 32;
unsigned char id = 8;
unsigned short width;
unsigned short height;
unsigned char *pPixels = NULL;
FILE *fp = NULL;

fp = fopen(filename,"r");

fread(header,sizeof(unsigned char),12,fp);
fread(&width,sizeof(unsigned short),1,fp);
fread(&height,sizeof(unsigned short),1,fp);
fread(&bpp,sizeof(unsigned char),1,fp);
fread(&id,sizeof(unsigned char),1,fp);

pPixels = new unsigned char[width * height * 4];
fread(pPixels, 4, width * height, fp);
fclose(fp);

GLuint texName;
glPixelStorei(GL_UNPACK_ALIGNMENT,1);
glGenTextures(1,&texName);
glBindTexture(GL_TEXTURE_2D,texName);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_REPEAT);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_REPEAT);
if(mipmap==0){
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
}
if(mipmap==1){
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR);
glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR_MIPMAP_LINEAR);
gluBuild2DMipmaps(GL_TEXTURE_2D,GL_RGBA,width,height,
GL_BGRA,GL_UNSIGNED_BYTE,pPixels);
}
glTexImage2D(GL_TEXTURE_2D,0,GL_RGBA,width,height,
0,GL_BGRA,GL_UNSIGNED_BYTE,pPixels);

delete pPixels;

return texName;

}

More then getting it to work I just really want to know WHY it isn’t working already.

Tank demos and source code – Windows

Here is some old stuff I put together ages ago back when I was still using Dark Basic Pro. Haters gonna hate but I still think DBPro is pretty great and fills a nice niche for noobs that want more control then they would get from a drag and drop interface but aren’t ready to learn C++. Although I’ll confess that Unity 3D has become a totally viable if not superior alternative for that. But back on subject I think I may have intended this to become one at some point but its not a game. its just a sort of animation with two AI armies of tanks fighting. The source code for everything is included for anyone that wants it.

Download the Windows version + source code
Alternate links

Cascade Beneath v0.1 and source code – PS3

[youtube=http://www.youtube.com/watch?v=pTSigEDRxEU]

Full disclosure: The above YouTube video is a recording of the game running on PC and not PS3. The game is identical on PS3 though.

Cascade Beneath is a simple clone of the equally simple game Fall Down. Use the left analog stick to move left and right and try to keep from getting pushed off the top of the screen for as long as possible.

Download the PS3 version
Alternate links

Download the PS3 version’s Source Code
Alternate links

Cubicle Shooter v0.4 and source code – PS3

[youtube=http://www.youtube.com/watch?v=OuagoukDEhM]

Another updated version of Cubicle Shooter.

As an added bonus having this installed will allow the text (including your score and high score) to load and be correctly displayed on screen for Dont Get Crushed v0.1.

Notable changes:
Improved textures for enemies.
Enemies are now animated.
Enemies die when shot.
Enemies are infinitely re-spawning.
There is now a textured and deformable ground (this differs from the destructible walls and is instead more reminiscent of the ground deformation in fracture)
The debug text has been replaced with larger and more legible sprite based text
The rate of fire has been doubled
The maximum number of cuboids that walls can be sub divided into has been doubled
Game saving and loading has once again been updated to reflect the changes

Performance:
The games performance has gotten both better and worse. The load time is significantly longer (this is largely to blame on the textures) and the starting frame rate is lower (the ground layer is mostly to blame for this). But on the upside I have gotten things running more efficiently especially the destructible walls and the frame rate doesn’t take that harsh drop around the 2700 cuboid mark anymore. so you can break apart the walls more now before the frame rate becomes unbearable.

Controls:
Move – Left analog stick
Aim – Right analog stick
Shooter – R1
Jump – X
Save – Select
Load – Start

Download the PS3 version
Alternate links

Download the PS3 version’s Source Code
Alternate links

Dont Get Crushed v0.1 and source code – PS3

Don’t Get Crushed is a PS3 port/remake of my previously released Wii game of the same name.

Use the left analog stick to move the grey ball left or right and avoid the other balls as they bounce across the screen. If you get crushed under one of the bouncing balls then its game over and your score is reset to zero. Your high score is automatically saved to your hard drive.

Download the PS3 version
Alternate links

Download the PS3 version’s Source Code
Alternate links

Tick Tock Car Race and source code – Windows

So here is what I put together for the SDLTutorials.com car contest. Its pre compiled for windows but includes the sorce code so you should be able to get it going on any other platform with SDL support. Its a bit of a mess but its functional and complete. Its looking like the deadline will likely be extended so I might go back and fix it up and add some better commenting.

Either way I’ll port it to Wii sooner or later. Probably later rather then sooner though. I want to do a quick port/remake of Don’t Get Crushed for PS3, then I want to get the demo for The Prophecy complete which I have been repeatedly intending to do and then delaying, finally I really want to finish some things in Cubicle Shooter and by the time I finally finish those three things I’ll probably have seen something shiny to spend a decade chasing. Yay procrastination.

The music used in the game is Tarmac by et_.

Download the Windows version and source code
Alternate links