Anyone has any issues with Max crashing on 64 bit

BlitzMax Forums/BlitzMax Programming/Anyone has any issues with Max crashing on 64 bit

sswift(Posted 2009) [#1]
A publisher I've submitted Space Beetles to has indicated that the game crashed their Mac when they were running an XP emulator or something, and a test on a 64bit Vista installation crashed as well. The game runs fine otherwise.

Any ideas what might cause this issue? Also, I've heard there's a way to run games in some kind of 32bit emulation layer in Vista? How does one go about enabling that for a particular game?


Arowx(Posted 2009) [#2]
I think in blitzmax the game is only built as a 32bit application so run's on 64bit Vista systems as a 32bit app by default, the OS works out that it's 32bit and runs it accordingly.


GfK(Posted 2009) [#3]
Yep, Blitzmax builds win32 apps but I'm not aware of any specific problems with running them on 64-bit systems.

As for it not running on a Mac with Win emulation.... is that really such an issue? If you want to play PC games, get a PC.


Jim Teeuwen(Posted 2009) [#4]
I never had any problems running blitz apps on my 64 bit linux system.


xlsior(Posted 2009) [#5]
Are you using OpenAL, by any chance?

I'm just curious, what would happen if you have spread a 32-bit OpenAL DLL to a computer that may at some point have manually installed a 64-bit DLL, confusing your application? (32 bit Blitzmax App probably wouldn't be able to call / handle a 64-bit system DLL)

As far as the XP-on-a-Mac crashing: Perhaps a side-effect of hardware virtualization not being handled properly somewhere along the road?

for troubleshooting purposes, I'd wonder if you may wish to compile a version of your program will all sound routines and libraries stripped out, and see if that makes the problem go away. If it does, at least it may show you what area to focus on.


ziggy(Posted 2009) [#6]
This or send the publisher a debug build with console mode and tell him to tell you any possible crash message in the console window, so you can locate any possible issue in the code.


skidracer(Posted 2009) [#7]
From what I have read on these forums, I would be more suspicious of the high def mouse hacks you may have in place.

Tablet peripherals and touch pads being a possible source of confusion for your driver.

Also, are you overriding default audio driver?


SLotman(Posted 2009) [#8]
No need for 32 bit emulation: blitzmax games run fine on Vista 64.

The only problem I had with my game was with OpenAL, which was distorting very badly the music, and even seemed to duplicate the audio in some part... switched back to directsound and it's working perfectly.


xlsior(Posted 2009) [#9]
No need for 32 bit emulation: blitzmax games run fine on vista 64.


...That's because Vista64 does the emulating for you, through WOW64. :-?


sswift(Posted 2009) [#10]
Skid:
I wouldn't call them "hacks". I'm simply accessing data the Win32 api provides.

Here's the code:



And this is how I handle the sound driver issue:


So, DirectSound.


Here's the whole app setup actually, there's something in there about hooking the windows procedure that I don't remember what it was for. Maybe the mouse code.




This is the bit where I'm not sure what I was doing:
HookWinProc(App.hWnd)


I hate when I comment stuff and the comment I wrote wasn't clear enough to help me remember why I did something later. :-)


sswift(Posted 2009) [#11]
Ah I figured out what I was doing.

(But as far as I know this has nothing to do with the crashing.)

That calls this function in the mouse code:

	Function HookWinProc(hWnd:Int)
		Local GWL_WNDPROC:Int = -4
		OldWinProc = SetWindowLongA(hWnd, GWL_WNDPROC, Int(Byte Ptr(WinProc)))
	End Function  


Which tells Windows to hook the function WinProc, also in the mouse code, to the BlitzMax window procedure. This is what allows me to capture the mouse events BlitzMAx doesn't normally expose.