Giter VIP home page Giter VIP logo

dungeonengine's Introduction

How to Run the game

READ CAREFULLY!!

  1. make sure you have all the files on your computer with the same file structure as in this repo
  2. remove all files within save_data/
  3. remove/modify any file contents under the Dungeons/ folder (DO NOT change or remove anything in the Dungeons/world/ folder though, that stuff is important for the Engine to run (see dungeon building for help on safely modifying the game))
  4. run Insert Dungeon Name Here.exe
  5. If you have issues, there's an issues page on github, but to be fair, idk how it works, so yeah.
  6. This Engine is still under development, don't expect much to work

tutorial (until I make an actual tutorial in-game)

  1. once the game has fully loaded, type [0]: engine:new-player <id> <max_health> <name> note:
    • <id> may not be 0
    • <max_health> will eventually be removed once I find a good default (try 20 for now if you're unsure)
    • <name> can contain spaces if surrounded by quotes (ex: "Example name idk")
  2. this will create a new player (whaaAAA????)
  3. now when you intend to type text as your player, start each message with [<player_id>]: (including the trailing space)
  4. [0]: ... is reserved for running commands
  5. more coming soon

Dungeon Building

Note: This is going to be a VERY long, detailed, guide to creating a dungeon and all it's components


File Structure
Dungeons | Rooms | Interactions
Weapons | Ammo | Armor
Items | Tools
StatusEffects
Enemies | Attacks | Entities | Combats
Interactable Types

Dungeon Script
Engine Code

Here's a handy tool to help you get started with dungeon building:
Dungeon Generation Tool

File Structure

Dungeons/
├─ <dungeon_id>/
│  ├─ resources/
│  │  ├─ ammo/
│  │  ├─ armor/
│  │  ├─ enemies/
│  │  ├─ items/
│  │  ├─ tools/
│  │  └─ weapons/
│  ├─ scripts/
│  │  ├─ rooms/
│  │  └─ <dungeon_id>/
│  ├─ rooms/
│  ├─ combats/
│  ├─ <dungeon_id>.json
│  └─ ec_functions.json
:

Dungeons

Base JSON values:

{
  "name": <text>,
  "version": <number>,
  "entry_point": <room identifier>,
  "events": {
    "on_enter": {engine code},
    "on_exit": {engine code}
  }
  "data": {
    "<name>": <value>|{boot engine code}
  }
}

More comming soon!

Rooms

{
  "name": <text>,
  "interactions": [
    // interactions will be explained below
  ],
  "events": {
    "on_enter": {engine code},
    "on_exit": {engine code},
    "on_input": {engine code}
  }
}

Interactions

for interactable types, go here.

Door Interaction JSON:

{
  "type": "engine:door",
  "id": <text>,
  "target": <room identifier>,
  "travel_message": <text>|{engine code},
  "lock_message": <text>|{engine code},
  "locked": <boolean>,
  "open_message": <text>|{engine code},
  "disengage_message": <text>|{engine code}
}

Weapons

WIP

Ammo

WIP

Armor

WIP

Items

{
  "parent": <item identifier>,
  "name": <text>|{boot engine code},
  "max_count": <int>,
  "count": <int>|{boot engine code},
  "data": {
    "<name>": {boot engine code}
  },
  "events": {
    "on_use": {engine code},
    "on_expended": {engine code}
  }
}

Tools

{
  "parent": <tool identifier>,
  "name": <text>|{boot engine code},
  "max_durability": <int>,
  "durability": <int>|{boot engine code},
  "data": {
    "<name>": {boot engine code}
  },
  "events": {
    "on_use": {engine code},
    "on_equip": {engine code},
    "on_unequip": {engine code},
    "on_damaged": {engine code},
    "on_break": {engine code}
  }
}

Status Effects

WIP

Enemies

WIP

Attacks

WIP

Entities

WIP

Interactable Types

WIP
see the door interactable type as an example

Combats

WIP

Engine Code

WIP

Engine Code is the scripting language used for events and operations within user-made dungeons.

note:
boot engine code is evaluated on dungeon load up. This means the functions you can use in it are limited
engine code is evaluated as needed during runtime, it is not evaluated on load up.

to use a dungeon script instead of writing engine code, reference the script with: {"#script": "path/to/script"} the path doesn't have to be absolute, nor does it require you to write the ds/dungeon_script extension in the file name, however, make sure the path cant be mistaken for another script file. (The compiler will look in every dungeon folder, until it finds something that matches the path)

ie: referencing scripts/rooms/room1/on_enter may match your_dungeon/scripts/rooms/room1/on_enter.ds or my_dungeon/script/rooms/room1/on_enter.ds so it is recommended that you have your dungeon namespace present in the path somewhere

dungeonengine's People

Contributors

wbfw3131 avatar westbot657 avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.