Mindustry icon indicating copy to clipboard operation
Mindustry copied to clipboard

Allow markers to use content/displays as textures

Open Redstonneur1256 opened this issue 4 months ago • 7 comments

  • Allow textures/quad markers to use content or logic displays as their texture.
  • [x] I have read the contribution guidelines.
  • [x] I have ensured that my code compiles, if applicable.
  • [x] I have ensured that any new features in this PR function correctly in-game, if applicable.

Redstonneur1256 avatar Aug 16 '25 22:08 Redstonneur1256

Regarding a few design choices, JsonSerializable is implemented on the base marker rather than texture/quad markers so that it can be compatible with #10762. I'm not a big fan of the TextureHolder class but using TypeIO for that seems like the most reliable option than to add json serializers for all types that might be thrown here from logic processors (or through network calls), if there's a better option I missed please tell me. Texture selection on the objectives dialog currently only supports a string as it did previously, maybe a selector similar to the sensor operation/core database could be added as well.

Redstonneur1256 avatar Aug 16 '25 22:08 Redstonneur1256

drawing from displays is a little unreliable, the displayed content isn't on the server in any usable way consider canvases

The4codeblocks avatar Aug 21 '25 17:08 The4codeblocks

Why would display contents need to be on the server? Also thanks for remiding me about canvases, I'll see what I can do when I'm on PC for this and drawing on displays as well. Please do not merge in the meantime (can't find draft option on mobile)

Redstonneur1256 avatar Aug 21 '25 17:08 Redstonneur1256

Should be good to go.

Redstonneur1256 avatar Aug 21 '25 20:08 Redstonneur1256

Why would display contents need to be on the server?

if the display isn't visible to the client, it won't work displays don't do anything when not rendered

The4codeblocks avatar Aug 27 '25 01:08 The4codeblocks

if the display isn't visible to the client, it won't work

Are you sure about that

Redstonneur1256 avatar Aug 27 '25 09:08 Redstonneur1256

if the display isn't visible to the client, it won't work

Are you sure about that

huh

The4codeblocks avatar Aug 27 '25 11:08 The4codeblocks