Skip to content

Commit

Permalink
feat(world-boss): Rage Strike support
Browse files Browse the repository at this point in the history
  • Loading branch information
SabreCat committed Feb 16, 2018
1 parent ac6a5ae commit 95179be
Show file tree
Hide file tree
Showing 13 changed files with 53 additions and 10 deletions.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 14 additions & 6 deletions website/client/components/groups/tavern.vue
Expand Up @@ -69,12 +69,15 @@
.col-sm-5.d-flex
strong {{ $t('rageStrikes') }}
.svg-icon.boss-icon.information-icon.ml-2(v-html="icons.informationIcon", v-b-tooltip.hover.top="questData.boss.rage.description()")
.col-sm-2
img.rage-strike(src="~assets/images/rage_strike2x.png")
.col-sm-2
img.rage-strike(src="~assets/images/rage_strike2x.png")
.col-sm-2
img.rage-strike(src="~assets/images/rage_strike2x.png")
.col-sm-2.text-center
img.rage-strike(src="~assets/images/world-boss/rage_strike@2x.png", v-if="!group.quest.extra.worldDmg.seasonalShop")
img.rage-strike-active(src="~assets/images/world-boss/rage_strike-seasonalShop@2x.png", v-if="group.quest.extra.worldDmg.seasonalShop")
.col-sm-2.text-center
img.rage-strike(src="~assets/images/world-boss/rage_strike@2x.png", v-if="!group.quest.extra.worldDmg.market")
img.rage-strike-active(src="~assets/images/world-boss/rage_strike-market@2x.png", v-if="group.quest.extra.worldDmg.market")
.col-sm-2.text-center
img.rage-strike(src="~assets/images/world-boss/rage_strike@2x.png", v-if="!group.quest.extra.worldDmg.quests")
img.rage-strike-active(src="~assets/images/world-boss/rage_strike-quests@2x.png", v-if="group.quest.extra.worldDmg.quests")
.boss-description.p-3(:style="{'border-color': questData.colors.extralight}", @click="sections.worldBoss = !sections.worldBoss")
strong.float-left {{ $t('worldBossDescription') }}
.float-right
Expand Down Expand Up @@ -478,6 +481,11 @@
height: auto;
}
.rage-strike-active {
max-width: 75px;
height: auto;
}
.world-boss-info-button {
width: 100%;
background-color: $gray-500;
Expand Down
31 changes: 28 additions & 3 deletions website/client/components/shops/seasonal/index.vue
Expand Up @@ -23,7 +23,8 @@
)
.standard-page
div.featuredItems
.background(:class="{opened: seasonal.opened}")
.background(:class="{opened: seasonal.opened && !broken, broken: broken}")
.background(:class="{cracked: broken, broken: broken}")
div.npc
div.featured-label
span.rectangle
Expand All @@ -32,7 +33,8 @@
div.content(v-if="!seasonal.opened")
div.featured-label.with-border.closed
span.rectangle
span.text(v-once, v-html="seasonal.notes")
span.text(v-if="!broken", v-html="seasonal.notes")
span.text(v-if="broken") {{ $t('seasonalShopBrokenText') }}
span.rectangle
div.content(v-else-if="seasonal.featured.items.length !== 0")
div.featured-label.with-border(v-if='!featuredGearBought')
Expand Down Expand Up @@ -237,6 +239,18 @@
background-repeat: repeat-x;
}
.background.broken {
background: url('~assets/images/npc/broken/seasonal_shop_broken_background.png');
background-repeat: repeat-x;
}
.background.cracked {
background: url('~assets/images/npc/broken/seasonal_shop_broken_layer.png');
background-repeat: repeat-x;
}
.content {
display: flex;
flex-direction: column;
Expand All @@ -259,10 +273,15 @@
}
}
.opened .npc{
.opened .npc {
background: url('~assets/images/npc/#{$npc_seasonal_flavor}/seasonal_shop_opened_npc.png');
background-repeat: no-repeat;
}
.broken .npc {
background: url('~assets/images/npc/broken/seasonal_shop_broken_npc.png');
background-repeat: no-repeat;
}
}
}
</style>
Expand Down Expand Up @@ -355,8 +374,14 @@
featuredGearBought: false,
backgroundUpdate: new Date(),
broken: false,
};
},
async mounted () {
let worldState = await this.$store.dispatch('worldState:getWorldState');
this.broken = worldState.worldBoss.extra.worldDmg.seasonalShop;
},
computed: {
...mapState({
content: 'content',
Expand Down
2 changes: 2 additions & 0 deletions website/client/store/actions/index.js
Expand Up @@ -15,6 +15,7 @@ import * as tags from './tags';
import * as hall from './hall';
import * as shops from './shops';
import * as snackbars from './snackbars';
import * as worldState from './world-state';

// Actions should be named as 'actionName' and can be accessed as 'namespace:actionName'
// Example: fetch in user.js -> 'user:fetch'
Expand All @@ -35,6 +36,7 @@ const actions = flattenAndNamespace({
hall,
shops,
snackbars,
worldState,
});

export default actions;
7 changes: 7 additions & 0 deletions website/client/store/actions/world-state.js
@@ -0,0 +1,7 @@
import axios from 'axios';

export async function getWorldState () {
let url = '/api/v3/world-state';
let response = await axios.get(url);
return response.data.data;
}
1 change: 1 addition & 0 deletions website/common/locales/en/limited.json
Expand Up @@ -34,6 +34,7 @@
"seasonalShopFallText": "Happy Fall Festival!! Would you like to buy some rare items? They’ll only be available until October 31st!",
"seasonalShopWinterText": "Happy Winter Wonderland!! Would you like to buy some rare items? They’ll only be available until January 31st!",
"seasonalShopFallTextBroken": "Oh.... Welcome to the Seasonal Shop... We're stocking autumn Seasonal Edition goodies, or something... Everything here will be available to purchase during the Fall Festival event each year, but we're only open until October 31... I guess you should to stock up now, or you'll have to wait... and wait... and wait... <strong>*sigh*</strong>",
"seasonalShopBrokenText": "My pavilion!!!!!!! My decorations!!!! Oh, the Dysheartener's destroyed everything :( Please help defeat it in the Tavern so I can rebuild!",
"seasonalShopRebirth": "If you bought any of this equipment in the past but don't currently own it, you can repurchase it in the Rewards Column. Initially, you'll only be able to purchase the items for your current class (Warrior by default), but fear not, the other class-specific items will become available if you switch to that class.",
"candycaneSet": "Candy Cane (Mage)",
"skiSet": "Ski-sassin (Rogue)",
Expand Down
2 changes: 1 addition & 1 deletion website/common/locales/en/questsContent.json
Expand Up @@ -662,7 +662,7 @@
"questDysheartenerCompletionChat": "`The Dysheartener is DEFEATED!`\n\nTogether, everyone in Habitica strikes a final blow to their tasks, and the Dysheartener rears back, shrieking with dismay. “What's wrong, Dysheartener?” AnnDeLune calls, eyes sparkling. “Feeling discouraged?”\n\nGlowing pink fractures crack across the Dysheartener's carapace, and it shatters in a puff of pink smoke. As a renewed sense of vigor and determination sweeps across the land, a flurry of delightful sweets rains down upon everyone.\n\nThe crowd cheers wildly, hugging each other as their pets happily chew on the belated Valentine's treats. Suddenly, a joyful chorus of song cascades through the air, and gleaming silhouettes soar across the sky.\n\nOur newly-invigorated optimism has attracted a flock of Hopeful Hippogriffs! The graceful creatures alight upon the ground, ruffling their feathers with interest and prancing about. “It looks like we've made some new friends to help keep our spirits high, even when our tasks are daunting,” Lemoness says.\n\nBeffymaroo already has her arms full with feathered fluffballs. “Maybe they'll help us rebuild the damaged areas of Habitica!”\n\nCrooning and singing, the Hippogriffs lead the way as all the Habitcans work together to restore our beloved home.",
"questDysheartenerBossRageTitle": "Shattering Heartbreak",
"questDysheartenerBossRageDescription": "The Rage Attack gauge fills when Habiticans miss their Dailies. If it fills up, the Dysheartener will unleash its Shattering Heartbreak attack on one of Habitica's shopkeepers, so be sure to do your tasks!",
"questDysheartenerBossRageSeasonal": "`The Dysheartener uses SHATTERING HEARTBREAK!`\n\nOh, no! After feasting on our undone Dailies, the Dysheartener has gained the strength to unleash its Shattering Heartbreak attack. With a shrill shriek, it brings its spiny forelegs down upon the gazebo that houses the Seasonal Shop! The concussive blast of magic shreds the wood, and the Seasonal Sorceress is overcome by sorrow at the sight.\n\nQuickly, let's keep doing our Dailies so that the beast won't strike again!",
"questDysheartenerBossRageSeasonal": "`The Dysheartener uses SHATTERING HEARTBREAK!`\n\nOh, no! After feasting on our undone Dailies, the Dysheartener has gained the strength to unleash its Shattering Heartbreak attack. With a shrill shriek, it brings its spiny forelegs down upon the pavilion that houses the Seasonal Shop! The concussive blast of magic shreds the wood, and the Seasonal Sorceress is overcome by sorrow at the sight.\n\nQuickly, let's keep doing our Dailies so that the beast won't strike again!",
"questDysheartenerBossRageMarket": "`The Dysheartener uses SHATTERING HEARTBREAK!`\n\nHelp! After feasting on our incomplete Dailies, the Dysheartener lets out another Shattering Heartbreak attack, smashing the walls and floor of the Market! As stone rains down, Alex the Merchant weeps at his crushed merchandise, stricken by the destruction.\n\nWe can't let this happen again! Be sure to do all our your Dailies to prevent the Dysheartener from using its final strike.",
"questDysheartenerBossRageQuests": "`The Dysheartener uses SHATTERING HEARTBREAK!`\n\nAaaah! We've left our Dailies undone again, and the Dysheartener has mustered the energy for one final blow against our beloved shopkeepers. The countryside around Ian the Quest Master is ripped apart by its Shattering Heartbreak attack, and Ian is struck to the core by the horrific vision. We're so close to defeating this monster.... Hurry! Don't stop now!",
"questDysheartenerDropHippogriffPet": "Hopeful Hippogriff (Pet)",
Expand Down

0 comments on commit 95179be

Please sign in to comment.