import { AppLayout } from './AppLayout';
import logo from './img/cat.png';
+import varlamov from './img/varlamov.png';
import { createMap } from './createMap';
import { GameController } from './GameController';
import { Notification } from './Notification';
constructor(props) {
super(props);
this.notification = new Notification();
+ this.handleVarlamov = function(tips) {
+ console.log(tips);
+ return tips;
+ }
this.gameController = new GameController(this.notification);
this.state = {
tips: this.gameController.tips(),
componentDidMount() {
this.gameController.createGame().then(() => this.gameController.loadTips()).then(() => {
this.setState({
- tips: this.gameController.tips(),
+ tips: this.handleVarlamov(this.gameController.tips()),
loading: false
}, () => {
createMap('map', this.onMapClick);
askTip = () => {
this.gameController.getMoreTips().then(() => {
this.setState({
- tips: this.gameController.tips()
+ tips: this.handleVarlamov(this.gameController.tips())
})
}).catch(error => {
this.notification.show(
move = () => {
this.gameController.goForward().then(() => {
this.setState({
- tips: this.gameController.tips()
+ tips: this.handleVarlamov(this.gameController.tips())
})
}).catch(error => {
this.notification.show(