Panning Problems Solved for Zork Games on PC

Need to sharpen your sword? Or perhaps your lantern ran out of fuel? Well come on in, drink some rye and let Jack sharpen your blade and fill that lantern!

Moderator: KM3K

BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Hey All:

After Zork: Grand Inquisitor has been languishing in my closet for nigh on 12 years, I got it out to play with my 11 year old daughter and followed your instructions to get it all running very nicely, except for the panning which goes by at warp nine if your mouse gets anywhere near the edge. Even CPU killer at 90% was not consistently making it work and was causing some of the videos to become slower too.

Since I am a programmer--and my daughter still believes I can do anything (yeah, like how long is THAT going to last!)--I decided to take a crack at it. My solution seems to work rather well and should be customizable for other zork / non-zork games with a similar issue.

The premise is as follows, as soon as the mouse hits a certain x position on the edge of the screen, the pan starts and my program (named "Pan Relief") moves the cursor away from the edge, thus stopping the pan. The length of time it takes Pan Relief to react to this speeds up or slows down the panning speed in Zork. Since I figured that different programs and different machines might have different threshholds, I allow you to specify the left and right columns that needed to be hit before Pan Relief kicks in, and the speed at which it kicks in (and thus the speed of the pan). I also put in an option for it to only be active when you're in a 640 x 480 screen so that if you have to switch between Zork and another program, it can automatically kick in and out. Finally it saves and restores its settings automatically.

Its defaults are what we're using for Zork Grand Inquistor and if other games need different ones, please share what you come up with. Lastly, I'm releasing at Freeware with Source Code (compilable on Delphi 5 and above) in case anyone wants to add future enhancements.

I hope this all works for you folks and helps bring back those old but great games to life! If you do find it helpful, please post a reply as I'd be thrilled to hear that other people got use out of it.
Attachments
PanReliefWithSourceCode.zip
The Pan Relief Program (Compiled and with Source Code)
(158.93 KiB) Downloaded 2460 times
PanRelief.zip
The Pan Relief Program (Compiled Version Only)
(139.29 KiB) Downloaded 2843 times
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Slight update -- since playing this for a couple of hours, we realized that you don't want the cursor being forced out of the "pan zone" on the top area where the inventory and spells appear, and there are certain cases where you want to quickly turn it off/on such as when you are in a close-up manipulation view where there is no possibility of panning.

So two new features --

1) You can now set a minimum HEIGHT before the cursor gets clipped the default is 75 which perhaps could be changed to 73 but is close enough -- this allows full access to the top areas without impedence

2) Pressing the PAUSE Key on the keyboard toggles on/off the Pan Clipping to give you complete freedom when you want it and pan clipping when you need it. Pressing PAUSE again restores the Pan Clipping new versions with and without source code attached.
Attachments
PanReliefWithSourceCode.zip
Pan Relief Updated Executable (With Source Code)
(159.45 KiB) Downloaded 2369 times
PanRelief.zip
Pan Relief Updated Executable (No source code)
(139.54 KiB) Downloaded 2748 times
User avatar
KM3K
TZL Administrator
TZL Administrator
Posts: 167
Joined: Tue Jul 01, 2008 9:31 pm
Location: Flood Control Dam #3
Contact:

Re: Panning Problems Solved for Zork Games on PC

Post by KM3K »

Wow, this sounds great! I have been just being careful or using the keyboard mainly. I'll try this out over the weekend.
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Let me know how it goes!
DataAngel
TZL Founder
TZL Founder
Posts: 837
Joined: Mon Jan 07, 2002 8:25 am
Location: USA

Re: Panning Problems Solved for Zork Games on PC

Post by DataAngel »

Freakin brilliant! Ill be sure to let you know how it works! 8)
User avatar
KM3K
TZL Administrator
TZL Administrator
Posts: 167
Joined: Tue Jul 01, 2008 9:31 pm
Location: Flood Control Dam #3
Contact:

Re: Panning Problems Solved for Zork Games on PC

Post by KM3K »

Sorry about the delay in responding. I just tested your program with Zork Nemesis and Zork Grand Inquisitor and both work great. It slows ZGI a little more than I like but I was able to turn up the panning speed to 50% to compensate. ZN still pans too fast even with 0% panning speed, but I found a good speed when making minimum left 120 and maximum left 520.
DataAngel
TZL Founder
TZL Founder
Posts: 837
Joined: Mon Jan 07, 2002 8:25 am
Location: USA

Re: Panning Problems Solved for Zork Games on PC

Post by DataAngel »

Okie dokie! I finally took the time to test it out and it works phenomenally! Too bad there isnt something that would allow custom settings per executable you ran. Thanks for sharing a fix! I am quite please and have added it to the How-To page for download!

I run a 24" LCD so I set mine to:
ZN: default x 130 x 510 @ 1%
ZGI: default x 70 x 572 @ 10%
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Stupid question -- someone just emailed me and said that they tried to download it and the links to the compiled version and version with source both reported that the links were removed. Was this deliberate. and if so, was there a better place to have put the files? If this was not deliberate, can they be restored?
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Ah, apparently the compiled version was moved to http://thezorklibrary.com/panrelief.zip

Is the Source Code version still up somewhere in case anyone wants to try their hand at improving it even further, such as giving it the capability for different profiles for different games?
User avatar
KM3K
TZL Administrator
TZL Administrator
Posts: 167
Joined: Tue Jul 01, 2008 9:31 pm
Location: Flood Control Dam #3
Contact:

Re: Panning Problems Solved for Zork Games on PC

Post by KM3K »

Sorry about that. It was an oversight in the transition. I have contacted DAT about getting the files back to where they were so that those old links work.
User avatar
KM3K
TZL Administrator
TZL Administrator
Posts: 167
Joined: Tue Jul 01, 2008 9:31 pm
Location: Flood Control Dam #3
Contact:

Re: Panning Problems Solved for Zork Games on PC

Post by KM3K »

BytePlayer, the files are back where they should be. Let me know if you see anything else that broke during the transition to the new server.
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

Will do!
FayeFlatonius
A white house, what?
Posts: 1
Joined: Sat Jan 01, 2011 7:16 am

Re: Panning Problems Solved for Zork Games on PC

Post by FayeFlatonius »

hey, i am playing zork nemesis, same old problem withthe panning. i've tried cpu killer, game speed adjuster, and your panning ratio program. However, i am still unable to slow it down enough to click the window from the rope in the monastary, maybe with your program i am missunderstanding howto use it? but i put the panning ratio's down quite low. it does slow down, but nowhere near enough for me to click the window from the rope? all it seems to be doing is limiting how far to the right/left my mouse can go[ is this the point ofthe program?] . i hav ea gforce 9200 graphics card,and a gig and a half of ram. any ideas on how i might beable to make it past the window? maybe i am doing some thing wrong?

apologies bout the long post, butthis is my childhood :-\
BytePlayer
A white house, what?
Posts: 7
Joined: Thu Feb 18, 2010 3:35 am

Re: Panning Problems Solved for Zork Games on PC

Post by BytePlayer »

All it seems to be doing is limiting how far to the right/left my mouse can go[ is this the point ofthe program?
Yes, that's fundamentally what it does. Basically the way the program functions is to kick the cursor back out of the left/right panning area so that the Zork program only notices that it's there for a very short time (between 0 and 100 milliseconds) thus not having a chance to pan very far.

In addition to the speed slider, you may be able to "trim" this value more by *increasing* the left minimum margin and *decreasing* the right minimum margin, thus disallowing the cursor to get deeper into the panning zone and perhaps further slowing down the left/right pan. If that fails, you might consider disabling your graphic's card hardware acceleration functions in the graphics card driver and/or booting up in safe mode (which forces generic graphic drivers which are far less efficient).

Good luck!
pettles
A white house, what?
Posts: 1
Joined: Mon Apr 11, 2011 3:54 am

Re: Panning Problems Solved for Zork Games on PC

Post by pettles »

Hey guys,

I just wanna thank all of you for helping me get this thing right.

BytePlayer you are an absolute champ, the panrelief program works sweet as.

Just letting you know, because it took me a bit of fiddling around, if you are running panrelief and Zork GI on a Vista machine, be sure to set both to 'Run as Administrator' otherwise once you run Zork GI the panrelief program stops limiting the scrolliong to the edge of the screen.

Dunno about Windows 7 or Zork Nemesis, but I would guess that it would be very similar. I will no doubt test it on my laptop once I upgrade.

Cheers

Pettles
Post Reply