Implements cheek pouch
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
00e20953b8
commit
06d1da3d3c
|
@ -0,0 +1,10 @@
|
||||||
|
namespace Gen7 {
|
||||||
|
[Ability effect=CheekPouch]
|
||||||
|
class CheekPouch : PkmnScript {
|
||||||
|
void OnAfterHeldItemConsume(Pokemon@ pokemon, const Item@ item) override {
|
||||||
|
if (item.HasFlag("berry")){
|
||||||
|
pokemon.Heal(pokemon.MaxHealth / 4);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
|
@ -4,6 +4,6 @@ shared abstract class ItemUseScript {
|
||||||
bool IsPokemonUseItem(){ return false; };
|
bool IsPokemonUseItem(){ return false; };
|
||||||
bool IsUseValidForPokemon(Pokemon@){ return false; };
|
bool IsUseValidForPokemon(Pokemon@){ return false; };
|
||||||
bool IsHoldable(){ return false; };
|
bool IsHoldable(){ return false; };
|
||||||
void OnUse(){};
|
void OnUse(Battle@){};
|
||||||
void OnPokemonUse(Pokemon@){};
|
void OnPokemonUse(Pokemon@, bool){};
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,7 @@ shared abstract class PkmnScript {
|
||||||
void OnEndTurn(){};
|
void OnEndTurn(){};
|
||||||
void OnDamage(Pokemon@, DamageSource, uint, uint){};
|
void OnDamage(Pokemon@, DamageSource, uint, uint){};
|
||||||
void OnFaint(Pokemon@, DamageSource){};
|
void OnFaint(Pokemon@, DamageSource){};
|
||||||
|
void OnAfterHeldItemConsume(Pokemon@, const Item@){};
|
||||||
void PreventIncomingCritical(ExecutingMove@, Pokemon@, uint8, bool &inout){};
|
void PreventIncomingCritical(ExecutingMove@, Pokemon@, uint8, bool &inout){};
|
||||||
void ModifyCriticalStage(ExecutingMove@, Pokemon@, uint8, uint8 &inout){};
|
void ModifyCriticalStage(ExecutingMove@, Pokemon@, uint8, uint8 &inout){};
|
||||||
void OverrideCriticalModifier(ExecutingMove@, Pokemon@, uint8, float &inout){};
|
void OverrideCriticalModifier(ExecutingMove@, Pokemon@, uint8, float &inout){};
|
||||||
|
|
|
@ -19,7 +19,7 @@ namespace Pokemon{
|
||||||
return pokemon.CurrentHealth < pokemon.MaxHealth;
|
return pokemon.CurrentHealth < pokemon.MaxHealth;
|
||||||
}
|
}
|
||||||
|
|
||||||
void OnPokemonUse(Pokemon@ pkmn) override {
|
void OnPokemonUse(Pokemon@ pkmn, bool isBattleUse) override {
|
||||||
pkmn.Heal(_amount);
|
pkmn.Heal(_amount);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
TESTERVERSION=0.0.14
|
TESTERVERSION=0.0.15
|
||||||
|
|
||||||
# Get the release information from the api for the specified version
|
# Get the release information from the api for the specified version
|
||||||
curl -X GET "https://git.p-epsilon.com/api/v1/repos/Deukhoofd/PokemonScriptTester/releases/tags/$TESTERVERSION" -H "accept: application/json" |
|
curl -X GET "https://git.p-epsilon.com/api/v1/repos/Deukhoofd/PokemonScriptTester/releases/tags/$TESTERVERSION" -H "accept: application/json" |
|
||||||
|
|
Loading…
Reference in New Issue