VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

A 2D DotProduct Demonstration

Peter Wilson  (25 Submissions)   Graphics   VB Script   Beginner   Wed 3rd February 2021

This application is a simple and clear demonstration of the DotProduct in two dimensions. The DotProduct is almost always used by game programmers, especially in shooting games like Unreal Tournament. The DotProduct allows the programmers to decide is the user is pointing his weapon at a monster, a pickup or a door. The DotProduct is also used for Back-Face culling and lighting effects. You can even use the DotProduct for real world physics calculations like "Newton's Conservation of Momentum". In fact, this is the real reason I created this little demo. I'm currently working on my Asteroids game (also on VBC) and wanted the Asteroids to bounce off each other convincingly. Since angles were involved, I figured I could probably use the DotProduct to save on calculations. I needed a little refresher course in the DotProduct, thus this project was born. If you are not interested in the DotProduct, you may be interested in the Splash screen. It has a built in Ant Simulator which probably deserves it's own submission.

Rate A 2D DotProduct Demonstration (5(5 Vote))

Download A 2D DotProduct Demonstration

A 2D DotProduct Demonstration Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters