Hot answers tagged

32 votes
Accepted

How to avoid ghosting when pressing multiple keys?

You can't. At least, not as a game developer. As a gamer, you can purchase more expensive keyboards with "anti-ghosting" features, but otherwise the limitation is part of the hardware itself, so ...
user avatar
  • 14.6k
19 votes

Is there a practical reason for saving game data in %UserProfile%\Documents instead of %AppData%?

Looking at my disk, I have 1 game that saves savegames in %APPDATA% 1 game that saves savegames in %LOCALAPPDATA% 2 games that ...
user avatar
  • 9,937
7 votes
Accepted

Accessing DualShock 4 motion sensor in Windows (ideally Unity)

I've found a workable approach. I grabbed the DS4Tool source and copied the bits I needed into my Unity project so I could read the reports from the device directly. (That's the NativeMethods class ...
user avatar
  • 115k
7 votes
Accepted

Where are the files UnityEngine.dll and UnityEditor.dll located on a Windows filesystem?

UnityEngine.dll and UnityEditor.dll can be found Editor\Data\Managed subfolder of your Unity ...
user avatar
  • 891
6 votes
Accepted

How do I make games that interact with desktop windows?

Games like that are called screenmates or desktop pets. They are a type of digital pet that interacts with desktop windows. Positioning Desktop pets query the host operating system's windowing ...
user avatar
  • 13.3k
6 votes

How can I make an update patch for a Unity game on Windows?

Specifically for Unity, you're correct that AssetBundles cannot update script code. You can use bundles for updating data, but any actual code changes will require a new version of the main game .exe ...
user avatar
5 votes

How to compile with OpenGL ES on Windows?

I suggest you save yourself a lot of pain and grab the ARM Mali OpenGL ES Emulator, or the PowerVR Graphics SDK v3.3. This way you will be ready to roll in minutes. This of course assumes that you do ...
user avatar
  • 29.1k
5 votes
Accepted

Avoid unreachable rooms in duengons

It depends on what algorithm you are using to generate your dungeon. There are algorithms which by their very nature ensure that everything is reachable: Algorithms which start with one room and then ...
user avatar
  • 112k
5 votes

If Windows 10 store games aren't crackable, why continue to publish on Steam?

The current operating system stats on Steam tell us that only 35% of Steam users even use Windows 10. And of those who do use Windows 10, not everyone regularly use the Windows store to shop for new ...
user avatar
  • 112k
4 votes
Accepted

SetRenderTarget(null) clearing previous draw calls

Having the exactly same issue here - the following code snipped works perfectly fine: ...
user avatar
4 votes

Bevel outline algorithm in 2D

What shapes are you using? If your shapes are convex (like circles, squares, rounded rectangles), you can just draw versions of different size and clip them to a triangle whose diagonal goes from ...
user avatar
  • 1,207
4 votes
Accepted

Are SDL games trivially portable from Linux to Windows?

SDL is a cross-platform library, so as long as your code is cross-platform(i.e. no OS specific calls, use '/' in directories instead of '\', etc.), yes you should be able to copy and paste without too ...
user avatar
  • 332
4 votes

Is there a practical reason for saving game data in %UserProfile%\Documents instead of %AppData%?

I don't care to recall the number of games I've had to start over after a backup/restore or similar thing because I moved all my important files from my documents, but totally forgot about user ...
user avatar
  • 41
4 votes
Accepted

Is Windows window creation faster / more efficient than GLFW window creation?

It depends GLFW is just a wrapper around the Windows API calls, so whether you create a window using GLFW or create one using the API, the same calls are ultimately being made. However, a wrapper ...
user avatar
3 votes

Accessing DualShock 4 motion sensor in Windows (ideally Unity)

I've created a solution to this myself. It's called JoyShockLibrary, and reads from DualShock 4, Switch Pro Controller, and Joy-Cons. It's open source, MIT license, and works well, although Bluetooth ...
user avatar
  • 2,430
3 votes
Accepted

Use of SpriteFonts without installing on host machine

Just build the XNB file on your personal machine, and use that file in your project. Remove the .spritefont file from your content project. Then add the built XNB ...
user avatar
3 votes
Accepted

Saving Game Data In Windows Store App

PlayerPrefs provides a key-value store implemented in a platform appropriate manner.
user avatar
  • 3,792
3 votes

Game loop on windows

No, you are not wrong. Actually that's true - if there are too many events the else will never be run, or at least will not be run quickly enough. If your UI methods take too much time to process the ...
user avatar
3 votes
Accepted

Save Texture2D to file in Monogame

Your code seems like it would work to me, but there are two things you would need to verify: Is the render target's format RGBA? Or is it just RGB? Are you trying to save as a PNG or a BMP? Bitmap....
user avatar
3 votes
Accepted

Native vs Desktop Resolution

Is it safe to assume that most users' desktop resolution is the same as their native resolution You're asking the wrong question. Is it a "safe" assumption? Yes. The real question: is it safe to ...
user avatar
3 votes
Accepted

Screen tearing in emulator

The issue you're describing is due to a lack of Vertical Sync (v-sync). Your drawing is not in sync with your monitor's refresh rate. From my research there is no way in the Windows API by default to ...
user avatar
  • 1,363
3 votes
Accepted

How to compile with OpenGL ES on Windows?

It seems like you're having several points where you're confused, so I'll go one by one: Not all LIB files are self contained. It depends on how the DLL is compiled and linked, but it is possible, ...
user avatar
  • 13.2k
3 votes

How to avoid ghosting when pressing multiple keys?

Buy a better keyboard. Ghosting is caused by the hardware itself. Even many gaming keyboards will still have this problem; they only invest in fixing the problem for "common" keys like WASD (but not '...
user avatar
3 votes
Accepted

Publishing an XNA project on Windows Store

XNA games aren't directly support in the Windows Store. The "appx" file types are generated when building a Windows Store app (it's one of the project options when you are creating a new project). As "...
user avatar
3 votes

Will any program written with XLib work on any desktop environment (Gnome, KDE, etc.)?

Short answer: yes, XLib will work for the foreseeable future. Although in some enviroments there will be additional libraries required. You don't need to worry about that. Long answer: XLib XLib ...
user avatar
  • 18.9k
3 votes

Is the Windows 10 Game Bar extensible?

make a product that starts alongside all games that support the game bar If you try to the open the Game Bar on somehting Windows doesn't recognize as a game, Windows will ask you if it is a game and ...
user avatar
  • 18.9k
3 votes

is if statements important or do I need them

#if isn't the same as a regular if statement, it is what's called a preprocessor directive. In C & C++, preprocessor ...
user avatar
  • 8,790

Only top scored, non community-wiki answers of a minimum length are eligible