refined the 3d cursor a bit. pretty happy with it. the thickness will be user adjustable. it also shows through terrain, but slightly dimmer where it's obscured

also showing "mouse pointer mode" where you can mouse over anywhere on screen to interact with blocks, and you mouselook with the right mouse button

thinking of keeping this as a toggleable mouse mode. thoughts?

edit: broke my thread :( previous posts are here https://mastodon.gamedev.place/@eniko/115345413827332419

#EniBlockGame #GameDev #IndieDev #ProcGen

fun fact: in order to draw the cursor as translucent i had to use the stencil buffer, because the boxes that make up the "lines" overlap at the corners, so without the stencil buffer it'd be more opaque at the corners

#EniBlockGame #GameDev #IndieDev

testing customizable thickness/opacity for the 3d cursor. think being able to set this to whatever you want will be nice for accessibility

#EniBlockGame #GameDev #IndieDev

oooohhhh what if i made it jiggly??

#EniBlockGame #GameDev #IndieDev

added an outline to the 3d cursor so it's always visible

#EniBlockGame #GameDev #IndieDev

i can now overlay a block breaking decal on blocks, and it works on blocks with shell texturing and even nominally on objects like ferns and flowers

i draw the block's faces again using the stencil buffer, then draw the breaking decal with depth read/write off, masking using the stencil buffer

the way it works for ferns/flowers is i just draw all faces of the breaking pattern block, and any pixels outside the object model are masked

#EniBlockGame #GameDev #IndieDev #ProcGen #PixelArt

major milestone in block game development: the first actual gameplay! you can go around and hold the left mouse button on blocks in order to break em :D

#EniBlockGame #GameDev #IndieDev #ProcGen #PixelArt

just discovered that the shell textures on leaf blocks do a really cute thing when they surround another block :3

#EniBlockGame #GameDev #IndieDev

changed the way block breaking work. 3d cursor now changes to encompass the whole block and the breaking decal is shown on all faces

i'll probably change the cursor to full block vs face (or no cursor at all) depending on what your currently held item is later but for now this works

#EniBlockGame #GameDev #IndieDev

not 100% sure what to do about hidden corners. should they show through other geometry with xray vision or just not be drawn?

#EniBlockGame

show hidden corners with xray vision
19.3%
don't show hidden corners
30.1%
make an option, but show by default
21%
make an option, but don't show by default
29.5%
Poll ended at .

time to turn in for the night but i managed to get some item icon rendering going

#EniBlockGame #GameDev #IndieDev

current status: agonizing about what to do for font rendering. do i wanna do truetype fonts, or use pixel art fonts

does my old truetype font implementation even still work at all?

edit: nope my truetype implementation is gone so if i wanna go with something i already have i guess it's pixel fonts

edit2: ok i can feel the life draining out of me just researching font systems so for now i'll just go with what i have and works: pixel fonts

#EniBlockGame

decided to go with a very 16-bit feeling aesthetic for block game's GUI. took a while to set up the shader for the background color gradient but it's totally worth it with the dither and crunchy pixels. and it can go diagonal, horizontal, or vertical!

oh and yes, you can customize the gradient colors :3

#EniBlockGame #GameDev #IndieDev #PixelArt

@eniko Strong FFVII vibes ❤️
@eniko Oh those are a vibe
@eniko the stb truetype loader seems to work well (I played with it a week ago)
@ror3d i dont super enjoy the idea of writing another font rendering system from scratch right now though >_>

@eniko I use stb_truetype to render glyphs to a text cache/atlas thing.

And I don't like it. I really would rather make my own pixel font. It would fit my game much better, and I could scale the text up and down and it'd look okay because it's pixelated on purpose. Truetype fonts just get blurry if you scale them naïvely.

But I also wanna support rendering people's names, and I don't wanna make a pixel font with 2^16 characters T_T

@eniko Well-fitting pixel fonts are so beautiful! Are you talking about menu items, or also about "ingame fonts" (sorry I don't know much about this), like floating above voxels, characters etc?
@kenran_ probably all of it, to be honest
@eniko A possible alternative solution that I'm using in my engine, which only supports pixel fonts: I'm using hiero to make a signed distance field bmfont, loading it as a pixel font in the engine, and using a shader for the SDF stuff. High resolution font without having to implement any new rendering!
@apicici oh that's a cute idea!
@eniko works really well, too. I'd be happy to share the details of the settings I use and the shader code if needed.
@apicici thanks! i may wind up taking you up on that
@eniko Pixel fonts are great anyway. 🎉

@eniko the only real limitation of pixel fonts IME is the scalability (at least beyond integer scaling).

There's also the issue of supported alphabets/glyphs, but unless the game will have user strings this is at least something you control.

@eniko Pixel Fonts Are Beautiful

@eniko Minecraft clone? Disgusting.

10/10. 😏

@eniko playable demo, when? 👀
@kaofelix hopefully by the end of the year? 🤞
@eniko @kaofelix playable block game for winter gift exchange?! It's a giftmas miracle! (But also don't push yourself too hard. Delayed game is better than burned out eniko)
@eniko oh this is disorienting. it looked to me like a surface with a few thin stacked layers. it makes no sense in the context of how the blocks work and will not be disorienting in motion, especially when one is in control of the camera movement, but in a screenshot this was 
@0 @eniko can happen irl too, tho =3
@efi @eniko true, this mouse has a few very puzzling photos that appear to have z-index problems but are just something like a weirdly cut wire fence that happens to coincide with the outline of a building
@eniko options are always best, but ofc also the most work.
@miniRoach when faced with options you still gotta pick a sensible default though
@eniko the default can easily be changed at a later date, implementing all the options is the hard part.

@eniko Impossible to answer without knowing gameplay implications.

Which option makes the game most fun?

@sol_hsa not sure how this impacts fun, it's just a little visual thing?
@eniko what do you mean by hidden corners?
@ghosttie in the video you can see the corners of the block even if they're underground

@eniko the corners of the 3d cursor? I figure it's UI so it doesn't need to follow the rules of physical things in the game world, but either way is fine

In my $dayjob I decided that "make it optional" usually means we don't know what the right answer is, so we should think about it some more

@eniko I reckon exactly as they are now, but even more transparent.
@Farbs this is by far the most irritating option >_>

@eniko oh yeah

that looks great

@eniko i am somewhat relieved that my suggestion was reasonable in scope and difficulty. i was secretly afraid i made your life unnecessarily hard.
@eniko your block thing is looking really good.

@eniko

Holy crap, that looks super cool!
Now I want to see people get super creative with that effect!

@eniko Yay! How do you rotate the camera if the cursor is like that?
@lisyarus i hold right mouse button and it goes into mouselook mode
@eniko Nice!
@lisyarus i dunno if something else will replace RMB at some point or not and it'll move to some other button but im very comfortable with this from MMOs like city of heroes
@eniko you should call it minegay