summaryrefslogtreecommitdiff
path: root/src/map/atcommand.c
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2018-05-01 19:36:15 +0200
committerHaru <haru@dotalux.com>2018-05-01 19:36:15 +0200
commit5c9ae7b9559438654265e3dd9afd26f30d499fcc (patch)
tree2d842a87ecc950eec2c0223e7dcbde97acfe0a27 /src/map/atcommand.c
parent3f6e0922d66d7ffc6a655fbd4e8bc59736e844fb (diff)
downloadhercules-5c9ae7b9559438654265e3dd9afd26f30d499fcc.tar.gz
hercules-5c9ae7b9559438654265e3dd9afd26f30d499fcc.tar.bz2
hercules-5c9ae7b9559438654265e3dd9afd26f30d499fcc.tar.xz
hercules-5c9ae7b9559438654265e3dd9afd26f30d499fcc.zip
Replace "--ja--" and "--en--" with constants (source only)
- Use `DEFAULT_MOB_NAME` instead of a literal "--en--" - Use `DEFAULT_MOB_JNAME` instead of a literal "--ja--" Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/atcommand.c')
-rw-r--r--src/map/atcommand.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c
index 9deed0098..990761137 100644
--- a/src/map/atcommand.c
+++ b/src/map/atcommand.c
@@ -2056,7 +2056,7 @@ ACMD(monster)
number = 1;
if (!name[0])
- strcpy(name, "--ja--");
+ strcpy(name, DEFAULT_MOB_JNAME);
// If value of atcommand_spawn_quantity_limit directive is greater than or equal to 1 and quantity of monsters is greater than value of the directive
if (battle_config.atc_spawn_quantity_limit && number > battle_config.atc_spawn_quantity_limit)
@@ -6128,9 +6128,10 @@ ACMD(mobsearch)
clif->message(fd, atcmd_output);
return false;
}
- if (mob_id == atoi(mob_name))
- strcpy(mob_name,mob->db(mob_id)->jname); // --ja--
- //strcpy(mob_name,mob_db(mob_id)->name); // --en--
+ if (mob_id == atoi(mob_name)) {
+ strcpy(mob_name,mob->db(mob_id)->jname); // DEFAULT_MOB_JNAME
+ //strcpy(mob_name,mob_db(mob_id)->name); // DEFAULT_MOB_NAME
+ }
snprintf(atcmd_output, sizeof atcmd_output, msg_fd(fd,1220), mob_name, mapindex_id2name(sd->mapindex)); // Mob Search... %s %s
clif->message(fd, atcmd_output);
@@ -6373,7 +6374,7 @@ ACMD(summon)
return false;
}
- md = mob->once_spawn_sub(&sd->bl, sd->bl.m, -1, -1, "--ja--", mob_id, "", SZ_SMALL, AI_NONE);
+ md = mob->once_spawn_sub(&sd->bl, sd->bl.m, -1, -1, DEFAULT_MOB_JNAME, mob_id, "", SZ_SMALL, AI_NONE);
if(!md)
return false;
@@ -6814,9 +6815,10 @@ ACMD(showmobs)
return false;
}
- if(mob_id == atoi(mob_name))
- strcpy(mob_name,mob->db(mob_id)->jname); // --ja--
- //strcpy(mob_name,mob_db(mob_id)->name); // --en--
+ if (mob_id == atoi(mob_name)) {
+ strcpy(mob_name,mob->db(mob_id)->jname); // DEFAULT_MOB_JNAME
+ //strcpy(mob_name,mob_db(mob_id)->name); // DEFAULT_MOB_NAME
+ }
snprintf(atcmd_output, sizeof atcmd_output, msg_fd(fd,1252), // Mob Search... %s %s
mob_name, mapindex_id2name(sd->mapindex));