Git Product home page Git Product logo

cobalt-calibur-3's Introduction

Cobalt Calibur 3.x

Cobalt Calibur 3 is a browser-based MMORPG (or, at least one day, it will be). The backend is written in Node.js and uses MongoDB for saving map data. The frontend uses the HTML5 Canvas tag to handle drawing of the map, and the map is sized when the page loads to fit the size of the users screen. It also uses some HTML5 audio for sound effects.

Example Server: cobaltcalibur.net

How To Play

Movement is done with the WASD and arrow keys. Pressing 1-6 will attempt to build the specified tile. Pressing F will attempt to harvest / mine / chop / collect the tile in front of the player. As you harvest materials, your inventory in the upper right will increase. As you place tiles, the inventory will decrease. Unlike other building games (e.g. Minecraft), you don't keep the items you created in inventory, just the raw materials.

Synthetic Tiles:

1 -> Wooden Wall (4 wood)
2 -> Wooden Floor (2 wood)
3 -> Stone Wall (4 stone)
4 -> Stone Floor (2 stone)
5 -> Wooden Door (12 wood)
6 -> Glass Window (4 sand)

Placing synthetic tiles will cause the corruption to slowly be pushed away. Doors will block enemies but will not block players.

Naturally Occuring Tiles

Trees -> Mine to receive 2 wood, becomes stump
Stump -> Mine to receive 1 wood, becomes grass
Grass -> Walk on it. Randomly becomes tree
Dirt -> Walk on it. Randomly becomes grass
Big Ore -> Mine to receive 2 ore, becomes small ore
Small Ore -> Mine to receive 1 ore, becomes rubble
Big Stone -> Mine to receive 2 stone, becomes small stone
Small Stone -> Mine to receive 1 stone, becomes rubble
Rubble -> Mine to receive 1 stone, becomes dirt
Water -> Makes sand from adjacent ground

Every morning, grass can grow a tree, dirt can grow grass. Dirt and grass adjacent to water will become sand. When there is an earthquake (every few days), it will deposit more stone and ore into the world (and possibly damage buildings).

When the server starts, NPCs can spawn on naturally occuring tiles. They then walk around, (currently) never dying.

Game Mechanics

Walking in the corruption has a chance of hurting the player. Standing adjacent to an enemy will hurt the player. Enemies have very simple AI, they move towards the player. There are day and night cycles, but they don't affect gameplay much. There are occasional earthquakes, and they change the landscape. Health slowly gets restored.

Installation

npm install

Running Game Server

You'll want to specify the port number as the first argument to the script (although it defaults to 80). If you are listening on 80, you'll probably need to run the command using sudo for permissions.

sudo node server.js 80

I personally run the app using Forever:

sudo npm install -g forever
sudo forever start server.js

Requirements

MongoDB, Node.js 0.8+

Screenshot

Cobalt Calibur 3.x Screenshot This is a nighttime screenshot (notice it is dark out). The blob at the top of the screen is a corrupted area.

Hosting on OpenShift

I wrote a step-by-step guide for how to download Cobalt Calibur, and get all of the hosting on Red Hat's OpenShift platform. This includes setting up a Node.js app and configuring MongoDB. The best part is that it is completely free, and only takes about 30 minutes to setup. Check it out here:

Guide to installing Cobalt Calibur on RedHat OpenShift

License

Dual BSD/GPL

cobalt-calibur-3's People

Contributors

calvinbushor avatar kalisjoshua avatar tlhunter avatar zarel avatar

Watchers

 avatar  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.