D2X - main function?

For all coding issues - MODers and programmers, HTML and more.

Moderators: Jeff250, fliptw

Post Reply
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

D2X - main function?

Post by Diedel »

Is there anybody around who knows how to create a D2X executable from the MSVC version?

I've got everything compiled (including SDL), but there is no main function. SDL offers a main function stub where you have to insert your program's main function code, but as already said, I don't know where that code is.

I have asked the guy maintaining the D2X project, but it looks like he cannot be arsed looking into D2x anymore. :cry:
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

Well I've got it to compile and run now.

Unfortunately, D2X CTD's even when run from the debugger in certain situations, probably due to a problem in an external component like a driver. That's really bad, because it's very hard to debug. :x
User avatar
SSX-Thunderbird
DBB Admiral
DBB Admiral
Posts: 1275
Joined: Sun Jun 03, 2001 2:01 am
Location: Washington (the state, not the city)

Post by SSX-Thunderbird »

I've gotten it to run without any problem from compiling. I've also made a few modifications to the copy I have :).
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

The question is whether you have been using the some public license compiler and the makefiles, or whether you have complete and working Microsoft Visual C++ work and project files.

I have created MSVC projects and workspace for D2X, and afaik there's none publicly availabe.

I've fixed the first problem in D2X btw: I expects each wall to have a wall at the opposite side if applicable (i.e. if the wall is not an overlay). Opening a wall that doesn't have a wall at it's opposite side did crash D2X - and my levels contain such walls to avoid hitting the wall number limit ... 8)

And btw.: The MSVC d2x OpenGL executable is about 750 KB, the 'official' one has about 1400 KB. That's almost double the size. I have some experience with GNU or GNU type C/C++ compilers, so I will not use them if I can ever avoid it. :P
User avatar
SSX-Thunderbird
DBB Admiral
DBB Admiral
Posts: 1275
Joined: Sun Jun 03, 2001 2:01 am
Location: Washington (the state, not the city)

Post by SSX-Thunderbird »

The copy I downloaded from CVS had project files for Visual C++ 6. I have .NET, which automatically made project files for its version (when I opened the VC++ 6 project file).
User avatar
Diedel
D2X Master
D2X Master
Posts: 5278
Joined: Thu Nov 05, 1998 12:01 pm
Contact:

Post by Diedel »

I had these project files too, and they didn't work for me - for whatever reason. So I took a look or two (at least :roll:) in the Makefile, figured the dependencies and required libraries, and built everything myself.

Which modifications did you add to your D2X copy? I'd probably like to integrate them into mine, if you do not have any objections. :)
User avatar
SSX-Thunderbird
DBB Admiral
DBB Admiral
Posts: 1275
Joined: Sun Jun 03, 2001 2:01 am
Location: Washington (the state, not the city)

Post by SSX-Thunderbird »

Just music, and some code to have any music playing shut off when a movie was to play (the original code for that was commented out for some odd reason).

Music is done with SDL_mixer, so if you want to use my code modifications, you'll need to get it :) (or I can pass the files along).

(EDIT)I have compressed the CVS snapshot that I have to RAR format, which took 40MB off the total size (50MB->10MB).
Post Reply