Skip to content

Depot vs. CastleDB

Kyle Kukshtel edited this page Jul 31, 2021 · 2 revisions

If you're familiar with CastleDB, it's very likely that Depot looks very familiar to you! This is by design, as Depot is meant to be a similar approach to the problem that Castle solves, namely data management, especially for games. Below I'll outline what makes Depot and Castle different, and why you should continue using Castle or switch to Depot

Core Differences

Programming Language

One major difference between Castle and Depot has to do with their underlining programming. As the creator of Castle is also the author of the Haxe programming language, Castle is largely written in Haxe.

Depot however uses Typescript, Javascript, and the Svelte framework. While Svelte may not be as mainstream as React, it's a popular web framework used by lots of people, meaning that it's easier to contribute to Depot if you know Javascript or Typescript, which many people do!

The point of contribution matters here, as the standalone version of CastleDB has been largely abandoned in order to improve the version that is nested inside of HIDE. Depot instead has a priority to always be available and the point, so it won't be dropped to support something else. Because it uses common and popular programming languages, it also means other people can much more easily contribute to continue to grow the project.

Frontend/Access

CastleDB runs as a standalone application inside of nw.js, an electron-style wrapper for html/js/css. Depot, for now, runs inside Visual Studio Code as an extension. The idea with Depot was to totally reduce the barrier to people using a tool like this by skipping the need to have them download an additional program. Because Code is the most popular editor in the world, delivering Depot directly to that environment seemed like the best way for people to quickly get up and running with the tool.

However, Depot is fundamentally just HTML/JS/CSS, so porting it to other platforms like the web itself or electron is imminently possible.

Features

Right now, Depot offers a subset of the features of CastleDB. Consult the chart below to see what is supported in Castle and what is or isn't supported in Depot:

Feature Support Notes
Unique Identifier GUID generated in Depot, ID's can't be duplicated.
Text
Boolean
Integer
Float
Color On Roadmap
Enumeration "Single Select" in Depot
Flags "Multi Select" in Depot
Reference "Line Reference" in Depot
File
Tile
List
Custom On Roadmap
Properties
Dynamic On Roadmap
Data/Tile Layer
Validation Depot enforces this right now for IDs to make sure they aren't the same, and won't let you create sheets with the same names
Level Editor
Show Line References
Line Moving On Roadmap
Column Moving On Roadmap
Line Deleting
Showing Images
Display Columns
Display Icon On Roadmap
Seperators On Roadmap
Groups On Roadmap
Compression
Binary Export On Roadmap

Many of the features above are on the Depot roadmap to be implemented, but the goal of Depot also isn't to just re-create CastleDB. It will have different features, with some overlap with Castle. Some offered features right now that Depot has that Castle doesn't are:

  • Column Metadata - Ability to add in different information about columns
  • Sheet Reference - Ability to reference sheets directly
  • Automatic Updates - Because Depot is delivered through Code, you can get automatic updates to the software

Data

Depot and CastleDB share a very similar data structure, but have some key differences.

Line/Sheet Reference by GUID

In CastleDB, references are currently done by string name or ID of the reference. Depot currently uses GUIDs for this. However, this may change in the future, as using GUIDs makes for less-readable files. Sheets, Lines, and Columns all have their own GUIDs.

Type Storage

In CastleDB, types are stored in columns with "typeStr". In Depot, a column's type is the string name of its type. This refers directly to the default type information stored in the depotDefaults.js folder in this repo. However, you can also just use the type string and go from there.