Skip to content
This repository has been archived by the owner on Jul 30, 2020. It is now read-only.

Commit

Permalink
Add Shiny Sprites Display
Browse files Browse the repository at this point in the history
* Update PokemonDataViewModel.cs

* Update PokemonImageConverter.cs

* Update PokemonIdToImageConverter.cs

* Update PokemonViewModelBase.cs

* Update MapPokemonMarker.xaml

* Update PokemonIdToImageConverter.cs

* Update PokemonImageConverter.cs

* Update PokemonDataViewModel.cs
  • Loading branch information
Lord-Haji authored Mar 29, 2017
1 parent 59bef99 commit 7e7e183
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<Grid>
<Button Background="Transparent" BorderThickness="0">
<Image Name="icon"
Source="{Binding Path=PokemonIcon, FallbackValue=http://www.serebii.net/pokemongo/pokemon/145.png}"
Source="{Binding Path=PokemonIcon, FallbackValue=https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon/145.png}"
VerticalAlignment="Center"
HorizontalAlignment="Center"
IsHitTestVisible="false"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public object Convert(object value, Type targetType, object parameter, CultureIn
{
var pokemonId = (PokemonId)value;

return $"http://www.serebii.net/pokemongo/pokemon/{(int)pokemonId:000}.png";
return $"https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon/{(int)pokemonId:000}.png";

}

Expand Down
2 changes: 1 addition & 1 deletion PoGo.Necrobot.Window/Converters/PokemonImageConverter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public object Convert(object value, Type targetType, object parameter, CultureIn
{
var id = (int)value;

return $"http://www.serebii.net/pokemongo/pokemon/{id:000}.png";
return $"https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon/{id:000}.png";

}

Expand Down
6 changes: 5 additions & 1 deletion PoGo.Necrobot.Window/Model/PokemonDataViewModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,11 @@ public string PokemonIcon
{
get
{
return $"http://assets.pokemon.com/assets/cms2/img/pokedex/full/{(int)PokemonData.PokemonId:000}.png";
if (pokemonData.PokemonDisplay.Shiny)
{
return $"https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon-shiny/{(int)PokemonData.PokemonId:000}.png";
}
return $"https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon/{(int)PokemonData.PokemonId:000}.png";
}
}

Expand Down
2 changes: 1 addition & 1 deletion PoGo.Necrobot.Window/Model/PokemonViewModelBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public string PokemonIcon
{
get
{
return $"http://www.serebii.net/pokemongo/pokemon/{(int)PokemonId:000}.png";
return $"https://raw.githubusercontent.com/Necrobot-Private/PokemonGO-Assets/master/pokemon/{(int)PokemonId:000}.png";
}
}

Expand Down

0 comments on commit 7e7e183

Please sign in to comment.