PDA

View Full Version : zoneing crash useing mw_052_053_alpha2


wize_one
01-22-2004, 11:35 AM
after i sourced in mw_052_053_alpha2.sql and walk into a zone line, client hangs and zone server gives error something about start zone or zone id(had to wipe DB so dont have exact error handy) and trying to send player to arena, simple fix was to use static zones. looking at the db.sql source and the source from mw_052_053_alpha2.sql they are a little diffrent.


from db.sql

CREATE TABLE start_zones (
x float NOT NULL default '0',
y float NOT NULL default '0',
z float NOT NULL default '0',
zone_id int(4) NOT NULL default '0',
player_deity int(4) NOT NULL default '0',
player_race int(4) NOT NULL default '0',
player_class int(2) NOT NULL default '0',
player_choice int(2) NOT NULL default '0'
) TYPE=MyISAM;

from mw_052_053_alpha2

CREATE TABLE start_zones (
x float NOT NULL default '0',
y float NOT NULL default '0',
z float NOT NULL default '0',
zone_id int(4) NOT NULL default '0',
bind_id int(4) NOT NULL default '0',
player_choice int(2) NOT NULL default '0',
player_class int(2) NOT NULL default '0',
player_deity int(4) NOT NULL default '0',
player_race int(4) NOT NULL default '0',
start_zone int(4) NOT NULL default '0'
) TYPE=MyISAM;


could the restructure of this table be causeing it?

Lurker_005
01-22-2004, 05:36 PM
Not likely, the two extra fields and differance in order should not affect it.

But what version of EQEmu is that db.sql from?

wize_one
01-22-2004, 09:24 PM
the db.sql was from eqemu 0.5.2

wize_one
01-22-2004, 11:38 PM
just sourced in mw_052_053_alpha2.sql again(no changes made to it)

did #zone qey2hh1 client locked up.

world.exe reports

[Error] Zone not found in database zone_id=0, moveing char to arena character:testmonk


also getting(this is new with this resourceing)

Unable to get group id: #1054: Unknown column 'groupid' in 'field list'

screamingogre
01-23-2004, 01:41 AM
For the zoneid not found issue, I had the same problem. But i determined it was due to a timing issue between zone.exe updating the database while world was trying to grab the data. I made a code fix (a DO while loop with an increment counter) around the DB call in client.cpp for the world executable and it solved the problem. I'll post my code here when I get back home later today.

For the groupID issue, go here for the fix.
http://www.eqemulator.net/forums/viewtopic.php?t=12310

On a side note I know some people are not having the zoneid issue while some are. I'm interested in knowing the system specs of the people who are having this issue. My theory is either slow machines or possibly even AMD chips might be the culprit.

**SO

screamingogre
01-23-2004, 11:29 AM
This is the fix I made to get rid of the ZoneID =0 error.

Add this to the Client.cpp file for the world compile. Under case OP_EnterWorld: // Enter world.

Replace the Current call "charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);" with this



long LOCounter;
do {
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
LOCounter++;
}while ((zoneID == 0) && (LOCounter > 10000));

This will call the database until the ZoneID is not equal to 0 or the counter hits 10001. You may need to tweek the counter number for your server depending on how fast or slow it is.

**SO

wize_one
01-23-2004, 09:05 PM
8( some of us dont have a compiler..8(

Squiffy
01-24-2004, 06:30 AM
Then there's not much you can do, unless you wait for the next version of EQEmu.

wize_one
01-24-2004, 08:14 AM
can some kind soul with a compiler please post up a fixed version.

it's so hard to try and work on everything when you have to cntl-alt-del because the game has locked up.

Cyril Gray
01-24-2004, 09:03 AM
wize_one,

Have you looked into a free C++ compiler off of the Internet?

While I haven't tried compiling the source code on one, it may be worth a try.

Here is a link to one resource:

http://www.thefreecountry.com/compilers/cpp.shtml

Tertiary
01-24-2004, 09:16 AM
wize_one,

Have you looked into a free C++ compiler off of the Internet?

While I haven't tried compiling the source code on one, it may be worth a try.

Here is a link to one resource:

http://www.thefreecountry.com/compilers/cpp.shtml

Dev-C++ works, you could try my guide:

http://www.eqemulator.net/forums/viewtopic.php?t=12313

However, be aware that you won't get any official support with binaries compiled via this method, but I will try and help if you want to give it a try.

flyonthewall
01-24-2004, 07:56 PM
long LOCounter;
do {
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
LOCounter++;
}while ((zoneID == 0) && (LOCounter > 10000));





This is awsome bro, I have been having the problem of being booted from the zone and my client hanging quite often and this fixed it. (Even though im running a completly localserver with no lag so apparenty that error isnt based up speed of the server itself)

Did the run from South Qeynos to East Freeport to test it and it worked great, only hit a snag when zonning into West Freeport when I got the dreaded "SOE has detected that your EQ client crashed" thingy but that prob a totally different error.

Finnaly got into looking as to why i couldnt compile under VS6 and found out I had downloaded the wrong zlib files. Didnt know anything about programming but i really wanted to use this code and get that problem fixed so I spent some time and realized my mistake so now i can start implenting code from people that know code into my server so things are starting to look up! :D

/exhausted ON

Thanks again and again for this nifty quick fix to that prob!

P.S. also getting the group_id error but i got it evertime i zoned and no real issue so i not bothering with it. Now time to work on spawns and zone lines, safe points ect....

jbb
02-08-2004, 05:34 AM
This "fix" doesn't look right to me.,
At the very least you need to initialize the counter variable, and then I think the test is the wrong way round too...

Monrezz
02-08-2004, 08:16 AM
long LOCounter;
do {
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
LOCounter++;
}while ((zoneID == 0) && (LOCounter > 10000));

This will call the database until the ZoneID is not equal to 0 or the counter hits 10001. You may need to tweek the counter number for your server depending on how fast or slow it is.
**SO

What values do you mean? Decrease it if you have more power, increase if your running on a less powerful system?

farce
02-08-2004, 10:37 AM
no, the other way around... faster machines will complete the loop quicker.. and the value may still not be available.. so you'd increase it.

toolh3
02-08-2004, 03:53 PM
I based mine on time passed, that way it doesn't matter how fast your machine is. This code waits 20 seconds before it gives up. Note that if it does get a good zone id, it breaks out of the loop.

__time64_t curtime1,curtime2;
_time64(&curtime1);
do
{
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
_time64(&curtime2);
}while(curtime2 - curtime1 <= 20 && zoneID == 0);

Monrezz
02-10-2004, 07:11 AM
__time64_t curtime1,curtime2;
_time64(&curtime1);
do
{
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
_time64(&curtime2);
}while(curtime2 - curtime1 <= 20 && zoneID == 0);


Has anyone using Dev-C++ or Win32 tried to compile using this? I get the following log when trying to compile:

Compiler: Default compiler
Building Makefile: "C:\EQEmu\cvs\eqemu\eqemu\Dev-C++ Compat\world\Makefile.win"
Executing make clean
rm -f client.o console.o LoginServer.o net.o zoneserver.o ../common/classes.o ../common/crc32.o ../common/database.o ../common/dbasync.o ../common/dbcore.o ../common/DBMemLeak.o ../common/debug.o ../common/EMuShareMem.o ../common/EQEMuError.o ../common/EQNetwork.o ../common/eqtime.o ../common/guilds.o ../common/Item.o ../common/md5.o ../common/misc.o ../common/MiscFunctions.o ../common/moremath.o ../common/Mutex.o ../common/packet_dump.o ../common/packet_dump_file.o ../common/packet_functions.o ../common/races.o ../common/serverinfo.o ../common/TCPConnection.o ../common/timer.o ../common/Portable_vsnprintf.o World_private.res World.exe

g++.exe -c client.cpp -o client.o -I"C:/Dev-C++/include/c++" -I"C:/Dev-C++/include/c++/mingw32" -I"C:/Dev-C++/include/c++/backward" -I"C:/Dev-C++/include" -I"c:/eqemu/zlib" -I"c:/mysql/include" -D__GNUWIN32__ -w -finline-functions -DWORLD -DSHAREMEM -DINVERSEXY -D_WIN32_WINNT=0x0400 -DWIN32 -D_CONSOLE -D_MBCS -DFIELD_ITEMS -DSHAREMEM -fexpensive-optimizations

client.cpp: In member function `bool Client::HandlePacket(const APPLAYER*)':
client.cpp:486: `__time64_t' undeclared (first use this function)
client.cpp:486: (Each undeclared identifier is reported only once for each
function it appears in.)
client.cpp:486: parse error before `,' token
client.cpp:487: `curtime1' undeclared (first use this function)
client.cpp:487: `_time64' undeclared (first use this function)
client.cpp:491: `curtime2' undeclared (first use this function)

make.exe: *** [client.o] Error 1

Execution terminated

Looks pretty simple to fix...but I know no C at all :(

Any help would be appreciated,

Monrezz

wagenworld
02-28-2004, 10:05 AM
I seem to be having the same problem.

I've had a great time setting it up. I absorbed the boards and searched twice for all of my questions. I've edited database tables, added and removed fields. I'm having a great time! :D

I am not able to zone however. It's 4pm now and i've been fiddling with everything I could get my hands into all day. I've broke it and fixed it all day long.... Last night was the server set up.

I suppose the next thing to do is start playing with the code. That I will save for tomorow.

Wag
yikes, is this my first post?

Rogean
03-06-2004, 08:55 PM
This is the fix I made to get rid of the ZoneID =0 error.

Add this to the Client.cpp file for the world compile. Under case OP_EnterWorld: // Enter world.

Replace the Current call "charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);" with this



long LOCounter;
do {
charid = database.GetCharacterInfo(char_name, &tmpaccid, &zoneID);
LOCounter++;
}while ((zoneID == 0) && (LOCounter > 10000));

This will call the database until the ZoneID is not equal to 0 or the counter hits 10001. You may need to tweek the counter number for your server depending on how fast or slow it is.

**SO

Id just like to point out that i was having the zoneid=0 problem, and was getting frustrated, Until i noticed that:
}while ((zoneID == 0) && (LOCounter > 10000));
should be
}while ((zoneID == 0) && (LOCounter < 10000));

Its checking if LOCounter is LESS THAN 10k and entering the loop if is, and increasing it by 1 every time it loops until its GREATER THAN 10k.

And that's rogean's math lesson of the day. tks

jbb
03-07-2004, 12:43 AM
Id just like to point out that i was having the zoneid=0 problem, and was getting frustrated, Until i noticed that:
}while ((zoneID == 0) && (LOCounter > 10000));
should be
}while ((zoneID == 0) && (LOCounter < 10000));

Hehe, I pointed this out about 10 messages ago - although to be fair my message wasn't very clear. Also LOCounter is uninitialised too in the version of code printed. Best add an "=0" to it's declaration.