{
  num: -13051,
  accuracy: true,
  basePower: 0,
  category: "Status",
  name: "Sogyo no Kotowari",
  pp: 5,
  priority: 4,
  flags: { noassist: 1, failcopycat: 1 },
  stallingMove: true,
  volatileStatus: "sogyonokotowari",
  onPrepareHit(pokemon) {
    return !!this.queue.willAct() && this.runEvent("StallMove", pokemon);
  },
  onHit(pokemon) {
    pokemon.addVolatile("stall");
  },
  condition: {
    duration: 1,
    onStart(target) {
      this.add("-singleturn", target, "move: Sogyo no Kotowari");
    },
    onTryHitPriority: 3,
    onTryHit(target, source, move) {
      if (!move || move.category === "Status") return;
      if (move.category !== "Special") return;
      if (!source || source === target) return;
      if (move.smartTarget) move.smartTarget = false;
      else this.add("-activate", target, "move: Sogyo no Kotowari");
      target.ukitakeStoredType = move.type || "Psychic";
      target.addVolatile("reishicharge", source, move);
      let reflectedDamage = Math.max(1, Math.floor((target.maxhp || target.baseMaxhp || 1) / 4));
      try {
        const calcMove = this.dex.getActiveMove(move.id || move.name);
        calcMove.hit = 0;
        const predicted = this.actions.getDamage(source, target, calcMove, true);
        if (typeof predicted === "number" && predicted > 0) {
          reflectedDamage = Math.max(1, Math.floor(predicted * 1.5));
        }
      } catch (e) {}
      this.damage(reflectedDamage, source, target, this.dex.moves.get("sogyonokotowari"));
      return this.NOT_FAIL;
    }
  },
  secondary: null,
  target: "self",
  type: "Psychic",
  zMove: { boost: { spd: 1 } },
  contestType: "Clever",
  desc: "Priority +4. Blocks a special damaging move, stores its type, and reflects amplified spiritual pressure. Repeated use can fail."
}
