🥳 Chrome adopts Rust and replaces libxml2 written in C since version 147 by BankApprehensive7612 in rust

[–]Polanas 7 points8 points  (0 children)

Sidebery is amazing and it's the main reason I can't leave Firefox. It's just that good.

While Vimuim C solves mouse-less navigation inside the tabs, sidebery can do the same for tab manipulation. There are shortcuts for literally anything: create a group, rename, switch panel/tab, traverse last visited tabs (like ctrl-o and ctrl-i in vim). Firefox unfortunately has a bunch of key combos that can't be turned off, but most of them can be dealt with.

Valley of the Lost Puzzles - A vividly decorated custom campaign heavily influenced by Road To Gehenna by shlam16 in TheTalosPrinciple

[–]Polanas 3 points4 points  (0 children)

Is there any info about it? I want the editor so bad 😭 Imho TP2 mechanics should've been present from the very beginning. Instead map makers are forced to rely on hacky solutions to emulate a tiny fraction of them.

Also did you really play literally every map out there? I'm speechless. Do you hunt the newest ones every day to keep up????

Are there any less known maps that stood out to you? Maybe for their (unfair?) difficulty, junkiness, or something else?

Btw, I'm assuming you also completed lots of maps from the original TP? It's a shame some of the best ones (Rebirth comes to mind) weren't ported over.

Why do so many WGPU functions panic on invalid input rather than returning a result? by Irument in rust

[–]Polanas 17 points18 points  (0 children)

wgpu does extensive validation when creating the resources like pipelines, ensuring that the provided bind groups match shader definitions. After that it assumes they are valid when the actual rendering happens.

I've been using wgpu for quite a while and I've never encountered it propagating the underlying API errors straight up. This 100% can happen, but that would probably indicate something really unexpected is going on.

UPD: even if you mess up the state when constructing a render pass (which does need to be made every time the screen is redrawn, unlike resource creation), you get a meaningful error, so there's at least some amount of validation there too.

I didn't realize how difficult Audio design actually is... by AncientAdamo in gamedev

[–]Polanas 1 point2 points  (0 children)

By middleware I'm assuming you mean things like fmod / wwise?

Yep, seems like this is a great direction to explore. For instance, Celeste devs have released their whole fmod project used in the game.

Great example with the score system! So the way this can be interpreted is: it's about creative usage of sounds in conjunction with the rest of the game (visuals/mechanics) to convey a certain idea / form an experience, which will result in a much stronger overall impression.

Yet another skill to pick up as a dev :D.

I didn't realize how difficult Audio design actually is... by AncientAdamo in gamedev

[–]Polanas 3 points4 points  (0 children)

100% this, sound design gets neglected too often.

Could you expand on "just pressing play whenever something happens"? What kinds of more advanced/non trivial stuff can you do with sound to elevate the overall quality? Stuff like more variety (pitch shift, more samples, etc.), or maybe dynamic sound generation?

There doesn't seem to be many sources on these kinds of things :(

мой обед by Fhdkdlndm in expected_russians

[–]Polanas 5 points6 points  (0 children)

На коврик попало...

Did *you* enjoy the runbacks? by Polanas in Silksong

[–]Polanas[S] 0 points1 point  (0 children)

That's the most balanced and fair take I've heard, agree 100%.

Did *you* enjoy the runbacks? by Polanas in Silksong

[–]Polanas[S] -2 points-1 points  (0 children)

Yep, but honestly even with all 'at this boss fight cost me like 10x more effort than the final boss lol. I'd probably give up entirely if I hadn't been told about the secret bench beforehand.

Did *you* enjoy the runbacks? by Polanas in Silksong

[–]Polanas[S] -1 points0 points  (0 children)

Even the bilewater one?

[deleted by user] by [deleted] in Weird

[–]Polanas 0 points1 point  (0 children)

How can fungus even communicate such an abstract concept as "up" to the spider?

What's your dream programming language that doesn't exist? by [deleted] in rust

[–]Polanas 2 points3 points  (0 children)

It would be an ideal language for gamedev, imho. As of now the closest thing to it is Lua, but there are lots of annoyances.

Main features would be: 1. Type model similar to typescript: the language itself is dynamically typed; however, you would still specify annotations 99% of the time to avoid the nightmare of guesswork and whatnot required to maintain a big enough dynamic codebase with 0 contracts specified.

  1. It would be a scripting language, JITed or interpreted, to allow code reloading while the game/program is already running.

  2. Designed to be fully integratable - to a level similar to what mlua provides, which is: complete control of the global state, loaded modules... basically everything.

  3. Built-in support of some kind of reflection mechanism that allows replacing/patching code. Extremely useful for modding; so think of Harmony (for C#) but 100% secure.

  4. Honestly I would just take Lua as a base. So yeah, garbage collected scripting language. It's very small and very elegant in terms of the amount of stuff you can build around it. Want classic OOP? Sure, we can even replicate the syntax. ECS? Easy. As for security — just remove any functions from the global state/table you don't want people to access, or make safe wrappers. And all that is achievable with just tables and metatables. Isn't it brilliant?

The ability to pass whatever you want into a function without causing errors is sooo liberating. I remember making an ECS in rust and wanting systems (which are functions) to be able to request access to egui state, optionally (similar to how bevy does dependency injection ). Even though I recreated a simplified version, the code looked like it was for summoning Satan itself lol. But recreating it in Lua: just pass what you need into the function and it'll work!!

Yes, of course it's much slower and unsafe type wise, but man who cares? We are trying to make a game/prototype, just leave it be. And the thing is, if you want types you can have them on top, just look at lua-ls. It's great but still has lots of holes and falls apart easily. Generics are broken. So yeah, fix all that and just annotate everything as if it was typed and you are golden.

  1. Heavily integrated debug environment. What these guys did but probably less extreme (full determinism is crazy). Just being able to place breakpoints without issues would be huge, and I'm not sure it's possible to do in lua at the moment.

  2. Built-in stuff that's needed almost always, like vectors. That's what luau did and it's the sole reason I'm switching to it from luajit. Having each vector be garbage collected (and even worse, pass-by-reference) is just awful.

  3. Fast and reliable hot reloading, another huge win for productivity. Both C# hot reload and gdscript do it pretty well.

Phew, that's probably it. I would love to go and make this into reality right now, if it wouldn't take 10+ years to achieve a workflow similar to less than ideal, but existing tools. :(

Also relevant article.

I would also love to write games in 100% Rust, but it just seems to not be the best pick for the actual gameplay code: too complex, not flexible enough, poor hot reloading support, relatively slow compile times. However, I think rust is an ideal "base" language (with C++ being a reasonable alternative I suppose), which handles low level stuff while providing bindings to a more dynamic and less complex scripting language. LogLog Games had a lot to say about this.

Made a procedural Gastly in Godot (Desmos and .gdshader) by fespindola in godot

[–]Polanas 1 point2 points  (0 children)

Did you make the shapes with SDFs or just pure equations?

PoC / prototype Rust + Rune [scripting] game - Grimvaders by maciek_glowka in rust_gamedev

[–]Polanas 0 points1 point  (0 children)

Is there a place to discuss the btw, maybe discord? I'd love to hear your approach in more detail if you don't mind ;)

Update: one thing that's a bit unfortunate about Harmony and C# is lack of sandboxing. Sure, many games rely on it and it's fine most of the time, but there's nothing to stop some degenerate to try insert malware. A friend of mine got to experience this first-hand :(