summaryrefslogtreecommitdiff
path: root/src/map/atcommand.c
diff options
context:
space:
mode:
authortoms <toms@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-20 18:54:18 +0000
committertoms <toms@54d463be-8e91-2dee-dedb-b68131a5f0ec>2006-08-20 18:54:18 +0000
commit6ae26ef0260b6f25c3f68115c300020a2b5b84b9 (patch)
tree59212169d7917653a9de6fcf19abfb25a7bac8fa /src/map/atcommand.c
parentd8515bb0bf7a0c59f38923509ef52ba3a553dae8 (diff)
downloadhercules-6ae26ef0260b6f25c3f68115c300020a2b5b84b9.tar.gz
hercules-6ae26ef0260b6f25c3f68115c300020a2b5b84b9.tar.bz2
hercules-6ae26ef0260b6f25c3f68115c300020a2b5b84b9.tar.xz
hercules-6ae26ef0260b6f25c3f68115c300020a2b5b84b9.zip
- Fixed some Homunc issues with HR servers (capping some values)
- Added @hominfo command to obtain real values (not capped ones) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@8378 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/atcommand.c')
-rw-r--r--src/map/atcommand.c30
1 files changed, 30 insertions, 0 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index 5c9983700..00d051284 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -309,6 +309,7 @@ ACMD_FUNC(makehomun); //[orn]
ACMD_FUNC(homfriendly); //[orn]
ACMD_FUNC(homhungry); //[orn]
ACMD_FUNC(homtalk); //[orn]
+ACMD_FUNC(hominfo); //[Toms]
/*==========================================
*AtCommandInfo atcommand_info[]構造体の定義
@@ -638,6 +639,7 @@ static AtCommandInfo atcommand_info[] = {
{ AtCommand_HomFriendly, "@homfriendly", 60, atcommand_homfriendly },
{ AtCommand_HomHungry, "@homhungry", 60, atcommand_homhungry },
{ AtCommand_HomTalk, "@homtalk", 0, atcommand_homtalk },
+ { AtCommand_HomInfo, "@hominfo", 0, atcommand_hominfo },
// add new commands before this line
{ AtCommand_Unknown, NULL, 1, NULL }
@@ -9923,6 +9925,34 @@ int atcommand_homtalk(
}
/*==========================================
+ * Show homunculus stats
+ *------------------------------------------
+ */
+int atcommand_hominfo(
+ const int fd, struct map_session_data* sd,
+ const char* command, const char* message)
+{
+
+ nullpo_retr(-1, sd);
+
+ if(!merc_is_hom_active(sd->hd))
+ return -1;
+
+ clif_displaymessage(fd, "Homunculus stats :");
+
+ snprintf(atcmd_output, sizeof(atcmd_output) ,"HP : %d/%d - SP : %d/%d", sd->hd->battle_status.hp, sd->hd->battle_status.max_hp, sd->hd->battle_status.sp, sd->hd->battle_status.max_sp);
+ clif_displaymessage(fd, atcmd_output);
+
+ snprintf(atcmd_output, sizeof(atcmd_output) ,"ATK : %d - MATK : %d~%d", sd->hd->battle_status.rhw.atk2+sd->hd->battle_status.batk, sd->hd->battle_status.matk_min, sd->hd->battle_status.matk_max);
+ clif_displaymessage(fd, atcmd_output);
+
+ snprintf(atcmd_output, sizeof(atcmd_output) ,"Hungry : %d - Intimacy : %d", sd->homunculus.hunger, sd->homunculus.intimacy);
+ clif_displaymessage(fd, atcmd_output);
+
+ return 0;
+}
+
+/*==========================================
* Show Items DB Info v 1.0
* originally by [Lupus] eAthena
*------------------------------------------