+0
Daily
9,539
stars
500
forks
155
watchers
147
prs
128
issues
0
releases
README
Learn JavaScript and TypeScript by writing code that fights
In WarriorJS, you write JavaScript or TypeScript to guide a warrior through
towers full of enemies. Each floor is a puzzle: battle sludge, dodge archers,
rescue captives, and reach the stairs alive. The code you write _is_ the
strategy — there's no clicking, no dragging, just logic and sharp thinking.
Whether you're writing your first if statement or refactoring for a perfect
score, every floor will test you.
Quick Start
1. Install Node.js 22 or later.
2. Install the CLI:
sh
npm install --global @warriorjs/cli
3. Launch the game:
sh
warriorjs
The game walks you through creating a warrior and choosing a tower. Open the
generated README.md for your first level's instructions, write your solution
in Player.js, then run warriorjs again to see how your warrior fares.
You can also play from your browser at
warriorjs.com.
Documentation
The official docs cover everything from first steps
to building your own towers:
- Gameplay
- Towers
- Player API
Contributing
The best way to contribute is to build a
tower — a set of levels that
other players can install and play.
You can also fix bugs, improve the docs, or add new abilities and units.
See the contribution guide and
Code of Conduct.
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.Top issues
#47Add flag to CLI to generate text READMEs11 comments · 2018-05-03#99Allow import/require in Player.js for modularity of user code10 comments · 2018-05-14#159README should show all levels when entering epic mode8 comments · 2018-05-25#123Mode with random enemies8 comments · 2018-05-18#63Check if unit is alive after effects8 comments · 2018-05-08#255Korean Translation3 comments · 2020-05-17#259I cannot sign in or create an account for the online platform2 comments · 2022-04-25#161Blind Mode?2 comments · 2018-05-25