mattkimber / gorender

Go implementation of Transrender sprite renderer
MIT License
9 stars 2 forks source link

Slicing sprites by width #4

Open 2TallTyler opened 4 years ago

2TallTyler commented 4 years ago

Hello,

I'd like to create some 2x2 houses from a voxel object which is 128 x 128 x 64, using the slicing functionality to divide this into four 64 x 64 x 64 sprites. Is this possible?

mattkimber commented 4 years ago

The slice functionality is for a specific use case, which is long vehicles where you want 3 spritesets but for each of the sections to be in the "correct" place relative to which section of vehicle they are.

I had the slicing a building problem in Stations, but there I divide the model into two voxel models. There are two things to note with this:

I did ponder on seeing this an automated tool to slice up a larger object into multiple objects and handle those two concerns automatically, maybe that could be a future project.

mattkimber commented 4 years ago

ps. https://github.com/mattkimber/timberwolfs_stations/tree/master/voxels/buildings - art_deco.vox and art_deco_2.vox are a tiled station building. Note I ignore my own advice about transparent walls...