Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

hubot-hangman

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hubot-hangman

A hubot script for playing hangman using the WORDNIK api, api-key required.

  • 1.3.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

Play Hangman using Wordnik and Hubot!

NPM NPM

A coffee-script based chat add-on for playing Hangman. The script originated in the hubot-scripts repo. The hubot-scripts repo was later deprecated in favor of using stand alone node_modules for each hubot add-on. Seeing as the hangman.coffee script had not been touched or modified in several years and the originator of the script did not have a repo with anything related to hangman, I opted to port this and keep it maintained with the MIT license.

Please feel free to leave any feedback on the github project.

The script requires a Wordnik API key which you will need to request and setup as a CONFIG_VAR on Heroku. The API keys are free to request. http://developer.wordnik.com/

API

  • hubot hangman - Display state of current game or start new game.
  • hubot hangman {x} - Make a single character guess.
  • hubot hangman {word} - Make a guess to solve the puzzle.

Installation

Run the following command

$ npm install hubot-hangman

Then to make sure the dependencies are installed:

$ npm install

To enable the script, add a hubot-hangman entry to the external-scripts.json file (you may need to create this file).

["hubot-hangman"]

Release Notes

1.3.1

  • Added ' as a default guess. Now spaces, dashes, and apostrophes will not require guessing and will be shown in the word printout.
  • If you notice any other special characters causing problems please create an issue on the github project for me to address.

1.3.0

  • Fixed: Issue #1
  • Thanks to cpradio for finding another special character bug.
  • Updated the special characters to be defined as an array that we can expand in the future if necessary.
  • Now both spaces and dashes will be shown in the word.
  • Example: This-is a-game would now be shown as ? ? ? ? - ? ? ? - ? ? ? ?.
  • Happy guessing!

1.2.1

  • 1.2.0 bug fix.
  • Dashes were considered guessed, but weren't shown as guessed characters.
  • Now dashes are shown in word. The 8 letter word is: ? ? ? ? - ? ? ?

1.2.0

  • Added - as a default guess. Many users don't expect a dash to appear in the word and hence never guess special characters.
  • Dash will be given for free.
  • If you guess a - it will be treated as a previously guessed letter and will not count against you.
  • If the word contains a dash, it will be shown automatically.

1.1.0

  • Bugfix: Changed unguessed character identifier from - to ?. Some words in the WORDNIK api include dashes, this can confuse the game leaving you stuck in an eternal loop. Changing the character to a question mark to prevent this from happening in the future. *'s and _'s have been avoided due to markdown formatting used by many chat client apps.

1.0.1

  • Updated tags for npmjs.com search

1.0.0

  • Confirmed hubot-hangman script is not available as NPM package
  • Migrated hubot-hangman script into NPM package format
  • Changed unguessed character identifier from _ to - to improve client formatting
  • Published npmjs.com

Keywords

FAQs

Package last updated on 26 Jul 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc