Owlbear Rodeo 2.0 Dev Log 6

Exploring the new options for storage and networking in Owblear Rodeo 2.0.

Owlbear Rodeo 2.0 Dev Log 6

For this month's Owlbear Rodeo dev log we're going to look at the new options for storage and networking in Owlbear Rodeo 2.0.

Before that we'd like to announce that as of next month Mitch will officially be working full time on Owlbear Rodeo.

This should hopefully give us time to provide more frequent updates, offer better engagement with the community and ensure that Owlbear Rodeo 2.0 gets released sooner.

Storage and Networking in 1.0

When we first developed Owlbear Rodeo 1.0 we wanted to develop a service that would work with as few servers as possible.

This would allow us to run a service with very little upkeep and keep the costs as low as possible, which was very important as it was just a passion project.

Below we're going to break down how we did this and show some of the limitations of this method.

To create a VTT (which is essentially a fancy image sharing website) without the use of a server we need 3 things:

  1. A way to store data (images and game states).
  2. A way to share images between all players.
  3. A way to sync state between all players.

Storage

To store images without a server we use a local database technology called IndexedDB.

This allows us to store the play state of a game as well as any images you import into Owlbear Rodeo in the web browser itself.

The technology here is pretty neat and can work well in a scenario like ours but it has some major pitfalls and limitations.

First the implementation of this technology varies greatly across browsers.

Here's a few differences we've observed:

  • Chromium based browsers are a lot faster with their use of a LevelDB backend instead of SQLite
  • Firefox disables all databases in private browsing modes. This means you need to design a system that can work with or without a database.
  • Safari has many bugs in their database implementation.
  • Storage persistence is not always guaranteed.

This last point is quite a big one if you want to store all user data offline. In order to get persistent storage (storage that won't be deleted by the web browser automatically) we need to request permission from the user.

This is a good thing as it means that every website you visit doesn't have the option to permanently store something on your device.

The issue is that this option is not supported in most browsers.

In Firefox a notification will be shown to the user asking for permission to use persistent storage. If accepted, all data we store in our website should be safe from any automatic cleaning mechanisms of the browser.

In Chrome the agency is taken from the user and the browser will try to automatically decide whether this data is important enough to protect from automatic clearing procedures.

In Safari this feature is not supported at all and in fact the browser will aggressively delete all your data if you do not visit a website after one week.

These limitations mean that data storage in Owlbear Rodeo 1.0 can be a bit of a gamble. We try our best to mitigate the issues by providing alternate saving means with our export/import feature but it is still not ideal and we don't believe that this situation is likely to get a lot better going forward.

Sharing images

To share images between players without the use of a server we use a peer-to-peer model with a technology called WebRTC.

This works by sending images directly from the owner of the image to any player that needs to see the image.

This works but has some big drawbacks:

  • Sending images from a DM to other players will use the DMs upload speed. This can be slow because a lot of internet providers will offer slow upload speeds.
  • Images must be sent to each connected player individually this means that if 5 players are connected the image must be sent 5 times.
  • Internet providers and firewalls are regularly set up to block this kind of traffic.

This last point is a big one and leads to a lot of often impossible to diagnose support requests. We attempt to mitigate this by providing relay servers that are designed to kick in if direct connections cannot be established but we are often stumped when one internet provider has decided to block all traffic from another provider.

Syncing

To sync the state of the game between players we originally made use of peer-to-peer connections but this was very unreliable and led to a lot of issues. As of version 1.7.0 of Owlbear Rodeo we make use of a centralized syncing server that is run by us. This costs us a bit to run but luckily the data sent is small enough that we can cover the costs by donations from our site and Patrons.

Moving from the free peer-to-peer syncing model to this server model made a big impact on the reliability of the site.

Storage and Networking in 2.0

A big goal for us with Owlbear Rodeo 2.0 is to provide a service that "just works" with this in mind we want to move to a storage model that won't delete your data or a communication method that won't be blocked by the policies of internet providers.

To do this we will be moving to a more established system ✨ the cloud ✨.

This allows us to fix all the issues listed in the previous section. As images will be stored by us they will be protected from the storage policies of the browsers. Images hosted on a server will also lead to significantly faster loading times because the server has more internet bandwidth compared to a home internet connection. As cloud storage is also the standard for web services it will mean that image loading will be more reliable as the connection won't be blocked by firewalls.

Similarly to when we moved to a server model for syncing game state, moving to a cloud model for both storage and image sharing will increase in speed and reliability but it will cost us a lot more to run the site.

To offset this cost we will be transitioning the current Patreon tiers to a subscription service that will be run by us.

As we also want the site to be accessible to the widest audience as possible we will be lowering the prices on these tiers and providing a lot more value with this service.

Before we get into the details keep in mind that these tiers are still very much a work in progress and all the values are subject to change.

The Nestling tier will be moving from $3 a month to a free tier that offers 100MB of cloud storage. We see this tier as perfect for players or DMs just wanting to get used to Owlbear Rodeo.

There will be no restrictions in terms of features for this tier, this includes full access to the upcoming plugins feature.

This tier will also have access to unlimited Basic Rooms.

A Basic Room is similar to Owlbear Rodeo 1.0, everytime you create a Basic Room a random name will be assigned and the room will only be open for a limited time.

Once the room closes you will need to create a new room to use the site but no data will be lost as the content you are viewing in the room will be saved to your account.

The Fledgling tier will be moving from $5 a month to $3.99 a month or you can get two months free by purchasing a year subscription for $39.99. This tier will offer 5GB of storage and have access to all the features of Owlbear Rodeo.

Just like the free tier you also have access to unlimited Basic Rooms but this tier will also offer a new feature we're calling Custom Rooms.

A Custom Room is a room that you can reserve with your own custom name and persistent URL. No one will be able to use this name once you reserve it and the state of the room will remain permanently. This will be perfect if you want to have a set room for each campaign you run that keeps the exact state at all times.

Lastly the Bestling tier will now actually offer more for the money. Moving from $10 per month to $7.99 per month or $79.99 a year it will offer 10GB of storage and access to more Custom Rooms.

Below is a graphic that compares the new tiers in a more digestible form.

When 2.0 launches you will be able to create an Owlbear Rodeo account and sign up to the tier of your choice.

To make the experience as seamless as possible we will also support anonymous users so your players will not need to create an account to join a room you have created.

What's Next?

This is something new for us so we'd love to hear any feedback on this move.

Overall we are happy with this direction, we think this will bring a whole new level of reliability and speed to Owlbear Rodeo. It will also help create an easier learning curve for new users as the paradigm of user accounts and cloud storage is a lot more familiar for a web app compared to using local storage.

From here our next goal is to get Owlbear Rodeo 2.0 into your hands for testing so stay tuned for more updates.