Changed

Changed

184k Downloads

Latex-resistant and Latex-compatible interfaces

gengyoubo opened this issue · 10 comments

commented

For compatibility with certain variants of the module, I think the following could be designed to prevent a bug

Latex-resistant interfaces

Its main function is to prevent the player from tfing into latex, and when using the command it pops up “A mysterious force is preventing you from becoming latex!”

Latex-compatible interfaces

When tfing special variants, the original functionality and the post-tf functionality will be preserved.

The basic composition of the code can be written like this


if(){

}else if(){

}else{

}

  • Latex-resistant methods
  • compatibility methods
  • Methods that are neither (generally referring to humans or Latex)
commented

This gives you two ways to register, one by yourself and the other by another module.

commented

I'll try it first and see if it works. If it doesn't work I'll turn this off.

commented

屏幕截图 2024-11-01 194412

commented
commented

What I need to think about is how to write code that is resistant to latexness and compatibility. After writing it could start with a way to put both human and variants outside of latex that can be put in anti-latexability. I'll start writing it when I've gathered enough intel!

commented

What is the point of this suggestion? Are other mod devs supposed to write implementations to these interfaces? Or is this just extra work on our end?

commented

gengyoubo@a311e4d

And why are you doing enum logic with integers, and returning a nullable instead of the mapped optional?

commented

You guys just do the 0.14.1 feature, I just need to get that implemented, I didn't make it mandatory for you to do it, right?

commented

What is the point of this suggestion? Are other mod devs supposed to write implementations to these interfaces? Or is this just extra work on our end?

First of all this can't be considered a suggestion, I'm just going to do this stuff. Secondly in general you don't really need to do compatibility stuff to keep it functional, but once tf after that some bugs happen so I feel the need to fix the bugs!

commented

Then why did you make an "issue"? If there's no problem or suggestion for this project, then there's no need for an issue.