- Char-server SQL won't perform the reconnect cleanup routines when kick_on_disconnect is disabled.

- Renamed summons_inherit_effects to summons_trigger_autospells as the setting now only makes the attacks of the slaves trigger the autospells of the master (as it should be).
- Corrected code capping no_spawn_on_player to 50 when the max should be 100.


git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@7459 54d463be-8e91-2dee-dedb-b68131a5f0ec
This commit is contained in:
skotlex 2006-07-03 19:59:48 +00:00
parent 0295ac624f
commit 1d6dbc95dc
10 changed files with 26 additions and 23 deletions

View File

@ -4,6 +4,13 @@ AS OF SVN REV. 5091, WE ARE NOW USING TRUNK. ALL UNTESTED BUGFIXES/FEATURES GO
IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK. IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
2006/07/03 2006/07/03
* Char-server SQL won't perform the reconnect cleanup routines when
kick_on_disconnect is disabled. [Skotlex]
* Renamed summons_inherit_effects to summons_trigger_autospells as the
setting now only makes the attacks of the slaves trigger the autospells of
the master (as it should be). [Skotlex]
* Corrected code capping no_spawn_on_player to 50 when the max should be
100. [Skotlex]
* Warmth will dispel when warping now (or else the effect is left on the * Warmth will dispel when warping now (or else the effect is left on the
ground) [Skotlex] ground) [Skotlex]
* Fixed reading of the refine_db not working right when MAX_REFINE is * Fixed reading of the refine_db not working right when MAX_REFINE is

View File

@ -132,9 +132,9 @@ slaves_inherit_mode: yes
// NOTE: The default is yes for official servers. // NOTE: The default is yes for official servers.
slaves_inherit_speed: yes slaves_inherit_speed: yes
// Will summoned monsters (alchemists, or @summon'ed monsters) inherit // Will summoned monsters (alchemists, or @summon'ed monsters) attack cause a
// the master's auto-spells and auto-effects properties? (Note 1) // chance of triggering the master's autospell cards? (Note 1)
summons_inherit_effects: yes summons_trigger_autospells: yes
// When a mob is attacked by another monster, will the mob retaliate against the master of said mob instead of the mob itself? // When a mob is attacked by another monster, will the mob retaliate against the master of said mob instead of the mob itself?
// NOTE: Summoned mobs are both those acquired via @summon and summoned by Alchemists // NOTE: Summoned mobs are both those acquired via @summon and summoned by Alchemists

View File

@ -3846,7 +3846,7 @@ int check_connect_login_server(int tid, unsigned int tick, int id, int data) {
} }
session[login_fd]->func_parse = parse_tologin; session[login_fd]->func_parse = parse_tologin;
realloc_fifo(login_fd, FIFOSIZE_SERVERLINK, FIFOSIZE_SERVERLINK); realloc_fifo(login_fd, FIFOSIZE_SERVERLINK, FIFOSIZE_SERVERLINK);
WFIFOHEAD(login_fd, 86); WFIFOHEAD(login_fd, 86);
WFIFOW(login_fd,0) = 0x2710; WFIFOW(login_fd,0) = 0x2710;
memcpy(WFIFOP(login_fd,2), userid, 24); memcpy(WFIFOP(login_fd,2), userid, 24);
memcpy(WFIFOP(login_fd,26), passwd, 24); memcpy(WFIFOP(login_fd,26), passwd, 24);

View File

@ -3767,6 +3767,9 @@ int check_connect_login_server(int tid, unsigned int tick, int id, int data) {
WFIFOSET(login_fd,86); WFIFOSET(login_fd,86);
if (!kick_on_disconnect)
return 0; //Do not perform on-connect cleanup duties.
//(re)connected to login-server, //(re)connected to login-server,
//now wi'll look in sql which player's are ON and set them OFF //now wi'll look in sql which player's are ON and set them OFF
//AND send to all mapservers (if we have one / ..) to kick the players //AND send to all mapservers (if we have one / ..) to kick the players

View File

@ -3789,7 +3789,6 @@ int login_config_read(const char *cfgName) {
} else if(strcmpi(w1,"ip_sync_interval")==0) { } else if(strcmpi(w1,"ip_sync_interval")==0) {
ip_sync_interval = 1000*60*atoi(w2); //w2 comes in minutes. ip_sync_interval = 1000*60*atoi(w2); //w2 comes in minutes.
} }
} }
} }
fclose(fp); fclose(fp);
@ -4167,7 +4166,6 @@ int do_init(int argc, char **argv) {
add_timer_func_list(online_data_cleanup, "online_data_cleanup"); add_timer_func_list(online_data_cleanup, "online_data_cleanup");
add_timer_interval(gettick() + 600*1000, online_data_cleanup, 0, 0, 600*1000); // every 10 minutes cleanup online account db. add_timer_interval(gettick() + 600*1000, online_data_cleanup, 0, 0, 600*1000); // every 10 minutes cleanup online account db.
if (ip_sync_interval) { if (ip_sync_interval) {
add_timer_func_list(sync_ip_addresses, "sync_ip_addresses"); add_timer_func_list(sync_ip_addresses, "sync_ip_addresses");
add_timer_interval(gettick() + ip_sync_interval, sync_ip_addresses, 0, 0, ip_sync_interval); add_timer_interval(gettick() + ip_sync_interval, sync_ip_addresses, 0, 0, ip_sync_interval);

View File

@ -3352,7 +3352,7 @@ static const struct battle_data_short {
{ "boss_spawn_delay", &battle_config.boss_spawn_delay }, { "boss_spawn_delay", &battle_config.boss_spawn_delay },
{ "slaves_inherit_mode", &battle_config.slaves_inherit_mode }, { "slaves_inherit_mode", &battle_config.slaves_inherit_mode },
{ "slaves_inherit_speed", &battle_config.slaves_inherit_speed }, { "slaves_inherit_speed", &battle_config.slaves_inherit_speed },
{ "summons_inherit_effects", &battle_config.summons_inherit_effects }, { "summons_trigger_autospells", &battle_config.summons_trigger_autospells },
{ "pc_damage_walk_delay_rate", &battle_config.pc_walk_delay_rate }, { "pc_damage_walk_delay_rate", &battle_config.pc_walk_delay_rate },
{ "damage_walk_delay_rate", &battle_config.walk_delay_rate }, { "damage_walk_delay_rate", &battle_config.walk_delay_rate },
{ "multihit_delay", &battle_config.multihit_delay }, { "multihit_delay", &battle_config.multihit_delay },
@ -3749,7 +3749,7 @@ void battle_set_defaults() {
battle_config.boss_spawn_delay=100; battle_config.boss_spawn_delay=100;
battle_config.slaves_inherit_mode=1; battle_config.slaves_inherit_mode=1;
battle_config.slaves_inherit_speed=1; battle_config.slaves_inherit_speed=1;
battle_config.summons_inherit_effects=1; battle_config.summons_trigger_autospells=1;
battle_config.pc_walk_delay_rate=20; battle_config.pc_walk_delay_rate=20;
battle_config.walk_delay_rate=100; battle_config.walk_delay_rate=100;
battle_config.multihit_delay=80; battle_config.multihit_delay=80;
@ -4198,8 +4198,8 @@ void battle_validate_conf() {
if (battle_config.plant_spawn_delay < 0) if (battle_config.plant_spawn_delay < 0)
battle_config.plant_spawn_delay = 0; battle_config.plant_spawn_delay = 0;
*/ */
if (battle_config.no_spawn_on_player > 50) if (battle_config.no_spawn_on_player > 100)
battle_config.no_spawn_on_player = 50; battle_config.no_spawn_on_player = 100;
if (battle_config.mob_remove_delay < 15000) //Min 15 sec if (battle_config.mob_remove_delay < 15000) //Min 15 sec
battle_config.mob_remove_delay = 15000; battle_config.mob_remove_delay = 15000;
if (battle_config.dynamic_mobs > 1) if (battle_config.dynamic_mobs > 1)

View File

@ -157,7 +157,7 @@ extern struct Battle_Config {
unsigned short mob_spawn_delay, plant_spawn_delay, boss_spawn_delay; // [Skotlex] unsigned short mob_spawn_delay, plant_spawn_delay, boss_spawn_delay; // [Skotlex]
unsigned short slaves_inherit_mode; unsigned short slaves_inherit_mode;
unsigned short slaves_inherit_speed; unsigned short slaves_inherit_speed;
unsigned short summons_inherit_effects; unsigned short summons_trigger_autospells;
unsigned short pc_walk_delay_rate; //Adjusts can't walk delay after being hit for players. [Skotlex] unsigned short pc_walk_delay_rate; //Adjusts can't walk delay after being hit for players. [Skotlex]
unsigned short walk_delay_rate; //Adjusts can't walk delay after being hit. [Skotlex] unsigned short walk_delay_rate; //Adjusts can't walk delay after being hit. [Skotlex]
unsigned short multihit_delay; //Adjusts can't walk delay per hit on multi-hitting skills. [Skotlex] unsigned short multihit_delay; //Adjusts can't walk delay per hit on multi-hitting skills. [Skotlex]

View File

@ -3124,12 +3124,7 @@ int map_readallmaps (void)
size = map[i].bxs * map[i].bys * sizeof(int); size = map[i].bxs * map[i].bys * sizeof(int);
map[i].block_count = (int*)aCallocA(size, 1); map[i].block_count = (int*)aCallocA(size, 1);
// Already initialized in aCallocA
//memset(map[i].block_count, 0, size);
map[i].block_mob_count = (int*)aCallocA(size, 1); map[i].block_mob_count = (int*)aCallocA(size, 1);
// Already initialized in aCallocA
//memset(map[i].block_mob_count, 0, size);
uidb_put(map_db, (unsigned int)map[i].index, &map[i]); uidb_put(map_db, (unsigned int)map[i].index, &map[i]);

View File

@ -255,7 +255,6 @@ enum {
MAX_ITEMGROUP, MAX_ITEMGROUP,
} item_group_list; } item_group_list;
struct block_list { struct block_list {
struct block_list *next,*prev; struct block_list *next,*prev;
int id; int id;

View File

@ -1324,11 +1324,6 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
break; break;
} }
if (md && battle_config.summons_inherit_effects && md->master_id && md->special_state.ai)
{ //Pass heritage to Master for status causing effects. [Skotlex]
sd = map_id2sd(md->master_id);
}
if(sd && skillid != MC_CARTREVOLUTION && skillid != AM_DEMONSTRATION && skillid != CR_REFLECTSHIELD && attack_type&BF_WEAPON){ /* カードによる追加効果 */ if(sd && skillid != MC_CARTREVOLUTION && skillid != AM_DEMONSTRATION && skillid != CR_REFLECTSHIELD && attack_type&BF_WEAPON){ /* カードによる追加効果 */
int i, type; int i, type;
for(i=SC_COMMON_MIN;i<=SC_COMMON_MAX;i++){ for(i=SC_COMMON_MIN;i<=SC_COMMON_MAX;i++){
@ -1340,6 +1335,12 @@ int skill_additional_effect (struct block_list* src, struct block_list *bl, int
} }
} }
if (md && battle_config.summons_trigger_autospells && md->master_id && md->special_state.ai)
{ //Pass heritage to Master for status causing effects. [Skotlex]
sd = map_id2sd(md->master_id);
src = sd?&sd->bl:src;
}
//Reports say that autospell effects get triggered on skills and pretty much everything including splash attacks. [Skotlex] //Reports say that autospell effects get triggered on skills and pretty much everything including splash attacks. [Skotlex]
if(sd && !status_isdead(bl) && src != bl && if(sd && !status_isdead(bl) && src != bl &&
!(skillid && skill_get_nk(skillid)&NK_NO_DAMAGE)) { !(skillid && skill_get_nk(skillid)&NK_NO_DAMAGE)) {