diff options
author | blackhole89 <blackhole89@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-10 16:54:18 +0000 |
---|---|---|
committer | blackhole89 <blackhole89@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-03-10 16:54:18 +0000 |
commit | 70d50d2cf22c2e55d5c069797ccc0801d1ce8eed (patch) | |
tree | 58fb1c5a1c0539c1afe911270ee55f2914fc50a3 /src/map/battle.c | |
parent | e111fabe50bd88d0acda24a72f8d4ddebb915f30 (diff) | |
download | hercules-70d50d2cf22c2e55d5c069797ccc0801d1ce8eed.tar.gz hercules-70d50d2cf22c2e55d5c069797ccc0801d1ce8eed.tar.bz2 hercules-70d50d2cf22c2e55d5c069797ccc0801d1ce8eed.tar.xz hercules-70d50d2cf22c2e55d5c069797ccc0801d1ce8eed.zip |
GS_MAGICALBULLET implementation: declaring variables after case: without defining a block of {}, using something weird called atn_rand(something) instead of just rand. Fixed.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5563 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r-- | src/map/battle.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/map/battle.c b/src/map/battle.c index 1a6179886..7c92f1517 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -1924,12 +1924,14 @@ static struct Damage battle_calc_weapon_attack( ATK_ADD(10*pc_checkskill(sd, TK_RUN));
break;
case GS_MAGICALBULLET:
+ {
int matk1=status_get_matk1(src),matk2=status_get_matk2(src);
if(matk1>matk2)
- ATK_ADD(matk2+atn_rand()%(matk1-matk2+1));
- else
- ATK_ADD(matk2);
+ {
+ ATK_ADD(matk2+rand()%(matk1-matk2+1));
+ } else ATK_ADD(matk2);
break;
+ }
}
}
//Here comes a second pass for skills that stack to the previously defined % damage. [Skotlex]
|