Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Move] Corrosive Gas #4793

Open
wants to merge 2 commits into
base: beta
Choose a base branch
from

Conversation

muscode13
Copy link
Contributor

@muscode13 muscode13 commented Nov 5, 2024

Locales PR

What are the changes the user will see?

Corrosive Gas will be usable in game

Why am I making these changes?

Corrosive Gas is currently unimplemented

What are the changes from a developer perspective?

  • isNullified, nullify(), removedNullification added to modifier.ts, alongside checks to shouldApply and match. This will nullify the held item and prevent it's effects from working. I thought this would be the best way to simulate Corrosive Gas' taking an item away then returning it at BattleEnd. I believe this can also be used for other unimplemented moves like Embargo and Magic Room in the future
  • NullifyHeldItemAttr - applies nullify on a random item modifier. This affect lasts until the end of the turn. It has all the same ability attrs as Knock Off or Incinerate, since Corrosive Gas technically removes the item. After the item is nullified, it isTransferable is set to false, to prevent knocking off, stealing, or corroding an already corroded item.
  • In battle-end-phase.ts I remove the nullified status from the item, as well as if it its isTransferable was set to false, it gets reverted to true. Since only transferable items would get nullified, it acts as a guard clause, preventing items that should be set to false getting set to true.
  • Finally in battle-scene.ts I added logic to hide the nullified items from the modifierBar

Screenshots/Videos

Basic Flow:

corrosive.mp4

Effect lasts on switch:

switch.mp4

Sticky Hold Interaction:

sticky.mp4

Substitute interaction:

sub.mp4

Untransferable Item interaction:

untransferitems.mp4

Harvest Interaction:

harvest.mp4

How to test the changes?

  • Use npm run test corrosive_gas
  • Use Corrosive Gas in-game

Checklist

  • I'm using beta as my base branch
  • There is no overlap with another PR?
  • The PR is self-contained and cannot be split into smaller PRs?
  • Have I provided a clear explanation of the changes?
  • Have I considered writing automated tests for the issue?
  • If I have text, did I make it translatable and add a key in the English locale file(s)?
  • Have I tested the changes (manually)?
    • Are all unit tests still passing? (npm run test)
  • Are the changes visual?
    • Have I provided screenshots/videos of the changes?

@muscode13 muscode13 marked this pull request as ready for review November 5, 2024 01:14
@muscode13 muscode13 requested a review from a team as a code owner November 5, 2024 01:14
@Tempo-anon Tempo-anon added the Move Affects a move label Nov 5, 2024
@torranx torranx added the Game Balance Changes focused on game balance label Nov 5, 2024
src/test/moves/corrosive_gas.test.ts Outdated Show resolved Hide resolved
src/test/moves/corrosive_gas.test.ts Show resolved Hide resolved
src/data/move.ts Outdated Show resolved Hide resolved
src/data/move.ts Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Game Balance Changes focused on game balance Move Affects a move
Projects
Development

Successfully merging this pull request may close these issues.

3 participants