0.2.6-rc2 • Published 2 months ago

@diory/diosphere-js v0.2.6-rc2

Weekly downloads
-
License
MIT
Repository
github
Last release
2 months ago

Diosphere

Install

npm install @diory/diosphere-js
# or
yarn add @diory/diosphere-js

Usage

import { Diosphere } from '@diory/diosphere'
const diosphere = new Diosphere()
diosphere.addRoom({ text: 'Hello room!' })
console.log('Hello Diosphere!', diosphere.toObject())

API

Diosphere

diosphere.initialise(roomsObject)
diosphere.queryDiosphere({ text: 'some-text' })
diosphere.resetDiosphere()
diosphere.toObject()
diosphere.toJson()

diosphere.enterRoom(someRoom)

diosphere.getRoom(someRoom)
diosphere.addRoom(someRoom)
diosphere.updateRoom(someRoom)
diosphere.removeRoom(someRoom)
diosphere.addRoomDoor(someRoom, someDoorToRoom)
diosphere.removeRoomDoor(someRoom, someDoorToRoom)
diosphere.addRoomConnection(someRoom, someConnection)
diosphere.removeRoomConnection(someRoom, someConnection)

Room

const room = new Room()
room.updateRoom(roomObject)

room.addDoor(door)
room.removeDoor(door)

room.addConnection(connection)
room.removeConnection(connection)

room.toObject()
room.toJson()

Development

Compile typescript in real time to /dist folder:

yarn build-watch

Run unit tests in the background:

yarn test-watch
0.2.6-rc2

2 months ago

0.2.6-rc1

2 months ago

0.2.3-rc6

3 months ago

0.2.3-rc8

3 months ago

0.2.3-rc7

3 months ago

0.2.5-rc3

3 months ago

0.2.3-rc9

3 months ago

0.2.5-rc2

3 months ago

0.2.5-rc1

3 months ago

0.2.3

3 months ago

0.2.5

3 months ago

0.2.4

3 months ago

0.2.3-rc2

3 months ago

0.2.3-rc4

3 months ago

0.2.3-rc3

3 months ago

0.2.3-rc5

3 months ago

0.2.2

3 months ago

0.2.1

3 months ago

0.2.0

3 months ago

0.1.0

4 months ago