• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Trading Card Game 2 protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Scripting Question] How do I write "If MoveType=Steel" in Essentials-ese?

  • 428
    Posts
    5
    Years
    I've tried getting this code to work but something about it breaks and makes any usage of any move put up unhelpful error messages until I close the game.

    Code:
    if moveType == :STEEL && user.hasActiveAbility?(:STEELWORKER)
    multipliers[:final_damage_multiplier] *= 1.5
    end

    I tried using other ways of checking if the move's type is Steel and this didn't work either:

    Code:
    if defType == :STEEL && user.hasActiveAbility?(:STEELWORKER)
    multipliers[:final_damage_multiplier] *= 1.5
    end

    How do I properly get Steelworker's code working?
     
    I've tried getting this code to work but something about it breaks and makes any usage of any move put up unhelpful error messages until I close the game.

    Code:
    if moveType == :STEEL && user.hasActiveAbility?(:STEELWORKER)
    multipliers[:final_damage_multiplier] *= 1.5
    end

    I tried using other ways of checking if the move's type is Steel and this didn't work either:

    Code:
    if defType == :STEEL && user.hasActiveAbility?(:STEELWORKER)
    multipliers[:final_damage_multiplier] *= 1.5
    end

    How do I properly get Steelworker's code working?

    It 100% depends on where and how you are implementing this code. However, I'm not really sure I see the point of this code you're implementing in the first place, since the Steel Worker ability already exists and applies the appropriate damage multiplier for Steel moves in its own code.
     
    I added a 0.1x power multiplier for non-STAB moves. Dhelmise lacks the Steel type so this affects him. I need to make Steelworker buff Steel moves to offset this nerf to nonSTAB moves.

    The nonSTAB nerf is necessary in my game because in my game any Pokemon can learn any move and I made super effective hits a bigger deal, which makes fast mons with coverage overpowered. Nerfing coverage into uselessness was the best solution.
     
    You could just increase the already present steelworker ability so that it offsets the multiplier for non-stab moves. Seems easier to me then trying to create a whole nother condition.
     
    Back
    Top