Desktop Games

Any ideas for current or future projects can be posted here.

Desktop Games

Postby krum » Wed Apr 01, 2009 1:29 am

I just recently thought of a VERY cool idea *at least to me*

Desktop Games!

it would be exactly like is sounds, use the desktop for games.

Ideas:
Desktop Wars - You fight on OTHER people's Desktops and use their REAL icons to fight (ie. firefox icon will be a flame thrower etc...)

Desktop Racing - Race 2D on others desktops (or single player on your own)

Desktop Pong - Same idea

Desktop <insert name here>


The whole idea would be to send the persons background image along with a "wall template" if used so they can actually interact with the background, and all the icons along with their location, and their desktop theme, so it is emulated as if they are on their desktop.

I thought I would share my idea, because I thought it would be a fun set of games that would be simple and unique!

-Peace!
krum
Developer
Developer
 
Posts: 270
Joined: Sat Jul 14, 2007 10:18 pm

Re: Desktop Games

Postby Calix » Thu Apr 02, 2009 10:16 pm

OMG! That idea is amazing! Doesn't exactly sound easy, but it does sound fun!
Image
User avatar
Calix
Site Admin
Site Admin
 
Posts: 436
Joined: Sun May 20, 2007 10:29 pm
Location: Dallas, TX

Re: Desktop Games

Postby steven » Fri Apr 03, 2009 4:57 am

Sounds easy you would just have to iron out the rules, like who would be mapping out these desktops, the owners? because it would be hard as shit for the game itself to like analyze the desktop and do it ya know, maybe have like a mapping system for the person to make the map/"desktop setup" to play on and it will be kind of like player generated and then you share them with the people you play against?
Image
User avatar
steven
Site Admin
Site Admin
 
Posts: 233
Joined: Thu Jul 05, 2007 4:44 pm

Re: Desktop Games

Postby krum » Mon Apr 06, 2009 10:55 am

I planned for it to be player generated.

It would be a simple editor that shows their desktop and you draw with a "Pencil" tool with a black and white overlay (Just like ody) the black part being solid areas, and depending on the "Composure" of the game would be a platform or a wall.

And maybe some other colors for pitfalls and such...there could be multiple maps per background.

you could of course use a pre-made background which would simply overlay the icons on the pre-made image.

so if my background were a sun, I could make a black overlay for it at the sun, or maybe a magenta overlay that will cause your person to burn up...

Tasks at hand:
- Finding all of the used icons on the desktop (shouldn't be too hard)
- Find all the text used with those icons (also shouldn't be too hard)
- Recognizing the icons specifically to the program (still pondering this one)
- Getting the current background (Shouldn't be too hard)
- Find a default action an unrecognized icon will do (Not sure)
- Getting the users desktop theme (Could be difficult)

other than that the rest is just sending your "Map" to others and coding the game, which the games are purposely "Simple" the fighting game will be a bit more advanced, but we can start with a 2D racer, which the icons can be placed as items or mines.

Your current desktop is not the only image you can use, but you can change the BG "In game"...

Ideas are welcome!

EDIT:
Actually the desktop theme may be quite easy...
"C:\WINDOWS\Resources\Themes"
krum
Developer
Developer
 
Posts: 270
Joined: Sat Jul 14, 2007 10:18 pm

Re: Desktop Games

Postby DJPieSlice » Mon May 04, 2009 12:24 pm

I have a suggestion:-

The program takes the player's wallpaper, then practically re-constructs a fake desktop.

I'm pretty sure there's a way to rip the files that are used for Windows, and the icons can easily be ripped out and turned into sprites.
User avatar
DJPieSlice
Developer
Developer
 
Posts: 65
Joined: Fri May 30, 2008 9:28 am

Re: Desktop Games

Postby krum » Mon May 11, 2009 12:55 am

that was the idea :-P

I can get the icons and where they are used on the desktop, the background would most defiantly be in the registry...the theme is within a file, but I would have to parse it and that could be tough, once those were figured out, making the games would be a lot easier...
krum
Developer
Developer
 
Posts: 270
Joined: Sat Jul 14, 2007 10:18 pm

Re: Desktop Games

Postby Calix » Tue May 12, 2009 12:04 am

Desktop Wallpaper Location -> HKCU\Control Panel\Desktop\Wallpaper

Though this is not the most reliable method since some people (me) don't use wallpapers. It'd be much better to grab the desktop's hWnd and copy it into a bitmap object.

Brainstorming time!

Using native .NET code...and totally untested...
Code: Select all
System.Drawing.Bitmap bmp = new Bitmap(Screen.GetBounds().Width, Screen.GetBounds().Height);
System.Drawing.Graphics bmpGR = new System.Drawing.Graphics.FromImage(bmp);
bmpGR.CopyFromScreen(new Point(1,1), new Point(0,0), Screen.GetBounds().Width, Screen.GetBounds().Height, CopyPixelOperation.SourceCopy); //Though not sure on this line, going from memory here...


Though, I'm not sure if this grabs the icons and start menu as well, but if it does, then I have another idea. Look at the registry key above, see if the user is using a desktop image, and if so, use that as the background. If the key is empty, then grab a group of pixels randomly from the desktop and hope that if they all match, that's the desktop color. I say random pixels, because you never know how icons are arranged on the desktop. Something like this:

Code: Select all
int[] rndPixels = new int[10];
bool match = false;
while( !match ) {
  for( int i = 0; i < 10; i++ ) {
    rndPixels[i] = bmp.getpixel(rnd() * Screen.GetBounds().Width, rnd() * Screen.GetBounds().Height);
  }

  int count = 0;
  for( int i = 0; i < 9; i++ ) {
    if( rndPixels[i] == [i + 1] )
      count++;
  }
 
  if ( count >= 3 ) // if at least 3 match, we've probably found the desktop color...I think :P
    match = true;
}


As for grabbing icons, I think windows uses a listview so it should be possible to get the desktop handle, and then use FindWindowEx with SysListView or something like that to grab the listview handle. After that, we would probably have to loop through each icon getting each DC, and then create a bitmap for each one...No pseudo-code for this one, I'm too tired...

At least, that should work to grab the desktop and the Icons.
Image
User avatar
Calix
Site Admin
Site Admin
 
Posts: 436
Joined: Sun May 20, 2007 10:29 pm
Location: Dallas, TX

Re: Desktop Games

Postby krum » Tue May 12, 2009 6:06 pm

that is basically my thought, the hardest part would be to get the theme... because I thought the game through as you can jump on the start menu and it will open like a spring and shoot you up.

This would be a VERY unique game, I have never head of this being done before (outside of an animation).

we could start with a desktop racing game, for 3 reasons:

1) it will get our foundation on grabbing the info needed to compile the settings.
2) it would lay down the foundation for future releases of this series
3) it would be much easier to make a 2D racing game...The physics would be easy and the power ups would simply be the icons placed randomly (or by the owner of the desktop)


Once we got the icons into the game, (along with what program they were linked to), we can figure out what each one will do what "event" they will trigger.

we would then load the background image, which if there is none, then I am almost 100% sure that the color of the background will be stored in the registry which would be easy to find. Once the background is loaded, it will search for a template like so... "BackGroundName.Template" if found it will load it (obvious) if not then it will do nothing and there will be no walls etc...

and of course when I say racing, I don't just mean "racing" I would want MANY different modes:
- Racing (No Weapons)
- Racing (Weapons)
- Battle
- Battle (No Weapons, but with Damage) aka. Destruction Derby
- etc...



and I could go on all day of how cool we could make this...but of course there are limitations, we would need to play everyone in the same resolution...which means the background would have to be greater than or equal to our set resolution...
krum
Developer
Developer
 
Posts: 270
Joined: Sat Jul 14, 2007 10:18 pm

Re: Desktop Games

Postby Calix » Wed May 13, 2009 9:41 pm

I didn't think the background color was in the reg, but apparently I was wrong. It looks as though it is stored in this key "HKCU\Control Panel\Colors\Background" which would make that even easier. The theme, would probably be the hardest part simply because of WindowsBlinds and the thousands of customized themes people use. It might be easiest just to take a snapshot of the entire start menu bar (store it in memory) and manipulate it dynamically.

As for powerups based on icons, instead of inventorying every single icon in the world, why not just grab the dominant color of the icon and use that to decide the powerup. Ie. Firefox's dominate color is obviously red/orange, so something revolving around flames would be the best bet for that. Internet Explorer and Thunderbird's primary colors are blue, so something dealing with Ice. Dreamweaver's icon is totally green, so...no idea for that one, but you get the idea. Then there could also be wildcards, like Google Chrome's icon is made up of 4 primary colors, green, red, blue, yellow, so this one could be any of those powerups, just pure random.

But yea, a 2D racer would be fairly easy to make I think.

Resolution would definitely be a big factor here. Though that can easily be solved by restricting players to only be able to play with users of similar or greater resolution (if the person who started the game had a resolution of 1024x768, and a player running 1280x1024 tried to join, this player could simply play in a boxed version instead of full screen on their desktop). It would just be a matter of preventing someone playing 800x600 from joining a 1024x768 game, you should get the idea.
Image
User avatar
Calix
Site Admin
Site Admin
 
Posts: 436
Joined: Sun May 20, 2007 10:29 pm
Location: Dallas, TX

Re: Desktop Games

Postby krum » Fri May 15, 2009 4:31 pm

the themes are stored in a file, all we would need to do is find which one they are using (surely stored in the reg SOMEWHERE) then find the corresponding file, open it and extract the images (of course the hardest part is opening it and extracting the needed data)

I like the randomness, but I think it would be nice to have BOTH systems, one where if the icon is not on record it would be chosen it's role via color.

that way the user or we can make icon specific things, and all the other ones will work as well.

I believe once we get over the hump of retrieving the information consistantly, the pieces would fall into place!

I just thought, another cool game would be asteroids with your icons! we can cut them into peices dynamically for when they are shot, and we could even have multiplayer or a battle royale!

this thing has endless possibilities!
krum
Developer
Developer
 
Posts: 270
Joined: Sat Jul 14, 2007 10:18 pm


Return to Ideas

Who is online

Users browsing this forum: No registered users and 1 guest


cron