Posts Tagged ‘C#’

27Jun

So here is my solar system shader. The description is mostly all the in the video.

Features: models, tie intercepter, environment mapping, bump mapping, clouds, cell shading, per pixel lighting, multi-pass lighting and all of this controlled with the xbox 360 controller.

Here is the HLSL file: the shader 🙂

Share
26Jun

Here is a screen shot from my ray tracer. I have 2 triangle in the background (lighting isn’t very awesome on them), 2 spheres with specular lighting and shadows working.  I am going to go back and add reflection and refraction one day. Like any other ray tracer this one works like this:

for each pixel

calculate ray, check if it intersects with any object

if it does find the color of that point on object determined  by light position and whether it is behind something or not

else use background color.

So as far as the code… This is writen in C++ using almost completely C conventions. I am using OpenGL (a pretty early version). Its about 70% C 30% C++. Prior to writing this program my knowledge was pretty limited. I am going to fix this and make it 100% C style. For now though I am being a little lazy.

Here is the source. Not the most elegant C code, but it is easy to follow and it is CLEAN, and I think commented even. Also the project folder is a little messy. If you open the solution it looks pretty clean though.

Share
29Apr

So recently the Game Development Club at SJSU had one of it’s regular programming competitions. This one was based on the Tower Defense genre. Edgar and myself decided to do it on the Zune. This was rather easy in comparison to other things I have been using lately (namely opengl haha). It is a pretty simple game. more of a tech demo/challenge to see how fast we could actually make a functional game. The game has 5 or 6 levels. We used the some code off of the creators club website. For the most part the code is pretty thrown together. It was more about seeing how fast we could actually do this.  Three days of working on it seems like a reasonable amount of time (especially since two of those days were pretty laid back).  I will post a video or something soon probably. Below is the installer for the Zune, and the source code for the game. I think I will modify the game to make levels dynamically generated and infinite. I could see this being a score based game (like tetris or something). There is not a ton of fun to be had right now. This is my first entry into the Zune world :)! I still need to post my blog on grid[z] for facebook. That game is basically done. It has been approved for their application database. I am currently adding leaderboards and live game support!!!

In the mean time:

Installer: http://www.parrisstudios.com/wp-content/uploads/2009/04/towerd.ccgame

Source Code: http://www.parrisstudios.com/wp-content/uploads/2009/04/towerd.rar

Final Thoughts: I think I may add some networking to this game. I really enjoyed line tower wars on warcraft 3, so I am thinking about making similar gameplay as that.

Enjoy 🙂

Share