Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!

1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


Member Since 10 Jul 2011
Offline Last Active Nov 08 2014 08:42 PM

Topics I've Started

Online Computer Science degree

07 September 2014 - 07:42 PM

I am in a predicament here. I want to go to school to get a bachelors in computer science, but I work on a boat 20 days out of the month and don't have time to go to school. I've decided to research online schooling and I have a couple questions about it. Time or cost is not as issue for me at this point. I'm just looking for something doable because of my work schedule.


1) Do I have to take general education courses like biology and history for an online degree is CS?


2)Does getting an online degree effect how companies look at your resume compared to an in-school degree?


Thanks in advance for any replies. I looked at a couple websites and the only thing that has deterred me so far is taking all the general education classes. I wouldn't mind a few math classes, but I don't want to take anything unnecessary if I don't have to.

Survival Game

06 September 2014 - 08:46 PM

I'm thinking of an idea for a survival game, mostly because the last actual good TRUE survival game I played was Lost in Blue. I like the idea of being stranded on an island. There aren't many available that I can find, the popular games being Rust, DayZ, and The Forest. But these games aren't true survival "stranded" type games.


The way my game will differ is in the inventory system and that everything on the island can be used. You can take a handful of sand and put it in a jar if you wanted to. Trash that washes up on shore can be stored in a pile to attract insects, which in turn can be used for bait when you fish. Leaves, branches, bark, and even roots from trees will all be useful. If you built a pickaxe, you could mine rocks and then smash them up into pebbles to use as ammo for a slingshot.


Inventory will be based solely on the fact that when you are on an island, you can't carry 99 logs in your pocket. When you pick up a stick, you hold it in your hands. When you have 5 sticks, you carry them as a bundle. If you want a big log, you have to heave it on your shoulder and carry it to your destination. You'll be able to craft pouches, belts, and quivers to hold sticks or arrows. To carry more than one log, you can craft a sled type thing that you drag. This will dramatically increase the difficulty of the game and give you a sense of what being stranded would really be like.


As far as the story, I haven't thought of one yet. The only thing I've thought about is creating a magical/voodoo element further in the game. For example: when youre able to travel further into the island, you may come across a cave with glowing lights inside and writing scribbled on the walls. I want to incorporate something like that into the game, but I'm not sure how quite yet.


So my question for anyone reading is, what are your opinions on the inventory system? I know hauling items back and forth to your shelter would be repetitive, but thats what you have to do to survive. What could I do with the story? There could be alternate endings, not unlike Lost in Blue, where you escape the island, get killed, or choose to live there for the rest of your days. 

Clipping planes in XNA 4

06 September 2014 - 07:09 PM

Following Riemers tutorials for creating a water effect, I came across a function device.ClipPlane which does not exist in XNA 4. I googled a bit and found this effect that someone wrote for clipping a plane.

float4x4 World; 
float4x4 View; 
float4x4 Projection; 
float4 ClipPlane0; 
void vs(inout float4 position : POSITION0, out float4 clipDistances : TEXCOORD0) 

    clipDistances.y = 0; 
    clipDistances.z = 0; 
    clipDistances.w = 0; 
    position = mul(mul(mul(position, World), View), Projection); 

	    clipDistances.x = dot(position, ClipPlane0); 
float4 ps(float4 clipDistances : TEXCOORD0) : COLOR0 
    return float4(0, 0, 0, 0); // TODO: whatever other shading logic you want 
        VertexShader = compile vs_2_0 vs(); 
        PixelShader = compile ps_2_0 ps(); 

The result is supposed to show a saved picture of my refraction texture, but nothing is clipped.

        public void DrawRefractionMap(Effect clipEffect, Camera camera, GraphicsDevice device)
            Plane refractionPlane = CreatePlane(waterHeight + 1.5f, new Vector3(0, -1, 0), camera, false);
            clipEffect.Parameters["ClipPlane0"].SetValue(new Vector4(refractionPlane.Normal, refractionPlane.D));


            device.Clear(ClearOptions.Target | ClearOptions.DepthBuffer, Color.Black, 1, 0);

            foreach (EffectPass pass in clipEffect.CurrentTechnique.Passes)

                DrawTerrain(clipEffect, camera, device);

            refractionTexture = (Texture2D)refractionRenderTarget;

            FileStream stream = File.OpenWrite("Screenshot3333.png");
            refractionTexture.SaveAsJpeg(stream, refractionTexture.Width, refractionTexture.Height);

Is there something wrong within the shader? I am not getting any errors or warnings 

DepthBuffer problems

28 August 2014 - 12:53 PM

I have an issue with drawing a Texture2d in my 3d game. I followed RB Whitakers advice on changing the depth buffer, but it didnt seem to work.




The ground is supposed to be checkered. The ground is just a flat model with a texture attached to it. 

 public void Draw(Matrix view, Matrix projection, Viewport viewport, GraphicsDevice device)
            Matrix[] transforms = new Matrix[Model.Bones.Count];
            Matrix worldMatrix = Matrix.Identity;
            Matrix rotationYMatrix = Matrix.CreateRotationY(ForwardDirection);
            Matrix translateMatrix = Matrix.CreateTranslation(Position);

            worldMatrix = rotationYMatrix * translateMatrix;

            smoke.Draw(view, projection, worldMatrix, viewport);
            device.DepthStencilState = new DepthStencilState()
                DepthBufferEnable = true

            foreach (ModelMesh mesh in Model.Meshes)
                foreach (BasicEffect effect in mesh.Effects)
                    effect.World =
                        worldMatrix * transforms[mesh.ParentBone.Index]; ;
                    effect.View = view;
                    effect.Projection = projection;

                    effect.PreferPerPixelLighting = true;

The item smoke is what is giving me the trouble. It just draws a texture at the position of the ship. Is there something else I have to do besides changing the DepthBUffer?

Drawing not working?

19 April 2014 - 05:03 PM

I've been looking over this problem for days now and I can't figure out why this class isnt drawing.




Thats my whole project so far, easier than pasting. I've set breakpoints and every method is being called and every variable initialized. This one has got me stumped :s