No Description

power_trick.c 363B

12345678910111213
  1. #include <battle.h>
  2. #include <bpre.h>
  3. u8 power_trick_swap()
  4. {
  5. custom_battle_elements.ptr->bank_affecting[battle_active_bank].powertrick = 1;
  6. u16 *atk = &battle_participants[battle_active_bank].atk;
  7. u16 *def = &battle_participants[battle_active_bank].def;
  8. u16 switch_var = *atk;
  9. *atk = *def;
  10. *def = switch_var;
  11. return 0;
  12. }