• ✨ ARCHIVE MODE ✨
    The forum has now been set to read-only mode, no new posts, resources, replies etc will not be possible.
    We recommend you join our Discord server to get real-time response: Discord Invite Link

[0.28.2]Moves that still don't work properly

Status
Not open for further replies.

Dratini

Pokémon Ranger
Aand each time i fight vs zuba and he use Lech Life it make game crashed >_>
Uproar work 1 round, should 2-5
Seems like Poison Sting also apply poison almost every hit, i fight vs weedle and he used 7x Sting, get posion 6x (i used 6x Antidote) and every time i fight pokmn with Sting, i get poison on 1st hit.
 

Darkfire

Administrator
Administrator
P3D Developer
Oh yeah beware Leech Life it currently doesn't round the number so it tries to deal half damage
 

Genshie

Pokémon Ranger
Don't know if this has been reported but Dream Eater does damage when a pokemon is awake and does even a little damage when it says it does nothing. Also another bug Electric attacks still hurt rock/ground types.
 

DracoHouston

Kolben Developer
Contributor
Don't know if this has been reported but Dream Eater does damage when a pokemon is awake and does even a little damage when it says it does nothing. Also another bug Electric attacks still hurt rock/ground types.
preattack is broken, it only came up when someone tried magnitude. turns out nils didn't even put it in lol. he's fixing it

the way dream eater's script works is it checks if the target is asleep or not, and sets the store string and if the target is awake sets the attack to do 0 damage. then special attack displays the message 'but it failed...' or perform the heal based on damage and display the message about eating the target's dream

because the pre attack function is never called in 0.27 and 0.28 this whole script breaks :(

Code:
SetAttackBaseDamage(138,100)
SetAttackMaxPP(138,15)
SetAttackCategory(138,1)
SetAttackContestCategory(138,1)
SetAttackType(138,13)
SetAttackPriority(138,0)
SetAttackAccuracy(138,255)
SetAttackAttackCategory(138, 2)
SetAttackSpecialAttackDelegate(138, "ATTACKS_PSYCHIC_DREAM_EATER_SPECIAL")
SetAttackPreAttackDelegate(138, "ATTACKS_PSYCHIC_DREAM_EATER_PRE_ATTACK")

function ATTACKS_PSYCHIC_DREAM_EATER_PRE_ATTACK()
    -- we set the absolute damage and store to tell the battle and special how this check turned out
    if Attacks_GetTargetStatusEffect("target") ~= "asleep" then
        Attacks_SetStore("0")
        -- make it do no damage but still attack, so special attack can trigger
        Attacks_SetAbsoluteDamage(0)
    else
        -- if absolute damage is set to -1 it goes back to calculating based on type, STAB, crit, power etc
        Attacks_SetAbsoluteDamage(-1)
        Attacks_SetStore("1")
    end
end

function ATTACKS_PSYCHIC_DREAM_EATER_SPECIAL()
    if Attacks_Store == "1" then
        --the target was asleep, drain
        local restore = math.floor(Attacks_DamageDealt / 2)
        if restore <= 0 then
            restore = 1
        end
        Attacks_AddBattleStep("GainHP", Attacks_TargetString .. "|" .. tostring(restore))
        Attacks_AddBattleStep("Message", Attacks_PrimaryTargetName .. " dream was eaten!")
    else
        --the target is awake, do nothing. it also would not have done damage
        Attacks_AddBattleStep("Message", "But it failed...")
    end
end
 

Darkfire

Administrator
Administrator
P3D Developer
Well I saved leech life....
Literally had nilllzz stop the upload to put it in cause it actually crashed the game :nailbiting:
 
Status
Not open for further replies.
Top