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

fix redundant string slicing and explicit checks for protosynthesis and quarkdrive #2248

Closed
wants to merge 4 commits into from

Conversation

Jerick120
Copy link

PR: smogon/pokemon-showdown#10300 needs to be merged along with this

@Zarel
Copy link
Member

Zarel commented May 16, 2024

You say "fix" but this just changes the protocol.

I have two objections here:

  • When we change the protocol, the client needs to keep support for the old protocol. If we didn't, old replays would all be broken.
  • I don't see any reason to change the protocol. The old one's string slicing may be ugly but it works. Like, I understand, I like your syntax better, too, but I don't think it's so much better to be worth having a bunch of replays using one syntax and a bunch of replays using another.

@Jerick120
Copy link
Author

You say "fix" but this just changes the protocol.

I have two objections here:

  • When we change the protocol, the client needs to keep support for the old protocol. If we didn't, old replays would all be broken.
  • I don't see any reason to change the protocol. The old one's string slicing may be ugly but it works. Like, I understand, I like your syntax better, too, but I don't think it's so much better to be worth having a bunch of replays using one syntax and a bunch of replays using another.

Thats fair, however the logs are supposed to have a | delimiter for each value and every other stat changing ability does except these two and thats undocumented. The logs return protosynthesisdef while they should return protosynthesis|def.

@Zarel
Copy link
Member

Zarel commented May 16, 2024

Hm. Yeah, I think that's a good point. Capitalization would also need to be fixed, and we'd need to update the volatile status display on the HP bar, but I think I could see that as being worth it.

Jerick120 and others added 2 commits May 16, 2024 10:19
Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
@Jerick120 Jerick120 closed this by deleting the head repository May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants