Add mount names for all drop pets and make creation more programmic

This commit is contained in:
Blade Barringer
2015-09-17 12:43:42 -05:00
parent df5a434d71
commit 993b568ad8
2 changed files with 27 additions and 42 deletions
+22 -42
View File
@@ -1,46 +1,26 @@
let each = require('lodash').each;
let t = require('../helpers/translator');
let eggs = {
Wolf: {
text: t('dropEggWolfText'),
adjective: t('dropEggWolfAdjective')
},
TigerCub: {
text: t('dropEggTigerCubText'),
mountText: t('dropEggTigerCubMountText'),
adjective: t('dropEggTigerCubAdjective')
},
PandaCub: {
text: t('dropEggPandaCubText'),
mountText: t('dropEggPandaCubMountText'),
adjective: t('dropEggPandaCubAdjective')
},
LionCub: {
text: t('dropEggLionCubText'),
mountText: t('dropEggLionCubMountText'),
adjective: t('dropEggLionCubAdjective')
},
Fox: {
text: t('dropEggFoxText'),
adjective: t('dropEggFoxAdjective')
},
FlyingPig: {
text: t('dropEggFlyingPigText'),
adjective: t('dropEggFlyingPigAdjective')
},
Dragon: {
text: t('dropEggDragonText'),
adjective: t('dropEggDragonAdjective')
},
Cactus: {
text: t('dropEggCactusText'),
adjective: t('dropEggCactusAdjective')
},
BearCub: {
text: t('dropEggBearCubText'),
mountText: t('dropEggBearCubMountText'),
adjective: t('dropEggBearCubAdjective')
},
};
const DROP_EGGS = [
'Wolf',
'TigerCub',
'PandaCub',
'LionCub',
'Fox',
'FlyingPig',
'Dragon',
'Cactus',
'BearCub',
];
let eggs = { };
each(DROP_EGGS, (pet) => {
eggs[pet] = {
text: t(`dropEgg${pet}Text`),
mountText: t(`dropEgg${pet}MountText`),
adjective: t(`dropEgg${pet}Adjective`),
}
});
module.exports = eggs;