olistic / warriorjs

🏰 An exciting game of programming and Artificial Intelligence
https://warriorjs.com
MIT License
9.41k stars 488 forks source link

How to contribute towers? #224

Open nukeop opened 5 years ago

nukeop commented 5 years ago

More of a question than an issue.

I assume I can't just for warriorjs, add my tower to it, and submit a pull request. I scoured npmjs.com for warriorjs modules, but I only found the official ones. If I were to create my own tower module, should I publish it on npm as a standalone package, or should I add it to this repo in a pull request after a review process? Will warriorjs find my module automatically on npm, or will people have to download it manually and paste it?

olistic commented 5 years ago

Let me try to answer all your questions separately:

If I were to create my own tower module, should I publish it on npm as a standalone package?

Yes, you should publish it to npm following the guidelines here and here.

should I add it to this repo in a pull request after a review process?

This is something you can do in addition to publishing it to npm. I don't guarantee your tower will be included in the game out of the box, but it's certainly a possibility. Let me also mention that I'm about to release an online version of the game (same core, so the same towers can work in both the CLI and the online version) and I'm open to requests for including new towers into the online version as well. Check it out here.

Will warriorjs find my module automatically on npm, or will people have to download it manually and paste it?

Neither. warriorjs will find towers automatically, but they have to be installed via npm first. Just installed, no extra step required, and the CLI will take care of the rest (finding it and making it available in the game).