I am using v21.1 of Pokemon Essentials. I am using this resource in the form of a plugin. It lists itself in the plugin list when the game complies, but it does not kick in and teach the Pokemon I want to have universal moves.
Code Block:
#===============================================================================
# * Near-Universal TMs - by FL (Credits will be apreciated)
#===============================================================================
#
# This script is for Pokémon Essentials. It makes all pokémon, except a few
# specific ones, learn the near universal moves as TM/TR/HM/Tutor, so it's not
# necessary to add the move to the PBS learnset.
#
#== INSTALLATION ===============================================================
#
# Put it above main OR convert into a plugin. No need to add/remove anything
# from PBS.
#
#===============================================================================
if !PluginManager.installed?("Near-Universal TMs")
PluginManager.register({
:name => "Near-Universal TMs",
:version => "1.0",
:link => "
https://www.pokecommunity.com/showthread.php?t=492298",
:credits => "FL"
})
end
NEAR_UNIVERSAL_TUTOR_MOVES = [
:ATTRACT,:BIDE,:CAPTIVATE,:CHARM,:CONFIDE,:CURSE,:DOUBLETEAM,:DOUBLEEDGE,:ENDURE,
:FACADE,:FRUSTRATION,:HEADBUTT,:HELPINGHAND,:HIDDENFORCE,:HIDDENPOWER,:MIMIC,:NATURALGIFT,
:PROTECT,:RAGE,:REST,:RETURN,:ROUND,:SECRETPOWER,:SLACKOFF,:SLEEPTALK,:SNORE,
:SUBSTITUTE,:SWAGGER,:FLATTER,:TAKEDOWN,:TOXIC,:WEATHERBALL
]
# Ignores forms
NEAR_INCOMPATIBLE_TUTOR_SPECIES = [
:DITTO,:SMEARGLE
#:CATERPIE,:METAPOD,:WEEDLE,:KAKUNA,:MAGIKARP,:DITTO,:UNOWN,:WOBBUFFET,
#:SMEARGLE,:WURMPLE,:SILCOON,:CASCOON,:WYNAUT,:BELDUM,:KRICKETOT,:BURMY,
#:COMBEE,:TYNAMO,:SCATTERBUG,:SPEWPA,:COSMOG,:COSMOEM,:BLIPBUG,:APPLIN
]
class Pokemon
alias :_compatible_with_move_FL_near :compatible_with_move?
def compatible_with_move?(move_id)
if (
NEAR_UNIVERSAL_TUTOR_MOVES.include?(move_id) &&
!NEAR_INCOMPATIBLE_TUTOR_SPECIES.include?(@species)
)
return true
end
return _compatible_with_move_FL_near(move_id)
end
end