diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-12-08 23:32:30 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2007-12-08 23:32:30 +0000 |
commit | 1745c6c17c039ef17d103eea9dcce7e4978cb79a (patch) | |
tree | c9dda71c06b37a5febda668832645eb4638c4587 /src | |
parent | e0edebcdda7817ecb520816440a00dff6108e398 (diff) | |
download | hercules-1745c6c17c039ef17d103eea9dcce7e4978cb79a.tar.gz hercules-1745c6c17c039ef17d103eea9dcce7e4978cb79a.tar.bz2 hercules-1745c6c17c039ef17d103eea9dcce7e4978cb79a.tar.xz hercules-1745c6c17c039ef17d103eea9dcce7e4978cb79a.zip |
- Fixed a 'variable may be used uninitialized' error.
- Removed 'type' being passed to skill_trap_splash since it was not used at all.
- Fixed Land Mine doing nothing.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11872 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r-- | src/map/clif.c | 4 | ||||
-rw-r--r-- | src/map/skill.c | 5 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/map/clif.c b/src/map/clif.c index 8707d53f6..e1f7b057b 100644 --- a/src/map/clif.c +++ b/src/map/clif.c @@ -8567,6 +8567,8 @@ void clif_parse_TakeItem(int fd, struct map_session_data *sd) void clif_parse_DropItem(int fd, struct map_session_data *sd) { int item_index, item_amount; + item_index = RFIFOW(fd,packet_db[sd->packet_ver][RFIFOW(fd,0)].pos[0])-2; + item_amount = RFIFOW(fd,packet_db[sd->packet_ver][RFIFOW(fd,0)].pos[1]); do { if (pc_isdead(sd)) break; @@ -8581,8 +8583,6 @@ void clif_parse_DropItem(int fd, struct map_session_data *sd) )) break; - item_index = RFIFOW(fd,packet_db[sd->packet_ver][RFIFOW(fd,0)].pos[0])-2; - item_amount = RFIFOW(fd,packet_db[sd->packet_ver][RFIFOW(fd,0)].pos[1]); if (!pc_dropitem(sd, item_index, item_amount)) break; diff --git a/src/map/skill.c b/src/map/skill.c index cc45546a6..f68466af3 100644 --- a/src/map/skill.c +++ b/src/map/skill.c @@ -6847,7 +6847,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns case UNT_SANDMAN: case UNT_FLASHER: case UNT_FREEZINGTRAP: - map_foreachinrange(skill_trap_splash,&src->bl, skill_get_splash(sg->skill_id, sg->skill_lv), sg->bl_flag, &src->bl,tick,type); + map_foreachinrange(skill_trap_splash,&src->bl, skill_get_splash(sg->skill_id, sg->skill_lv), sg->bl_flag, &src->bl,tick); clif_changetraplook(&src->bl, sg->unit_id==UNT_LANDMINE?UNT_FIREPILLAR_ACTIVE:UNT_USED_TRAPS); src->range = -1; //Disable range so it does not invoke a for each in area again. sg->limit=DIFF_TICK(tick,sg->tick)+1500; @@ -7014,7 +7014,7 @@ int skill_unit_onplace_timer (struct skill_unit *src, struct block_list *bl, uns case UNT_GROUNDDRIFT_FIRE: map_foreachinrange(skill_trap_splash,&src->bl, skill_get_splash(sg->skill_id, sg->skill_lv), sg->bl_flag, - &src->bl,tick,0); + &src->bl,tick); sg->unit_id = UNT_USED_TRAPS; clif_changetraplook(&src->bl, UNT_FIREPILLAR_ACTIVE); sg->limit=DIFF_TICK(tick,sg->tick)+1500; @@ -9072,6 +9072,7 @@ int skill_trap_splash (struct block_list *bl, va_list ap) case UNT_FLASHER: skill_additional_effect(ss,bl,sg->skill_id,sg->skill_lv,BF_MISC,tick); break; + case UNT_LANDMINE: case UNT_BLASTMINE: case UNT_CLAYMORETRAP: case UNT_FREEZINGTRAP: |