https://github.com/chrismou/phergie-irc-plugin-react-dice
Phergie plugin for provides randomly generated numbers in response to dice rolling requests (https://github.com/phergie/phergie-irc-bot-react)
https://github.com/chrismou/phergie-irc-plugin-react-dice
Last synced: 2 months ago
JSON representation
Phergie plugin for provides randomly generated numbers in response to dice rolling requests (https://github.com/phergie/phergie-irc-bot-react)
- Host: GitHub
- URL: https://github.com/chrismou/phergie-irc-plugin-react-dice
- Owner: chrismou
- License: bsd-2-clause
- Created: 2014-12-19T13:12:37.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2016-03-24T14:33:18.000Z (about 9 years ago)
- Last Synced: 2025-03-04T11:16:20.405Z (3 months ago)
- Language: PHP
- Homepage:
- Size: 70.3 KB
- Stars: 0
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# Dice rolling plugin for [Phergie](http://github.com/phergie/phergie-irc-bot-react/)
[Phergie](http://github.com/phergie/phergie-irc-bot-react/) plugin for returning randomly generated numbers in response to dice rolling requests.
[](https://travis-ci.org/chrismou/phergie-irc-plugin-react-dice)
[](https://codeclimate.com/github/chrismou/phergie-irc-plugin-react-dice/coverage)
[](https://codeclimate.com/github/chrismou/phergie-irc-plugin-react-dice)
[](https://www.paypal.me/chrismou)## About
This plugin returns the total of a user specified number of dice rolls.
By default, the plugin responds to "dice " (number of sides is optional, defaults to 6); i.e. dice 5 returns the total of five 6-sided die rolls.
## Install
The recommended method of installation is [through composer](http://getcomposer.org).
```
composer require chrismou/phergie-irc-plugin-react-dice
```See Phergie documentation for more information on
[installing and enabling plugins](https://github.com/phergie/phergie-irc-bot-react/wiki/Usage#plugins).## Configuration
To activate the plugin using the default settings, add the following to your phergie config:```php
new \Chrismou\Phergie\Plugin\Dice\Plugin
```You can configure some of the settings as follows:
```php
new \Chrismou\Phergie\Plugin\Dice\Plugin(
"defaultSides": 6, // The number of sides on the dice if excluded from the command
"maxRolls": 50, // Maximum number of dice
"maxSides": 1000, // Maximum number of sides per dice
"showSums": true // Show the sums in the response
)
```## Tests
To run the unit test suite:
```
curl -s https://getcomposer.org/installer | php
php composer.phar install
./vendor/bin/phpunit
```## License
Released under the BSD License. See `LICENSE`.