diff --git a/client/src/actions.jsx b/client/src/actions.jsx index f9fb6cd5..4b9d11ac 100644 --- a/client/src/actions.jsx +++ b/client/src/actions.jsx @@ -51,6 +51,7 @@ export const setTeamPage = value => ({ type: 'SET_TEAM_PAGE', value }); export const setTeamSelect = value => ({ type: 'SET_TEAM_SELECT', value: Array.from(value) }); export const setTutorial = value => ({ type: 'SET_TUTORIAL', value }); +export const setTutorialGame = value => ({ type: 'SET_TUTORIAL_GAME', value }); export const setVboxHighlight = value => ({ type: 'SET_VBOX_HIGHLIGHT', value }); export const setVboxSelected = value => ({ type: 'SET_VBOX_SELECTED', value }); diff --git a/client/src/components/game.construct.jsx b/client/src/components/game.construct.jsx index 186a55ef..79f2a8bc 100644 --- a/client/src/components/game.construct.jsx +++ b/client/src/components/game.construct.jsx @@ -24,6 +24,7 @@ const addState = connect( animText, gameSkillInfo, itemInfo, + tutorialGame, } = state; function selectSkillTarget(targetConstructId) { @@ -33,10 +34,6 @@ const addState = connect( return false; } - // intercept self casting skills - if (activeSkill && activeSkill.skill.self_targeting) { - ws.sendGameSkill(game.id, activeSkill.constructId, null, activeSkill.skill.skill); - } return { game, account, @@ -47,6 +44,7 @@ const addState = connect( selectSkillTarget, gameSkillInfo, itemInfo, + tutorialGame, }; }, @@ -55,7 +53,11 @@ const addState = connect( dispatch(actions.setGameEffectInfo(info)); } - return { setGameEffectInfo }; + function setTutorialGameClear(activeSkill, tutorialGame) { + if (activeSkill && tutorialGame) dispatch(actions.setTutorialGame(null)); + } + + return { setGameEffectInfo, setTutorialGameClear }; } ); @@ -93,7 +95,8 @@ class GameConstruct extends Component { selectSkillTarget, animFocus, animText, - + tutorialGame, + setTutorialGameClear, setGameEffectInfo, gameSkillInfo, itemInfo, @@ -146,7 +149,10 @@ class GameConstruct extends Component { return (
Select your skills, click on targets and then hit ready.
+