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

Remove redundant hardcoded code to tile corner rendering #701

Merged
merged 1 commit into from
Sep 27, 2024

Conversation

BenCheung0422
Copy link
Member

Resolves #700.
This restriction exists for both GrassTile and SandTile.
Related investigation to the effect is done previously:

The effects when there are tiles exist on orthogonal directions (for each pair of orthogonal directions):

flowchart LR
    A1[corner] --> B11[diagonal]
    A1 --> B12[!diagonal]
    A2[!corner] --> B21[diagonal]
    A2 --> B22[!diagonal]
    B11 --> single
    B21 --> single
    B12 --> corner
    B22 --> full
    B12 -.-> B11
    B22 -.-> B21
Loading

single: singleton texture with connective; takes place only on corner parts; using "full" over "border center"
corner: whether corner texture is set
diagonal: whether diagonal tile exists
dotted arrow: effect of !side code

Source: #700 (comment)

This part of code has existed already before the last big update to the resource pack system. It was probably aiming to resolve the issue that a missing of corner might cause rendering misfunctioning. In the past, it actually functioned as like having checkCorners == false, by referring to 34c4381. What I can see is that, that method overwrite is kind of pointless as the constructions of both SandTile and GrassTile already made checkCorners = false. However, after deeper investigation, the method overwrite had been implemented before checkCorners (as you can see in 8881490). It is possibly because the developers had not realized the overshadowed functionality of code when adding checkCorners. Anyway, this redundant part of code which is as well limiting the customizability of resources is eventually removed here.

For both `GrassTile` and `SandTile`
@BenCheung0422 BenCheung0422 added UX/QoL Bug Something that shouldn't happen. labels Sep 27, 2024
@BenCheung0422 BenCheung0422 changed the title Remove hardcoded restriction to tile corner rendering Remove redundant hardcoded code to tile corner rendering Sep 27, 2024
@Litorom Litorom merged commit 10d832c into MinicraftPlus:main Sep 27, 2024
2 checks passed
Makkkkus pushed a commit that referenced this pull request Dec 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something that shouldn't happen.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

setting a corner texture for grass (and likely other tiles) with a resource pack doesn't work
2 participants