In part 8 of this series of posts on DirectDraw, I had mentioned that there still seems to be a minor problem with the program. Read the "Note" section at the end of the post. The problem now has been solved. Recap The problem was that even after calculating the new positions for the marbles, the marbles would still be overlapping because of the approximations that we use. And this would sometimes repeat many times over which creates the problem. Solution The fix that I'd said in the "Note" section ......
Hi there! What do get when you combine this and this? Well, maybe a game called Crash Marbles? ;) Anyways, game is still pretty far off but here is a video of the result: Well, the basic concept of the "would-be" game revolves around the player having to dodge the evil marbles and also collect the powers that show up randomly on the screen. I am still thinking about how to make the game more interesting and entertaining. Don't bother about the score that shows in the top left, its still work in progress ......
You could sure use some mouse input with the marbles. Remove the timer stuff from the DDEX3 program that we modified and add handling for WM_LBUTTONDOWN, WM_LBUTTONUP and WM_MOUSEMOVE messages in the WindowProc() function. You will need to add some code to find out if WM_LBUTTONDOWN was on the marble and then move the position of the marble relative to its last position whenever you get WM_MOUSEMOVE message. Here is a video of it: If you run this in debug mode you can notice considerable lag because ......
This post explains the code behind colliding marbles.
Long time ago, when I was sitting jobless in my previous company, my manager asked me to study up on DirectShow, for no particular reason (: I eventually ended up writing a small article on DirectShow. The article explains how to create a small audio and video player (for desktop PCs) using DirectShow. Here is the link to the article. From now on, I will use my Code Project account to share the complete source code of the programs I write here. Do you want to know why a Mac is really the only option. ......
Hi there! The marbles finally collide and collide they do! (: I came across this thread, where Professor Fu-Kwun Hwang has a nice applet on collisions. If you go through the entire thread, professor Hwang explains the equations and mathematics related to elastic two-dimensional collisions. The calculations for a collision is a mathematically involved affair, as I had mentioned in my previous post. I can't say I fully understand the computations yet, maybe I will look into the details later (: Anyways, ......
The title of this post might be a little misleading but frankly I haven't had the motivation to take the Spaceship to the next level. I had a few ideas that I wanted to do but I got lost in nothing. I don't know. Anyways, I won't be pasting any code here this time around because there is not much that I have done in the first place (: Just played around a bit with the spaceship and came up with this in about half-hour. Nothing fancy. As you can see, the balls pass through each other! I have been ......
This post deals with Menu items and defining menu items in resource files. How to get popup menus for both left and right softkey and much more.
This post explains about Transparent Blitting.