diff --git a/CMakeLists.txt b/CMakeLists.txt index 214c332..54185d3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -63,29 +63,29 @@ endif() # Specify directories # include_directories( - "${PROJECT_SOURCE_DIR}/subprojects/SDL/include" - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_image" - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_image/include" - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_ttf/include" - "${PROJECT_SOURCE_DIR}/subprojects/minIni/dev" - "${PROJECT_SOURCE_DIR}/subprojects/bdd-for-c" - "${PROJECT_SOURCE_DIR}/subprojects/bdd-for-c-mocks" - "${PROJECT_SOURCE_DIR}/subprojects/portmidi/pm_common" - "${PROJECT_SOURCE_DIR}/dependencies/spine-runtimes/spine-c/spine-c/include" - "${PROJECT_SOURCE_DIR}/dependencies/getopt-for-windows" - "${PROJECT_SOURCE_DIR}/dependencies/libwebsockets/build/include" - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/include" - "${PROJECT_SOURCE_DIR}/dependencies/sqlite" + "${CMAKE_HOME_DIRECTORY}/subprojects/SDL/include" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_image" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_image/include" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_ttf/include" + "${CMAKE_HOME_DIRECTORY}/subprojects/minIni/dev" + "${CMAKE_HOME_DIRECTORY}/subprojects/bdd-for-c" + "${CMAKE_HOME_DIRECTORY}/subprojects/bdd-for-c-mocks" + "${CMAKE_HOME_DIRECTORY}/subprojects/portmidi/pm_common" + "${CMAKE_HOME_DIRECTORY}/dependencies/spine-runtimes/spine-c/spine-c/include" + "${CMAKE_HOME_DIRECTORY}/dependencies/getopt-for-windows" + "${CMAKE_HOME_DIRECTORY}/dependencies/libwebsockets/build/include" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/include" + "${CMAKE_HOME_DIRECTORY}/dependencies/sqlite" ) if (IZ_PLATFORM STREQUAL "WINDOWS") link_directories( - "${PROJECT_SOURCE_DIR}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}" - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_image/lib/${IZ_PROJECT_ARCH}" - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_ttf/lib/${IZ_PROJECT_ARCH}" - "${PROJECT_SOURCE_DIR}/subprojects/portmidi/build/Release" - "${PROJECT_SOURCE_DIR}/dependencies/libwebsockets/build/lib/Release" - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/lib" + "${CMAKE_HOME_DIRECTORY}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_image/lib/${IZ_PROJECT_ARCH}" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_ttf/lib/${IZ_PROJECT_ARCH}" + "${CMAKE_HOME_DIRECTORY}/subprojects/portmidi/build/Release" + "${CMAKE_HOME_DIRECTORY}/dependencies/libwebsockets/build/lib/Release" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/lib" ) if (NOT ${CMAKE_BUILD_TYPE} STREQUAL "Debug") set(IZ_EXECUTABLE_TYPE WIN32) @@ -371,71 +371,71 @@ add_executable( if (IZ_PLATFORM STREQUAL "WINDOWS") add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" + "${CMAKE_HOME_DIRECTORY}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_image/lib/${IZ_PROJECT_ARCH}/SDL2_image.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_image/lib/${IZ_PROJECT_ARCH}/SDL2_image.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/SDL2_ttf/lib/${IZ_PROJECT_ARCH}/SDL2_ttf.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/SDL2_ttf/lib/${IZ_PROJECT_ARCH}/SDL2_ttf.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/subprojects/portmidi/build/Release/portmidi.dll" + "${CMAKE_HOME_DIRECTORY}/subprojects/portmidi/build/Release/portmidi.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/libwebsockets/build/bin/Release/websockets.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/libwebsockets/build/bin/Release/websockets.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libssl-1_1-${IZ_SDL_ARCH}.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libssl-1_1-${IZ_SDL_ARCH}.dll" $) add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libcrypto-1_1-${IZ_SDL_ARCH}.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libcrypto-1_1-${IZ_SDL_ARCH}.dll" $) add_custom_command(TARGET server POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" + "${CMAKE_HOME_DIRECTORY}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" $) add_custom_command(TARGET server POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/libwebsockets/build/bin/Release/websockets.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/libwebsockets/build/bin/Release/websockets.dll" $) add_custom_command(TARGET server POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libssl-1_1-${IZ_SDL_ARCH}.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libssl-1_1-${IZ_SDL_ARCH}.dll" $) add_custom_command(TARGET server POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libcrypto-1_1-${IZ_SDL_ARCH}.dll" + "${CMAKE_HOME_DIRECTORY}/dependencies/openssl/${IZ_PROJECT_ARCH}/bin/libcrypto-1_1-${IZ_SDL_ARCH}.dll" $) add_custom_command(TARGET game-test-input POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_if_different - "${PROJECT_SOURCE_DIR}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" + "${CMAKE_HOME_DIRECTORY}/subprojects/SDL/VisualC/${IZ_SDL_ARCH}/${CMAKE_BUILD_TYPE}/SDL2.dll" $) endif () add_custom_command(TARGET game POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory - "${PROJECT_SOURCE_DIR}/assets" + "${CMAKE_HOME_DIRECTORY}/assets" $/assets) add_custom_command(TARGET asset-inv POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy_directory - "${PROJECT_SOURCE_DIR}/assets" + "${CMAKE_HOME_DIRECTORY}/assets" $/assets) diff --git a/README.md b/README.md index 7dd2807..0790e8b 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,10 @@ A run-and-gun shooter inspired by Metal Slug. The following tools are required: +* [Windows SDK](https://developer.microsoft.com/en-us/windows/downloads/windows-sdk/) + +These required tools may be installed via Chocolatey (recommended): + * CMake * Ninja * Clang @@ -18,6 +22,10 @@ The following tools are required: > Set your `CMAKE_MT` environment variable to the full path of `mt.exe`, which can be found on your Windows SDK > installation folder (usually `C:/Program Files (x86)/Windows Kits/10/bin/10.0.19041.0/x86/mt.exe`) +> **Note:** The CMake cache might be filled in with library paths that might be unknown when Visual Studio is installed. +> It will cause errors in building. Run the scripts provided in this project to ensure that the correct library paths +> are supplied. + 1. Clone this repo. 2. Clone the repositories under `dependencies.txt` except for SDL2. 3. Unpack the **MSVC** archive under `dependencies` folder in this project's root. Rename the directory as `SDL2`. diff --git a/assets_src/gfx/characters-izanagi.cdr b/assets_src/gfx/characters-izanagi.cdr index abadf5e..8f7d238 100644 Binary files a/assets_src/gfx/characters-izanagi.cdr and b/assets_src/gfx/characters-izanagi.cdr differ