GregTech icon indicating copy to clipboard operation
GregTech copied to clipboard

[Suggestion] Paint Stripper to remove Paint

Open ALongStringOfNumbers opened this issue 5 years ago • 3 comments

Is your feature request related to a problem? Please describe. Currently you can paint machines to a color, but there is no way to remove the paint. There have been some people that say that painting the machine white again leaves some slight texture differences from the original machine.

Describe the solution you'd like Since there are a variety of chemicals available in the mod that could work as a paint stripper, I would like a paint stripper, maybe can go into a spray can or some other application method, to remove the paint, and its NBT stored value, from the machine

ALongStringOfNumbers avatar Dec 24 '20 04:12 ALongStringOfNumbers

This seems like interesting idea and it could be useful. Also we should provided means to remove paint if we have way to paint stuff.

Regarding implementation I am not sure how to handle it so we can discus it here. Options that seems viable:

  1. Spray can like tool (requires new AbstractUsableBehaviour)
  2. Completely new tool (requires new tool with recipe, texture and new AbstractUsableBehaviour)
  3. Using current Chemical Bath (extend Chemical Bath with custom recipe handling, provide tooltip or JEI page for this functionality)

LAGIdiot avatar Jan 11 '21 19:01 LAGIdiot

I think that the best way would be option 1, as it would extend the use of an existing tool, and would not seem too hard to implement, Simply using the spray can filled with paint stripper on a painted machine, similar to what is currently done with cables.

One thing that I am unsure about though is the composition of the paint stripper, and how it should be acquired.

ALongStringOfNumbers avatar Jan 19 '21 08:01 ALongStringOfNumbers

I had a look at how difficult this is to implement, the answer is that it already is (nearly).

There are at least 3 different implementations of painting.

  1. There is BlockColored from minecraft. This is used by blocks that are not tile entities, for example the frames. For this, white is treated as unpainted. So a white spray can is already a paint remover. But glass or glass panes are treated as special cases, so painting them white means white.

  2. MetaTileEntity has its own DEFAULT_PAINTING_COLOR This is a special color that will treat the block as unpainted, so you can paint things white, but that means you cannot remove the paint. However only the multiblock tank and the workbench use it, so other tile entities use white as no paint like (1) above. NOTE: In my testing the workbench actually uses white as unpainted as well, which maybe an unitentional bug?

  3. The pipes have their own DEFAULT_INSULATION_COLOR This works like (2) but is a different value. This means you can't unpaint cables or fluid pipes. But breaking them doesn't save their color, so that is a way to unpaint them. NOTE: The DEFAULT_INSULATION_COLOR is treated as a special value to allow such pipes to connect to any other color.

In summary, the only things you can't "unpaint" at the moment are glass/panes (actually the stained version) and the multiblock fluid tanks. CAVEAT: There maybe other painting methods I missed in the codebase.

warjort avatar Feb 10 '21 10:02 warjort