summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-26 20:49:37 +0000
committerLupus <Lupus@54d463be-8e91-2dee-dedb-b68131a5f0ec>2004-11-26 20:49:37 +0000
commit001f8acbf66d799408cce996ee7a7a74f63c979a (patch)
tree3f600eefcb4aaa4304e6ba94f5f999ad19afe621 /src
parentdadeccc29bcbd5c79e836981902ee44d83f6ca86 (diff)
downloadhercules-001f8acbf66d799408cce996ee7a7a74f63c979a.tar.gz
hercules-001f8acbf66d799408cce996ee7a7a74f63c979a.tar.bz2
hercules-001f8acbf66d799408cce996ee7a7a74f63c979a.tar.xz
hercules-001f8acbf66d799408cce996ee7a7a74f63c979a.zip
Fixed Abrakadabra skill
and 2 minor bugs in skills.c (related to consumed items) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/athena@372 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src')
-rw-r--r--src/map/skill.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index bb6df7f3d..f1d58f8c8 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -2969,11 +2969,12 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
break;
case SA_ABRACADABRA:
//require 1 yellow gemstone even with mistress card or Into the Abyss
- if (pc_search_inventory(sd, 715) <= 0 ) {
+ if ((i=pc_search_inventory(sd, 715)) < 0 ) { //bug fixed by Lupus (item pos can be 0, too!)
clif_skill_fail(sd,sd->skillid,0,0);
break;
}
- pc_delitem(sd, pc_search_inventory(sd, 715), 1, 0);
+ //pc_delitem(sd, pc_search_inventory(sd, 715), 1, 0);
+ pc_delitem(sd, i, 1, 0);
//
do{
abra_skillid=skill_abra_dataset(skilllv);
@@ -3726,7 +3727,7 @@ int skill_castend_nodamage_id( struct block_list *src, struct block_list *bl,int
case BS_REPAIRWEAPON: /* 武器修理 */
if(sd) {
//動作しないのでとりあえずコメントアウト
- if (pc_search_inventory(sd, 999) <= 0 ) {
+ if (pc_search_inventory(sd, 999) < 0 ) { //fixed by Lupus (item pos can be = 0!)
clif_skill_fail(sd,sd->skillid,0,0);
map_freeblock_unlock();
return 1;