Announcement: Be excellent to each other.


Caravel Forum : Caravel Boards : Development : DROD 2 port to Mac OS X
New Topic New Poll Post Reply
Poster Message
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged

File: drod2-ppc.patch (84.6 KB)
Downloaded 62 times.
License: Other
From: Unspecified
icon DROD 2 port to Mac OS X (0)  
The attached patch provides a port of DROD 2.0.5 to Mac OS X. There are still some issues that I need to resolve, but it should basically work. I recommend that you play with a copy of your Data directory, which you can place in the same directory as the executable.

Known problems:
Mouse cursors do not display properly. I generally get a black square for a mouse cursor.
A few things will get painted with "incorrect" colors. (tool tips, for example)

04-25-2005 at 12:22 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
... and a binary is available at http://users.telerama.com/~realms/drod2-ppc.bz2

You should not need any shared libraries other than ones provided by Apple on OS X 10.3.9. If you are running an earlier version of the OS, it might work, too. Try it out and let me know!
04-25-2005 at 12:38 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
patmo98
Level: Delver
Rank Points: 39
Registered: 03-14-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
I am using 10.3.9. I am using the binary and when ever I run it I get the error:

DROD:Assertion error in line 765 of ../../DROD/Main.cpp: "Unexpected MID value."
Problem Starting DROD: An unexpected error occurred, and DROD was not able to retrieve a description of the problem. This problem might be corrected by reinstalling DROD.
Error=376


[Edited by patmo98 at Local Time:04-25-2005 at 08:12 PM]
04-25-2005 at 08:11 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 5058
Registered: 02-04-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
patmo98 wrote:
Error=376
This error # means the font init failed. I couldn't tell you what the problem is on your end, though.

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.
04-25-2005 at 09:50 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
Hmm. It sounds like the database didn't get initialized properly. The font init failed, and then the lookup for the message text failed as well. Is your Data directory from 2.0.5? Could there be anything "funny" about it? Did a DataPath.txt file get created? What are its contents?

Incidentally, if I run with an empty Data directory, I get a message about font initialization failed. Where would it have looked up the message from?? There's something I don't grok here....
04-25-2005 at 11:41 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
patmo98 wrote:
I am using 10.3.9. I am using the binary and when ever I run it I get the error:

DROD:Assertion error in line 765 of ../../DROD/Main.cpp: "Unexpected MID value."
Problem Starting DROD: An unexpected error occurred, and DROD was not able to retrieve a description of the problem. This problem might be corrected by reinstalling DROD.
Error=376

Aha! I do get the same thing if I don't have a Data directory at all. The test I did before must have gotten the message text from by searching up the path of the current directory, or something.

Note that the "Data" directory that I use is one that I copy from the install location of JtRH on my Linux box. It has a template copy of players.dat, I believe. I don't use (just haven't tried) the ~/.caravel/drod-2.0 directory that has writable copies of players.dat etc.
04-26-2005 at 12:03 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
patmo98
Level: Delver
Rank Points: 39
Registered: 03-14-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
wmarkham wrote:
Aha! I do get the same thing if I don't have a Data directory at all.


Sorry, that fixed it. I was using my Data folder from DROD:AE. I didn't see anything wrong when I was running it but when I quit the terminal had these errors:

DROD:Assertion error in line 855 of ../../FrontEndLib/Sound.cpp: "CSound::PlayNextSong(): Failed to load song."
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 430 of ../../FrontEndLib/BitmapManager.cpp: "!"needs to be tested""
DROD:Assertion error in line 855 of ../../FrontEndLib/Sound.cpp: "CSound::PlayNextSong(): Failed to load song."


I don't care about them since there didn't seem to be any problems but they might be helpful to you. Did JtRH work because all of the libs that I installed before or do I not need SDL, SDL_ttf, freetype, and expat for DROD:JtRH

[Edited by patmo98 at Local Time:04-26-2005 at 12:11 AM: Had to turn off smilies to make the error show up.]
04-26-2005 at 12:11 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
patmo98 wrote:
Did JtRH work because all of the libs that I installed before or do I not need SDL, SDL_ttf, freetype, and expat for DROD:JtRH
In theory, (actually I'm pretty sure it worked properly) the binary has all the necessary functionality from SDL etc. linked in statically. None of those are needed.

Sound.cpp:855 would be, uh, some problem loading the music. I think I can fix that.

The other assertion is actually one that I put in as a kind of code-coverage test. I haven't tested that code, so I would be interested in knowing what you did to make it fire. It is in BitmapManager::LightenRect, in case that gives a good hint.

04-26-2005 at 12:27 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
wmarkham wrote:
Sound.cpp:855 would be, uh, some problem loading the music. I think I can fix that.

The other assertion is actually one that I put in as a kind of code-coverage test. I haven't tested that code, so I would be interested in knowing what you did to make it fire. It is in BitmapManager::LightenRect, in case that gives a good hint.
Ok, so it turns out that I have no idea about the sound thing. LightenRect, however, appears to be stairways up.
04-26-2005 at 12:36 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
I put a new binary at http://users.telerama.com/~realms/drod2-ppc.bz2.


[Edited by wmarkham at Local Time:04-26-2005 at 12:49 AM: make the hyphen part of the link]
04-26-2005 at 12:47 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
patmo98
Level: Delver
Rank Points: 39
Registered: 03-14-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
wmarkham wrote:
Sound.cpp:855 would be, uh, some problem loading the music. I think I can fix that.
I had an entry in drod.ini pointing at a file that didn't exist, so
I don't think you will be able to fix it.:D In the new copy all of the "color" warning are gone.

[Edited by patmo98 at Local Time:04-26-2005 at 02:22 AM]
04-26-2005 at 02:10 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
Thanks again, patmo, for trying these out!

I've applied my patches to the 2.0.6 source code. I'm packaging it up a bit differently now. The download is now a .dmg file. Inside that, there is an application bundle. But you should be able to just mount the .dmg, and copy the "DROD" application next to your Data directory, just like with the executable. Download it at http://users.telerama.com/~realms/drod-2.0.6.dmg

Hmm.. what else? Ok, so stairways up no longer produce the assertion, as you noted in the previous version, but there are still a few other pieces of UI code that I changed, but couldn't figure out how to exercise. So, there might be some "easter eggs" in there! The mouse cursors do display, although I just shrink them down at runtime until they meet SDL's limitations. They look silly, but less so than an opaque black square. The application is supposed to have a real icon, but Finder doesn't display it. I think I need to change the image format, or something. Oddly, the icon does display in file selection dialogs. *shrug* Text labels sometimes disappear, for example after I change a key binding in the settings screen.

By the way, Erik is working on having an official, tested, OS X port of the game. I'm pretty psyched.


[Edited by wmarkham at Local Time:04-26-2005 at 06:40 PM]

[Edited by wmarkham at Local Time:04-26-2005 at 06:41 PM: I keep losing my hyphen. grr.]
04-26-2005 at 06:40 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+2)  
It occured to me that I have been a bit lax about some of the obligations that I have when redistributing the binary. The new disk image includes a Licenses folder, which is copied from the source code. The binary includes code from:

Expat
FreeType 2
libjpeg
libpng
SDL
SDL_ttf
SDL_mixer
libogg
libvorbis
zlib

Documentation about the licenses under which these are redistributed can be found in the "Licenses" folder, as well as information about where to find the source code.

The binary .dmg can be downloaded from http://users.telerama.com/~realms/drod-ppc-2.0.6b.dmg

The exact patches I used to generate this binary can be found in http://users.telerama.com/~realms/drod-ppc-2.0.6b.patches

Also, this software is provided as is.

[Edited by wmarkham at Local Time:04-28-2005 at 08:17 AM: fix misspelled URL's; add "as is" disclaimer]
04-28-2005 at 08:15 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
Speicus
Level: Delver
Rank Points: 40
Registered: 04-14-2005
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
OK, got it to work. Awesome! Two things immediately stick out for me:

1) Buttons don't work. I click on them, they don't do anything. Not a big deal most of the time because the esc and enter keys usually do what the buttons do, but it's a problem when I can't change my keyboard settings to a laptop-friendly setup.

2) When I hold down a key, I just move once. I should keep moving! I don't know if this is a feature that simply hasn't been added to the mac version yet, but it should definitely be in there eventually.
05-11-2005 at 12:23 PM
View Profile Send Private Message to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (0)  
Speicus wrote:
OK, got it to work. Awesome! Two things immediately stick out for me:

1) Buttons don't work. I click on them, they don't do anything. Not a big deal most of the time because the esc and enter keys usually do what the buttons do, but it's a problem when I can't change my keyboard settings to a laptop-friendly setup.

2) When I hold down a key, I just move once. I should keep moving! I don't know if this is a feature that simply hasn't been added to the mac version yet, but it should definitely be in there eventually.

I'm glad to hear that it mostly works! Would you mind posting these bugs over in the bugs forum? Mark the topics with "OSX" so that they are easy to identify as being related to the beta. (Actually, are these issues with the "official" beta, or the open source port?) Thanks!

[Edited by wmarkham at Local Time:05-11-2005 at 03:28 PM]
05-11-2005 at 03:24 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
KaS_m
Level: Roachling
Rank Points: 10
Registered: 05-31-2005
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
I'd like to help out on the Mac OS X port of DROD. I've downloaded the source that's been made available at Caravel, but (without having looked at it yet) I'm guessing it's probably not up to date with the work you've done, wmarkham.

Now, I don't know the licensing status of DROD or the Mac OS X port, or if the Mac port is even open source at this point. But if it is, would you mind giving it to me? I could help... if nothing else, to fix the bug that is preventing it from working on my system (erik told me he would post that bug at the proper location. thanks, erik :)

Oh, and it would be convenient if you'd send me the Xcode (CodeWarrior, w/e) project to import, too.
05-31-2005 at 02:40 AM
View Profile Send Private Message to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
KaS_m wrote:
I'd like to help out on the Mac OS X port of DROD. I've downloaded the source that's been made available at Caravel, but (without having looked at it yet) I'm guessing it's probably not up to date with the work you've done, wmarkham.

Now, I don't know the licensing status of DROD or the Mac OS X port, or if the Mac port is even open source at this point. But if it is, would you mind giving it to me? I could help... if nothing else, to fix the bug that is preventing it from working on my system (erik told me he would post that bug at the proper location. thanks, erik :)

Oh, and it would be convenient if you'd send me the Xcode (CodeWarrior, w/e) project to import, too.

There are basically two versions of JtRH for Mac, namely the open source version and the beta version. The open source version can be built by applying the patches that I posted in this thread to the open source code released by Caravel. There is a makefile in Master/Darwin that builds the game. Read it, as well as the Config file, for instructions to do so. There is a prebuilt binary posted in this thread as well.

Additionally, there is a proprietary version that resides in Caravel's CVS repository. If you have access to it, you should be able to build from that. A built executable from the proprietary version is available at http://www.drod.net/forum/downloads.php. (It is the OS X Beta)

These two are largely similar. The main difference is that the open source version has CaravelNet functionality disabled. The "beta" version is more recent, and incorporates some bug fixes that are not present in the open source one. Also, due to licensing differences and other factors, the open source binary includes just an executable without any data files, and the beta packages up data files as well into an application bundle.
06-02-2005 at 04:51 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
KaS_m
Level: Roachling
Rank Points: 10
Registered: 05-31-2005
IP: Logged
icon Re: DROD 2 port to Mac OS X (-1)  
I don't want to sound like I'm making accusations, I'm sure you've thought this out better than I, but -

You say there is a "proprietary" version and an open source version. If http://www.caravelgames.com/sourcecode.html is any indication, the open source release is at least one point release behind the proprietary 2.0.7.

Now, maybe I don't understand the MPL very well, but as far as I know the only way this could be MPL compliant is if the code of DROD was structured so as to keep all proprietary code in a separate library. Since the changes in 2.0.7 seem to affect plenty of core functionality (memory usage optimizations, AI improvements, etc.), I doubt that it is merely an update to a proprietary DROD library. If they are truly imporvements to the MPL-covered code, then they must be released under the terms of the license.

Of course, this is all based on the assumption, which I now realize I haven't thoroughly researched, that 2.0.7 has not been released. All I know is, it's not on that website or in this thread.

Oh, and I'm no longer talking about the Mac OS X version alone. The reason I ask is that the DROD release available in Portage (I use Gentoo) is out of date, and I'd like to commit an ebuild of 2.0.7, not 2.0.6 (my save files were created in 2.0.7). I'd be using the public domain data files I keep hearing about, not the uploading the ones I paid for, of course.

Also, I'd like to recommend Autopackage as a replacement for that crappy old Loki installer you guys are using on Linux. I'll make one myself, if you'd like.

Maybe I made this long-winded post in the wrong place. Oh well.
06-04-2005 at 10:06 PM
View Profile Send Private Message to User Show all user's posts Quote Reply
ErikH2000
Level: Legendary Smitemaster
Avatar
Rank Points: 2794
Registered: 02-04-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
KaS_m wrote:
You say there is a "proprietary" version and an open source version. If http://www.caravelgames.com/sourcecode.html is any indication, the open source release is at least one point release behind the proprietary 2.0.7.
Yep, as you point out, the source code hasn't been updated to match the latest release. Within a week, we'll be releasing 2.0.8 and we'll include source with that. In the future I'm going to make a point to release both the patch and source together. I don't want people thinking I'm trying to avoid releasing source. It's really just a matter of being slightly disorganized and perpetually behind on all the work there is to do.
Now, maybe I don't understand the MPL very well, but as far as I know the only way this could be MPL compliant is if the code of DROD was structured so as to keep all proprietary code in a separate library.
You do understand the MPL correctly, and have pointed out an overlooked problem with our project complying with the license. I talked to Mike about it and we'll just move the "proprietary" CaravelNet code into a separate library. There's nothing particularly special about the CaravelNet code, but we don't want it in the public source releases because it would help people hack our server. By putting it in a lib we'll be in compliance with MPL.
Also, I'd like to recommend Autopackage as a replacement for that crappy old Loki installer you guys are using on Linux. I'll make one myself, if you'd like.
A little tact, please. Instead of calling the setup program Gerry chose and worked on "crappy", you could describe benefits of replacing it with Autopackage. And then Gerry might be persuaded. I leave decisions about the Linux distribution to him.

-Erik

____________________________
The Godkiller - Chapter 1 available now on Steam. It's a DROD-like puzzle adventure game.
dev journals | twitch stream | youtube archive (NSFW)
06-04-2005 at 11:09 PM
View Profile Send Email to User Show all user's posts This architect's holds Quote Reply
trick
Level: Legendary Smitemaster
Rank Points: 2580
Registered: 04-12-2003
IP: Logged
icon Re: DROD 2 port to Mac OS X (+2)  
KaS_m wrote:
Also, I'd like to recommend Autopackage as a replacement for that crappy old Loki installer you guys are using on Linux. I'll make one myself, if you'd like.
I did actually look into using Autopackage when choosing an installer for JtRH, as well as several other install systems. Loki Setup has many faults, but after comparing it with the other choices out there I decided it was the best choice, at least for now. In particular, it is stand-alone, very easy to use for the end-user, can install JtRH with only a few clicks, supports different install options, can show the EULA and a separate README, prevents multiple installations, supports uninstallation, and supports automatic patching.

Autopackage's .package files requires the Autopackage executable to run. The .package files can download the installer executable, but that obviously requires internet access. Not quite as bad as ZeroInstall, but this is still not stand-alone. Also, Autopackage can not display an EULA. I also didn't find anything about install options, multiple installations, or patching (it's possible I didn't look hard enough, though).

If better choices come along (and rumors have it they will :)), I'll be happy to switch to one of those. For now, though, Loki Setup is good enough.

- Gerry
06-05-2005 at 04:07 PM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
wmarkham
Level: Master Delver
Avatar
Rank Points: 125
Registered: 12-06-2004
IP: Logged
icon Re: DROD 2 port to Mac OS X (+1)  
ErikH2000 wrote:
You do understand the MPL correctly, and have pointed out an overlooked problem with our project complying with the license. I talked to Mike about it and we'll just move the "proprietary" CaravelNet code into a separate library.

I'm pretty sure that the existence of the open source version under MPL does not preclude the use of that same code, by its original authors, within the proprietary version.

When the next public release of source code is made, of course, all of my latest Mac-related code will be included in it. Because I expect that this code will soon be released in that manner anyway, I have elected not to spend my time generating and posting additional patches to the 2.0.6 open source code.
06-06-2005 at 05:52 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
New Topic New Poll Post Reply
Caravel Forum : Caravel Boards : Development : DROD 2 port to Mac OS X
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.