D2X-W32 Linux port

A forum just for you old time Descent and Descent2 players.
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

just noticed a serious bug during gameplay:

Whenever you fire you primary or secondary weapon, the weapon/missle doesn't move...it just draws itself in front of the ship, and it doesn't move. After about 10 seconds, the laser or missle disappears. You can even fly around the missles and reenact a scene from the matrix (but that's not the point)....also, not all area experience this problem. Sometimes the weapons do shoot like they suppose to, but most of the time they don't
User avatar
kaelan
DBB Ace
DBB Ace
Posts: 42
Joined: Tue Nov 22, 2005 2:51 pm
Contact:

Post by kaelan »

This is probably due to the vector calculations (vec_mag_quick I believe). One of the usages (vec_dist_quick?) was changed over, but I had to change both over for the OS X port. Perhaps it should be both for Linux as well.
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Kirby seems not to have the most recent source code. That bug has been fixed in 1.5.27.
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

Diedel wrote:Kirby seems not to have the most recent source code. That bug has been fixed in 1.5.27.
you mean 1.5.28 :P

one serious bug down...one to go: The robots are hyperactive when it comes to their movements. One second I'm alone in a hallway, and the next second I get rammed a thousand times by one of those hornet robots (for a second there, I almost typed horney :p )

Also (just introduced with 1.5.28 )...when I try to quit, KDE literally locks up....can't do a CTRL+ALT+ESC or a CTRL+ALT+Backspace....I have to reset every time now.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

Kirby wrote:
Diedel wrote:Kirby seems not to have the most recent source code. That bug has been fixed in 1.5.27.
you mean 1.5.28 :P

one serious bug down...one to go: The robots are hyperactive when it comes to their movements. One second I'm alone in a hallway, and the next second I get rammed a thousand times by one of those hornet robots (for a second there, I almost typed horney :p )

Also (just introduced with 1.5.28 )...when I try to quit, KDE literally locks up....can't do a CTRL+ALT+ESC or a CTRL+ALT+Backspace....I have to reset every time now.
deidel ... this is what i was talking abot on linux forums ... 1.5.27 guidebot smokes crack and does speed and robots seem to be all sorts of incongruent :)
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Hm. I had found a vector math function that works on Win32 not working on Linux and Mac OS X, so I had replaced a call to it by a function that does what it's supposed to do.

After your continuous (justified) complaints, I have now investigated further into the matter and found that the broken function is called at several other places.

A quick fix for you is to open maths/vecmat.h, search for "fix_vec_mag_quick" and replace the non-WIN32 branch of the function with the following (yellow) code:
maths/vecmat.c wrote:fix vm_vec_mag_quick (fix a, fix b, fix c)
#ifdef _WIN32
_asm {
...
}
#else
vms_vector v = {a,b,c};
return vm_vec_mag (&v);

#endif
}
I will post a source update in the next few minutes as well.

I am really asking myself why in all the earth this works on Win32, but not on Linux (even with comparable hardware), or on Mac OS X. Probably a compiler problem (different code generation). The assembly code I have written for the Win32 version is the exact equivalent of the C code for the other OS's.
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

very nice....game is perfect now :)

now the only problem left is the lockup when quitting (either from the main menu option, or the window's X button) Upgraded to KDE 3.5 and the latest source code of D2x-XL didn't fix it...

btw...KDE 3.5 is freakin' sweet :)
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

hrmpf ... no lockup with Gnome ...
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

damn....

It must be something you did between the 1.5.27 and 1.5.28 releases.....cause it was quitting fine before then
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Maybe kaelan did it. ;)
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

1. appreciate the work you are doing.

ok, now here is my current issue. i just compiled your new source (1.5.29), although i have not seen so many WARNINGs during a make in my life, it finished and i was on my way back in. menus work fine, but when i get into a game the screen blacks and the monitor clicks as if not syncing. this wasn't a problem before. any ideas?

*edit* front screen says version 1.5.28. also, i have sound, and input works (i can hear myself shoot :))
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Linux is not yet at 1.5.29. You'd need to check out the source code from the SVN to get up-to-date source code. I will check this and come back to you later.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

Diedel wrote:Linux is not yet at 1.5.29. You'd need to check out the source code from the SVN to get up-to-date source code. I will check this and come back to you later.
yeah... like i said in the edit it is 1.5.28, i was going by the header top of the page. i will check out the svn tonight when i get home from work and let you know. if you can take a poke at it too i would appreciate it, 1.5.27 looked great... the robots were just psychotic.
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

No problems here. If you have a ~/.d2x-xl, put a semicolon in front of the fullscreen option and see whether the program works in windowed mode.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

running it windows helped me figure something out. windowed it bounces back and forth between 1280x1024 and a much smaller automap which is one of my 'cockpit windows', this is the case with every resolution i run. if i switch pilots and don't use the map window i have no problems, if i switch (F3) to the widescreen mode, it runs fine. so it appears that for me it is the map windows. any ideas on this one???
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Yeah, your gfx driver.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

so you dont have the same problem running the automap in a cockpit window?

it seems odd since this is something new, this worked find previously.
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Actually, I can't tell until monday.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

well until then ... i will just play without the automap in the cockpit windows, seems like a pretty small thing. im not about do go digging through driver archives to find an older driver just yet, i wanna hear for sure that no one else is having trouble, espcecially since this wasnt a problem before the last update. :)
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

If your drivers are up-to-date, don't bother changing them. I find this pretty amazing though, as I wouldn't know of any recent changes to the OpenGL code.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

yeah ... well i am using the same nvidia drivers ... 7676, and nothing about this system has changed between your builds.

i am baffled by it as well, but i will continue to wait until i find out if you have any issues with running the automap in a cockpit window.

it is strange.
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

No problems here (v1.5.33 currently) with openSUSE 10. Low end NVidia gfx card.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

well damn... time to start messing around. i have 1.5.30, but i get 1.5.33 and see what happens. then i will start messing around with gl libraries. but man ... i am really confused why it worked... then it didn't lol.
worst cast scenario is that i dont get to use that automap feature.

(i dont suppose there is a way for you to add the ability to change which cockpit windows you are using in the options menu...) :D
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

You can toggle through all cockpit window types with Shift+F2 and Shift+F3 (left/right window).
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

except when experiencing the problems that i am with said cockpit windows. shift+f2 only recognizes f2... or shift... but never both :(
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

This works for me on my Linux box (openSUSE 10.0). You do have SDL 1.2.8-8 installed?
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

Diedel wrote:This works for me on my Linux box (openSUSE 10.0). You do have SDL 1.2.8-8 installed?
yup... how do you think i got it installed in the first place. :)

(openSUSE 10.0)
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

with the new Linux 1.5.34 release, my freezing problems just got a hell of alot worse....

Linux freezes now on startup of d2x-xl (before the intro movie even plays)...of course, the only way to get by now is to reset my machine.

what's going on here?? :?
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

Kirby wrote:with the new Linux 1.5.34 release, my freezing problems just got a hell of alot worse....

Linux freezes now on startup of d2x-xl (before the intro movie even plays)...of course, the only way to get by now is to reset my machine.

what's going on here?? :?
u can't kill x? (ctrl-alt-backspace by default)

linux normally doesnt lock up... its the x server / window manager. just a suggestion. :)
User avatar
Kirby
DBB Ace
DBB Ace
Posts: 151
Joined: Thu Nov 03, 2005 7:27 pm

Post by Kirby »

correct....can't kill X, can't switch between different sessions. Only thing I can do is restart

There's little I can do on my part....I could recompile xorg and update to the latest ATi drivers (ugh...ATi). And if that fails, I could try compiling the debug version of d2x-xl again, and hopefully an error prints out before the freeze....but other than that, I dunno.... :/
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Get v1.5.37 first, just updated it.

I have none of the problems described here with d2x-xl on Linux, so unfortunately I cannot help you here.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

1.5.37

alright, here is the problem now. everything copiles just fine, but when running the executable binary, the d2x-xl window opens for a moment then immediatly closes without an error message (exactly as it did when i had the game data in the wrong directory before). since the game data hasn't moved, i am wondering if you know why this would be?

sh autogen.sh
./configure --enable-release=yes
make
rename d2x-gl d2x-xl
strip ./d2x-xl
cp ./d2x-xl /usr/local/bin
cp ./d2x-xl /usr/local/share/d2x-xl
d2x-xl

seems i just making all sorts of backwards progress here, everything worked great at first, then you updated and the robots went crazy, then you updated and my automap cockpit window went crazy, now i can't get the damn thing to run... lol ... i should quite while i was behind.

please help! :) (is the current executable on your site 1.5.37?)
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Usually this happens when d2x-xl doesn't find something ... I will check this again.

Current Linux binary is 1.5.37 (binaries are always sync'd with source).

Edit: d2x-xl linux doesn't find the data files if they're in the D2 main and not the data subfolder. Grrrr. Everytime I fix this for one OS, it fails on another.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

hmm... all the data is in its respective directories, not in the main... i did use a script to rename all the files as lowercase... out of habit, since we all know linux has issues with files that are 'differently cased'. :)
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Try 1.5.39 (1.5.40 on the way, btw. :roll: )
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

lol ... :) ok
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

your executable on the site did the same thing, so tomorrow when i am awake i will try to compile it. but i don't have much hope. :(
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Can you post a directory listing of your D2 folder with all subdirectories and their contents please?

I will also prepare a binary creating some informational output to ~/d2x.log to hopefully give some hints about what's going on here.
fyrephlie
DBB Benefactor
DBB Benefactor
Posts: 956
Joined: Tue Nov 15, 2005 12:49 am

Post by fyrephlie »

Code: Select all

fyrephlie@linux:/usr/local/share/d2x-xl> ls
afi.plr     cambot.hxm           d2x-h.mvl    d2x-xl          descent2.exe  descentg.ini          endnote.txt   groupa.256   ice.256      palette.256   setup.exe
alien1.256  credits.256          d2x.ini      d2x-xl-old      descent2.ham  descent.hi            eregcard.exe  groupa.pig   ice.pig      pcxview.exe   src
ALIEN1.256  d2_1x_to_12.exe      d2x-l.mvl    d2x-xl-src.tgz  descent2.hog  descent.ico           eregcard.ini  hmidet.386   intro-h.mvl  readme.txt    water.256
alien1.pig  d2.bat               d2x-sdl      default.plr     descent2.s11  Descent II Win95.exe  fire.256      hmidrv.386   missions     rename.sh     water.pig
alien2.256  D2 Win95 Readme.doc  d2x-w32.ico  deisl1.isu      descent2.s22  descent.png           fire.pig      hmimdrv.386  modem.lst    robots-h.mvl
alien2.pig  d2x-gl               d2x-w32.png  demos           descent.cfg   drgnfli.plr           fyre.plr      hoard.ham    other-h.mvl  robots-l.mvl

Code: Select all

fyrephlie@linux:/usr/local/share/d2x-xl/missions> ls
ambage.hog  cd1225.mn2    d2chaos.hog   descent.b50   dissent2.mn2  hashbash.hog  min69.mn2     minerva5.hog  neptune.txt   pullteth.mn2    thas.hog      (unttl)2.mn2  yeeha.mn2
ambage.mn2  chaos.hog     d2chaos.mn2   descent.faq   dissent2.txt  hashbash.mn2  minerv21.hog  minerva5.mn2  nirvana.htm   pullteth.txt    thas.mn2      vamped.hog
ambage.txt  chaos.msn     d2x.hog       descent.hog   getsmrt2.hog  hashbash.txt  minerv21.mn2  minerva5.txt  nwtr.hog      revival_13.rtf  thetoe.hog    vamped.mn2
carma.hog   crazines.hog  d2x.mn2       descent.m50   getsmrt2.mn2  keparty2.hog  minerv21.txt  neptune2.hog  nwtr.mn2      revnic.hog      thetoe.mn2    vamped.txt
carma.mn2   crazines.mn2  dementia.hog  descent.phx   gunner.hog    keparty2.mn2  minerva3.hog  neptune2.mn2  panic.hog     revnic.mn2      ultraes.hog   wizzer.hog
carma.txt   d2-2plyr.hog  dementia.mn2  descent.pig   gunner.mn2    kparty2.txt   minerva3.mn2  neptune.hog   panic.mn2     stadium2.hog    ultraes.mn2   wizzer.mn2
cd1225.hog  d2-2plyr.mn2  descent2.adv  dissent2.hog  gunner.txt    min69.hog     minerva3.txt  neptune.mn2   pullteth.hog  stadium2.mn2    (unttl)2.hog  yeeha.hog

Code: Select all

fyrephlie@linux:/usr/local/share/d2x-xl/demos> ls
descent2.dem  descent.dem

Code: Select all

you already know whats in /src
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

firefly,

d2x-xl v1.5.41-Linux has some logging to ~/d2x.log built into it. Get the binaries, run the program, and post the contents of that file here please. :)
Post Reply