Thanks for the answers.
So anyway, I tried to create basic class that would let me display text.
class TextEngine{
public:
sf::Font Font;
std::string GetFont();
int CreateFont(std::string FileDir);
sf::String CreateText(sf::String Text, std::string String, float Size, float X, float Y);
int DisplayText(sf::RenderWindow Window, sf::String FileToDisplay);
};
std::string TextEngine::GetFont(){
std::string FileName;
lua_getglobal(Menu,"Font");
FileName = (std::string)lua_tostring(Menu, -1);
lua_pop(Menu, 1);
return FileName;
};
int TextEngine::CreateFont(std::string FileDir)
{
Font.LoadFromFile(FileDir);
return 0;
}
sf::String TextEngine::CreateText(sf::String Text, std::string String, float Size, float X, float Y){
Text.SetText(String);
Text.SetFont(Font);
Text.SetSize(Size);
Text.SetX(X);
Text.SetY(Y);
return Text;
};
int TextEngine::DisplayText(sf::RenderWindow Window, sf::String FileToDisplay){
Window.Draw(FileToDisplay);
return 0;
};
but whenever I try to use it, it gives me compiler errors that refers me to this "NonCopyable.hpp" page.
Am I accessing a private member? How do I fix this?