summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-11-15 02:47:28 +0000
committershennetsind <shennetsind@54d463be-8e91-2dee-dedb-b68131a5f0ec>2012-11-15 02:47:28 +0000
commit2bab57f59afab08bf6b162c79e674badb8322223 (patch)
tree988ca17a02a6593e3e5c972dc35f268ddbea5207
parent87a5c390724a5df7bcbc130d2c51affbbe23ff73 (diff)
downloadhercules-2bab57f59afab08bf6b162c79e674badb8322223.tar.gz
hercules-2bab57f59afab08bf6b162c79e674badb8322223.tar.bz2
hercules-2bab57f59afab08bf6b162c79e674badb8322223.tar.xz
hercules-2bab57f59afab08bf6b162c79e674badb8322223.zip
Updated @reloadskilldb to update all connected clients skill infos; and to explain why I'll write a short, cute story.
Prior to this change, if you changed a skill type from, say, ground to self, and reloaded the skill db, you'd need to relog (or force kick everyone in the server) in order for this to refresh in their clients; thanks to this change @reloadscript will refresh everyones skill tree. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@16928 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--src/map/skill.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index c01da31d5..ad6ef2b45 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -17782,9 +17782,16 @@ static void skill_readdb(void)
}
-void skill_reload (void)
-{
+void skill_reload (void) {
+ struct s_mapiterator *iter;
+ struct map_session_data *sd;
skill_readdb();
+ /* lets update all players skill tree : so that if any skill modes were changed they're properly updated */
+ iter = mapit_getallusers();
+ for( sd = (TBL_PC*)mapit_first(iter); mapit_exists(iter); sd = (TBL_PC*)mapit_next(iter) )
+ clif_skillinfoblock(sd);
+ mapit_free(iter);
+
}
/*==========================================