Dev Blog #8 - Welcoming 2019 with Plexnet!

Another few months, another blog update! 
Hey everyone, we’re back again after another quiet spell. We’ve dropped small bits of news in our Discord recently but we didn’t want to leave all our non-Discord-using friends in the dark so a proper update was in order. Our last blog covered our progress in the backend, and that continues today with a brand new development we’d like to introduce to you: Plexnet! More on that below, along with a sample of something else we’ve been working on...

Before we jump in though, we wanted to thank you guys for your patience with this project and reiterate some of the reasons for the slow progress lately (especially for those of you who haven’t checked in for a while). As much as we’d love to be working on Super Plexis full time — and practically-speaking we did up until the first iOS release — this past year we’ve had to devote a lot of time and energy to work in our personal lives, partly for our own finances but also to secure resources for Super Plexis now that we’re no longer depending on 3rd parties for servers and account systems (meaning those costs will be our responsibility now). We want to create a stable environment so we can test the game and it’s online features with an active community without having to worry about developing a “monetization” model prematurely to cover costs. So while it’s been slow lately, know that we’re in it for the long run and have big plans for this year!

What is Plexnet?

PlexNet is an open-source TCP/UDP netcode library for cross-platform games (written in Java). We’ve created this library as a way to decentralize some of the development that takes place in Super Plexis and our future online games, and also as a contribution to the game development community. While we cannot yet justify open sourcing our REST server API (think matchmaking servers, account servers, etc), we figure this is one way we can give back and open the door for contribution. PlexNet is open-source, meaning that anyone will be able to use this library in their game, completely free of charge. Online play in the upcoming cross-platform versions of Super Plexis will be powered by PlexNet, so this library is also one (of many) ways for potential contributors or team candidates to step into the game (pun intended).

Before we accept any pull requests, we are ensuring the stability of an alpha version of PlexNet for the use case of Super Plexis. Right now we are adding just a few more important features to the library, tying up a few loose ends, and maximizing code coverage for an early alpha version. In the coming weeks, we expect to announce that the library is alpha-ready and start accepting pull requests. We will also demo its use case for Super Plexis to show how one might use PlexNet for their own game, or how one might contribute to development.

Features to expect in the alpha release of PlexNet (this list is not exhaustive):

  • Stable client-server connections over TCP and (optionally) UDP

  • Simplified error handling across all ends of the netcode spectrum

  • Customizable client-server sessions (think “game modes” or “game types”) via factory model

  • Optional packet transit types that act as a gradient between TCP and UDP to allow for customizable speeds, reliability, ordering, etc.

  • Lag simulation constraints for testing

  • Logging

  • Customizable client-server functionality via factory model

  • Unsafe low-level access to multithreaded buffered IO streams

  • Safe high-level manipulation of multithreaded buffered IO streams, and even higher-level packet IO streams

  • Packet serialization / deserialization and packet handlers depending on the type of client-server session

  • Option to use either our high-level serialization methods or inject your own

  • Synchronization handled under the hood (use the library as though it were single-threaded), or optionally interact with low-level asynchronous parts of the library

  • Acceptance policies which can revoke connections on failure (think “matchmaking security” or “banhammer”)

  • Host peer-to-peer or LAN (think “Minecraft”, “Ark”, “Halo 2”), or host on dedicated servers (think “League of Legends”, “Dota”)

  • Basic deploy-run scripts for dedicated machines, currently written in Bash (very subject to change), over SSH

  • Using Gradle to build and include in projects (or include dependencies for the library)

We can’t wait to get all these backend features working together and shown in action! Servers, account systems, databases, netcode: these are some of the hardest things to “get right” for online games, but getting that foundation down pat now means much faster and easier development on the game itself moving forward. If 2018 was the year of the backend, 2019 will be very “front” facing!

On the subject of frontend, in some of our recent planning for UI and art in the game, we got to talking about resolution and screen sizes. Revisiting those areas led to some pretty big decisions being made: the first being we no longer plan to support phones with a resolution below 1136 x 640 (in iPhone terms that means any device smaller than an iPhone 5). When we first started development we believed the game could be light-weight enough to run even on some of the oldest hardware, but here we are fresh into 2019 and it’s pretty clear those older devices have fallen out of use and are no longer supported by most companies anyway. It also gives us more flexibility with formatting our dynamic menus and battle screens.

Speaking of battle screens, the 2nd big change is in relation to the games “simulated resolution.” In pixel art games that basically refers to the scale of the art itself versus the true resolution of the screen it’s displayed on. So while one sprite might only be 20x20 pixels of art, it will always be displayed at twice that size (or whatever desired scale ratio: 2x, 3x, etc) on modern screens. I could go on about the details but it’s easier to show than tell! Here’s something we’ve been experimenting with (click here for a full res ver):

(Very much just a concept image! But also very much what we’re shooting for in-engine.)

(Very much just a concept image! But also very much what we’re shooting for in-engine.)

… but that’s all we can share for now! If you have any questions about anything in this blog please do pop in to our Discord. We can’t wait to progress further and share more details as we go, and we’ll likely share things there first!