Skip to content

sublimegame/bdsx

 
 

Repository files navigation

BDSX 2.0 : BDS + node.js

logo
Minecraft Bedrock Dedicated Server that supports node.js.

import { events } from "bdsx/events";
import { MinecraftPacketIds } from 'bdsx/bds/packetids';
events.packetAfter(MinecraftPacketIds.Login).on((ptr, networkIdentifier, packetId)=>{
    const ip = networkIdentifier.getAddress();
    const cert = ptr.connreq.cert;
    const xuid = cert.getXuid();
    const username = cert.getId();
    console.log(`Connection: ${username}> IP=${ip}, XUID=${xuid}`);
});

How to use it?

Starting with VSCode

1. Open the project with VSCode
2. Open a terminal(Ctrl+Shift+`)
3. run `npm i` # install npm packages and BDS
4. Press `F5` # build & run

Starting with the executable

run ./bdsx.bat (on Windows)
run ./bdsx.sh (on Linux)

Starting with Docker

docker run -ti karikera/bdsx

File Structure

[bdsx project]
├ [bdsx] # Core Library
├ [example_and_test]
├ [bedrock_server] # Installed BDS
├ launcher.ts # Script before launching BDS.
├ index.ts # Main entry point.
├ bdsx.sh # Executable for Linux
└ bdsx.bat # Executable for Windows
# ./launcher.ts imports ./index.ts after launching BDS
# Please start your own code from ./index.ts

BDSX Discussions

https://github.com/bdsx/bdsx/discussions

BDSX Wiki (Include JS API Reference)

https://github.com/bdsx/bdsx/wiki

Bug Report and Q&A

https://github.com/bdsx/bdsx/issues

Discord for Q&A

https://discord.gg/pC9XdkC

BDSX Core

https://github.com/bdsx/bdsx-core

About

Minecraft, BDS + node.js

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 98.1%
  • Assembly 1.7%
  • Other 0.2%