summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-01-21 11:02:21 +0000
committerultramage <ultramage@54d463be-8e91-2dee-dedb-b68131a5f0ec>2008-01-21 11:02:21 +0000
commitf473fd8efada1697eb9e55cc0523801f2bdd629d (patch)
tree7d8daaf651877f6021cb261771bb0acc6d427cf5
parent2448a5c498f13b1da358ddf46c40ed9ca6456fe8 (diff)
downloadhercules-f473fd8efada1697eb9e55cc0523801f2bdd629d.tar.gz
hercules-f473fd8efada1697eb9e55cc0523801f2bdd629d.tar.bz2
hercules-f473fd8efada1697eb9e55cc0523801f2bdd629d.tar.xz
hercules-f473fd8efada1697eb9e55cc0523801f2bdd629d.zip
Fixed/cleaned r12114 and 12117.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12119 54d463be-8e91-2dee-dedb-b68131a5f0ec
-rw-r--r--src/map/charcommand.c2
-rw-r--r--src/map/clif.c32
-rw-r--r--src/map/clif.h1
3 files changed, 15 insertions, 20 deletions
diff --git a/src/map/charcommand.c b/src/map/charcommand.c
index 893dd1425..768251005 100644
--- a/src/map/charcommand.c
+++ b/src/map/charcommand.c
@@ -2836,7 +2836,7 @@ int charcommand_jailtime(const int fd, struct map_session_data* sd, const char*
}
if (pl_sd->sc.data[SC_JAILED]->val1 == INT_MAX) {
- clif_displaymessage(fd, "This player have been jailed indefinitely.");
+ clif_displaymessage(fd, "This player has been jailed indefinitely.");
return 0;
}
diff --git a/src/map/clif.c b/src/map/clif.c
index ffbc78cb1..fd8b2e076 100644
--- a/src/map/clif.c
+++ b/src/map/clif.c
@@ -99,21 +99,6 @@ static int max_char_id = DEFAULT_MAX_CHAR_ID;
int clif_parse (int fd);
/*==========================================
- * Send specials effect to tarjet
- *------------------------------------------*/
-int clif_specialeffecttoone(struct block_list *bl, struct block_list *dst, int type)
-{
- struct map_session_data *sd = (struct map_session_data *)dst;
-
- WFIFOW(sd->fd,0) = 0x1f3;
- WFIFOL(sd->fd,2) = bl->id;
- WFIFOL(sd->fd,6) = type;
- WFIFOSET(sd->fd, packet_len(0x1f3));
-
- return 0;
-}
-
-/*==========================================
* mapŽI‚ÌipÝ’è
*------------------------------------------*/
int clif_setip(const char* ip)
@@ -3449,9 +3434,9 @@ void clif_getareachar_unit(struct map_session_data* sd,struct block_list *bl)
TBL_PC* tsd = (TBL_PC*)bl;
clif_getareachar_pc(sd, tsd);
if(tsd->state.size==2) // tiny/big players [Valaris]
- clif_specialeffecttoone(bl, &sd->bl, 423);
+ clif_specialeffect_single(bl, 423, sd->fd);
else if(tsd->state.size==1)
- clif_specialeffecttoone(bl, &sd->bl, 421);
+ clif_specialeffect_single(bl, 421, sd->fd);
}
break;
case BL_NPC:
@@ -3465,9 +3450,9 @@ void clif_getareachar_unit(struct map_session_data* sd,struct block_list *bl)
{
TBL_MOB* md = (TBL_MOB*)bl;
if(md->special_state.size==2) // tiny/big mobs [Valaris]
- clif_specialeffecttoone(bl, &sd->bl, 423);
+ clif_specialeffect_single(bl, 423, sd->fd);
else if(md->special_state.size==1)
- clif_specialeffecttoone(bl, &sd->bl, 421);
+ clif_specialeffect_single(bl, 421, sd->fd);
}
break;
case BL_PET:
@@ -7057,6 +7042,15 @@ int clif_specialeffect(struct block_list* bl, int type, enum send_target target)
return 0;
}
+void clif_specialeffect_single(struct block_list* bl, int type, int fd)
+{
+ WFIFOHEAD(fd,10);
+ WFIFOW(fd,0) = 0x1f3;
+ WFIFOL(fd,2) = bl->id;
+ WFIFOL(fd,6) = type;
+ WFIFOSET(fd,10);
+}
+
// messages (from mobs/npcs) [Valaris]
int clif_message(struct block_list* bl, const char* msg)
{
diff --git a/src/map/clif.h b/src/map/clif.h
index 3b188a468..b93321985 100644
--- a/src/map/clif.h
+++ b/src/map/clif.h
@@ -358,6 +358,7 @@ void clif_friendslist_reqack(struct map_session_data *sd, struct map_session_dat
int clif_mob_hp(struct mob_data *md);
int clif_weather(int m); // [Valaris]
int clif_specialeffect(struct block_list* bl, int type, enum send_target target); // special effects [Valaris]
+void clif_specialeffect_single(struct block_list* bl, int type, int fd);
int clif_message(struct block_list *bl, const char* msg); // messages (from mobs/npcs) [Valaris]
int clif_GM_kickack(struct map_session_data *sd,int id);