TIS-3D

TIS-3D

981k Downloads

Display module docs issue

crazyStewie opened this issue ยท 6 comments

commented

The in-game manual implies that the display module has a resolution of 28x28. However, from both testing within the game and looking at the source code, the actual resolution seems to be 24x24.
Relevant code :

private static final int RESOLUTION = 24;

Relevant docs :

Each sequence of five received by the display module is interpreted as a draw call with the components: color, column, row, width and height. The grid is quadratic and has twenty-eight (28) columns and rows. Color values are from a fixed palette. The exact color values may vary by vendor, however the general color names follow the physical spectrum of this world:

commented

Can confirm, on latest Forge version (tis3d-1.16.5-forge-1.6.6+25) the display size is 24x24

commented

Don't think that you are correct

2021-10-25_14 33 20

Hard to see the first bar as it is black, but the other bars are clearly longer than 28

commented

@duncanwebb Which version are you using?
This is the result I get using your code on the latest avaliable file (tis3d-1.17.1-forge-1.6.6+6.jar from Sep 18, 2021) :

Display result

image

Code used

image

From what I can see, the resolution was changed in b8c6dbb, while the manual line that refers to it was kept the same since it was created in e2d86a0

commented

I'm playing all of fabric 3
TIS-3D-MC1.16.2-Fabric-1.6.1.23
TIS-3D-Additions-0.2.1+1.16.2

It looks like a change that would break old code that uses the display module.
Honestly, I can't envisage any useful applications for the display module, as it far too slow to be useful and would take a lot of code, five lines of the available 40 for each draw. The best use I can think of is a progress bar. I don't like being negative, as I know how much effort goes into writing reliable code.

commented

IIRC I noticed this in the 1.16 port and kind of forgot about adjusting this on the side. The module was always intended to only use the "inner" area of the module (to match all other modules), but it didn't. Fixed the code, but forgot the documentation. Fixed the documentation now.

commented

so interestingly, it looks like before #b8c6dbb the internal resolution was 32x32, rather than 28x28.