Jump to content

  •  

x13th

Member Since 13 Jul 2013
Offline Last Active Apr 14 2017 04:51 PM
-----

Topics I've Started

Char server stopped

30 November 2016 - 04:01 AM

I'm trying to convert rAthena Clan system to Herc and now after compiling no error shows up until when i run the server the char server stopped. I'm using windows btw.

 

I found what causing it but dont know why.

If I add

inter_clan->sql_init();

to

int inter_init_sql(const char *file)

the char server will stopped working

 

so here's the whole code

int inter_init_sql(const char *file)
{
	inter->config_read(file, false);

	//DB connection initialized
	inter->sql_handle = SQL->Malloc();
	ShowInfo("Connect Character DB server.... (Character Server)\n");
	if( SQL_ERROR == SQL->Connect(inter->sql_handle, char_server_id, char_server_pw, char_server_ip, (uint16)char_server_port, char_server_db) )
	{
		Sql_ShowDebug(inter->sql_handle);
		SQL->Free(inter->sql_handle);
		exit(EXIT_FAILURE);
	}

	if( *default_codepage ) {
		if( SQL_ERROR == SQL->SetEncoding(inter->sql_handle, default_codepage) )
			Sql_ShowDebug(inter->sql_handle);
	}

	wis_db = idb_alloc(DB_OPT_RELEASE_DATA);
	inter_guild->sql_init();
	inter_storage->sql_init();
	inter_party->sql_init();
	inter_pet->sql_init();
	inter_homunculus->sql_init();
	inter_mercenary->sql_init();
	inter_elemental->sql_init();
	inter_mail->sql_init();
	inter_auction->sql_init();
        inter_clan->sql_init();

	geoip->init();
	inter->msg_config_read("conf/messages.conf", false);
	return 0;
}

 

here's my int_clan.c

http://upaste.me/97313640759e978d3

 

and my int_clan.h

http://upaste.me/f64c36408e18094f3


getmonster display name

18 November 2016 - 09:30 AM

How can we get monster display name when triggered OnNPCKillEvent? Is there a way?


Slave / Master ID

17 November 2016 - 06:19 AM

I've been searching through the src and can't find the code on how can a summoned slave stay when the master log out.

I have specific mob id and create an object is_f_slave and can be call through md ( e.g. md->is_f_slave , for checking purpose )

So how can I prevent this slave to stay put?


Fake NPC Name

16 November 2016 - 10:22 AM

Is it possible to build a fake npc name script command?

 

Like

fakenpcname("NPC#1","NPC_F_N");

 

eventually the NPC#1 name will change to NPC_F_N.


[Question] Plugin

15 November 2016 - 02:17 PM

Hi. I've been playing around the src and just realized there's a Plugin function. My question is, when should be use this? Does this apply when adding new skill, calculating damage, etc?