summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/map/charcommand.c3
-rw-r--r--src/map/map.c4
-rw-r--r--src/map/mob.c32
3 files changed, 23 insertions, 16 deletions
diff --git a/src/map/charcommand.c b/src/map/charcommand.c
index f531f3fc0..696abd7c7 100644
--- a/src/map/charcommand.c
+++ b/src/map/charcommand.c
@@ -181,6 +181,9 @@ is_charcommand(const int fd, struct map_session_data* sd, const char* message) {
nullpo_retr(CharCommand_None, sd);
+ if (sd->sc.count && sd->sc.data[SC_NOCHAT].timer != -1 && sd->sc.data[SC_NOCHAT].val1&MANNER_NOCOMMAND)
+ return CharCommand_None;
+
if (!message || !*message)
return CharCommand_None;
diff --git a/src/map/map.c b/src/map/map.c
index f16282bf4..e2815ecdd 100644
--- a/src/map/map.c
+++ b/src/map/map.c
@@ -3316,13 +3316,13 @@ int do_init(int argc, char *argv[]) {
do_init_clif();
do_init_script();
do_init_itemdb();
- do_init_mob(); // npcの初期化・でmob_spawnして、mob_dbを?照するのでinit_npcより先
+ do_init_skill();
+ do_init_mob();
do_init_pc();
do_init_status();
do_init_party();
do_init_guild();
do_init_storage();
- do_init_skill();
do_init_pet();
do_init_merc(); //[orn]
do_init_npc();
diff --git a/src/map/mob.c b/src/map/mob.c
index fa23e1b7b..11d44955f 100644
--- a/src/map/mob.c
+++ b/src/map/mob.c
@@ -3744,7 +3744,7 @@ static int mob_readskilldb(void)
if (mob_id > 0 && mob_db(mob_id) == mob_dummy)
{
if (mob_id != last_mob_id) {
- ShowWarning("mob_skill: Non existant Mob id %d at %s, line %d\n", mob_id, filename[x], count);
+ ShowError("mob_skill: Non existant Mob id %d at %s, line %d\n", mob_id, filename[x], count);
last_mob_id = mob_id;
}
continue;
@@ -3767,7 +3767,7 @@ static int mob_readskilldb(void)
break;
if(i==MAX_MOBSKILL){
if (mob_id != last_mob_id) {
- ShowWarning("mob_skill: readdb: too many skill! Line %d in %d[%s]\n",
+ ShowError("mob_skill: readdb: too many skill! Line %d in %d[%s]\n",
count,mob_id,mob_db_data[mob_id]->sprite);
last_mob_id = mob_id;
}
@@ -3780,17 +3780,19 @@ static int mob_readskilldb(void)
for(j=0;j<tmp && strcmp(sp[2],state[j].str);j++);
if (j < tmp)
ms->state=state[j].id;
- else
- ShowError("mob_skill: Unrecognized state %s at %s, line %d\n", sp[2], filename[x], count);
+ else if (!ms->state) {
+ ShowWarning("mob_skill: Unrecognized state %s at %s, line %d\n", sp[2], filename[x], count);
+ ms->state=MSS_ANY;
+ }
//Skill ID
j=atoi(sp[3]);
if (j<=0 || j>MAX_SKILL_DB) //fixed Lupus
{
if (mob_id < 0)
- ShowWarning("Invalid Skill ID (%d) for all mobs\n", j);
+ ShowError("Invalid Skill ID (%d) for all mobs\n", j);
else
- ShowWarning("Invalid Skill ID (%d) for mob %d (%s)\n", j, mob_id, mob_db_data[mob_id]->sprite);
+ ShowError("Invalid Skill ID (%d) for mob %d (%s)\n", j, mob_id, mob_db_data[mob_id]->sprite);
continue;
}
ms->skill_id=j;
@@ -3826,26 +3828,28 @@ static int mob_readskilldb(void)
if (ms->target > MST_AROUND)
{
if (battle_config.error_log)
- ShowWarning("Wrong mob skill target for ground skill %d (%s) for %s\n",
- ms->skill_id, skill_get_name(ms[i].skill_id),
+ ShowWarning("Wrong mob skill target for ground skill %d (%s) for %s.\n",
+ ms->skill_id, skill_get_name(ms->skill_id),
mob_id < 0?"all mobs":mob_db_data[mob_id]->sprite);
ms->target = MST_TARGET;
}
- } else if (ms[i].target > MST_MASTER) {
+ } else if (ms->target > MST_MASTER) {
if (battle_config.error_log)
- ShowWarning("Wrong mob skill target 'around' for non-ground skill %d (%s). for %s\n",
- ms[i].skill_id, skill_get_name(ms[i].skill_id),
+ ShowWarning("Wrong mob skill target 'around' for non-ground skill %d (%s) for %s\n.",
+ ms->skill_id, skill_get_name(ms->skill_id),
mob_id < 0?"all mobs":mob_db_data[mob_id]->sprite);
ms->target = MST_TARGET;
}
- ms->cond1=-1;
tmp = sizeof(cond1)/sizeof(cond1[0]);
for(j=0;j<tmp && strcmp(sp[10],cond1[j].str);j++);
if (j < tmp)
ms->cond1=cond1[j].id;
- else
- ShowError("mob_skill: Unrecognized condition 1 %s at %s, line %d\n", sp[10], filename[x], count);
+ else {
+ ShowWarning("mob_skill: Unrecognized condition 1 %s at %s, line %d\n",
+ sp[10], filename[x], count);
+ ms->cond1=-1;
+ }
ms->cond2=atoi(sp[11]);
tmp = sizeof(cond2)/sizeof(cond2[0]);