The Ur-Quan Masters Home Page Welcome, Guest. Please login or register.
Did you miss your activation email?
November 05, 2024, 11:37:09 am
Home Help Search Login Register
News: Celebrating 30 years of Star Control 2 - The Ur-Quan Masters

+  The Ur-Quan Masters Discussion Forum
|-+  The Ur-Quan Masters Re-Release
| |-+  General UQM Discussion (Moderator: Death 999)
| | |-+  Hires Netmelee Improvement Mod: Help needed
« previous next »
Pages: [1] 2 Print
Author Topic: Hires Netmelee Improvement Mod: Help needed  (Read 5494 times)
oldlaptop
*Smell* controller
****
Offline Offline

Posts: 337



View Profile
Hires Netmelee Improvement Mod: Help needed
« on: January 30, 2013, 11:44:44 pm »

I've been working on porting the Netmelee Improvement Mod to the HD Mod codebase. Unfortunately, I've run into a snag - the Windows executables I've built with my cross compiler have exhibited strange bugs, and I don't have access to any other compilers for further testing (or any knowledge of Windows development for debugging). If someone out there could build this code for Windows, preferably with MSVC, and post it for testing, I'd be greatly appreciative. Smiley (The code is incidentally known to build and run on Linux just fine, I have no idea if/how well it works on OSX.)

https://github.com/oldlaptop/Hires-Shiver-Balance-Mod
Logged

Play Supermelee online in #uqm-arena!
Netmelee Improvement Mod
Defender
Enlightened
*****
Offline Offline

Gender: Male
Posts: 817



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #1 on: January 31, 2013, 01:29:58 am »

very interested in this.

this is what i get...

src/uqm/restart.c:83: error: `resFactorWasChanged' undeclared (first use in this function)
src/uqm/restart.c:83: error: (Each undeclared identifier is reported only once
src/uqm/restart.c:83: error: for each function it appears in.)
src/uqm/restart.c: In function `DoRestart':
src/uqm/restart.c:192: error: `resFactorWasChanged' undeclared (first use in this function)
make: *** [obj/release/src/uqm/restart.c.o] Error 1
« Last Edit: January 31, 2013, 01:51:42 am by Defender » Logged
superbutcherx
*Many bubbles*
***
Offline Offline

Posts: 116



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #2 on: January 31, 2013, 11:25:31 am »

very interested in this.

this is what i get...

src/uqm/restart.c:83: error: `resFactorWasChanged' undeclared (first use in this function)
src/uqm/restart.c:83: error: (Each undeclared identifier is reported only once
src/uqm/restart.c:83: error: for each function it appears in.)
src/uqm/restart.c: In function `DoRestart':
src/uqm/restart.c:192: error: `resFactorWasChanged' undeclared (first use in this function)
make: *** [obj/release/src/uqm/restart.c.o] Error 1


That might be the same as the issue fixed in r972 (http://code.google.com/p/uqm-hd/source/detail?r=972):
Try including "options.h" in restart.c.
Logged
oldlaptop
*Smell* controller
****
Offline Offline

Posts: 337



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #3 on: January 31, 2013, 10:00:46 pm »

That might be the same as the issue fixed in r972 (http://code.google.com/p/uqm-hd/source/detail?r=972):
Try including "options.h" in restart.c.

Yes, I found that out the hard(er) way Wink
Logged

Play Supermelee online in #uqm-arena!
Netmelee Improvement Mod
Defender
Enlightened
*****
Offline Offline

Gender: Male
Posts: 817



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #4 on: February 01, 2013, 01:33:04 am »

i have that same problem we talked about. the melee graphics are messed up.
Logged
daddyo
Zebranky food
*
Offline Offline

Posts: 22



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #5 on: February 01, 2013, 08:07:48 am »

Sorry been really busy this week, I'll give it a try compiling Monday.  Darn zlib...

An encouraging statement at the top of zlib.h:  /* various hacks, don't look Smiley */
« Last Edit: February 04, 2013, 10:10:58 pm by daddyo » Logged
daddyo
Zebranky food
*
Offline Offline

Posts: 22



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #6 on: February 04, 2013, 10:46:47 pm »

I have a Project 6014 Visual C 2010 uqmdebug.exe!  Miracles can happen, although the source I started with was missing functions, so I worked around them for the moment.  I compiled it with static libraries since I'm not sure why dll's would be used when I believe they are never shared on the installs, and probably wouldn't want to anyway.  Given that the .exe is 3 megabytes in size, can't possibly be an issue with disk space!

Now I'm trying your guys codeline...
« Last Edit: February 04, 2013, 10:48:33 pm by daddyo » Logged
daddyo
Zebranky food
*
Offline Offline

Posts: 22



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #7 on: February 04, 2013, 11:51:47 pm »

A few compile errors so far:

error C2275: 'FRAME' : illegal use of this type as an expression   C:\...\sc2\sc balance mod\src\uqm\tactrans.c   line 388   col 1
error description:

'identifier' : illegal use of this type as an expression

An expression uses the -> operator with a typedef identifier.

The following sample generates C2275:

View ColorizedCopy to ClipboardPrint// C2275.cpp
  typedef struct S {
      int mem;
  } *S_t;
  void func1( int *parm );
  void func2() {
      func1( &S_t->mem );   // C2275, S_t is a typedef
  }
 
error C2275: 'PRIMITIVE' : illegal use of this type as an expression   C:\...\sc2\sc balance mod\src\uqm\tactrans.c   line 725   col 1

error desc: (same as above)

IntelliSense: a value of type "void *" cannot be assigned to an entity of type "STARSHIP *"   c:\...\sc2\sc balance mod\src\uqm\tactrans.c   line 307, 357, 711, 741   col 2, 4, 2, 4

error desc: none available

Hope this helps.  If you have suggestions for changes I'll try them. 
Logged
oldlaptop
*Smell* controller
****
Offline Offline

Posts: 337



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #8 on: February 05, 2013, 12:43:15 am »

MSVC may be irritated that the variable declarations it's complaining about (in the C2275 errors) don't occur right at the top of their respective blocks, you could try putting them there. If that fixes the errors for you I'll change them in git.

Intellisense would seem to be complaining about a macro used throughout UQM source, I'd be willing to bet it says that about most files in vanilla UQM too.
Logged

Play Supermelee online in #uqm-arena!
Netmelee Improvement Mod
Elestan
*Smell* controller
****
Offline Offline

Posts: 431



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #9 on: February 05, 2013, 04:22:14 pm »

IntelliSense: a value of type "void *" cannot be assigned to an entity of type "STARSHIP *"   c:\...\sc2\sc balance mod\src\uqm\tactrans.c   line 307, 357, 711, 741   col 2, 4, 2, 4
MSVC may be irritated that the variable declarations it's complaining about (in the C2275 errors) don't occur right at the top of their respective blocks, you could try putting them there. If that fixes the errors for you I'll change them in git.

Intellisense would seem to be complaining about a macro used throughout UQM source, I'd be willing to bet it says that about most files in vanilla UQM too.

Yes.  Intellisense is attempting to enforce the stricter C++ type conversion rules, which don't allow implicit conversion from a void pointer to a typed pointer.  However, you're allowed to get away with it in C.
Logged
onpon4
Enlightened
*****
Offline Offline

Gender: Male
Posts: 709


Sharing is good.


View Profile WWW
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #10 on: February 05, 2013, 04:44:53 pm »

C++ and C aren't the same language. UQM's code is in C, not C++, so you ought to be using a C compiler.
Logged

Elestan
*Smell* controller
****
Offline Offline

Posts: 431



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #11 on: February 05, 2013, 04:56:55 pm »

C++ and C aren't the same language. UQM's code is in C, not C++, so you ought to be using a C compiler.

VC++ does include a C compiler, but that error is from Intellisense, the realtime syntax checker, which only understands C++.  I'd probably turn it off for C projects.

There should be fewer of these warnings in the current SVN for core; I went through and cleaned up some (though far from all) of the C++/C incompatibilities a while ago.
Logged
daddyo
Zebranky food
*
Offline Offline

Posts: 22



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #12 on: February 05, 2013, 10:57:07 pm »

I got rid of all the compile errors, but did it the hard way by moving some variable declarations to the tops of functions and explicit casting, the latter is a good idea anyway.  I never understood why VC makes you put variables at the tops sometimes, I think it's been that way for a long time though, I just forgot about it.  I did try to turn off C++ checks for at least the troublesome file but didn't seem to make a difference, but did find the turn off intellisense errors so it compiles w/o explicit casting.

Now I'm getting these 5 link errors, seem to be missing some functions:
unresolved external symbol _init_talkpet_comm referenced in function _init_race   C:\...\sc balance mod\build\msvc6\commglue.obj   UrQuanMasters

unresolved external symbol _generateZoqFotPikColony1Functions   C:\...\sc balance mod\build\msvc6\gendef.obj   UrQuanMasters

unresolved external symbol _generateZoqFotPikColony0Functions   C:\...\sc2\sc balance mod\build\msvc6\gendef.obj   UrQuanMasters

unresolved external symbol _generateZoqFotPikScoutFunctions   C:\...\sc balance mod\build\msvc6\gendef.obj   UrQuanMasters

unresolved external symbol _generateTalkingPetFunctions   C:\...\sc balance mod\build\msvc6\gendef.obj   UrQuanMasters

I think I've an incomplete build from your download link,
« Last Edit: February 05, 2013, 11:08:23 pm by daddyo » Logged
oldlaptop
*Smell* controller
****
Offline Offline

Posts: 337



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #13 on: February 05, 2013, 11:15:09 pm »

Github provides automagically generated .zips of repositories:

https://github.com/oldlaptop/Hires-Shiver-Balance-Mod/archive/master.zip

If that's what you're having problems with... gee, I guess you could try cloning the git repository and working from that.
Logged

Play Supermelee online in #uqm-arena!
Netmelee Improvement Mod
Elestan
*Smell* controller
****
Offline Offline

Posts: 431



View Profile
Re: Hires Netmelee Improvement Mod: Help needed
« Reply #14 on: February 06, 2013, 02:22:59 am »

I never understood why VC makes you put variables at the tops sometimes, I think it's been that way for a long time though, I just forgot about it.
It does this for files that end in .c, because the C89 standard required it.  Newer versions of C stopped requiring it, but VC still enforces the old rule.
Logged
Pages: [1] 2 Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!