-
-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Added rudimentary hexagonal renderer #76
base: main
Are you sure you want to change the base?
Conversation
Can you add some small sample map to test this with? |
I've pushed a map, which made me realise that I'd only done the Y orientation. There are some caveats here, and this is very simplistic, but hopefully sufficient to start with. |
Hey - just pinging this PR to see if theres anything more you'd like me to do to hopefully get it merged? |
I had not yet time to test it, will do it soon |
func (r *Renderer) _renderLayer(layer *tiled.Layer) error { | ||
|
||
var xs, xe, xi, ys, ye, yi int | ||
if r.m.RenderOrder == "" || r.m.RenderOrder == "right-down" { | ||
var odd bool |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe you can introduce some strategy pattern here already? these if's will become hard to maintain
This is very simplistic, and due to the limited rendering order options at the moment it has some visual artifacts. However it does render things in a reasonable manner to the screen.