mirror of
https://github.com/infinitefusion/infinitefusion-e18.git
synced 2025-12-06 06:01:46 +00:00
Fixes critical capture (based on 70bc2480f4)
This commit is contained in:
@@ -247,27 +247,10 @@ module PokeBattle_BattleCommon
|
|||||||
echoln isOnLastBall
|
echoln isOnLastBall
|
||||||
# Critical capture check
|
# Critical capture check
|
||||||
if isOnLastBall
|
if isOnLastBall
|
||||||
c = 0
|
c = x * 6 / 12
|
||||||
numOwned = $Trainer.pokedex.owned_count
|
|
||||||
if numOwned > 600;
|
|
||||||
c = x * 5 / 12
|
|
||||||
elsif numOwned > 450;
|
|
||||||
c = x * 4 / 12
|
|
||||||
elsif numOwned > 300;
|
|
||||||
c = x * 3 / 12
|
|
||||||
else
|
|
||||||
c = x * 2 / 12
|
|
||||||
end
|
|
||||||
# elsif numOwned > 150;
|
|
||||||
# c = x * 2 / 12
|
|
||||||
# elsif numOwned > 30;
|
|
||||||
# c = x / 12
|
|
||||||
# end
|
|
||||||
# Calculate the number of shakes
|
|
||||||
if c > 0 && pbRandom(256) < c
|
if c > 0 && pbRandom(256) < c
|
||||||
@criticalCapture = true
|
@criticalCapture = true
|
||||||
return 4 if pbRandom(65536) < y
|
return 4
|
||||||
return 0
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
# Calculate the number of shakes
|
# Calculate the number of shakes
|
||||||
|
|||||||
Binary file not shown.
Reference in New Issue
Block a user