Skip to content

Commit

Permalink
Straighten the straightening
Browse files Browse the repository at this point in the history
  • Loading branch information
EnPassant4264 committed Aug 29, 2024
1 parent dcec815 commit d23febc
Show file tree
Hide file tree
Showing 4 changed files with 49 additions and 4 deletions.
3 changes: 2 additions & 1 deletion data/mods/earthsky/abilities.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2958,7 +2958,8 @@ export const Abilities: {[abilityid: string]: ModdedAbilityData} = {
},
tangling: {
onHit(target, source, move) {
if (this.checkMoveMakesContact(move, source, target)) {
if (this.checkMoveMakesContact(move, source, target))
this.add('-activate', target, 'ability: Tangling');{
source.addVolatile('singletrap', target, Dex.abilities.get('tangling'), 'trapper');
}
},
Expand Down
17 changes: 14 additions & 3 deletions data/mods/earthsky/conditions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,7 @@ export const Conditions: {[k: string]: ModdedConditionData} = {
return 4;
},
onStart(target, source, move) {
this.add('-start', target, 'Block', '[silent]');
this.add('-activate', target, 'trapped');
},
onTrapPokemon(pokemon) {
Expand Down Expand Up @@ -212,6 +213,10 @@ export const Conditions: {[k: string]: ModdedConditionData} = {
return false;
}
},
onEnd(target) {
this.add('-end', target, 'trapped');
this.add('-end', target, 'Block', '[silent]');
},
},
meanlooked: {
name: 'meanlooked',
Expand All @@ -222,12 +227,17 @@ export const Conditions: {[k: string]: ModdedConditionData} = {
return 4;
},
onStart(target, source, move) {
this.add('-start', target, 'Mean Look', '[silent]');
this.add('-activate', target, 'trapped');
},
onTrapPokemonPriority: 100,
onTrapPokemon(pokemon) {
pokemon.trapped = true;
},
onEnd(target) {
this.add('-end', target, 'trapped');
this.add('-end', target, 'Mean Look', '[silent]');
},
},
arenatrapped: {
name: 'arenatrapped',
Expand All @@ -248,12 +258,13 @@ export const Conditions: {[k: string]: ModdedConditionData} = {
pokemon.tryTrap();
},
onStart(target) {
this.add('-start', target, 'singletrap', '[silent]');
this.add('-activate', target, 'trapped');
},
onEnd(pokemon) {
this.add('-end', pokemon, 'singletrap');
onEnd(target) {
this.add('-end', target, 'trapped');
this.add('-end', target, 'singletrap', '[silent]');
},
end: " [POKEMON] was freed from trapping.",
},
strongpartialtrap: {
name: 'strongpartialtrap',
Expand Down
6 changes: 6 additions & 0 deletions data/mods/earthsky/moves.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6854,6 +6854,12 @@ export const Moves: {[moveid: string]: ModdedMoveData} = {
this.runEvent('AfterSubDamage', target, source, move, damage);
return this.HIT_SUBSTITUTE;
},
onTrapPokemonPriority: -10,
onTrapPokemon(pokemon) {
if(!pokemon.volatiles['meanlooked']){
pokemon.trapped = false;
}
},
onEnd(target) {
this.add('-end', target, 'Substitute');
},
Expand Down
27 changes: 27 additions & 0 deletions data/mods/earthsky/typechart.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,31 @@ export const TypeChart: {[k: string]: ModdedTypeData} = {
},
HPivs: {atk: 30, def: 30},
},
ghost: {
damageTaken: {
trapped: 3,
singletrap: 3,
blocked: 3,
arenatrapped: 3,
Bug: 2,
Dark: 1,
Dragon: 0,
Electric: 0,
Fairy: 0,
Fighting: 3,
Fire: 0,
Flying: 0,
Ghost: 1,
Grass: 0,
Ground: 0,
Ice: 0,
Normal: 3,
Poison: 2,
Psychic: 0,
Rock: 0,
Steel: 0,
Water: 0,
},
HPivs: {def: 30, spd: 30},
},
};

0 comments on commit d23febc

Please sign in to comment.