summaryrefslogtreecommitdiff
path: root/src/map/unit.c
diff options
context:
space:
mode:
authorshennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-03-18 01:37:53 +0000
committershennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-03-18 01:37:53 +0000
commitaefef10ae8e198660785b9dbaa267751274ba672 (patch)
treecc3acdb6ce754e5d16cd458138ec98618db51f05 /src/map/unit.c
parent9374324b4198605a9ee57f31de010ae18af49256 (diff)
downloadhercules-aefef10ae8e198660785b9dbaa267751274ba672.tar.gz
hercules-aefef10ae8e198660785b9dbaa267751274ba672.tar.bz2
hercules-aefef10ae8e198660785b9dbaa267751274ba672.tar.xz
hercules-aefef10ae8e198660785b9dbaa267751274ba672.zip
Added Official Guild Aura Implementation bugreport:667
Before: - Guild Aura would only trigger when guild master moved Now: - Guild Aura is triggered when master moves and/or when guild mate gets inside the area - Guild Aura range is no longer hardcoded, you may modify it from skill_unit_db Also: - Added new skill_unit_db target type 'guild' git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@15707 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/unit.c')
-rw-r--r--src/map/unit.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/map/unit.c b/src/map/unit.c
index 61046c4e0..9c6b8d760 100644
--- a/src/map/unit.c
+++ b/src/map/unit.c
@@ -183,29 +183,6 @@ static int unit_walktoxy_timer(int tid, unsigned int tick, int id, intptr_t data
{// mercenary is too far from the master so warp the master's position
unit_warp( &sd->md->bl, sd->bl.m, sd->bl.x, sd->bl.y, CLR_TELEPORT );
}
-
- if (sd->state.gmaster_flag &&
- (battle_config.guild_aura&((agit_flag || agit2_flag)?2:1)) &&
- (battle_config.guild_aura&(map_flag_gvg2(bl->m)?8:4))
- )
- { //Guild Aura: Likely needs to be recoded, this method seems inefficient.
- struct guild *g = sd->state.gmaster_flag;
- int skill, strvit= 0, agidex = 0;
- if ((skill = guild_checkskill(g, GD_LEADERSHIP)) > 0) strvit |= (skill&0xFFFF)<<16;
- if ((skill = guild_checkskill(g, GD_GLORYWOUNDS)) > 0) strvit |= (skill&0xFFFF);
- if ((skill = guild_checkskill(g, GD_SOULCOLD)) > 0) agidex |= (skill&0xFFFF)<<16;
- if ((skill = guild_checkskill(g, GD_HAWKEYES)) > 0) agidex |= (skill&0xFFFF);
- if (strvit || agidex)
- {// replaced redundant foreachinrange call with smaller and much more efficient iteration
- for( i = 0; i < g->max_member; i++ )
- {
- if( g->member[i].online && g->member[i].sd && sd->bl.m == g->member[i].sd->bl.m && check_distance_bl(&sd->bl, &g->member[i].sd->bl, 2) )
- {// perform the aura on the member as appropriate
- skill_guildaura_sub(g->member[i].sd, sd->bl.id, strvit, agidex);
- }
- }
- }
- }
} else if (md) {
if( map_getcell(bl->m,x,y,CELL_CHKNPC) ) {
if( npc_touch_areanpc2(md) ) return 0; // Warped