Multiplayer features in action in Dreamlab. 👉 Star us on GitHub!
Dreamlab was created with one key mission in mind: making multiplayer easy and accessible for everyone. While single-player games are fun, adding multiplayer brings a new layer of excitement and challenge. But in 2024, adding multiplayer to a game can still be tricky due to fragmented solutions and complicated networking systems.
Dreamlab tackles this issue head-on, providing a multiplayer experience by default—designed to integrate seamlessly from day one of your game development.
We believe that multiplayer should be a core feature, not an afterthought. In Dreamlab, all games are multiplayer-ready out of the box, eliminating the usual hassle of networking integrations. This approach allows developers to focus on gameplay, without getting bogged down in backend complexities.
Dreamlab offers:
Unlike traditional engines, Dreamlab's networking is built-in and designed to scale. Our engine is developed with Deno and TypeScript, prioritizing performance, security, and simplicity.
Here are a few features that make Dreamlab's multiplayer unique:
Dreamlab uses a unique approach to handling networked properties, allowing you to define values as networked in TypeScript. This makes it extremely easy to sync properties between the server and clients automatically.
For example, here's how you can make an object's speed networked:
import { Behavior } from '@dreamlab/engine'
export default class SpinBehavior extends Behavior {
speed: number = 1
setup() {
// Make the "speed" value visible in the editor and networked between clients
this.defineValue(SpinBehavior, 'speed')
}
onTick() {
// Only run on the server
if (!this.game.isServer()) return
// Rotate the entity!
this.entity.transform.rotation += this.speed
}
}