Hi, I'm working on a Client App and I wish to create a Client class where I create 2 threads (R and S), who execute functions Receiver and Sender, respectively...
class Client {
sf::IPAddress ServerAddress;
sf::SocketTCP Socket;
sf::Packet Packet;
sf::Thread R, S;
void Receiver(void*);
void Sender(void*);
bool connected;
bool updated;
public:
Client();
sf::Packet Receive();
void Send(sf::Packet);
bool IsConnected();
bool IsUpToDate();
};
Then, I get:
Thread.hpp|92|error: 'sf::Thread::Thread()' is protected|
I tried with
class Client : public sf::Thread {
and
class Client : private sf::Thread {
but this doesn't resolve it
How can I resolve it?
PD: Sorry if bad english ^^