2021-09-13 15:53:43 +03:00
|
|
|
cmake_minimum_required(VERSION 3.17)
|
|
|
|
project(shooter)
|
|
|
|
|
|
|
|
set(CMAKE_CXX_STANDARD 20)
|
|
|
|
|
2021-10-09 13:41:12 +03:00
|
|
|
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}")
|
2021-09-13 15:53:43 +03:00
|
|
|
|
|
|
|
add_executable(shooter
|
|
|
|
# game:
|
2021-10-09 13:41:12 +03:00
|
|
|
Source.cpp
|
2021-09-13 15:53:43 +03:00
|
|
|
Player.cpp
|
|
|
|
Player.h
|
|
|
|
Client.cpp
|
|
|
|
Client.h
|
|
|
|
Server.cpp
|
|
|
|
Server.h
|
2021-09-14 13:47:53 +03:00
|
|
|
weapon/Weapon.cpp
|
|
|
|
weapon/Weapon.h
|
|
|
|
weapon/Ak47.cpp
|
|
|
|
weapon/Ak47.h
|
|
|
|
weapon/Shotgun.cpp
|
|
|
|
weapon/Shotgun.h
|
|
|
|
weapon/Gun.cpp
|
|
|
|
weapon/Gun.h
|
2021-09-13 15:53:43 +03:00
|
|
|
Bonus.cpp
|
|
|
|
Bonus.h
|
2021-09-14 13:47:53 +03:00
|
|
|
weapon/Gold_Ak47.h
|
|
|
|
weapon/Rifle.cpp
|
|
|
|
weapon/Rifle.h
|
2021-10-02 21:17:03 +03:00
|
|
|
PlayerController.cpp
|
|
|
|
PlayerController.h
|
|
|
|
Shooter.cpp
|
|
|
|
Shooter.h
|
2021-10-17 08:35:12 +03:00
|
|
|
ShooterConsts.h
|
2021-09-13 15:53:43 +03:00
|
|
|
# 3d engine:
|
2021-10-17 08:35:12 +03:00
|
|
|
engine/Consts.h
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/utils/Time.h
|
|
|
|
engine/utils/Time.cpp
|
2021-10-12 17:12:47 +03:00
|
|
|
engine/Point4D.h
|
|
|
|
engine/Point4D.cpp
|
2021-10-17 08:35:12 +03:00
|
|
|
engine/Vec3D.cpp
|
|
|
|
engine/Vec3D.h
|
|
|
|
engine/Vec2D.cpp
|
|
|
|
engine/Vec2D.h
|
2021-10-12 17:12:47 +03:00
|
|
|
engine/Matrix4x4.h
|
|
|
|
engine/Matrix4x4.cpp
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/Triangle.h
|
|
|
|
engine/Triangle.cpp
|
2021-10-17 08:35:12 +03:00
|
|
|
engine/Plane.h
|
|
|
|
engine/Plane.cpp
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/Mesh.h
|
|
|
|
engine/Mesh.cpp
|
|
|
|
engine/utils/Log.h
|
|
|
|
engine/utils/Log.cpp
|
|
|
|
engine/ResourceManager.h
|
|
|
|
engine/ResourceManager.cpp
|
|
|
|
engine/World.h
|
|
|
|
engine/World.cpp
|
|
|
|
engine/Camera.h
|
|
|
|
engine/Camera.cpp
|
|
|
|
engine/Screen.h
|
|
|
|
engine/Screen.cpp
|
|
|
|
engine/Engine.h
|
|
|
|
engine/Engine.cpp
|
2021-10-02 21:17:03 +03:00
|
|
|
engine/Keyboard.cpp
|
|
|
|
engine/Keyboard.h
|
|
|
|
engine/Mouse.cpp
|
|
|
|
engine/Mouse.h
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/animation/Animation.h
|
2021-10-02 21:17:03 +03:00
|
|
|
engine/animation/Timeline.cpp
|
|
|
|
engine/animation/Timeline.h
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/animation/Interpolation.h
|
|
|
|
engine/animation/Animation.cpp
|
|
|
|
engine/animation/ATranslate.h
|
|
|
|
engine/animation/AScale.h
|
|
|
|
engine/animation/ARotate.h
|
|
|
|
engine/animation/AWait.h
|
|
|
|
engine/physics/RigidBody.cpp
|
|
|
|
engine/physics/RigidBody.h
|
|
|
|
engine/physics/Simplex.h
|
2021-10-02 20:36:07 +03:00
|
|
|
engine/Object.cpp
|
2021-09-13 15:53:43 +03:00
|
|
|
engine/Object.h
|
|
|
|
engine/gui/Button.cpp
|
|
|
|
engine/gui/Button.h
|
|
|
|
engine/gui/Window.cpp
|
|
|
|
engine/gui/Window.h
|
|
|
|
engine/network/ClientUDP.cpp
|
|
|
|
engine/network/ClientUDP.h
|
|
|
|
engine/network/MsgType.cpp
|
|
|
|
engine/network/MsgType.h
|
|
|
|
engine/network/ReliableMsg.cpp
|
|
|
|
engine/network/ReliableMsg.h
|
|
|
|
engine/network/ServerUDP.cpp
|
|
|
|
engine/network/ServerUDP.h
|
|
|
|
engine/network/UDPConnection.cpp
|
|
|
|
engine/network/UDPConnection.h
|
|
|
|
engine/network/UDPSocket.cpp
|
|
|
|
engine/network/UDPSocket.h
|
|
|
|
engine/animation/AFunction.h
|
2021-10-17 08:35:12 +03:00
|
|
|
)
|
2021-09-13 15:53:43 +03:00
|
|
|
|
2021-09-13 17:01:26 +03:00
|
|
|
if(APPLE OR UNIX)
|
2021-09-13 15:53:43 +03:00
|
|
|
include_directories(/usr/local/include)
|
|
|
|
else()
|
2021-10-09 13:41:12 +03:00
|
|
|
set(SFML_DIR "SFML/lib/cmake/SFML")
|
2021-09-13 15:53:43 +03:00
|
|
|
set(SFML_STATIC_LIBRARIES TRUE)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
find_package(SFML 2.5.1 COMPONENTS graphics audio REQUIRED)
|
|
|
|
|
|
|
|
if (SFML_FOUND)
|
|
|
|
include_directories(${SFML_INCLUDE_DIR})
|
|
|
|
endif()
|
|
|
|
|
|
|
|
target_link_libraries(shooter sfml-audio sfml-network sfml-graphics sfml-window sfml-system)
|