Skip to content

Little Tiles Partial Compatability#520

Open
milkev wants to merge 1 commit intoryanhcode:mainfrom
milkev:main
Open

Little Tiles Partial Compatability#520
milkev wants to merge 1 commit intoryanhcode:mainfrom
milkev:main

Conversation

@milkev
Copy link
Copy Markdown

@milkev milkev commented Apr 25, 2026

The Issue I'm Trying to Fix
Little Tiles incompatability. It crashes when physics objects have little tiles on them and an entity collides with the physics object. Notably no crash occurs when physics objects collide with little tiles in the "real world", they just simply treat the little tiles as if they dont exist.

What I Did
When VoxelShapeMixin.sable$allBoxes is called in a context relevant to little tiles, it will always be null. I added some null checks for this in entity collision, and just skip over the relevant code if it is null.

The Results
This results in little tile blocks being placeable and visible on physics objects, however little tile blocks are completely ignored for physics object collision checks. (same as when a physics object collides with little tile blocks in the "real world")

I have not tested little tiles advanced functionality as I dont have experience working with that stuff in the first place, I just make visual stuff.

Little Tiles on physics objects do not render upon first entering a world, requiring a little tile to be modified on the physics object to make little tiles on that physics object visible again.

Little Tiles are also not highlightable or breakable by hand while on physics objects. They can still be modified by little tiles tools and premade structures can be placed.

Little Tiles in the "real world" are not affected at all (from my testing) by these changes.

Other Options
Option 1: A better (but still easier than full compatability) option would be to prevent Little Tiles from being placed on physics objects in the first place. However, doing so via preventing placement via canPlace doesnt work due to LittleTiles placement logic not obeying canPlace. (And I'm not smart enough to figure out how their placement logic works). If there is a way to prevent certain blocks or block types from existing on Sub-Levels on a deeper level that would be better (and honestly a great addition, gonna make a relevant issue for this)

Option 2: Instead of skipping the relevant code, generate a full-box collision for little tiles. Depending on opinion, this may be better than them having no collision. I'm whatever either way I just dont know how to do this.

When VoxelShapeMixin.sable$allBoxes is called in a context relevant to little tiles, it will always be null. I added some null checks for this, and just skip over the relevant code if it is null. This results in little tile blocks being placeable and visible on physics objects, however little tile blocks are completely ignored for physics object collision checks
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 25, 2026

CLA assistant check
All committers have signed the CLA.

@hexadexxa
Copy link
Copy Markdown

Surely this would be something good to have for all sorts of weird mod compatabilities

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants