Initial Commit
This commit is contained in:
commit
fd874bd15b
|
@ -0,0 +1,38 @@
|
||||||
|
# Prerequisites
|
||||||
|
*.d
|
||||||
|
|
||||||
|
# Compiled Object files
|
||||||
|
*.slo
|
||||||
|
*.lo
|
||||||
|
*.o
|
||||||
|
*.obj
|
||||||
|
|
||||||
|
# Precompiled Headers
|
||||||
|
*.gch
|
||||||
|
*.pch
|
||||||
|
|
||||||
|
# Compiled Dynamic libraries
|
||||||
|
*.so
|
||||||
|
*.dylib
|
||||||
|
*.dll
|
||||||
|
|
||||||
|
# Fortran module files
|
||||||
|
*.mod
|
||||||
|
*.smod
|
||||||
|
|
||||||
|
# Compiled Static libraries
|
||||||
|
*.lai
|
||||||
|
*.la
|
||||||
|
*.a
|
||||||
|
*.lib
|
||||||
|
|
||||||
|
# Executables
|
||||||
|
*.exe
|
||||||
|
*.out
|
||||||
|
*.app
|
||||||
|
|
||||||
|
build
|
||||||
|
cmake-build-*
|
||||||
|
|
||||||
|
bin
|
||||||
|
lib
|
|
@ -0,0 +1,3 @@
|
||||||
|
[submodule "Botcraft"]
|
||||||
|
path = Botcraft
|
||||||
|
url = https://github.com/adepierre/Botcraft.git
|
|
@ -0,0 +1,8 @@
|
||||||
|
# Default ignored files
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
||||||
|
# Editor-based HTTP Client requests
|
||||||
|
/httpRequests/
|
||||||
|
# Datasource local storage ignored files
|
||||||
|
/dataSources/
|
||||||
|
/dataSources.local.xml
|
|
@ -0,0 +1 @@
|
||||||
|
AymDroid
|
|
@ -0,0 +1,2 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module classpath="CMake" type="CPP_MODULE" version="4" />
|
|
@ -0,0 +1,4 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="CMakeWorkspace" PROJECT_DIR="$PROJECT_DIR$" />
|
||||||
|
</project>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/.idea/AimDroid.iml" filepath="$PROJECT_DIR$/.idea/AimDroid.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,8 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="$PROJECT_DIR$" vcs="Git" />
|
||||||
|
<mapping directory="$PROJECT_DIR$/Botcraft" vcs="Git" />
|
||||||
|
<mapping directory="$PROJECT_DIR$/Botcraft/3rdparty/asio" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
|
@ -0,0 +1,39 @@
|
||||||
|
project(AymDroidBot)
|
||||||
|
|
||||||
|
# Declaring my source files
|
||||||
|
set(SRC_FILES
|
||||||
|
${PROJECT_SOURCE_DIR}/src/main.cpp
|
||||||
|
)
|
||||||
|
|
||||||
|
# Declaring my headers (this is not strictly
|
||||||
|
# necessary, but this will add them to the file
|
||||||
|
# structure in visual on windows)
|
||||||
|
set(HDR_FILES
|
||||||
|
${PROJECT_SOURCE_DIR}/include/main.hpp
|
||||||
|
)
|
||||||
|
|
||||||
|
# Create my target
|
||||||
|
add_executable(${PROJECT_NAME} ${HDR_FILES} ${SRC_FILES})
|
||||||
|
|
||||||
|
# Add my include folder to the include path
|
||||||
|
target_include_directories(${PROJECT_NAME} PUBLIC include)
|
||||||
|
|
||||||
|
# Linking my code to botcraft, cmake will handle everything
|
||||||
|
target_link_libraries(${PROJECT_NAME} botcraft)
|
||||||
|
|
||||||
|
# All this stuff is not really necessary, we just set the output folder
|
||||||
|
# to be the same than for botcraft so we don't need to manually copy the shared
|
||||||
|
# library next to the executable
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES DEBUG_POSTFIX "_d")
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RELWITHDEBINFO_POSTFIX "_rd")
|
||||||
|
if(MSVC)
|
||||||
|
# To avoid having one subfolder per configuration when building with Visual
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY_DEBUG "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY_RELEASE "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY_RELWITHDEBINFO "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY_MINSIZEREL "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
|
||||||
|
set_property(TARGET ${PROJECT_NAME} PROPERTY VS_DEBUGGER_WORKING_DIRECTORY "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
else()
|
||||||
|
set_target_properties(${PROJECT_NAME} PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${BOTCRAFT_OUTPUT_DIR}/bin")
|
||||||
|
endif(MSVC)
|
|
@ -0,0 +1 @@
|
||||||
|
#pragma once
|
|
@ -0,0 +1,10 @@
|
||||||
|
#include "botcraft/AI/SimpleBehaviourClient.hpp"
|
||||||
|
|
||||||
|
int main(int argc, char *argv[]) {
|
||||||
|
Botcraft::SimpleBehaviourClient client(true);
|
||||||
|
|
||||||
|
client.Connect(argv[1], argv[2], (argc > 3) ? argv[3] : "");
|
||||||
|
client.RunBehaviourUntilClosed();
|
||||||
|
client.Disconnect();
|
||||||
|
return 0;
|
||||||
|
}
|
|
@ -0,0 +1 @@
|
||||||
|
Subproject commit 26c71535a8e7b24419488961205474310bfdeb1a
|
|
@ -0,0 +1,16 @@
|
||||||
|
cmake_minimum_required(VERSION 3.10)
|
||||||
|
|
||||||
|
project(AymDroid)
|
||||||
|
|
||||||
|
# Here we can set some values for botcraft options
|
||||||
|
# They will still appear in cmake_gui in windows
|
||||||
|
set(BOTCRAFT_BUILD_EXAMPLES OFF CACHE BOOL "")
|
||||||
|
|
||||||
|
# This will enter the Botcraft folder and
|
||||||
|
# process Botcrat/CMakeLists.txt to add its
|
||||||
|
# targets to our current project
|
||||||
|
add_subdirectory(Botcraft)
|
||||||
|
|
||||||
|
# This will enter our My_Code folder and
|
||||||
|
# process My_Code/CMakeLists.txt
|
||||||
|
add_subdirectory(AymDroid)
|
Loading…
Reference in New Issue