// Fill out your copyright notice in the Description page of Project Settings.
#include "BullCowCartridge.h"
void UBullCowCartridge::BeginPlay() // When the game starts
{
Super::BeginPlay();
//Welcoming the Player
PrintLine(TEXT("Hi There!! Welcome to the Bull Cow Game!!!\n"));
PrintLine(TEXT("Guess the 4 letter word!")); // Magic Number Remove!
PrintLine(TEXT("press \"Enter\" to continue..."));
// Setting Up Game
HiddenWord = TEXT("head"); // Set the HiddenWord
// Set Lives
//Prompt Player For Guess
}
void UBullCowCartridge::OnInput(const FString& Input) // When the player hits enter
{
ClearScreen();
//Checking PlayerGuess
PrintLine(Input);
if (Input == HiddenWord)
{
PrintLine(TEXT("You have won!"));
}
else
{
PrintLine(TEXT("You have lost!"));
}
// Check if Input has right number of characters, if not prompt to check again
// Compare one letter against another in Input (verifying if Input is Isogram), if not prompt to check again
// If yes, Print Player Wins Message
// If No subtract 1 from Life
// Check If life > 0
// If yes, ask to enter another word,
//if life = 0, ask if want to play again? Press enter to play again
// If received enter input, replenish Life
// If don't want to play again,press ESC and game ends? Show player HiddenWord
// Check User Input
// PlayAgain or Quit
}