D2X-XL on Mac OS X
Moderators: Grendel, Aus-RED-5
D2X-XL on Mac OS X
If anyone is interested, I have started to port D2X-XL to Mac OS X. I grabbed the 1.5.22 snapshot of the Linux port yesterday. After working through a good deal of the cruft in the bigendian support, I have a compiled version that works somewhat. There are still major bugs in it, but for less that a day's work, its going fairly well. The first level will even start up and let you fly around a little bit (before some Asserts kill it).
Wow Wow Wow! Yeeeeehaaaaaaaaaaaw!
You da man!
There will be some extra work to be done in the multiplayer communications part, as I have added some new functions to support Entropy games and stuff like that; I will sift through that stuff and try to add it at least so that you only have to fix it, ok?
Please use the 1.5.24 version from my Descent site, as I have fixed a few issues and added full UDP/IP support today.
If you run into severe problems, tell me about the symptoms, maybe I have an idea (given my experience with D2X).
You da man!
There will be some extra work to be done in the multiplayer communications part, as I have added some new functions to support Entropy games and stuff like that; I will sift through that stuff and try to add it at least so that you only have to fix it, ok?
Please use the 1.5.24 version from my Descent site, as I have fixed a few issues and added full UDP/IP support today.
If you run into severe problems, tell me about the symptoms, maybe I have an idea (given my experience with D2X).
For anyone desiring to check it out right now, I have a binary on my website. As this is my first stab at release an OS X binary, I'd love someone to check it out and let me know if it works. It currently has been compiled for 10.4. There shouldn't be anything that prevents earlier versions of OS X (10.3 at least), though I will need to install the cross-development SDKs.
http://programerror.com/packages/d2x-xl.dmg
There is also a copy of the SDL framework on my site as well, just in case its needed.
http://programerror.com/packages/SDL-1.2.9.dmg
The OS X version uses the same conventions as the linux build. So I put the data files in /usr/local/share/d2x-xl/ and made sure that it was writeable by my username.
My testing was done with the PC data files, so if anyone has mac data files that wants to test it out, it also would be helpful. (I was still using PC's exclusively when I bought all my copies of D1 thru D3... hence why I wanted to get the port working)
http://programerror.com/packages/d2x-xl.dmg
There is also a copy of the SDL framework on my site as well, just in case its needed.
http://programerror.com/packages/SDL-1.2.9.dmg
The OS X version uses the same conventions as the linux build. So I put the data files in /usr/local/share/d2x-xl/ and made sure that it was writeable by my username.
My testing was done with the PC data files, so if anyone has mac data files that wants to test it out, it also would be helpful. (I was still using PC's exclusively when I bought all my copies of D1 thru D3... hence why I wanted to get the port working)
- Shadowfury333
- DBB Ace
- Posts: 326
- Joined: Mon Aug 09, 2004 8:36 pm
I've tried downloading the .dmg.zip file, but the .zip is apparently missing some info for the .dmg:
Code: Select all
Archive: d2x-xl-osx.zip
error [d2x-xl-osx.zip]: missing 14 bytes in zipfile
(attempting to process anyway)
error [d2x-xl-osx.zip]: attempt to seek before beginning of zipfile
(please check that you have transferred or created the zipfile in the
appropriate BINARY mode and that you have compiled UnZip properly)
(attempting to re-compensate)
inflating: d2x-xl-1.5.29.dmg
error: invalid compressed data to inflate
file #2: bad zipfile offset (local header sig): 1173754
(attempting to re-compensate)
Perhaps an alternative download location may help:
http://programerror.com/packages/d2x-xl-1.5.29.zip
http://programerror.com/packages/d2x-xl-1.5.29.zip
Menus don't work
Hi,
I tested version 1.5.29 on my mac os 10.4 and the game works but the menus don't. The menus only refresh when I minimize the app and open it up again.
So far so good. I think it is great that there is a mac port in the works and I say thanks to all who worked on d2x xl and the mac port.
MrGRiN
I tested version 1.5.29 on my mac os 10.4 and the game works but the menus don't. The menus only refresh when I minimize the app and open it up again.
So far so good. I think it is great that there is a mac port in the works and I say thanks to all who worked on d2x xl and the mac port.
MrGRiN
Another set of questions... are you using the retail or shareware data files? The shareware data files caused all kinds of rendering problems with the menus.
Perhaps more importantly, are you using the Mac data files. I think there may be a difference. The code should work with them, though I don't have them to test with. I bought all my copies of descent back when I used PCs exclusively. If you are using them, perhaps we could arrange for me to 'borrow' them to develop with.
Perhaps more importantly, are you using the Mac data files. I think there may be a difference. The code should work with them, though I don't have them to test with. I bought all my copies of descent back when I used PCs exclusively. If you are using them, perhaps we could arrange for me to 'borrow' them to develop with.
kaelan,
I have sent an e-mail from my other account to you regarding a crash.
One kind request: Could you test d2x-xl-osx with my level Glass House (see multiplayer level section of my D2 site)? I wonder whether my extensions get loaded properly (little/big endian stuff).
If not, I'd have to fix the level loading routines accordingly.
karx
I have sent an e-mail from my other account to you regarding a crash.
One kind request: Could you test d2x-xl-osx with my level Glass House (see multiplayer level section of my D2 site)? I wonder whether my extensions get loaded properly (little/big endian stuff).
If not, I'd have to fix the level loading routines accordingly.
karx
I'm using the retail PC data files. I also had no mac back then when I bought d2. I'll try another set of data files from a friend and report if this works. He told me he had to try several different sets of data files before it worked for him so I'm pretty sure when I get the right data files it will work.
Thanks for your help.
Thanks for your help.
As far as the data files go, I have found a bug related to some filename problems. Basically the findfile functions were case sensitive, which can be problematic given the standard case-insenstive case-preserving HFS+ file system. This shouldn't affect the game data, but it will affect demos, player files, and third-party levels. I can post a binary that fixes these later today, though there are still a number of other bugs. I will be compiling the OS X binary with support for logging some debug information that can help figure out what's going wrong. More details to follow.
Well, for me, it still launches then crashes. At leas this time it brings up an error report thing, but still the app barely launches before crashing immediately.
This is version 1.5.40
screenshot
if you need comp specs here:
iBook G4
PowerPC 7447A (1.42 GHz)
1 GB DDR SDRAM
32 MB Radeon Mobility 9550 graphics
Mac OS X v10.4.3
This is version 1.5.40
screenshot
if you need comp specs here:
iBook G4
PowerPC 7447A (1.42 GHz)
1 GB DDR SDRAM
32 MB Radeon Mobility 9550 graphics
Mac OS X v10.4.3
@kd527:
you have to make sure that your d2 data files lie in /usr/local/share/d2x-xl.
or start d2x-xl with -hogdir parameter.
....
d2x used an ini-file for switches. is there any eqivalent in d2x-xl?
i ktrace/kdump-ed d2x-xl to see if any such files are accessed but at the first sight i didn't find any. but i have to admit that i haven't had the time to look thoroughly.
bye
ibn
you have to make sure that your d2 data files lie in /usr/local/share/d2x-xl.
or start d2x-xl with -hogdir parameter.
....
d2x used an ini-file for switches. is there any eqivalent in d2x-xl?
i ktrace/kdump-ed d2x-xl to see if any such files are accessed but at the first sight i didn't find any. but i have to admit that i haven't had the time to look thoroughly.
bye
ibn
The Mac version is looking for a d2x.ini in the game folder or the subfolder 'config' (e.g. '/Applications/Games/D2X-XL/config/d2x.ini').
The Mac version currently doesn't recognize the DESCENT2 environment variable and still cannot handle having the D2 data in some arbitrary folder and starting the game from there (blame kaelan ).
I have just made some code changes to fix this, but I will have to wait for kaelan to create new binaries for the Mac (and he will have to wait for me to check the stuff into the SVN repository).
I will also have the next mac version put some diagnostic messages into a file named "d2x.log" - maybe that will help in pinning down the cause of that bug.
The Mac version currently doesn't recognize the DESCENT2 environment variable and still cannot handle having the D2 data in some arbitrary folder and starting the game from there (blame kaelan ).
I have just made some code changes to fix this, but I will have to wait for kaelan to create new binaries for the Mac (and he will have to wait for me to check the stuff into the SVN repository).
I will also have the next mac version put some diagnostic messages into a file named "d2x.log" - maybe that will help in pinning down the cause of that bug.
So a couple of things...
With version 1.5.40, it will look for the data files in /Applications/Games/D2X-XL first. If that directory doesn't exist, it will default to /usr/local/games/d2x-xl.
If it still has trouble, I have built the OS X binary with support for printing a debugging trace log that may help me figure out what's going wrong. To create it, open up a Terminal window. Go to wherever you have placed the d2x-xl.app. Once there do the following:
cd d2x-xl.app/Contents/MacOS
./d2x-xl -debug -printlog
This will open up d2x-xl, and if it is able to find the data directory, it will create a file d2x.log. Email this log file to me at d2x@programerror.com.
With version 1.5.40, it will look for the data files in /Applications/Games/D2X-XL first. If that directory doesn't exist, it will default to /usr/local/games/d2x-xl.
If it still has trouble, I have built the OS X binary with support for printing a debugging trace log that may help me figure out what's going wrong. To create it, open up a Terminal window. Go to wherever you have placed the d2x-xl.app. Once there do the following:
cd d2x-xl.app/Contents/MacOS
./d2x-xl -debug -printlog
This will open up d2x-xl, and if it is able to find the data directory, it will create a file d2x.log. Email this log file to me at d2x@programerror.com.
kaelan,
there are some new (old) bugs in 1.5.40/41. I have uploaded the current source code to http://www.descent2.de/resources/d2x-xl-unified-src.zip, because I cannot check it into the SVN repos until in a few hours. So if you have time and like to, grab the source, check it in and build a new OS X version. You can enable the -debug-printlog switch for all OS's (or I'll do that tonight).
there are some new (old) bugs in 1.5.40/41. I have uploaded the current source code to http://www.descent2.de/resources/d2x-xl-unified-src.zip, because I cannot check it into the SVN repos until in a few hours. So if you have time and like to, grab the source, check it in and build a new OS X version. You can enable the -debug-printlog switch for all OS's (or I'll do that tonight).
- Shadowfury333
- DBB Ace
- Posts: 326
- Joined: Mon Aug 09, 2004 8:36 pm
- Shadowfury333
- DBB Ace
- Posts: 326
- Joined: Mon Aug 09, 2004 8:36 pm
I have a couple things to accomplish in this post... Please tell me if there's a more appropriate place.
First, thanks for doing the work to port to OS X! I'm excited to see that D2X is alive and well, after such a long hiatus in development. I downloaded the binary (1.5.40) and only encountered a couple problems (which I'll get to below), but in general it is very stable and in good shape.
Second, if you need a 3D math expert, I'll help to the extent I can. I'm not really an expert in that area, but I did take a 3D computer graphics course in college and still have the textbook, and I have a basic understanding of the 4x4 arrays and 4x1 vectors used to do the computation.
Third, my bug reports... Please let me know if there's a better way to post these.
1: On occasion (actually the very first time I played) I get an error that crashes the program very soon after entering a level and starting to fly. A dialog appears that states something like "invalid geometry".
2: I am hoping to set up multiplayer gaming on my lab of eMacs. I have installed the program on several machines and have had trouble getting things working. None are running firewalls, and they're all plugged into the same switch. When I start a multicast game, I get a UDP error dialog box that tells me "querying my own hostname." This is both for setting up a game, and for joining. On the hosting machine, I get to the screen where I wait for others to sign on. But on the other machine, I can't see the hosted game. I've tried all three multiplayer options with the same result. Have you seen this before? Have you gotten a multiplayer game to work?
First, thanks for doing the work to port to OS X! I'm excited to see that D2X is alive and well, after such a long hiatus in development. I downloaded the binary (1.5.40) and only encountered a couple problems (which I'll get to below), but in general it is very stable and in good shape.
Second, if you need a 3D math expert, I'll help to the extent I can. I'm not really an expert in that area, but I did take a 3D computer graphics course in college and still have the textbook, and I have a basic understanding of the 4x4 arrays and 4x1 vectors used to do the computation.
Third, my bug reports... Please let me know if there's a better way to post these.
1: On occasion (actually the very first time I played) I get an error that crashes the program very soon after entering a level and starting to fly. A dialog appears that states something like "invalid geometry".
2: I am hoping to set up multiplayer gaming on my lab of eMacs. I have installed the program on several machines and have had trouble getting things working. None are running firewalls, and they're all plugged into the same switch. When I start a multicast game, I get a UDP error dialog box that tells me "querying my own hostname." This is both for setting up a game, and for joining. On the hosting machine, I get to the screen where I wait for others to sign on. But on the other machine, I can't see the hosted game. I've tried all three multiplayer options with the same result. Have you seen this before? Have you gotten a multiplayer game to work?
So the short answer is yes, multiplayer functionality on OS X is a known bug.
I believe that there must be something wrong with how D2X-XL is attempting to setup network connection, and since it fails, everything that follows (creating, browsing, joining) doesn't work. Beyond knowing it's a problem, I haven't had much of a chance to diagnose it.
The geometry error, on the other hand, is an interesting one. If you can do a trace log (as described above) and send it to me, I'll try to see if I can reproduce it. I may need to pad out what is in the trace logs in future versions, depending on how well they work. I've basically just enabled the tracing that was in D2X.
I believe that there must be something wrong with how D2X-XL is attempting to setup network connection, and since it fails, everything that follows (creating, browsing, joining) doesn't work. Beyond knowing it's a problem, I haven't had much of a chance to diagnose it.
The geometry error, on the other hand, is an interesting one. If you can do a trace log (as described above) and send it to me, I'll try to see if I can reproduce it. I may need to pad out what is in the trace logs in future versions, depending on how well they work. I've basically just enabled the tracing that was in D2X.
Thanks for the reply.
In the true nature of bugs, once I actually went to reproduce it the geometry error, it evaporated. It happened a couple times, each when I ran it for the first time on a given machine. I tried a couple more "virgin" machines but didn't get it to fail.
Let me know if I can do anything to help.
In the true nature of bugs, once I actually went to reproduce it the geometry error, it evaporated. It happened a couple times, each when I ran it for the first time on a given machine. I tried a couple more "virgin" machines but didn't get it to fail.
Let me know if I can do anything to help.
#1 Multiplayer
Try direct UDP/IP.
#2 3D math
I need to know how to rotate a spatially arbitrarily oriented object around a certain object axis (that has also been displaced from the world axis).
Background: I am trying to implement rotating cameras which always should rotate around their vertical (Y) axis no matter how that axis is oriented relative to the word Y axis.
I have a position vector and a orientation matrix. I thought transforming the desired angle into a matrix and adding that to the orientation matrix would do the trick, but not so.
I also tried rotating the Y displacement vector with the orientation matrix, creating a 2nd matrix from the result and multiplying it with the orientation matrix, but that didn't work either.
I tried a lot of other things, but I cannot figure this. I am really upset about this darn 3D math crap. Cannot find something useful with Google either.
Edit:
I've got it. Was probably thinking too complicated.
Try direct UDP/IP.
#2 3D math
I need to know how to rotate a spatially arbitrarily oriented object around a certain object axis (that has also been displaced from the world axis).
Background: I am trying to implement rotating cameras which always should rotate around their vertical (Y) axis no matter how that axis is oriented relative to the word Y axis.
I have a position vector and a orientation matrix. I thought transforming the desired angle into a matrix and adding that to the orientation matrix would do the trick, but not so.
I also tried rotating the Y displacement vector with the orientation matrix, creating a 2nd matrix from the result and multiplying it with the orientation matrix, but that didn't work either.
I tried a lot of other things, but I cannot figure this. I am really upset about this darn 3D math crap. Cannot find something useful with Google either.
Edit:
I've got it. Was probably thinking too complicated.
Glad you got the math figured out. Those transform matrices can be tricky since they're order-dependent.
As for the multiplayer, I did try straight UDP/IP, though admittedly not exhaustively. I set up one machine to host and then pointed the other towards its IP, but nothing showed up in the "available games" list. I'll need to do some more testing, though, to be convinced that it's not working. Do you have a list of variables that should be accounted for when I try to be more thorough?
As for the multiplayer, I did try straight UDP/IP, though admittedly not exhaustively. I set up one machine to host and then pointed the other towards its IP, but nothing showed up in the "available games" list. I'll need to do some more testing, though, to be convinced that it's not working. Do you have a list of variables that should be accounted for when I try to be more thorough?