Skip to content

Commit

Permalink
Added zones database
Browse files Browse the repository at this point in the history
  • Loading branch information
Nakroma committed Mar 27, 2020
1 parent a6e55dd commit 5fd3285
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ npm install wow-classic-items
const Database = require('wow-classic-items')
const items = new Database.Items(options)
const professions = new Database.Professions(options)
const zones = new Database.Zones(options)
```
`items` is functionally identical to an array and can be used as such:
```js
Expand Down Expand Up @@ -54,7 +55,7 @@ professions.get('Alchemy') // .get returns specified profession
name: 'Some Random Boss', // Only set on Boss Drop
zone: [209], // Only set on Zone Drop
dropChance: 0.33, // Only set on Drops
quests: [{ questId: 256, name: 'Some Random Quest' }] // Only set on Quest
quests: [{ questId: 256, name: 'Some Random Quest', faction: 'Horde' }] // Only set on Quest
}
}, ...]
```
Expand Down
11 changes: 10 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,4 +86,13 @@ class Professions extends Database {
}
}

module.exports = { Items, Professions }
/**
* Zone Database
*/
class Zones extends Database {
constructor (options) {
super('zones', options)
}
}

module.exports = { Items, Professions, Zones }
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "wow-classic-items",
"version": "0.6.0",
"version": "0.6.1",
"description": "Collection of all WoW Classic items.",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit 5fd3285

Please sign in to comment.