ItsFirefly
I now present the first, native, optimized build for all Raspberry Pi models that you can help test. It's fast, efficient and beautiful. You can play this forever, without DRM or limitations.
Thanks to amazing feedback from HN, I've added great features to the game over time, available on all operating systems:
– control remapping – pasting text (from password managers too!) – energy saving – quest rewards – additional languages (10 in total)
I'm livestreaming as I submit this post; feel free to hop by with questions and comments. It was awesome last time we did this! Here are the links:
YouTube: https://www.youtube.com/watch?v=KFhxfYA98gw Twitch: https://www.twitch.tv/AngeldustLive
Have fun playing! I'll be here after the livestream to answer your replies.
Angeldust's physics are relatively straightforward since it's based on a voxel grid. All game world intersections are approximated using axis-aligned bounding boxes (AABBs). I wrote the physics engine myself from scratch to reduce the number of game world data lookups, because that's pretty much the hot path in the code.
In the YouTube video from my earlier comment you can see that initially I started out with just game world boundary clipping and simple plane physics on the checkerboard. As I expanded my game world model, the physics engine grew along. So my advice would be (again) to start simple and grow from there. You'll do fine!
https://www.youtube.com/watch?v=J7LK0s8LgmQ
Maybe this style appeals more to you?
For the 3D world, start with a checkerboard pattern or so. In fact, this is almost exactly what I did to start Angeldust. I once showed off some early game prototypes on my stream, take a look at this one for example: https://www.youtube.com/watch?v=qMs8YpkSrg0&t=3289
If you keep watching that stream you'll see other in-progress versions so you can see how my product evolved.
For Angeldust I've done dozens of updates, each and every single one building upon the existing base. Looking back it's amazing to see that the product evolved in an almost linear fashion from v0.0 all the way to the current version without ever having to drop or redo features. But because the product evolved as a whole I can not really distill a time estimate for only the "client side engine".
I mean: would you consider testing the client side engine part of client side engine development? For testing you need a working server. For which you "need" a working network simulator. It's dependencies all the way down.
And how about translation work for in-engine strings, updating shared libraries and frameworks, issue tracking, writing the asset conversion toolchain (which needs assets, which need integration). It's very hard to come up with any solid number. Maybe if you can severely limit your question's scope I can come up with an educated guess.
"[Y]our apps … are available worldwide and functioning as expected. If your customers are reporting issues, they may not meet the requirements for the apps or have some issues on their devices and would need to contact technical support for assistance."
I'm glad you and others reported problems with availability, but it looks to be something outside of my control. If you still want to get Angeldust on your Apple device from the App Store you might have to contact Apple to help diagnose the issue. I'm sorry that I am unable to help you.
Like I posted earlier, Angeldust is available from several other sources besides the iTunes and Mac App Store:
Itch.io (Win, Mac, Linux, Android): https://metagaming.itch.io/angeldust
Steam (Win, Mac, Linux): https://store.steampowered.com/app/488440/
Google Play Store (Android): https://play.google.com/store/apps/details?id=nl.metagaming....
Note that I'm working on a newer render engine that actually uses more GPU shading capabilities and this engine runs even smoother than the current one, since it balances the workload a lot better between CPU and GPU.
As for data structures: both client- and server-side it's pretty much a simple std::map<coordinate, chunk*>. Its O(log(n)) lookup is adequate and I don't want or need to do complicated things to ensure decent performance. On top of the map I do spatially-aware caching to prevent say 99% of actual map lookups which turns the majority of lookups into O(1) which seems pretty much optimal.
As for keeping data: the server is authoritative in everything. The server keeps the data. You can take any device, install Angeldust and sign in with your credentials and you'll find yourself back in the same world, same friends, same progress, same everything that you had on another device.
Same with game state: the server tells the client everything. The client is basically just a dumb graphical terminal application that renders 3D visuals instead of VT100 text.
All external effects that can happen to an entity are written to an atomic integer that tracks healing points, damage points and effects like poison and stunning. Angeldust currently runs on CPUs supporting atomic integers everywhere, so this doesn't have to fall back to mutexes. On platforms/compilers without atomic integers I have a software-fallback that uses mutexes for this, but currently it's not used anywhere.
Most world state is compiled into flat byte arrays each tick to save processing time, since many clients can be in the same area at once. The server bundles these world state byte arrays for chunks near a client together and sends them over the network. The client interpolates from these updates. What you see on screen lags behind subtly to make sure animations are smooth. I think this happens in most online games since you don't really want to extrapolate.
Angeldust's game pace and mechanics are designed so that the interpolation doesn't affect your aiming accuracy or game experience too much.
To compensate, the Itch.io Android APK is actually pretty much identical to the Google Play Store version, but it just includes all 3D assets too.
As for the processing per tick: the entire active chunk set gets semi-randomly processed by threads. You'd be absolutely right that the order of operations isn't always deterministic. An entity not being processed for a tick doesn't happen since the old chunk will still process entities that are "on hold", but only perform a subset of operations. Double-processing does occur and this is sometimes visible while playing with a chat message being duplicated. This happens pretty rarely and I took care to make sure occasional double-processing doesn't interfere with gameplay mechanics.
As for synchronization: yes, each tick all processing threads join together and the server performs minor central processing and scheduling. Then the next tick begins and all threads are started again.
Currently I only have my livestreams as a public presence. I find it a very comfortable and pleasant medium for conveying who I am. It lets me share stories and ideas including non-verbal cues and that's a major plus for me. So if you want to learn more, definitely subscribe or follow on YouTube and/or Twitch:
https://www.youtube.com/AngeldustLive
https://www.twitch.tv/AngeldustLive
I honestly appreciate talking about technical things a lot, even though I might be playing what appears to be a silly video game. As for streaming: I just did three consecutive days, but will take a short break. I'll be back this Thursday.
https://www.twitch.tv/AngeldustLive
I'm not a social media user and I currently don't keep a public blog. There are many interesting aspects of Angeldust to talk about and I have many war stories from this and previous projects that would make for an interesting read or listen.
Just this evening I talked on my livestream about my rough introduction to SIGPIPE randomly killing my server processes. I can understand that a YouTube or Twitch livestream isn't the most convenient format for hearing these stories, but it's currently my most warm and entertaining way to share them.
Streaming is a highlight in my life, while writing out stories feels like work. Very faintly I'm crystallizing a plan to share knowledge in a written way, but for now I think the livestream is going to be my preferred way for requesting and telling stories.
I've been playing the game in both the "Cartoon" and "3D" visual style for years and it's been a very pleasant and eye-pleasing experience for me. Please open your world a bit for me. Maybe share some of your design work for inspiration. Thanks in advance for your feedback.
The Second Life approach sounds like a very good solution if you're having to, and willing to use multiple servers because of performance reasons. I think Angeldust's architecture is a bit cleaner and more straightforward due to different design goals. I specifically wanted to reduce complexity and keep a simple infrastructure so that I could code, debug and manage everything on my own.
I also have the luxury of using a single, big, many-core server if necessary. When Second Life started I don't think 32+-core servers were a thing, so their scaling model was probably also born out of sheer necessity.
I anticipate most problems in the Nintendo Switch platform rules and guidelines that I'm completely unfamiliar with as of yet. And I lack the hardware to test. But now that I'm forced to think more about it, both seem like solvable problems. Thanks for the inspiration :)
But I always advise enthusiastic players to keep an eye out on real life. Mind your health and your relationships. Real life, family, friends—they all come first. Of course you can be friends in-game and even build meaningful relationships there, but that's no substitute for living a well-balanced "real" life.
I've been an avid gamer in the past, and right now I'm a very avid developer. I try to balance that in real life by playing sports and exercising three or four times per week. Going out on walks, to the movies, meeting up with friends. "Balance in all things" as a character from Baldur's Gate would say.
In addition I also ran Angeldust on Haiku. There is no reason why a product like this wouldn't run everywhere.
(Also shoutout to theo and/or tedu if you're here.)
There is a special meaning for the game. The short backstory is included on the game's website. Here's the gist: in the game's lore Violet and Crimson are angel siblings. Violet is the angel of creation, Crimson the angel of destruction. Due to unforeseen circumstances both angels shatter to dust. This dust dwindles towards the planet where the game takes place. Subsequently parts of the game world and its inhabitants have been permanently infused with magical energy. Energy derived from the dust of angels. Angeldust.
"Angeldust" is beautifully fitting and it's a beautiful name in my opinion. I wouldn't want it any other way. There's an entire design language behind the lore, the names and composition of the game world. To a casual observer this might not be apparent or make sense. But everything ties together perfectly.
I've seen discussion and jokes about the name before when reaching a larger audience. It's great that people have an opinion on the name and some of it's (in my view) lesser known historical usages. As far as I'm concerned Angeldust is a pretty cool video game product with unique properties. In no way, shape or form do I want to endorse or conjure connection to other, past uses of "Angeldust". I hope you can appreciate the context, connection and product that "Angeldust" refers to for me.
And then I get there's a bit of confirmation-bias and pattern-matching going on with my name. I wouldn't have expected otherwise from the smart hackers here. I have no good argument against this. I wasn't aware that I share my name with a (for you all, well known?) dude from the past. Given finite first and last names, collisions are bound to happen. Maybe we should start using MD5- or SHA-hashes as names to prevent this in the future.
It might also help that I'm Dutch and we're supposedly pretty "direct" by default. I've also learned from dealing with Russian players who are even more versed at that craft.
When the hype settles down I'll probably move back to a small VPS. I always joke that Angeldust and the server would even run on your toaster. I bet it would even be able to serve hundreds of simultaneous players before turning into toast.
When I was a five or six years old kid I used to program on our home computer, a Philips P2000. Monochrome green on black CRT, Zilog Z80 CPU, different ROMs for running BASIC or Pascal or whatever you hacked onto it. My very first program drew Christmas trees on screen. Very appropriate to share this story right now. I immediately showed my mom, who wasn't really impressed, because she didn't understand what I had done. I had told my computer what to do—wow!
Then one day I was walking around the schoolyard imagining the world around me being digitized and available as large, 3D blocks inside my computer. "My" P2000 wasn't advanced enough to pull it off and similarly I wasn't advanced enough to program something like that. But the idea of having a coarse, 3D replica of my world and being able to have fun in there with my school buddies always stuck with me.
Many years later, at an intellectual dead-end in my job I took a month-long vacation to regain focus on my life and myself. And I suddenly remembered my childhood dream, or fantasy, of that 3D world. And I realized that computers were now advanced enough and I was advanced enough. So I decided to take on the journey, channelling my inner five-year old.
Some players have joked about this with me. That they're actually investing their time in the figments of a five year old's imagination. And that's not far from the truth. Even though Angeldust is better, more beautiful and more professional that I had ever imagined, it is the actual implementation of my childhood dream.
So the answer to your question is that I started development somewhere between being five years old and now. Hopefully this answer still gives you some joy and insight!
For the write state, you're absolutely right that entities will need to transition between chunks. The server looks up the destination in the "active chunk set" I mentioned and then uses per-chunk std::vector<>s guarded by a mutex to push "migrating" entities. This requires a mutex since multiple CPUs/cores/threads/chunks can be pushing entities to the same destination chunk. These mutexes largely have zero to little contention.
Does that answer your question in an acceptable way?
I've been really lucky to be able to successfully fulfill my childhood dream by making this game. But like Freddie Mercury sung: it's [not always] been a bed of roses or a pleasure cruise. I've sacrificed progress in other areas of my life to see this through to the end. I hope to catch up there starting as early as next year. Nonetheless I definitely wouldn't be the same without having taken on this adventure. I've grown so much as a developer, an entertainer and even as a person by creating Angeldust.
Itch.io: https://metagaming.itch.io/angeldust
Steam: https://store.steampowered.com/app/488440/
If anyone nows a way to distribute iOS 6.1+ apps that doesn't violate my agreements with Apple, get in touch with me :D!