dedicated fix
This commit is contained in:
parent
45e085b370
commit
2915c8a030
@ -26,16 +26,18 @@ add_executable( gremlin
|
|||||||
# define executable
|
# define executable
|
||||||
add_executable( gremlin_dedicated
|
add_executable( gremlin_dedicated
|
||||||
Application
|
Application
|
||||||
main
|
server
|
||||||
game
|
game
|
||||||
Time
|
Time
|
||||||
network
|
network
|
||||||
${VIDEO_SOURCES}
|
|
||||||
)
|
)
|
||||||
|
|
||||||
add_dependencies( gremlin
|
add_dependencies( gremlin
|
||||||
enet
|
enet
|
||||||
)
|
)
|
||||||
|
add_dependencies( gremlin_dedicated
|
||||||
|
enet
|
||||||
|
)
|
||||||
|
|
||||||
if (WIN32)
|
if (WIN32)
|
||||||
set(PLATFORM_LIBRARIES ws2_32 winmm)
|
set(PLATFORM_LIBRARIES ws2_32 winmm)
|
||||||
@ -48,7 +50,11 @@ endif(UNIX)
|
|||||||
target_link_libraries(gremlin
|
target_link_libraries(gremlin
|
||||||
enet ${PLATFORM_LIBRARIES}
|
enet ${PLATFORM_LIBRARIES}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
target_link_libraries(gremlin_dedicated
|
||||||
|
enet ${PLATFORM_LIBRARIES}
|
||||||
|
)
|
||||||
|
|
||||||
if (ENABLE_VIDEO)
|
if (ENABLE_VIDEO)
|
||||||
# set dependencies
|
# set dependencies
|
||||||
add_dependencies( gremlin
|
add_dependencies( gremlin
|
||||||
@ -66,4 +72,4 @@ if (ENABLE_VIDEO)
|
|||||||
target_link_libraries(gremlin
|
target_link_libraries(gremlin
|
||||||
glfw spark
|
glfw spark
|
||||||
)
|
)
|
||||||
endif(ENABLE_VIDEO)
|
endif(ENABLE_VIDEO)
|
||||||
|
@ -2,14 +2,6 @@
|
|||||||
|
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
class Server : public Application {
|
|
||||||
public:
|
|
||||||
virtual void initialize(int argc, char ** argv) {
|
|
||||||
Application::initialize(argc, argv);
|
|
||||||
setMaster(true);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
int main(int argc, char ** argv) {
|
int main(int argc, char ** argv) {
|
||||||
try {
|
try {
|
||||||
Client app;
|
Client app;
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
int main(int argc, char ** argv) {
|
int main(int argc, char ** argv) {
|
||||||
try {
|
try {
|
||||||
Application app;
|
Application app;
|
||||||
app.setMaster();
|
app.setMaster(true);
|
||||||
app.initialize(argc, argv);
|
app.initialize(argc, argv);
|
||||||
while (app.isRunning())
|
while (app.isRunning())
|
||||||
app.update();
|
app.update();
|
||||||
|
Loading…
Reference in New Issue
Block a user