- 9
- Posts
- 5
- Years
- Seen Jun 18, 2020
I would like to make Pokémon in the game have set Individual Values, as opposed to a random number. Where is the IV code located, and how should I rewrite it?
In PokeBattle_Pokemon under the def initialize(species,level,player=nil,withMoves=true), line 930:
do I replace with something like:
Update: Didn't work. Didn't expect it to, but not giving up.
This seemed to work:
Now Pokémon will randomly come with full IVs or no IVs. Please tell me if this is the best way, or if there will be issues later on?
In PokeBattle_Pokemon under the def initialize(species,level,player=nil,withMoves=true), line 930:
Code:
@iv = []
for i in 0...6
@iv[i] = rand(32)
end
do I replace with something like:
Code:
@iv = []
for i in 0...6
case @iv.random(2)
when 0
@iv[i]=iv[0,0,0,0,0,0]
when 1
@iv=iv[31,31,31,31,31,31]
end
Update: Didn't work. Didn't expect it to, but not giving up.
This seemed to work:
Code:
case rand(2)
when 0; @iv = [0,0,0,0,0,0]
when 1; @iv = [31,31,31,31,31,31]
end
Now Pokémon will randomly come with full IVs or no IVs. Please tell me if this is the best way, or if there will be issues later on?
Last edited by a moderator: