Prerequisites and Building

Here we speak about Code and Design.
User avatar
nemerle
Posts: 398
Joined: Thu Jan 10, 2013 3:40 pm

Post by nemerle » Mon Sep 11, 2006 11:02 pm

Nah, no reason to, this would be pointless.
"Ich was in one sumere dale,
in one suthe diyhele hale,
iherde ich holde grete tale
an hule and one niyhtingale."

PotajiTo
Posts: 10
Joined: Mon Aug 14, 2006 10:22 pm

Post by PotajiTo » Sat Sep 16, 2006 9:18 am

Hi, just wanted to know if it's normal that I had to install boost, because you didn't said anything about it.

User avatar
nemerle
Posts: 398
Joined: Thu Jan 10, 2013 3:40 pm

Post by nemerle » Sat Sep 16, 2006 10:18 am

Yes it's normal, and it's my mistake, sorry.
"Ich was in one sumere dale,
in one suthe diyhele hale,
iherde ich holde grete tale
an hule and one niyhtingale."

desinger
Posts: 5
Joined: Mon Sep 11, 2006 12:25 pm

Post by desinger » Sun Sep 17, 2006 4:23 pm

another error where i go wrong ???
[quote:4b42c800b5]EntityStorage.cpp
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2039: 'getCharEntity' : is not a member of 'Client'
D:\\cohemu\\Common\\include\\Client.h(33) : see declaration of 'Client'
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2227: left of '->m_char' must point to class/struct/union/generic type
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2228: left of '.serializeto' must have class/struct/union
Entity.cpp
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2039: 'getCharEntity' : is not a member of 'Client'
D:\\cohemu\\Common\\include\\Client.h(33) : see declaration of 'Client'
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2227: left of '->m_char' must point to class/struct/union/generic type
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2228: left of '.serializeto' must have class/struct/union
d:\\cohemu\\MapServer\\src\\Entity.cpp(22) : warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
d:\\cohemu\\MapServer\\src\\Entity.cpp(34) : warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
d:\\cohemu\\MapServer\\src\\Entity.cpp(35) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
MapHandler.cpp
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2039: 'getCharEntity' : is not a member of 'Client'
D:\\cohemu\\Common\\include\\Client.h(33) : see declaration of 'Client'
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2227: left of '->m_char' must point to class/struct/union/generic type
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2228: left of '.serializeto' must have class/struct/union
d:\\cohemu\\MapServer\\src\\MapHandler.cpp(35) : error C2065: 'm_client' : undeclared identifier
d:\\cohemu\\MapServer\\src\\MapHandler.cpp(35) : error C2227: left of '->setCharEntity' must point to class/struct/union/generic type
type is ''unknown-type''
d:\\cohemu\\MapServer\\src\\MapHandler.cpp(73) : error C2227: left of '->getCharEntity' must point to class/struct/union/generic type
type is ''unknown-type''
MapServerEndpoint.cpp
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2039: 'getCharEntity' : is not a member of 'Client'
d:\\cohemu\\common\\include\\Client.h(33) : see declaration of 'Client'
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2227: left of '->m_char' must point to class/struct/union/generic type
D:\\cohemu\\MapServer\\include\\MapPacket.h(1221) : error C2228: left of '.serializeto' must have class/struct/union[/quote:4b42c800b5]

User avatar
nemerle
Posts: 398
Joined: Thu Jan 10, 2013 3:40 pm

Post by nemerle » Mon Sep 18, 2006 4:48 am

Get the latest svn revision, (267). It's compileable and linkeable.
"Ich was in one sumere dale,
in one suthe diyhele hale,
iherde ich holde grete tale
an hule and one niyhtingale."

desinger
Posts: 5
Joined: Mon Sep 11, 2006 12:25 pm

Post by desinger » Mon Sep 18, 2006 11:12 am

another error and many warnings...
[quote:64b7c9416e]mapserver_lib.lib(MapHandler.obj) : error LNK2019: unresolved external symbol "public: class Entity * __thiscall Client::getCharEntity(void)" ([email protected]@@[email protected]@XZ) referenced in function "public: virtual bool __thiscall MapHandler::ReceivePacket(class GamePacket *)" ([email protected]@@[email protected]@@Z)
mapserver_lib.lib(MapHandler.obj) : error LNK2019: unresolved external symbol "public: void __thiscall Client::setCharEntity(class Entity *)" ([email protected]@@[email protected]@@Z) referenced in function "public: virtual bool __thiscall MapHandler::ReceivePacket(class GamePacket *)" ([email protected]@@[email protected]@@Z)
D:\\cohemu\\output\\Debug\\authserver.exe : fatal error LNK1120: 2 unresolved externals[/quote:64b7c9416e]

[quote:64b7c9416e]d:\\cohemu\\Common\\src\\BitStream.cpp(290) : warning C4244: '=' : conversion from 'unsigned __int64' to 's32', possible loss of data
d:\\cohemu\\GameServer\\src\\CharacterHandler.cpp(100) : warning C4244: 'argument' : conversion from 'time_t' to 'unsigned int', possible loss of data
d:\\cohemu\\AdminServer\\src\\AdminDatabase.cpp(149) : warning C4101: 'binary_password' : unreferenced local variable
d:\\cohemu\\AdminServer\\src\\AdminDatabase.cpp(150) : warning C4101: 'unescaped_len' : unreferenced local variable
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
d:\\cohemu\\MapServer\\src\\Entity.cpp(22) : warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
d:\\cohemu\\MapServer\\src\\Entity.cpp(34) : warning C4244: 'initializing' : conversion from 'double' to 'float', possible loss of data
d:\\cohemu\\MapServer\\src\\Entity.cpp(35) : warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
D:\\cohemu\\MapServer\\include\\MapPacket.h(693) : warning C4390: ';' : empty controlled statement found; is this the intent?
d:\\cohemu\\mapserver\\src\\maphandler.cpp(35) : warning C4700: uninitialized local variable 'm_client' used
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(127) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(128) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(129) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(130) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(131) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(132) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(133) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthPacketCodec.cpp(134) : warning C4244: '=' : conversion from 'unsigned long' to 'unsigned char', possible loss of data
d:\\cohemu\\AuthServer\\src\\AuthFSM.cpp(139) : warning C4244: 'argument' : conversion from 'u64' to 'u16', possible loss of data
[/quote:64b7c9416e]

User avatar
nemerle
Posts: 398
Joined: Thu Jan 10, 2013 3:40 pm

Post by nemerle » Mon Sep 18, 2006 12:23 pm

Yup, these errors were there because i didn't commit some work-in-progress mapserver code. But since i've just commited them, things should work now. As for warnings, feel free to correct those and submit a patch :)
"Ich was in one sumere dale,
in one suthe diyhele hale,
iherde ich holde grete tale
an hule and one niyhtingale."

PotajiTo
Posts: 10
Joined: Mon Aug 14, 2006 10:22 pm

Post by PotajiTo » Mon Sep 18, 2006 2:55 pm

Should the auth server work right now? Because I built it, run it, create the cohemu db and user, change the coh shorcut and regedit things etc. But when I try to login it crash. The message is:
[code:1:b2031a059e]mainConnected to PostgreSQL database server version 80104.
(3584|1720) User woot trying to login from 0.0.0.0.
Result status: ERROR: relation "accounts" does not exist

Result status: ERROR: relation "accounts" does not exist

Result status: ERROR: relation "accounts" does not exist

ACE_ASSERT: file \\cohemu\\AuthServer\\src\\AuthFSM.cpp, line 71 assertion failed fo
r 'client'.Aborting...[/code:1:b2031a059e]

Probably something to do with my null knowledge concerning db?
Oh.. and Great work!

malign
Posts: 61
Joined: Fri Sep 02, 2005 11:39 pm

Post by malign » Tue Sep 19, 2006 2:43 pm

Potajito: did you populate the database with the included account database schema?

Creating the database itself is not enough. The database server needs a "skeleton" so to speak, so it knows what data resides where.

I am not sure how to populate a pgsql db in Windows directly, as I have never used the PostGreSQL instance under Windows. Although, I am sure it is easy using some point and click method. However, you can use PGAdmin III.

Get it here: http://www.pgadmin.org/download/windows.php

This will also enable you to connect to any remote PostGreSQL database server so long as it allows connections from your IP address and you have a valid username/password and database to select.

To populate the accounts db this way, fire up PGAdmin III after you install it. Add your server. If your db server is on the same host, just use 127.0.0.1. Also, give it the admin username and password. Now, connect to the new server by double clicking the icon for whatever name you gave in the "Add Server" configuration in the left panel. If it connected OK, you should see your accounts database in the left. Click on that.

Now, click on the "Execute arbitrary SQL queries." button on the top panel. It looks like a paper with SQL on it with a pencil writing. Make sure you have your cohemu database selected first on the left. Now, paste the contents of this file into that text box that pops up:

https://trac.cohemu.net/browser/AdminSe ... cohemu.sql

Then click on the green arrow or "Execute query". This should populate the db with all needed info including the accounts table.

To do this on UNIX or Linux, su - to the pgsql user. ie,

[quote:3639e56b66]
[email protected]:(/home/malign)% su - pgsql
Password:
[email protected]:(/usr/local/pgsql)%
[/quote:3639e56b66]

Now that you're the pgsql user, import the schema file into the db to populate it with its "skeleton".

[quote:3639e56b66]
[email protected]:(/usr/local/pgsql)% psql <your_cohemu_db_name> < cohemu.sql
[/quote:3639e56b66]

I hope this un-nullifies your db knowledge. =)

--malign

PotajiTo
Posts: 10
Joined: Mon Aug 14, 2006 10:22 pm

Post by PotajiTo » Tue Sep 19, 2006 5:57 pm

Thanks maling, I could get it to work more or less. It's amazing what you all are doing here!
PD: To get to the server selection screen I had to comment some ACE_ASSERTs, is it intended? Then the client said that it couldn't connect to the db, but that's a minor issue. I'm glad it got all that far ^^

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests