Go Back   EQEmulator Home > EQEmulator Forums > Support > Support::Windows Servers

Support::Windows Servers Support forum for Windows EQEMu users.

Reply
 
Thread Tools Display Modes
  #1  
Old 03-17-2005, 09:11 AM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Exclamation Trouble with DR3

Greetings,

Is there anyone out there who been able to successfully compile the current CVS dump (DR3) in windows using VS.NET 2k3? I was able to compile World.exe, EQsharemem.dll, however Zone.exe will not compile, due to numerous "Constant too big" errors, 33 to be exact. I read another post regarding this issue and nobody answered the person. Then I found another post about the same thing in which FNW replied saying to make the constants smaller. I go to the lines where these errors are listed at, and find nothing that looks like it needs to be, or even should be adjusted, and certainly doesn't look like the examples FNW gave.

If anyone has been able to get around this, please tell me how it is done, OR, if anyone is willing to share a copy of the latest perl-enabled compilation of Zone.exe (DR3) please PM me. I would prefer to do my own compiling but at this point am willing to settle for someone elses.

Thanks in advance.

Regards,
SI
Reply With Quote
  #2  
Old 03-17-2005, 10:52 AM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

SEARCH BUTTON IS YOUR FRIEND
__________________
Sysadmin.
Reply With Quote
  #3  
Old 03-18-2005, 02:21 AM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Default

First, that didn't help. I'm not looking for quick smart-ass replies, like "Search is your friend" because ...I did search, for a long time, and that is why I bothered to post in the first place. Second, the post you linked to does not help me.

Quote:
Then I found another post about the same thing in which FNW replied saying to make the constants smaller. I go to the lines where these errors are listed at, and find nothing that looks like it needs to be, or even should be adjusted, and certainly doesn't look like the examples FNW gave.
What you linked, is what I was referring to.

The examples he shows there does not even come close to anything shown on the lines that VS.NET reports the "Constant too big" error. Being that I am not a coder, I am unable to know what needs to be changed. I have never had a problem compiling the server binaries on my own till now, and that's what I need help with.

Still requesting help with this, or anyone generous enough to donate a DR3 Zone.exe. Thanks.

Regards,
SI
Reply With Quote
  #4  
Old 03-18-2005, 02:41 AM
mrea
Discordant
 
Join Date: Sep 2004
Location: Camp Hill,PA
Posts: 370
Default

If the post http://www.eqemulator.net/forums/sho...89&postcount=2 is what sysadmin linked it is exactly your problem. Do what it says and you'll be in good shape
Reply With Quote
  #5  
Old 03-18-2005, 03:49 AM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Default

Alright, I'm going to have to post some examples. What FNW shows in that thread is NOT what I'm seeing on the lines that show as containing errors. Here are a few examples:

This is what shows in the VS.NET compiler after trying to compile. This is just ONE example of 33 errors, all are the same, "Constant too big":
Quote:
c:\EQEmuCVS\Source\zone\AA.cpp(489): error C2177: constant too big
I then double click that to go right to that file and line to edit it, and find this:
Quote:
aps->experience = (int32)(((float)330.0f * (float)m_pp.expAA) / (float)max_AAXP);
Not the 99999990e111 type thing that FNW is talking about. Soo...what would I edit in that line? I tried adjusting the numbers in a few of these instances but nothing changed, or errors started showing up in other files. Please note that almost all of the errors that showed up contained lines like this one, with a lot of mumbo jumbo and no large arbitrary numbers such as those described by FNW.

Here's another example:
Quote:
c:\EQEmuCVS\Source\zone\aggro.cpp(896): error C2177: constant too big
Going there shows me this:
Quote:
float perwalk_x = 0.5;
There are 5 lines almost exactly like this in the code surrounding that line. Why are they not pointed out like this one?

I am very new at C++ coding. The extent of my abilities include creating a hello world program in the console, and (used to be) compiling EQemu flawlessly. When I look at lines like that above though, it's a foreign language to me. I am very willing to learn, and am currently making an attempt in my spare time to work on my C++ skills, but I really need help with this.

Regards,
SI

Last edited by sonicintuition; 03-18-2005 at 11:53 AM..
Reply With Quote
  #6  
Old 03-18-2005, 04:20 AM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default as is saif.. SEARCH IS YOUR FRIEND

Visual Studio Developer site says

Quote:
Compiler Error C2177
constant too big

A constant value is too large for the variable type it is assigned.

The following sample generates C2177:

// C2177.cpp
int main() {
int a=18446744073709551616; // C2177
int b=18446744073709551615; // OK
}

FNW knows his stuff, I don't but I was smart to find the same answer on VS2005 website and you did not, even when you searched "for a long time". Also you should rename yourself to sonic because as I see you have no intuition.
__________________
Sysadmin.

Last edited by sysadmin; 03-18-2005 at 12:24 PM..
Reply With Quote
  #7  
Old 03-18-2005, 04:41 AM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Default

As you can see in my above post, I clearly state that I am very new to C++ coding, and reading this stuff is like a foreign language. Being new I would have no clue if the errors are something native to the EQemu code itself or something that can be fixed with outside help, therefore I did not look outside the community for assistance. Now that you've explained that to me, I will do that. Thanks for your advice.

Regards,
SI
Reply With Quote
  #8  
Old 03-18-2005, 04:43 AM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

You are in a better position than me, I do not know ANY c or c++ or VC or any other flavor. I myself have been flamed MANY times because I did not searched for the answer, or was dumb enough to not find the answer on the internet.

I simply was pointing out that WE(includes me also) should do the best in our power to find the answer before buggin a developer since they have more important things to think about and solve before answering any of mine or anyone elses noob questions.
__________________
Sysadmin.

Last edited by sysadmin; 03-18-2005 at 12:47 PM..
Reply With Quote
  #9  
Old 03-18-2005, 04:52 AM
RangerDown
Demi-God
 
Join Date: Mar 2004
Posts: 1,066
Default

There's no need for the personal attacks. The code that SI is reporting is worthy of investigation, since 0.5 should be a perfectly valid value for a float. The MSKB article posted does little to remedy the fact that 0.5 is a nice middle-of-the-road value for a "float" type.

What may be wrong in this case is either the compiler you're using is somehow confused or improperly set, or the actual offender is one or two lines above or below the line number you're seeing in error messages. Your compiler may, for whatever reason, have a different idea of what a "float" is than the standard data type.

If others are getting C2177's on those very lines, then something may be wrong with the code. But I've visually verified the code you pasted follows proper syntax, and since you are the only one reporting errors there, we have to assume the problem lies in the compiler you are using.
__________________
<idleRPG> Rogean ate a plate of discounted, day-old sushi. This terrible calamity has slowed them 0 days, 15:13:51 from level 48.
Reply With Quote
  #10  
Old 03-18-2005, 09:51 AM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

In my experience with other programming languages the same compiler led to different errors when using different hardware, aside the options used to configure the compiler.

I think the best possible solution would be to search the knowledge base at the compiler's developer site. They might have already a solution, or at least a workaround.
.
__________________
Sysadmin.

Last edited by sysadmin; 03-18-2005 at 05:55 PM..
Reply With Quote
  #11  
Old 03-18-2005, 10:38 AM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

This might be irrelevant to the problem in VS2k3 but an interesting read, seems microsoft crippled the c compilers a long time ago due to a marketing decision.

Link

Jack Klein wrote:
Quote:
Re: Error C2177 Constant too big when compiling Gammal.c
On 3 Mar 2004 15:51:34 -0500, Antoun Kanawati <antounk@comcast.net> wrote in
comp.lang.c++.moderated:

Quote:
The constant is a "long double". VC++ 4.0 predates civilization and did not know about such types (long-double and long-long).
This is just plain wrong, at least about long double. Microsoft knew very well what long double was, from version 3.0 of their MS-DOS only Microsoft C compiler. They supported the Intel coprocessor/FPU 80 bit extended precision type.

This support continued through all of their 16-bit compilers (Microsoft C and C++ 7.0, and Visual C++ 1.52). It was only when they introduced Windows NT and 32 bit compilers that they made a marketing decision to drop extended precision type.

Their stated reason was that some of the processors for which they were planning to sell Windows NT did not have hardware support for floating point types wider than 64 bits. Their decision was that portability to other processors running Windows NT was more important than the programmer's decision whether or not to choose precision over compatibility.

You can see this on Microsoft's web site at the following link:

http://support.microsoft.com/support.../Q129/2/09.asp

Quote:
Try with a current gcc/g++ or VC++. I don't recall if VC++ 6.x has long doubles, but it's worth a try.
Visual C++ 4, 5, and 6 all supported long doubles. But they all implement long double as 64 bit FPU floating point types, identical with double. The last version of Visual C++ that supported 80 bit Intel FPU extended precision 80 bit types for long double was the last 16 bit compiler,
Visual C++ 1.52.

I wouldn't know if they have brought this support back in 7.0 or 7.1, but I doubt it.

Their marketing decision seriously cripples Visual C++ on the x86 for some types of serious numerical and engineering programming. Others, such as Borland and GCC, do not have this limitation.
.
__________________
Sysadmin.

Last edited by sysadmin; 03-18-2005 at 11:19 PM..
Reply With Quote
  #12  
Old 03-18-2005, 02:39 PM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Default

Thanks guys. Now that I have a clearer picture of why this may be happening I'm not so damned confused. I'm not even going to try compiling this any more, nothing I've tried is making anything any better. Changing numbers around only leads to more constant too big errors on other lines in other files. Messing with something this deep is just too much for someone with almost 0 experience in C++ coding. So I'll just let the developers do their thing for now.

I'm still requesting a copy of DR3's Zone.exe from anyone generous enough, since that is now my only option of getting it. I just wanted to test it out on my server, see the new bug fixes in action, etc. If anyone would be willing to lend a hand PM me. Thank you.

Regards,
SI
Reply With Quote
  #13  
Old 03-18-2005, 03:18 PM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

I would suggest you register on a Microsoft support forum and post the problem there. I am not sure you will get a solution, but at least would make microsoft aware of the error you are having.
__________________
Sysadmin.
Reply With Quote
  #14  
Old 03-19-2005, 02:30 AM
sonicintuition
Hill Giant
 
Join Date: Jan 2005
Posts: 124
Default

I'll probably do that because, despite my frustration, I'd still like to learn how to program with C++ and I'm sure there is a wealth of knowledge to be had there. Thanks again for the advice.

I've been offered a copy of Zone.exe for DR3 so I won't be posting about this anymore. Thanks to all who tried to help.

Regards,
SI
Reply With Quote
  #15  
Old 03-19-2005, 05:01 PM
sysadmin
Hill Giant
 
Join Date: Feb 2005
Posts: 163
Default

It seems this will not change anytime soon since they are still using 64bit long double double for variable structure.

This is straight from MS Visual Studio website:

Quote:
Double Structure
Represents a double-precision floating point number.

For a list of all members of this type, see Double Members.

System.Object
System.ValueType
System.Double

[Visual Basic]
<Serializable>
Public Structure Double
Implements IComparable, IFormattable, IConvertible
[C#]
[Serializable]
public struct Double : IComparable, IFormattable, IConvertible
[C++]
[Serializable]
public __value struct Double : public IComparable, IFormattable,
IConvertible
[JScript] In JScript, you can use the structures in the .NET Framework, but you cannot define your own.

Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Remarks
The Double value type represents a double-precision 64-bit number with values ranging from negative 1.79769313486232e308 to positive 1.79769313486232e308, as well as positive or negative zero, PositiveInfinity, NegativeInfinity, and Not-a-Number (NaN).
__________________
Sysadmin.

Last edited by sysadmin; 03-20-2005 at 01:03 AM..
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 03:24 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3