Jump to content

360 Snake


blindwig
 Share

Recommended Posts

  • 5 years later...

Hello, to anyone that's been here long enough to remember me!

I got a sudden hankering to check out my old 360 Snake game a few days ago, so I downloaded it and the latest version of AuoIt, wondering if it would still work.

More or less, it does. It requires adding includes for WindowsConstants and ComboConstants (as these used to be part of GUIConstants)

Executing the script gave me mixed results:

On my home computer, a 2-core 32-bit WindowsXP machine, the script crashes AutoIt right after the game starts

On my work computer, a 4-core 64-bit Windows 7 machine, running under Autoit 32-bit, it also crashes

On my work computer, running under AutoIt 64-bit, it runs but very slow

I traced the crashes down to 4 lines in the FoodDraw() routine; calls to function "LineTo" in GDI32 need to have the last parameter removed. So for example this:

DllCall($hDLL_GDI32, "int", "LineTo", "hwnd", $hd[0], "int", $Food[2], "int", $Food[3], "int", 0)

changes to this:

DllCall($hDLL_GDI32, "int", "LineTo", "hwnd", $hd[0], "int", $Food[2], "int", $Food[3])

The script no longer crashes, and runs fine on my 32-bit XP machine.

It also no longer crashes on my 64-bit W7 machine in 32-bit mode, but as with 64-bit mode it runs the script very slowly.

It still run very slowly on the 64-bit machine with AutoIt64

So all this leaves me with a few questions:

Why did this extra parameter crash the latest version of AutoIt, and why did it not crash earlier versions?

And why does it only crash 32-bit versions?

Why does it run so slowly on my 64-bit machine?

Link to comment
Share on other sites

Try to add

#AutoIt3Wrapper_UseX64=n

Slightly faster (maybe?) but still unplayably slow

Link to comment
Share on other sites

Slightly faster (maybe?) but still unplayably slow

I think this is because Aero.

Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs, and the Universe
trying to produce bigger and better idiots.
So far, the Universe is winning.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...