diff options
Diffstat (limited to 'src/map/atcommand.c')
-rw-r--r-- | src/map/atcommand.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/src/map/atcommand.c b/src/map/atcommand.c index 5c31155b1..c355f6bbd 100644 --- a/src/map/atcommand.c +++ b/src/map/atcommand.c @@ -72,8 +72,7 @@ struct atcmd_binding_data* get_atcommandbind_byname(const char* name) { //----------------------------------------------------------- // Return the message string of the specified number by [Yor] //----------------------------------------------------------- -const char* msg_txt(int msg_number) -{ +const char* atcommand_msg(int msg_number) { if (msg_number >= 0 && msg_number < MAX_MSG && atcommand->msg_table[msg_number] != NULL && atcommand->msg_table[msg_number][0] != '\0') return atcommand->msg_table[msg_number]; @@ -1053,7 +1052,7 @@ ACMD(heal) if ( hp < 0 && sp <= 0 ) { status->damage(NULL, &sd->bl, -hp, -sp, 0, 0); - clif->damage(&sd->bl,&sd->bl, timer->gettick(), 0, 0, -hp, 0, 4, 0); + clif->damage(&sd->bl,&sd->bl, 0, 0, -hp, 0, 4, 0); clif->message(fd, msg_txt(156)); // HP or/and SP modified. return true; } @@ -1064,7 +1063,7 @@ ACMD(heal) status->heal(&sd->bl, hp, 0, 0); else { status->damage(NULL, &sd->bl, -hp, 0, 0, 0); - clif->damage(&sd->bl,&sd->bl, timer->gettick(), 0, 0, -hp, 0, 4, 0); + clif->damage(&sd->bl,&sd->bl, 0, 0, -hp, 0, 4, 0); } } @@ -1927,12 +1926,7 @@ ACMD(monster) clif->message(fd, msg_txt(40)); // Invalid monster ID or name. return false; } - - if (mob_id == MOBID_EMPERIUM) { - clif->message(fd, msg_txt(83)); // Monster 'Emperium' cannot be spawned. - return false; - } - + if (number <= 0) number = 1; @@ -1957,7 +1951,7 @@ ACMD(monster) range = (int)sqrt((float)number) +2; // calculation of an odd number (+ 4 area around) for (i = 0; i < number; i++) { map->search_freecell(&sd->bl, 0, &mx, &my, range, range, 0); - k = mob->once_spawn(sd, sd->bl.m, mx, my, name, mob_id, 1, eventname, size, AI_NONE); + k = mob->once_spawn(sd, sd->bl.m, mx, my, name, mob_id, 1, eventname, size, AI_NONE|(mob_id == MOBID_EMPERIUM?0x200:0x0)); count += (k != 0) ? 1 : 0; } @@ -10240,4 +10234,5 @@ void atcommand_defaults(void) { atcommand->doload = atcommand_doload; atcommand->base_commands = atcommand_basecommands; atcommand->add = atcommand_add; + atcommand->msg = atcommand_msg; } |