Dead Pixels > General Discussions > Topic Details
BLC Jan 25 @ 7:01am
Launcher error: Specified cast is not valid.
Hi all

I get the following error when trying to execute the game:

Dead Pixels Launcher has encountered an error.
Version:Steam 1.1.3

Specified cast is not valid.

at System.Runtime.InteropServices.Marshal.ThrowExceptionForHRInternal(Int32 errorCode, IntPtr errorInfo)
at System.Runtime.InteropServices.Marshal.ThrowExceptionForHR(Int32 errorCode)
at System.Management.ManagementScope.InitializeGuts(Object o)
at System.Management.ManagementScope.Initialize()
at System.Management.ManagementObjectSearcher.Initialize()
at System.Management.ManagementObjectSearcher.Get()
at Nuclex.Input.DirectInputManager.isXInputDevice(DeviceInstance deviceInstance)
at Nuclex.Input.DirectInputManager.CreateGamePads()
at Nuclex.Input.InputManager.setupGamePads()
at Nuclex.Input.InputManager..ctor(GameServiceContainer services, IntPtr windowHandle)
at Dead_Pixels_Launcher.Game1..ctor(String[] args)
at Dead_Pixels_Launcher.Program.Main(String[] args)

I can see reference to input manager code here, and I've also seen a couple of other threads which reference controller issues. I've tried the following suggested fixes: verify game cache (I actually deleted & re-installed also); remove non-essential USB devices; re-install USB game controller (as in, manually remove drivers and re-install); adding the launch string -disablecontrollers. None of this helps, I'm afraid.

My spider senses (alright - programming experience!) tells me that there's some kind of data type issue in the code, but obviously I can't see the game code to debug it mysef :)
Showing 1-15 of 36 comments
< >
BLC Jan 25 @ 7:05am 
I should probably also mention that I've tried the suggestions on the launcher support page also: XNA framework, DX runtime, etc.
CantStrafeRight  [developer] Jan 25 @ 10:13am 
Hey dev here.

Are you the same person that emailed me? I'm just trying to work out if this is a second case of this error in 24 hours or the same person.

I'm going to embaress myself here. Can you try "-disablecontrolers" with one L. Looks like I may have spelt it wrong in the code.
DarthWound Jan 25 @ 10:40am 
Originally posted by CantStrafeRight:
Hey dev here.

Are you the same person that emailed me? I'm just trying to work out if this is a second case of this error in 24 hours or the same person.

I'm going to embaress myself here. Can you try "-disablecontrolers" with one L. Looks like I may have spelt it wrong in the code.

It works with -disablecontrolers. Of course only keyboard can be used.
Sorry I just sent an email (DarthWound / Alex) before trying.

edit : as I said in my email, game works fine if I launch the exe directly.
And controller works fine too when using this method.
CantStrafeRight  [developer] Jan 25 @ 11:00am 
Thanks Alex.

It seems this is a steam issue as it effects my PC too.
CantStrafeRight  [developer] Jan 25 @ 11:35am 
Are those affected by this error using the Steam Beta Client?

Out of my 4 PC's only two are affected by this bug and both use the beta client.
DarthWound Jan 25 @ 11:36am 
I am on Steam Beta Client, yes. Didn't try with a regular version.
edit : and I don't have any issue with other games btw, only DeadPixels.
BLC Jan 26 @ 5:33am 
Originally posted by CantStrafeRight:
Hey dev here.

Are you the same person that emailed me? I'm just trying to work out if this is a second case of this error in 24 hours or the same person.

I'm going to embaress myself here. Can you try "-disablecontrolers" with one L. Looks like I may have spelt it wrong in the code.

Hi there

I didn't email you no, so there are a couple of instances of this it seems - at least you've been able to replicate the bug however.

I've tried with -disablecontrolers (single L ;) ) and it works fine - launcher worked with no issues. Interestingly enough however, after loading the launcher at least once it seems to work even if I don't use -disablecontrolers in subsequent attempts.

I'm also on the Beta client.
Lofty Donkey Jan 26 @ 8:49pm 
Probably a Beta Client issue. I've had the same thing on the Steam beta.
Jowwdown Jan 27 @ 3:29am 
I had the same problem (launcher error while using Steam Beta Client) and managed to fix it by reverting back to the non-Steam Beta Client
\,,/ Willdabeast \,,/ Jan 28 @ 10:39am 
I had the same issue too. But I got it to work fine by just going to My Computer/C:/ Program files/ Steam/Steamapps/common/Dead Pixels.In this folder will be 2 Dead Pixel icons. Either one will start the game, and no issues with not being able to use controllers. Xbox controller is working just fine with it. Just make a shortcut on your desktop. The original shortcut steam made doesn't seem to work anymore. Hope this helps someone!
Packrat Jan 29 @ 8:37am 
I'm also having this issue, but I don't recall downloading a beta version of Steam. The settings menu says there's one available and that I'm not participating. Not sure how else I'd tell which client I'm using.

Apologies if I'm making some stupid mistake here, but I'm terrible with software.
Zigi Jan 29 @ 5:52pm 
Same problem. Not using Steam Beta client.

Using the "-disablecontrolers" launch option works for me too, unfortunately removing it again also makes me get the launcher error back. So I can't play with controller now, hope you can fix this! :)
DarthWound Jan 29 @ 5:59pm 
Originally posted by Zigi:
I can't play with controller now
You can, but you have to launch the game without Steam (post #3).
Zigi Jan 29 @ 7:31pm 
Ah yes, I missed that part, thanks!
TheRomMan Jan 29 @ 9:12pm 
I'm sorta new to Steam. Where do i put the -disablecontrolers
Showing 1-15 of 36 comments
< >
Per page: 15 30 50