• 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!
  • Which Pokémon Masters protagonist do you like most? Let us know by casting a vote in our Masters favorite protagonist poll here!
  • Red, Hilda, Paxton, or Kellyn - which Pokémon protagonist is your favorite? Let us know by voting in our poll!
  • 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.

Creating Delta Species

Now that you know the thing looks right, you can revert DELTAPOKEMONCHANCE to its initial value and now know that Delta Pokemon work right.
 
Would it even be possible to give a Delta Pokemon to a trainer and manually set up said Pokemon's type? After looking at how Trainers are compiled, I'm stumped.
 
Alright. I guess there's just one more thing I'd kinda like to set up either an event encounter or a gift delta that has a predetermined type/dual type. After that, I think I'll have all I need.
 
The way we have this programmed right now, you can't give a pre-determined dual-type Delta. But, it should be fairly easy if you really want. In the example maps, there's an event (I don't remember where) that gives you a Spiky-Eared Pichu. That's to show how to give special Pokemon.
 
I'm fully aware of the spiky-eared Pichu. Though with how it's programmed right now, what would I need to do to edit to where the types are random for wild Pokemon, but can be set with event Pokemon?
 
1.) in PokeBattle_Pokemon, near the top with all the other initializings, add attr_accessor(:deltatype2)

2.) Now scroll down to your def makeDelta and replace it with this:
Code:
# Makes this Pokemon delta species.
  def makeDelta
    case rand(17)
    when 0
      @deltatype=0
    when 1
      @deltatype=1
    when 2
      @deltatype=2
    when 3
      @deltatype=3
    when 4
      @deltatype=4
    when 5
      @deltatype=5
    when 6
      @deltatype=6
    when 7
      @deltatype=7
    when 8
      @deltatype=8
    when 9
      @deltatype=10
    when 10
      @deltatype=11
    when 11
      @deltatype=12
    when 12
      @deltatype=13
    when 13
      @deltatype=14
    when 14
      @deltatype=15
    when 15
      @deltatype=16
    when 16
      @deltatype=17
    when 17
      @deltatype=18
    end
    case rand(22)
    when 0
      @deltatype2=0
    when 1
      @deltatype2=1
    when 2
      @deltatype2=2
    when 3
      @deltatype2=3
    when 4
      @deltatype2=4
    when 5
      @deltatype2=5
    when 6
      @deltatype2=6
    when 7
      @deltatype2=7
    when 8
      @deltatype2=8
    when 9
      @deltatype2=10
    when 10
      @deltatype2=11
    when 11
      @deltatype2=12
    when 12
      @deltatype2=13
    when 13
      @deltatype2=14
    when 14
      @deltatype2=15
    when 15
      @deltatype2=16
    when 16
      @deltatype2=17
    when 17
      @deltatype2=18
    end
    @deltaflag=true
  end
Now hardcoded Deltas can also randomly be dual-typed.

3.) now go to def type2, and add the blue line:
Code:
# Returns this Pokémon's second type.
  def type2
    if self.isDelta?
      ret=((@personalID/4)/17)%17
      ret+=1 if ret>8
      ret=@deltatype if @deltatype != nil
      ret=@deltatype2 if @deltatype2 != nil
      return ret
    end
    dexdata=pbOpenDexData
    pbDexDataOffset(dexdata,@species,9)
    ret=dexdata.fgetb
    dexdata.close
    return ret
  end

4.) now when you want to make an event Delta with a predetermined type, you add this kind of thing:
Code:
p=PokeBattle_Pokemon.new(:GLACEON,30,$Trainer)
p.makeDelta
p.deltaflag=getConst(PBTypes,:PSYCHIC)
p.deltaflag2=getConst(PBTypes,:FIGHTING)
 
Lots of people have asked me how to make Delta Pokemon the way I did it in Entropy. You're the first I was willing to actually help, because it looked to me like you were already going down the right path, just at a slower pace. Plus the fact that your Deltas can be random types, I felt differentiated our methods enough.
 
I might have to check your game out now. I already saw the features, and it looks interesting.
 
I apologize for double posting, but there was something else that crossed my mind. When breeding a regular Pokemon with a delta species, I'd like for there to be a chance of it transferring one or both of its types. (Single-type delta being the more common of the two) As for two deltas being bred, same thing, only the chances of the egg being delta are higher, and the types of both parents can possibly mix.

Is that possible?
 
Let me get this straight:

Breeding Delta and non-Delta means that any Delta children will have the same type as their Delta parent, but doesn't affect the chance of the kids being Delta

Breeding two Deltas increases the chance of having Delta kids (by how much?) and also means the parents' types can mix.
 
Either one type of the parent (Always that type if the parent is a single type Delta) or both types of the parent (This never occurs if the parent is a single type, unless the other parent is a Delta)

I coded the chances of shinies to increase by 10 in my game if both parents are shiny while the shiny charm increases it by 2 and the Masuda method increases it by 5, so I might increase those chances by 10 as well.
 
I'm visiting my family for Easter, so won't be able to give you precise code until Monday. But... You are aware the code you edited for the Masuda Method, etc. actually is like rerolling dice when the number is bad? You want to reroll ten times?
 
I didn't realize that was what it was like. I might have to adjust the number then. Just to be clear, we're both thinking of this code, right?
Code:
# Masuda method and Shiny Charm
  shinyretries=0
  shinyretries+=10 if father.isShiny? && mother.isShiny?
  shinyretries+=5 if father.language!=mother.language
  shinyretries+=4 if father.isShiny? || mother.isShiny?
  shinyretries+=2 if hasConst?(PBItems,:SHINYCHARM) &&
                     $PokemonBag.pbQuantity(:SHINYCHARM)>0
 
I didn't realize that was what it was like. I might have to adjust the number then. Just to be clear, we're both thinking of this code, right?
Code:
# Masuda method and Shiny Charm
  shinyretries=0
  shinyretries+=10 if father.isShiny? && mother.isShiny?
  shinyretries+=5 if father.language!=mother.language
  shinyretries+=4 if father.isShiny? || mother.isShiny?
  shinyretries+=2 if hasConst?(PBItems,:SHINYCHARM) &&
                     $PokemonBag.pbQuantity(:SHINYCHARM)>0

Yes, that's it. Think of it like this. It's called Shiny RETRIES
 
Right. I should probably bump the number down then. 10 rerolls seems like too much. But I digress.
 
Whether a Pokemon is Shiny or whether it's Delta actually runs off the same number. So, let's use the code you've already edited.

Code:
# Masuda method and Shiny Charm
  shinyretries=0
  shinyretries+=10 if father.isShiny? && mother.isShiny?[COLOR="Red"]
  shinyretries+=10 if father.isDelta? && mother.isDelta?[/COLOR]
  shinyretries+=5 if father.language!=mother.language
  shinyretries+=4 if father.isShiny? || mother.isShiny?[COLOR="Red"]
  shinyretries+=4 if father.isDelta? || mother.isDelta?[/COLOR]
  shinyretries+=2 if hasConst?(PBItems,:SHINYCHARM) &&
                     $PokemonBag.pbQuantity(:SHINYCHARM)>0
  if shinyretries>0
    for i in 0...shinyretries
      break if egg.isShiny?[COLOR="Red"] || egg.isDelta?[/COLOR]
      egg.personalID=rand(65536)|(rand(65536)<<16)
    end
  end

I'll have to look back and see how I made the typeflags work before working on the other half of your request.
 
In PField_DayCare, around line 191, you should find this:
Code:
  # Inheriting form
  if isConst?(babyspecies,PBSpecies,:BURMY) ||
     isConst?(babyspecies,PBSpecies,:SHELLOS) ||
     isConst?(babyspecies,PBSpecies,:BASCULIN)
    egg.form=mother.form
  end

Add this either above or below it:
Code:
  # parents' Delta types
  delta_types=[]
  if mother.isDelta?
    delta_types.push(mother.type1)
    delta_types.push(mother.type2) if !delta_types.include?(mother.type2)
  end
  if father.isDelta?
    delta_types.push(father.type1) if !delta_types.include?(father.type1)
    delta_types.push(father.type2) if !delta_types.include?(father.type2)
  end
  case delta_types.length
  when 1
    egg.deltatype=delta_types[0]
  when 2
    egg.deltatype=delta_types[0]
    egg.deltatype2=delta_types[1]
  when 3,4
    bob=rand(delta_types.length)
    egg.deltatype=delta_types[bob]
    delta_types[bob]=nil
    delta_types.compact!
    bob=rand(delta_types.length)
    egg.deltatype2=delta_types[bob]
  end

If mom is Delta, the game puts her types into a hat, avoiding repeats. If dad is Delta, his types also get added to the hat, avoiding repeats even with mom's types.

If there's only one type in the hat, then the kid, if Delta, will be only one type. If there's two, the Delta children will be both types. If there's more than two, it'll choose two randomly.
 
Back
Top