MCPcopy Index your code
hub / github.com/olistic/warriorjs

github.com/olistic/warriorjs @v0.14.0 sqlite

repository ↗ · DeepWiki ↗ · release v0.14.0 ↗
259 symbols 902 edges 199 files 186 documented · 72%
README

WarriorJS Banner

An exciting game of programming and Artificial Intelligence

CircleCI Codecov Follow+WarriorJS+on+Twitter Join+WarriorJS+on+Spectrum

In WarriorJS, you are a warrior climbing a tall tower to reach The JavaScript Sword at the top level. Legend has it that the sword bearer becomes enlightened in the JavaScript language, but be warned: the journey will not be easy. On each floor, you need to write JavaScript to instruct the warrior to battle enemies, rescue captives, and reach the stairs alive...

No matter if you are new to programming or a JavaScript guru, WarriorJS will put your skills to the test. Will you dare?

Play

Go to warriorjs.com and play from the comfort of your browser! Sharpen your skills and compete against other players around the globe. Good luck in your journey, warrior!

Documentation

Although there is some in-game documentation, at some point you may want to visit the official docs.

Jump straight to some of the most-visited pages:

CLI

Wanna play offline? No problem, just follow these steps:

  1. Install WarriorJS CLI with npm:
npm install --global @warriorjs/cli
  1. Launch the game:
warriorjs
  1. Create your warrior.

  2. You'll be pointed to a README file with instructions for the first level.

Check out the Install docs for more details.

Preview

WarriorJS Preview

WarriorJS CLI launched from the Integrated Terminal in VS Code. To the left, Player.js, and to the right, a Markdown Preview of README.md.

Contributing

We welcome contributions to WarriorJS! These are the many ways you can help:

Please read our contribution guide to get started. Also note that this project is released with a Contributor Code of Conduct, please make sure to review and follow it.

Contributors

Thanks goes to each one of our contributors! :pray: Become a contributor.

Backers

Support us with a monthly donation and help us continue our activities! Become a backer.

Sponsors

Become a sponsor and get your logo here and on the official docs! Become a sponsor.

Acknowledgments

This project was born as a port of ruby-warrior. Credits for the original idea go to Ryan Bates.

Special thanks to Guillermo Cura for designing a wonderful logo.

License

WarriorJS is licensed under a MIT License.

Core symbols most depended-on inside this repo

getSpaceAt
called by 32
packages/warriorjs-core/src/Unit.js
log
called by 31
packages/warriorjs-core/src/Unit.js
getUnit
called by 21
packages/warriorjs-core/src/Space.js
printLine
called by 20
packages/warriorjs-cli/src/ui/printLine.js
parseArgs
called by 18
packages/warriorjs-cli/src/parseArgs.js
addUnit
called by 18
packages/warriorjs-core/src/Floor.js
getAbsoluteDirection
called by 17
packages/warriorjs-geography/src/getAbsoluteDirection.js
getRelativeDirection
called by 17
packages/warriorjs-geography/src/getRelativeDirection.js

Shape

Method 121
Function 114
Class 24

Languages

TypeScript100%

Modules by API surface

packages/warriorjs-core/src/Unit.js34 symbols
packages/warriorjs-cli/src/Profile.js25 symbols
packages/warriorjs-cli/src/Game.js18 symbols
packages/warriorjs-core/src/Space.js13 symbols
packages/warriorjs-core/src/Floor.js12 symbols
packages/warriorjs-core/src/Position.js10 symbols
packages/warriorjs-core/src/Warrior.js8 symbols
packages/warriorjs-core/src/Level.js7 symbols
packages/warriorjs-cli/src/Tower.js6 symbols
packages/warriorjs-cli/src/ProfileGenerator.js6 symbols
packages/warriorjs-core/src/loadLevel.js5 symbols
packages/warriorjs-effects/src/ticking.js3 symbols

Dependencies from manifests, versioned

@warriorjs/abilities0.13.0 · 1×
@warriorjs/core0.14.0 · 1×
@warriorjs/effects0.12.2 · 1×
@warriorjs/geography0.7.0 · 1×
@warriorjs/helper-get-grade-letter0.11.1 · 1×
@warriorjs/helper-get-level-config0.12.3 · 1×
@warriorjs/helper-get-level-score0.14.0 · 1×
@warriorjs/tower-baby-steps0.13.0 · 1×
@warriorjs/units0.13.0 · 1×
ansi-escapes3.0.0 · 1×
ansi-styles3.2.1 · 1×
array-shuffle1.0.1 · 1×

For agents

$ claude mcp add warriorjs \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact