Advertiser Content

Scripting Question Removing 100 EV limit from vitamins

Started by princessyiris September 12th, 2019 2:18 PM
  • 1053 views
  • 4 replies

Vendily

Female
Online now
Posted 5 Days Ago
971 posts
4.3 Years
A good start is seeing what the vitamin code calls!
ItemHandlers::UseOnPokemon.add(:HPUP,proc{|item,pokemon,scene|
   if pbRaiseEffortValues(pokemon,PBStats::HP)==0
     scene.pbDisplay(_INTL("It won't have any effect."))
     next false
   else
     scene.pbRefresh
     scene.pbDisplay(_INTL("{1}'s HP increased.",pokemon.name))
     pokemon.changeHappiness("vitamin")
     next true
   end
})
this pbRaiseEffortValues looks promising, let's check that one out!
There's a couple of spots where 100 shows up there, so if you change all of them, that should do the trick!

Vendily

Female
Online now
Posted 5 Days Ago
971 posts
4.3 Years
I know you've already found your answer, and I've already volunteered one but there's also pbJustRaiseEffortValues which only raises the EVs without checking the 100 limit. You do have to pass the amount of EVs gained, it doesn't have a default value like pbRaiseEffortValues.

Advertiser Content