Ferazel's Wand

About SheepShaver, a PPC Mac emulator for Windows, MacOS X, and Linux that can run System 7.5.3 to MacOS 9.0.4.

Moderators: Cat_7, Ronald P. Regensburg, ClockWise

Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

I would appreciate any help you guys are willing to give for compiling SheepShaver; I'll start a new topic about that shortly.

Regarding the InputSprockets extensions, that is an interesting find. I wonder if that explains why games that use InputSprockets (such as Mars Rising) are so buggy. I hope that this will not be an issue for Ferazel's Wand because it has InputSprocket controls disabled by default. I tested the program with the extensions disabled, and it gets as far into the loading as it did before. Still, it will be an issue to be aware of in the future.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7821
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Ferazel's Wand

Post by Ronald P. Regensburg »

Elyus wrote:I would appreciate any help you guys are willing to give for compiling SheepShaver;
See our wiki: http://www.emaculation.com/doku.php/com ... r_basilisk
Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

Ferazel's Wand lovers will be pleased to know that it can run in SheepShaver, just without gamma fades. I did a little research about the Monitor_Tool that was causing problems and discovered that it is an Ambrosia tool that they used in some of their games for effects. Ben Spees talked about it briefly on the Ambrosia forums in 2004 saying that it was used for the gamma fade effects in Ferazel.

Because everything was still pointing to the gamma operations as causing the trouble, I put breakpoints at the functions in SheepShaver for setting and getting the monitor's gamma values. Through a lot of trial-and-error and fiddling around in HexEdit, I found that the game seemed to be quitting very shortly after this piece of code in video.cpp:

Code: Select all

	case cscGetGamma:							// GetGamma
	D(bug("GetGamma\n"));
	WriteMacInt32(param, (uint32)csSave->gammaTable);
	return statusErr;
And also, the set_gamma function had been disabled:

Code: Select all

static int16 set_gamma(VidLocals *csSave, uint32 gamma)
{
	return paramErr;

	<snip>
}
So, after changing "statusErr" to "noErr" and removing the "return paramErr" from set_gamma, I was stunned when Ferazel's Wand actually started! As I mentioned, all of the nice fade effects don't work and the screen doesn't turn blue when you're underwater, but everything else seems to run perfectly.

I know that not everybody wants to compile from source, so I've put an experimental build 20120323 (this is not an official build) on my student site. It can be downloaded HERE. This is a 32/64-bit Universal Macintosh build. I doubt I have the tools necessary for compiling the Windows and Linux versions because I don't use those systems, but I only changed two lines of code, so it shouldn't be hard to compile versions for them.

An unintended effect is that EV: Nova also runs in this build. The only glitch I have found is that the menu buttons don't load, but fortunately, the menu hotkeys do work (N for New, O for Open, E for Enter, and Q for Quit). EV: Nova causes some instability; SheepShaver crashed when I tried to open it a second time in one session. Again, this is all experimental, Gwenole disabled the set_gamma function back in version 1.11 according to the old source files. As such, this version may be more unstable for general purpose emulation, and I've not really tested for compatibility with other games. Many thanks to Cat_7, Ronald P. Regensburg, Myrd, and others for maintaining and working on SheepShaver for all this time!
Last edited by Cat_7 on Fri Mar 23, 2012 9:30 am, edited 1 time in total.
Reason: added the file name concerned
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

YES!!! However, I would STRONGLY prefer to have a Windows build, as that is my main system. Hopefully this is not too much to ask.

I feel very fortunate... to have been present at the beginning of this monumental event...
User avatar
Cat_7
Expert User
Posts: 6121
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: Ferazel's Wand

Post by Cat_7 »

Hi,

Great find, I'm sure you are making several people happy today! Would you have any use for the old basilisk for windows gamma ramp fix that allowed EV-Nova to run?

EDIT : removed link. Latest build now is in SheepShaver for Windows sticky post in the SheepShaver forum.

Best,
Cat_7
Last edited by Cat_7 on Thu Mar 29, 2012 4:45 am, edited 3 times in total.
Reason: Link fixed
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

Hmm, it seems that link doesn't work.
kataetheweirdo
Master Emulator
Posts: 312
Joined: Sun Feb 01, 2009 4:55 pm

Re: Ferazel's Wand

Post by kataetheweirdo »

That is so sweet. Thank you for making a patch. I'm gonna check it out right now!
Jon God
Inquisitive Elf
Posts: 28
Joined: Fri Aug 05, 2011 6:18 am

Re: Ferazel's Wand

Post by Jon God »

I love you guys.

Maybe I can ask Ben Spees to make a patch that makes the fading work some other way, so it works in Sheepshaver?
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

Wanted to say thanks again! Also wanted to ask if the framerate can be improved, or is it not possible without the gamma ramp?
Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

Cat_7, I actually found the source from that patch earlier this week; it was largely responsible for my initial interest in the gamma correction functions in SheepShaver. I believe the author of that patch used ICM to implement the fading effects in Windows. I don't know enough about it now, but maybe in the future some SDL tool could be used to provide a cross-platform version of the feature in SheepShaver.

Jon God, you're welcome :) . I suppose you could ask Ben Spees. He'd probably be interested to know that the game is running in SheepShaver, but I don't know if he'd want to undertake the process of removing the Ambrosia Monitor_Tool from the code. He might have to change some of the game's core libraries if he switched to another tool like DrawSprocket. Interestingly enough, he was trying to do that when he was looking to make an OS X version of Ferazel, called Refazel; he said at the time that he was trying to replace the Monitor_Tool with something Carbon compatible (original post). I believe Ambrosia SW shut that project down since they hold the distribution rights for Ferazel.

FerazelX, I'm not having any issues with the frame rate on a Mac, so I can only assume that its the speed of the emulator in Windows that may be causing slowdowns. You could try increasing the minimum memory for the game and/or allocate more to SheepShaver. You could also try enabling InputSprocket. Because my experience with other games that use InputSprocket has been fairly negative in SheepShaver, I initially recommended against using the setting in Ferazel. Afterwards, I decided to try it to see what would happen, and surprisingly, there were no freezes or crashes! Actually, the audio plays more smoothly with it enabled, so you may get a better frame rate. A word of caution: I have noticed a bug with InputSprocket that the controls sometimes "stick" or become unresponsive. Pressing escape and canceling the dialog that pops up seem to fix it, but it could still be annoying if you're in the middle of a battle. But I think you should try it and see if it is an improvement.
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

Tried with InputSprocket, better but not full speed. What settings do you use to get it to run?
Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

Running Mac OS 8.5.1 with Quicktime v3.0, 256 MB of RAM for SheepShaver. Ferazel's Wand lists 22657 kB, 21057 kB, and 22657 kB as Suggested, Minimum, and Preferred memory sizes, respectively.

In-game preferences:
Graphics: High Detail
Effects: Enhanced
Resolution Switching, Reuse saved game files, Reduce frame rate, and Allow background tasks are all unchecked.
InputSprocket is enabled under controls.
Sound Effects and Music are both checked.

This is all for the demo version of the game. The result is fluid animation, skip-free music, and a game speed that is slightly faster than what I remember as being the usual speed, but it is still completely playable.

Reduce frame rate is the only option in my settings that changed the game speed, but I'm sure you've already deselected that. Even reducing the graphics and effects detail kept the game at the same speed as before, just with lower quality graphics. You should probably play around with different combinations of all these settings though, just to see if they affect your game speed.

One other possibility that occurs to me is that I am using the demo, so all of the data is stored on the hard drive. Does the full version install all of the data on the hard drive, or does it keep some of it on the CD? Reading from the CD can cause skipping in SheepShaver during games, so if it is reading a lot from there, you might want to make a disk image and mount that in SheepShaver so that the game thinks its reading from CD, but all of the data will in fact be on the hard drive.
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

It's working fine now!

It doesn't read anything off the CD. In fact, the CD isn't even present right now.
Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

I'm glad to hear you got it working. Did you have to change any of the settings or did allocating more memory help?

On an unrelated note, I was checking several of Ambrosia's other old games and discovered that Slithereens now works in SheepShaver as well. Unfortunately, Pillars of Garendall still doesn't open. I tried the Windows demo, and it runs great in VirtualBox, so now I just need to find the Windows version to play that one. I think this means that all of Ambrosia's old games are now playable on newer systems through emulation.
Jon God
Inquisitive Elf
Posts: 28
Joined: Fri Aug 05, 2011 6:18 am

Re: Ferazel's Wand

Post by Jon God »

Harry the Handsome Executive works for me but the music sounds horrible. Like the midi isn't playing, it's just the notes.

Anyone else have this issue?
kataetheweirdo
Master Emulator
Posts: 312
Joined: Sun Feb 01, 2009 4:55 pm

Re: Ferazel's Wand

Post by kataetheweirdo »

@JonGod:

Are you sure this is true, even when Quicktime 2.5 is installed or could it possibly be a missing instruments file?
Elyus
Tinkerer
Posts: 94
Joined: Wed Mar 21, 2012 12:35 am

Re: Ferazel's Wand

Post by Elyus »

Just a little update on Pillars of Garendall: I could not get it to work at all with my OS 9 installation. For some reason, it does run under OS 8.5.1, but I had to update to Quicktime 4.0.3. It looks like it will work fine now, though for some odd reason the music is not playing in Fantrima, but it seems to play elsewhere. Audio playback through Quicktime still seems to have a lot of issues in SheepShaver.
Jon God
Inquisitive Elf
Posts: 28
Joined: Fri Aug 05, 2011 6:18 am

Re: Ferazel's Wand

Post by Jon God »

Aha, that's what was wrong.

Though, the sound is very choppy. I will see if I can make something of it.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7821
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Ferazel's Wand

Post by Ronald P. Regensburg »

The latest QuickTime version that is compatible with SheepShaver is 4.1.2. Why not try that version?

http://support.apple.com/kb/DL1134?viewlocale=en_US
Myrd
Granny Smith
Posts: 107
Joined: Mon Dec 25, 2006 4:09 am

Re: Ferazel's Wand

Post by Myrd »

I've committed the Ferazel's Wand fixes to CVS. Thanks!
Myrd
Granny Smith
Posts: 107
Joined: Mon Dec 25, 2006 4:09 am

Re: Ferazel's Wand

Post by Myrd »

I've now fixed the gamma code in CVS so that the fades in Ferazel's Wand actually work!
FerazelX
Tinkerer
Posts: 81
Joined: Sun Jan 20, 2008 11:38 am

Re: Ferazel's Wand

Post by FerazelX »

Myrd, think you can provide us with OS X and Windows builds?
User avatar
Ronald P. Regensburg
Expert User
Posts: 7821
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Ferazel's Wand

Post by Ronald P. Regensburg »

You can compile your own builds from cvs yourself anytime. See: http://www.emaculation.com/doku.php/com ... r_basilisk

And building SheepShaver for MacOSX has become very easy (with XCode 3.2.x) since Myrd made SheepShaver available as XCode project.

Here is a OSX build from cvs compiled minutes ago: http://www.xs4all.nl/~ronaldpr/sheepsha ... l_test.zip
Last edited by Ronald P. Regensburg on Wed Mar 28, 2012 9:26 pm, edited 1 time in total.
Reason: Corrected file name and link
User avatar
Cat_7
Expert User
Posts: 6121
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: Ferazel's Wand

Post by Cat_7 »

Latest windows build here:

http://www.emaculation.com/forum/viewto ... 446#p27446

Best,
Cat_7
kataetheweirdo
Master Emulator
Posts: 312
Joined: Sun Feb 01, 2009 4:55 pm

Re: Ferazel's Wand

Post by kataetheweirdo »

Thank you again, Elyus, Myrd and Cat_7, for providing me an opportunity to play some of Ambrosia's other games for the first time in several years.
Post Reply