Im am making my first game and one of the files just won't compile.
I keep getting this error whenever I try to compile this file (this is only the problem part):
if (answer[0] == 'y')
{
if (player->GetGold >= 10) // PROBLEM
{
player->SpendGold(10);
cout << "You find a nice bed and fall fast asleep.";
Wait();
cout << "\n(HP and MP restored\n\n";
cout << "HP: " << player->GetHealth() << " / " << player->GetMaxHealth() << "\n";
cout << "MP: " << player->GetMana() << " / " << player->GetMaxMana() << "\n";
player->SetHealth(player->GetMaxHealth());
player->SetMana(player->GetMaxMana());
Wait();
}
else
{
cout << "It looks like you don't have enough gold.\n";
Wait();
answer[0] = 'n';
}
}