@SonnyBonds@mastodon.gamedev.place avatar

SonnyBonds

@SonnyBonds@mastodon.gamedev.place

PROGRAMMING / MUSIC / GAMES

C++, music and silly games as Sonny Bonds

Life as Anders

Owner/founder of Kilohearts

Former Meqon, AGEIA and Power Challenge

Somehow can't stay away from build systems.

he/him 🇸🇪

#cpp #audio #programming #gamedev

This profile is from a federated server and may be incomplete. Browse more on the original instance.

SonnyBonds, to GNOME
@SonnyBonds@mastodon.gamedev.place avatar

Fantastic titlebar/content ratio. Good job everyone.

#gnome

sinbad, to random
@sinbad@mastodon.gamedev.place avatar

I don't even use Microsoft Edge. 😠

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@sinbad Something something edging

SonnyBonds, to GNOME
@SonnyBonds@mastodon.gamedev.place avatar

Seriously, does the titlebar really have to be like 10% of the screen height?

pervognsen, to random
@pervognsen@mastodon.social avatar

I switched from Windows to Linux not directly because of the most recent shit show with Recall (though it's part of the general trend). But it sure does make me feel even better about making that choice when I'm struggling with some minor annoyance on Linux.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen What distro did you pick?

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen Considering trying some Linux out on my home laptop, but I use it for work quite a bit where we currently can't build for Linux. Guess that's a reason as good as any to port stuff, but that makes switching a vastly different undertaking.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@wolfpld @pervognsen Possibly. We're doing pretty UI heavy stuff and while I know WSL can do UI too I don't know how representative of an environment it is. But yes it could definitely be a way to get some of the main stuff running. (We're currently on Windows and MacOS so it already has platform splits and I expect at least some things will be the same on linux and macos.)

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@wolfpld @pervognsen Installed a dual boot of Endeavor OS now. Haven't had time to poke around a lot yet, but initial install went without hitches as far as I can tell.

SonnyBonds, to random
@SonnyBonds@mastodon.gamedev.place avatar

@sinbad Hey, sorry if I'm asking something I could figure out on my own, but is there somewhere I could read about your agent AI/behavior stuff?

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@sinbad Cool, I'm mostly interested in the concepts. Thanks!

sinbad, to random
@sinbad@mastodon.gamedev.place avatar

Bleh, Git 2.45 broke fresh clones of repos using git-lfs because they disallow post-checkout hooks by default, this broke my overnight game builds. https://github.com/git-lfs/git-lfs/issues/5749

Should be fixed in Git 2.45.2 apparently, but the temporary workaround is to define the env var GIT_CLONE_PROTECTION_ACTIVE=false during clone

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@sinbad We went from a SVN repo to Git with LFS and when we did that we first converted without LFS and then migrated binary stuff to LFS. It did it really well without much problem as I can remember, but it rewrites git history so you can obviously only do it on a repo where that's ok.

pervognsen, to random
@pervognsen@mastodon.social avatar

Who remembers this awesome jankfest? The IK was bleeding edge for 1998 and when that indie game Hellish Quart came out I remember getting flashbacks to Die By The Sword.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen There's Trespasser as well that combined being an FPS with being a janky mess.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen Yeah I mean I loved all of this stuff, jank aside. There's a reason I ran straight into game physics at Meqon/AGEIA/PhysX after school. 😄

Liquidream, to random
@Liquidream@mastodon.gamedev.place avatar

Framed
🎥 🟩 ⬛ ⬛ ⬛ ⬛ ⬛
Finally! There was no way I wasn't getting this in one 😁
https://framed.wtf

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@Liquidream Cool game! It took me more tries than I'd like to admit for this one, but I picked another random one and got it on the first frame. Maybe I should quit while on top. 😄

demofox, to random
@demofox@mastodon.gamedev.place avatar

I asked my son "if you flip a coin 3 times, is it more likely to get 3 heads in a row, or head, tails, tails?"
He thought for a second and thought "they are equally likely aren't they?"
Oh damn... he is so much smarter than I was.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@demofox Now do the Monty Hall thing 😄

pervognsen, to random
@pervognsen@mastodon.social avatar

This came up in another thread today but I figure I'd throw a brief comment to the timeline. The concept of "grace periods" where you separate the logical and physical deletion of resources is something you see in RCU, EBR, QSBR, etc, but it's just as useful in single-threaded code where you only have pseudo-concurrency through subroutine calls. Like the age-old pattern of deferring deletion until the end of the game loop, or autorelease pools in Objective C which get drained by the run loop.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen What would you say the big upsides of e.g. "slot arenas" are compared to classic allocation of objects? Memory locality is obviously one, although I'm thinking that mostly affects operations that involve sequential iteration over objects?

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen Can you have generations in an arena with different object sizes? I'm thinking an old generation value should never end up in the middle of a new object, if that makes sense.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen Got it, just wanted to double check if there was some trick I hadn't thought about.

My most recent foray into it was mostly for a different reason; having clonable arenas so a full state can be synced between threads or stored for undo etc etc. But that means the arena location isn't static and needs to be passed around together with references and I never came up with a satisfactory way of doing that.

pervognsen, (edited ) to random
@pervognsen@mastodon.social avatar

It looks a bit funny but Rc<Arc<T>> seems like a reasonable choice in a lot of cases. Specifically, you have locally shared ownership of a remotely shared resource instead of directly sharing ownership of the remote resource (which comes with contention issues). Most of the time you probably wouldn't literally have Rc<Arc<T>> but Rc<LocalStruct> where LocalStruct (transitively) has an Arc<T>. But same thing really.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen I've been thinking about this a bit in C++ but at that point I thought of it as some multilevel RC thing and for some reason it felt like it wouldn't work easily. But just wrapping an Arc in a Rc (or corresponding types) is a good and clear way of thinking about it!

(I did however try switching all shared_ptr for a nonatomic version and saw no apparent improvements on perf so I stopped thinking too much about it.)

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen Well unless I'm misunderstanding, it only needs one indirection for accessing the data and one for accessing the refcount since it stores both pointers (which may be a problem in itself by all means). But yes when doing both it needs to dereference two independent pointers.

There are of course other implementations than shared_ptr though, and std doesn't even have a non-atomic one. Was just thinking conceptually about the nesting.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@artificialmind @pervognsen We (ab)use weak_ptrs quite a lot for some event listener management and stuff so we don''t use make_shared for a lot of stuff. (We have a macro for Reasons for our UI components and it doesn't do make_shared.) It probably doesn't make a difference as the structures are neither huge nor allocated/deallocated a lot, but feels conceptually right.

For some other things that are more blobs of data and stuff we do use make_shared though. More of a vibes based policy. :)

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen @artificialmind Yes I totally see what you mean. Conceptually it's not really a 1:1 match, especially since the resources aren't really shared but has a pretty strict ownership hierarchy. The thing I like about it is that the refcount gives you lifetime extension. As long as you hold a ref you know it's valid, and can avoid rugpulling stuff like a component removing itself while it's processing an event etc etc without deferred freeing.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen @artificialmind Yeah there probably are better ways. I've messed a bit with arenas lately just prototyping things but haven't quite internalized how to work with it in a way that I really like.

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@pervognsen @artificialmind Yes absolutely. I think a complicating (but not disqualifying) factor in our case is that we're making plugins and don't really have control over the "main loop". There's rather multiple entry points from both host and system. It's of course still possible to do it, autorelease-style or otherwise, but it makes it a little bit more annoying.

SonnyBonds, to firefox
@SonnyBonds@mastodon.gamedev.place avatar

Firefox users, is there any way to search youtube in the address bar? In Chrome I just type "you" and hit tab and it goes into a search right in the bar. Same for some other sites.

#firefox

sinbad, to random
@sinbad@mastodon.gamedev.place avatar

In my quest to reevaluate games I bounced off before, I’ve now moved on to Elite Dangerous, which I last played in 2019. As a bonus I now have a Thrustmaster Airbus edition flight stick (a friend found a job lot in charity shop and kindly gave me one) which improves the experience. I had to re-learn a lot and keep remapping the controls as I went so I didn’t get that far, but I didn’t hate it? I got bored really quickly last time but I’m kinda enjoying the chill space ship management. We’ll see

SonnyBonds,
@SonnyBonds@mastodon.gamedev.place avatar

@sinbad I really like the sound design in it. The calm and fairly silent environment really adds to the vibe.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • mdbf
  • everett
  • osvaldo12
  • magazineikmin
  • thenastyranch
  • rosin
  • tester
  • Youngstown
  • Durango
  • slotface
  • ngwrru68w68
  • kavyap
  • DreamBathrooms
  • megavids
  • InstantRegret
  • ethstaker
  • GTA5RPClips
  • tacticalgear
  • normalnudes
  • Leos
  • modclub
  • khanakhh
  • cubers
  • cisconetworking
  • anitta
  • provamag3
  • lostlight
  • All magazines