Ir para conteúdo

Featured Replies

Postado
[  1%] Building CXX object CMakeFiles/tfs.dir/src/actions.cpp.o
In file included from /root/cast/forgottenserver/src/game.h:31:0,
                 from /root/cast/forgottenserver/src/actions.cpp:26:
/root/cast/forgottenserver/src/player.h: In member function ‘bool Player::startLiveCast(const string&)’:
/root/cast/forgottenserver/src/player.h:1145:68: error: invalid static_cast from type ‘ProtocolGame_ptr {aka std::shared_ptr<ProtocolGame>}’ to type ‘ProtocolCaster*’
     return client != nullptr && static_cast<ProtocolCaster*>(client)->startLiveCast(password);
                                                                    ^
/root/cast/forgottenserver/src/player.h: In member function ‘bool Player::stopLiveCast()’:
/root/cast/forgottenserver/src/player.h:1149:68: error: invalid static_cast from type ‘ProtocolGame_ptr {aka std::shared_ptr<ProtocolGame>}’ to type ‘ProtocolCaster*’
     return client != nullptr && static_cast<ProtocolCaster*>(client)->stopLiveCast();
                                                                    ^
/root/cast/forgottenserver/src/player.h: In member function ‘bool Player::isLiveCaster() const’:
/root/cast/forgottenserver/src/player.h:1153:68: error: invalid static_cast from type ‘const ProtocolGame_ptr {aka const std::shared_ptr<ProtocolGame>}’ to type ‘ProtocolCaster*’
     return client != nullptr && static_cast<ProtocolCaster*>(client)->isLiveCaster();
                                                                    ^
make[2]: *** [CMakeFiles/tfs.dir/src/actions.cpp.o] Error 1
make[1]: *** [CMakeFiles/tfs.dir/all] Error 2
make: *** [all] Error 2

 

 

Alguém sabe me dizer o por que do error?

O codigo em questão que está dando problema é esse creio eu...

        const std::map<uint8_t, OpenContainer>& getOpenContainers() const {
                return openContainers;
        }
        
        bool startLiveCast(const std::string& password) {
                return client != nullptr && static_cast<ProtocolCaster*>(client)->startLiveCast(password);
        }

        bool stopLiveCast() {
                return client != nullptr && static_cast<ProtocolCaster*>(client)->stopLiveCast();
        }

        bool isLiveCaster() const {
                return client != nullptr && static_cast<ProtocolCaster*>(client)->isLiveCaster();
        }    

 

 

Engine: Tfs 1.3

 

 

 

@This life is filled with hurt

When happiness doesn't work

Trust me and take my hand

When the lights go out you will understand

Postado
  • Autor
  Em 17/11/2016 em 08:54, Fir3element disse:

provavelmente vc não adicionou os arquivos que contém a classe ProtocolCaster no compilador

 

Sim era isso mesmo, já foi resolvido ;D

Obrigado

 

@This life is filled with hurt

When happiness doesn't work

Trust me and take my hand

When the lights go out you will understand

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.7k

Informação Importante

Confirmação de Termo