import {GameActionsService} from './game-actions.service'; import {MicroLessonInfoOxDefault} from 'ox-types'; // Todo esto vale la pena ? export abstract class GameService { public currentLevel: number; // TODO check if this is neccesary. public currentMicroLessonId: string; protected constructor(private gameActions: GameActionsService) { this.gameActions.startGame.subscribe((x: {info: MicroLessonInfoOxDefault}) => { this.currentMicroLessonId = x.info.microLessonId; this.startGame(); }); } protected abstract beforeStartGame(): void; startGame() { this.beforeStartGame(); } /*public restartGame() { this.challengeService.nextChallenge(); this.challengeService.assignCurrentExerciseFromCache(); }*/ }