jjant / runty8

A Pico8 clone in Rust.
MIT License
227 stars 17 forks source link

Port Editor sprites #16

Closed jjant closed 1 year ago

jjant commented 2 years ago

Description

We're missing a bunch of sprites used in the editor (Pico8 screenshot for reference), including:

In Runty8 these sprites are currently implemented as a regular sprite sheet, which you can edit by running cargo run, and save to disk with Ctrl + S.

lesleyrs commented 1 year ago

What are the random scribbles at sprite 11 and 26 in editor-assets? Also the mouse cursor should be hidden since the sprite is used.

I noticed that the editor will not find your editor_assets if you've replaced them manually unless you run cargo clean, is that just how cargo works or what? I thought I lost my art but no it was still there when viewing it in gimp.

The reason I was moving files around like I said above is because I can't find some assets that are used in the editor but not in the spritesheet. For example the map icon and sprite icon only have a light version, while the others have both. Where are they located? Never mind I see it's palette swapping. But I'm not sure why you have both palettes drawn for some sprites still, I'll just make a pr with 1 colour.

jjant commented 1 year ago

What are the random scribbles at sprite 11 and 26 in editor-assets?

Just scribbles from ages ago when I was first implementing sprite rendering I think :D

Also the mouse cursor should be hidden since the sprite is used.

True! I think I'd disabled that because something about it didn't work in web, I'll give your branch a try.

I noticed that the editor will not find your editor_assets if you've replaced them manually unless you run cargo clean, is that just how cargo works or what? I thought I lost my art but no it was still there when viewing it in gimp.

Hmmm interesting, this might be an artifact of the crate I'm using, include_dir, but from this comment I assumed that would work fine :( (that's been released in 0.7.3 which we're using). I'll try to repro this.

~The reason I was moving files around like I said above is because I can't find some assets that are used in the editor but not in the spritesheet. For example the map icon and sprite icon only have a light version, while the others have both. Where are they located?~ Never mind I see it's palette swapping. But I'm not sure why you have both palettes drawn for some sprites still, I'll just make a pr with 1 colour.

I think at the time I wasn't sure of which pattern I liked more. On one hand, having 2 sprites per icon is a bit of duplication, but on the other it means that rendering editor icons is just rendering a sprite, instead of having to do non-obvious palette swapping (as you experienced). What's your opinion?

lesleyrs commented 1 year ago

I noticed that the editor will not find your editor_assets if you've replaced them manually unless you run cargo clean, is that just how cargo works or what? I thought I lost my art but no it was still there when viewing it in gimp.

Hmmm interesting, this might be an artifact of the crate I'm using, include_dir, but from this comment I assumed that would work fine :( (that's been released in 0.7.3 which we're using). I'll try to repro this.

idk how it's intended to work, but if git clean is required it'd be useful to mention it to avoid confusion.

~The reason I was moving files around like I said above is because I can't find some assets that are used in the editor but not in the spritesheet. For example the map icon and sprite icon only have a light version, while the others have both. Where are they located?~ Never mind I see it's palette swapping. But I'm not sure why you have both palettes drawn for some sprites still, I'll just make a pr with 1 colour.

I think at the time I wasn't sure of which pattern I liked more. On one hand, having 2 sprites per icon is a bit of duplication, but on the other it means that rendering editor icons is just rendering a sprite, instead of having to do non-obvious palette swapping (as you experienced). What's your opinion?

Well I was expecting them to be separate because that's usually how it is. But I wouldn't be surprised if pico-8 used pal swapping themselves so it makes sense. The palette used should probably be the default "unselected" one, so you'd have to quickly draw over them as I made them the selected palette. It's fine to do this after merging my pr because the spritesheet still needs to be cleaned up.