[Release] Legend.mu client & server source code S16 1.1

Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Ok, so... Main.exe or something dont like 127.0.0.1. It working with local ip.

ps. got auto crash when waiting on server select...



Now, i need help with gameserver, it closes right after it open
I changed server code in db and gameserver config, i cant even see logs to know what's wrong
Because of this code...
Code:
void GameServer::LoadCommonSettings()
{
    sLog->outInfo(LOG_DEFAULT, "Loading Common Settings...");
    uint32 oldMSTime = getMSTime();

    sMain->Load();

        this->SetMaxConnectionsPerIP(sMain->GetInt32("Network.MaxConnectionPerIP", 0));

    std::string temp_client_version = sMain->GetString("GameServer.Version", "");
    char temp_client_version_buff[8];    
    memset(temp_client_version_buff, 0, 8);
    memcpy(temp_client_version_buff, temp_client_version.c_str(), temp_client_version.size() > 8 ? 8 : temp_client_version.size());

    Tokens tokens(temp_client_version_buff, '.');

    this->SetGameServerVersion(0, tokens[0][0]);
    this->SetGameServerVersion(1, tokens[1][0]);
    this->SetGameServerVersion(2, tokens[1][1]);
    this->SetGameServerVersion(3, tokens[2][0]);
    this->SetGameServerVersion(4, tokens[2][1]);

sMain->GetString("GameServer.Version", "") - we want here setting GameServer.Version and second argument is default value if we dont get anything from db



Ok, so in gameserver.conf we have GameServer.Code = 0.
Then in void MainApplication::Load() we load default settings for all servers
QueryResult result1 = GameServerDatabase.Query("SELECT `key`, `value` FROM settings WHERE server_id = -1");
and than settings for current server
QueryResult result2 = GameServerDatabase.PQuery("SELECT `key`, `value` FROM settings WHERE server_id = '%u'", sGameServer->GetServerCode());




Ok, it's working, w8 a couple minutes i will upload all i have



My repo
With my current db, files and other.
Account in database user 123456


@Mulegend btw, can you give us any item_bag value? Or server by himself can make example?



2021-03-11_11:46:14 ERROR [ CHARACTER SELECT ] [SRV 0 -- 1501 - IP: 192.168.1.60 - MAC: B4:2E:99:C75:A3 - Account: 1-user - Character: 1-test] has wrong world 0.
Oh ok... thinking
So, it's about character_base table
 

Attachments

You must be registered for see attachments list
Last edited:
Newbie Spellweaver
Joined
Aug 19, 2011
Messages
26
Reaction score
2
Re: [Release] Legend.mu client & server source code S16 1.1

My repo
With my current db, files and other.
Account in database user 123456

thank you for share, i can't run file main_test.exe in link here:

because windows defender of windows 10 delete main_test.exe, please fix it.

thank you.
 
Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Re: [Release] Legend.mu client & server source code S16 1.1

thank you for share, i can't run file main_test.exe in link here:

because windows defender of windows 10 delete main_test.exe, please fix it.

thank you.
I cant fix it, coz it packed with themida. Just add to excludes.
Anyway, if this main have any virus, i cant fix that nether, coz i dont have sources of main. Just main.dll

DB is empty, only schema, so it's not very good worknig server.
You cant download it, run it and play for fun for now.

Current progress:
I can login,
I can create character,
Can't enter world

PS. if you changing anything in game db you need to restart gameserver, coz it cached data on start


@Mulegend, help me please a little.
I added character_base for DK, but server everytime says [ CHARACTER SELECT ] %s has wrong world %d
What i missing?



Ok, i found that i need to input data in game.world_template and game.gate_template
 
Last edited:
Newbie Spellweaver
Joined
Dec 17, 2020
Messages
12
Reaction score
21
Re: [Release] Legend.mu client & server source code S16 1.1

you need to add world (map) entry into world_template table. For Lorencia (default map for DK):

Code:
INSERT INTO `mu_online_game`.`world_template` (`entry`, `display_entry`, `state`, `file`, `name`, `spawn_gate`, `experience`, `zen_rate`, `flags`) VALUES ('0', '0', '0', 'terrain1.att', 'Lorencia', '17', '1', '1', '0');

Also, there is a bug in world_area_attribute table (wrong name of column, causes GS crash on startup after adding world). Run this query:

Code:
ALTER TABLE `mu_online_game`.`world_area_attribute` CHANGE COLUMN `world` `world_id` SMALLINT UNSIGNED NOT NULL ;

 
Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Re: [Release] Legend.mu client & server source code S16 1.1

I know about this bugs. Need to fix some more db schemas in future.
dudusiao did you add something in gate_template?
 
Skilled Illusionist
Joined
May 1, 2006
Messages
381
Reaction score
167
Re: [Release] Legend.mu client & server source code S16 1.1

PS. if you changing anything in game db you need to restart gameserver, coz it cached data on start



Reload data:
Code:
INSERT INTO `50x_mu_character`.`server_signal` 
( `server`, `signal`, `data_1`, `data_2`, `data_3` )
VALUES
	( 0, 5, 1, 0, 0 );
 
Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Re: [Release] Legend.mu client & server source code S16 1.1



Reload data:
Code:
INSERT INTO `50x_mu_character`.`server_signal` 
( `server`, `signal`, `data_1`, `data_2`, `data_3` )
VALUES
    ( 0, 5, 1, 0, 0 );
Thx for data



Yeah, thx.
Do you have full world_template?
 
Newbie Spellweaver
Joined
Aug 23, 2015
Messages
77
Reaction score
46
Re: [Release] Legend.mu client & server source code S16 1.1

Current progress:
I can login,
I can create character,
Can't enter world

With what you uploaded I can see the Create Character screen, but nothing happens when I try to create it.

I only get an empty screen after I try to create the character.

Any ideas on what could be missing?



Used account:
user / 123456

Database:
-View attachment DB-exported-2021.03.11-15.01-v3.rar
 

Attachments

You must be registered for see attachments list
Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Re: [Release] Legend.mu client & server source code S16 1.1

Into mu_online_game.character_base
I know that this is wrong values

Current progress:
Can login
Can create character
Can enter world
Cant move
Chat working

Looking...
@dudusiao your character can move?
 
Last edited:
Newbie Spellweaver
Joined
Aug 23, 2015
Messages
77
Reaction score
46
Re: [Release] Legend.mu client & server source code S16 1.1



Updated. Same issue, no character is created after I press OK



I also have these errors in the GameServer log:
Loading Gate...
Wrong Gate Loaded :2 - World: 1
Wrong Gate Loaded :3 - World: 1
Wrong Gate Loaded :5 - World: 1
Wrong Gate Loaded :6 - World: 1

I found some errors in the Database log for: LoginServer

And in the Database log for ServerLink:

I'll look later at the errors
 

Attachments

You must be registered for see attachments list
Last edited:
Junior Spellweaver
Joined
Oct 4, 2007
Messages
173
Reaction score
74
Re: [Release] Legend.mu client & server source code S16 1.1

Updated. Same issue, no character is created after I press OK

View attachment 169333View attachment 169334
Alter table characters.character_info, set to guid AUTO_INCREMENT flag. Forgot about it
Alter table login.accounts_security, remove primary key



I also have these errors in the GameServer log:
It coz you dont have world_template for each world.
From code
if ( !sWorldMgr->IsWorld(add_gate->world) )
{
sLog->outError(LOG_DEFAULT, "Wrong Gate Loaded :%u - World: %u", add_gate->id, add_gate->world);
delete add_gate;
continue;
}
 
Skilled Illusionist
Joined
Feb 13, 2004
Messages
351
Reaction score
54
Re: [Release] Legend.mu client & server source code S16 1.1


I was using vs2019 comunity edition...I unnistall it, what version of VS is needed? I could download vs2013 update5 but x86...not x64
 
Newbie Spellweaver
Joined
Feb 19, 2013
Messages
69
Reaction score
2
Re: [Release] Legend.mu client & server source code S16 1.1

How?
Mine cant
Everything works, just one problem with gameserver:

2021-03-11_16:12:10 INFO ========================================================2021-03-11_16:12:10 INFO ========================================================2021-03-11_16:12:10 INFO >>>>>>>>>>>>>>>>>>>>> GAME SERVER <<<<<<<<<<<<<<<<<<<<<<2021-03-11_16:12:10 INFO ========================================================2021-03-11_16:12:10 INFO ========================================================2021-03-11_16:12:10 INFO Process priority class set to HIGH2021-03-11_16:12:10 INFO Starting DB...2021-03-11_16:12:10 ERROR Cannot connect to MuLog database 127.0.0.1;3306;root;123456;mu_online_log

I'm using files from your repo
 
Newbie Spellweaver
Joined
Feb 19, 2013
Messages
69
Reaction score
2
How come gameserver immediately closes after opening it. And it's working fine for you guys
 
Skilled Illusionist
Joined
Feb 13, 2004
Messages
351
Reaction score
54
Re: [Release] Legend.mu client &amp; server source code S16 1.1

use this client:
and change IpAddress in Offset.h from the mesosa source

But that client dont use Main.dll how you "hook" that main.dll from the source of mesosa to main.exe?




Check if exist this database: mu_online_log