Jump to content
Sign in to follow this  
  • entries
  • comments
  • views

Scan & Emitter

Sign in to follow this  


Made some more scanning fixes yesterday, including creating a new model for the scanner/pda.

One reason to change it was that the old pda looked like a palm pilot, and thus was asymmetrical in the left vs right hand. All other guns are symmetrical, so we changed it to make it have a gun-like handle, but still a flat screen facing the player.

Also, we use a clever approach for finding the muzzle position of a gun which didn't work with the pda. What I do is : when loading a weapon entity's mesh, I go through its vertices and find verts near the border of the bounding box on the muzzle side ( +Z ). Then I average these verts to give me the muzzle position. This works great for all of the guns we have so far, because it finds the business end ( which is square or round ), and gives me the center point of that structure. The scanner now has a spike sticking out of the screen that acts as the muzzle.

The scanner screen lights up when scanning something. Earlier, I was changing the gun's emissive color to make it more green, but that just made the whole gun greenish - not what I was looking for.

I decided to add a masked emissive term instead. The unused diffuse.alpha channel is now used for an emissive mask, specifying where the per-material emissive color shines through, irrespective of the lighting environment.

Right now the emissive color is used for the LCD screen of the pda, and parts of several weapons.

Sign in to follow this  


Recommended Comments

Man, if we have gun shaped PDAs in the future, my business meetings with the Giovanni family are going to get a lot more interesting.

Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!