Skip to content

Commit

Permalink
Split up and cleaned some CMake files
Browse files Browse the repository at this point in the history
  • Loading branch information
mmatyas committed May 25, 2024
1 parent 93c5b86 commit 09e8cc2
Show file tree
Hide file tree
Showing 5 changed files with 125 additions and 163 deletions.
23 changes: 2 additions & 21 deletions src/common/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -66,29 +66,10 @@ add_library(CommonFiles STATIC
uicontrol.h
uimenu.cpp
uimenu.h
ui/MenuCode.h
ui/MI_Button.cpp
ui/MI_Button.h
ui/MI_Image.cpp
ui/MI_Image.h
ui/MI_ImageSelectField.cpp
ui/MI_ImageSelectField.h
ui/MI_MapField.cpp
ui/MI_MapField.h
ui/MI_MapPreview.cpp
ui/MI_MapPreview.h
ui/MI_ScoreText.cpp
ui/MI_ScoreText.h
ui/MI_SelectField.cpp
ui/MI_SelectField.h
ui/MI_SliderField.cpp
ui/MI_SliderField.h
ui/MI_Text.cpp
ui/MI_Text.h
ui/MI_TextField.cpp
ui/MI_TextField.h
)

add_subdirectory(ui)

if (USE_PNG_SAVE AND NOT USE_SDL2_LIBS)
target_sources(CommonFiles PRIVATE savepng.cpp savepng.h)
endif()
Expand Down
23 changes: 23 additions & 0 deletions src/common/ui/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
target_sources(CommonFiles PRIVATE
MenuCode.h
MI_Button.cpp
MI_Button.h
MI_Image.cpp
MI_Image.h
MI_ImageSelectField.cpp
MI_ImageSelectField.h
MI_MapField.cpp
MI_MapField.h
MI_MapPreview.cpp
MI_MapPreview.h
MI_ScoreText.cpp
MI_ScoreText.h
MI_SelectField.cpp
MI_SelectField.h
MI_SliderField.cpp
MI_SliderField.h
MI_Text.cpp
MI_Text.h
MI_TextField.cpp
MI_TextField.h
)
144 changes: 2 additions & 142 deletions src/smw/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -32,148 +32,8 @@ add_executable(smw WIN32
../common/movingplatform.h
)

#
# Game objects
#
target_sources(smw PRIVATE
objects/blocks/IO_Block.cpp

objects/blocks/BounceBlock.cpp
objects/blocks/BounceBlock.h
objects/blocks/BreakableBlock.cpp
objects/blocks/BreakableBlock.h
objects/blocks/DonutBlock.cpp
objects/blocks/DonutBlock.h
objects/blocks/FlipBlock.cpp
objects/blocks/FlipBlock.h
objects/blocks/NoteBlock.cpp
objects/blocks/NoteBlock.h
objects/blocks/OnOffSwitchBlock.cpp
objects/blocks/OnOffSwitchBlock.h
objects/blocks/PowerupBlock.cpp
objects/blocks/PowerupBlock.h
objects/blocks/ViewBlock.cpp
objects/blocks/ViewBlock.h
objects/blocks/SwitchBlock.cpp
objects/blocks/SwitchBlock.h
objects/blocks/ThrowBlock.cpp
objects/blocks/ThrowBlock.h
objects/blocks/WeaponBreakableBlock.cpp
objects/blocks/WeaponBreakableBlock.h

objects/moving/MovingObject.cpp
objects/moving/MovingObject.h

objects/overmap/OverMapObject.cpp
objects/overmap/OverMapObject.h
)

#
# Player components
#
target_sources(smw PRIVATE
player_components/PlayerAwardEffects.cpp
player_components/PlayerAwardEffects.h
player_components/PlayerBurnupTimer.cpp
player_components/PlayerBurnupTimer.h
player_components/PlayerCollisions.cpp
player_components/PlayerCollisions.h
player_components/PlayerCape.cpp
player_components/PlayerCape.h
player_components/PlayerCardCollection.cpp
player_components/PlayerCardCollection.h
player_components/PlayerInvincibility.cpp
player_components/PlayerInvincibility.h
player_components/PlayerJail.cpp
player_components/PlayerJail.h
player_components/PlayerKuriboShoe.cpp
player_components/PlayerKuriboShoe.h
player_components/PlayerOutOfArenaTimer.cpp
player_components/PlayerOutOfArenaTimer.h
player_components/PlayerSecretCode.cpp
player_components/PlayerSecretCode.h
player_components/PlayerShield.cpp
player_components/PlayerShield.h
player_components/PlayerSpinStatus.cpp
player_components/PlayerSpinStatus.h
player_components/PlayerSuicideTimer.cpp
player_components/PlayerSuicideTimer.h
player_components/PlayerSuperStomp.cpp
player_components/PlayerSuperStomp.h
player_components/PlayerTail.cpp
player_components/PlayerTail.h
player_components/PlayerTanookiSuit.cpp
player_components/PlayerTanookiSuit.h
player_components/PlayerWarpStatus.cpp
player_components/PlayerWarpStatus.h
player_components/PlayerWings.cpp
player_components/PlayerWings.h
)

#
# Menu screens
#
target_sources(smw PRIVATE
menu/MainMenu.cpp
menu/MainMenu.h
menu/BonusWheelMenu.cpp
menu/BonusWheelMenu.h
menu/GameSettingsMenu.cpp
menu/GameSettingsMenu.h
menu/ModeOptionsMenu.cpp
menu/ModeOptionsMenu.h
menu/MapFilterEditMenu.cpp
menu/MapFilterEditMenu.h
menu/MatchSelectionMenu.cpp
menu/MatchSelectionMenu.h
menu/OptionsMenu.cpp
menu/OptionsMenu.h
menu/PlayerControlsMenu.cpp
menu/PlayerControlsMenu.h
menu/PlayerControlsSelectMenu.cpp
menu/PlayerControlsSelectMenu.h
menu/TeamSelectMenu.cpp
menu/TeamSelectMenu.h
menu/TournamentScoreboardMenu.cpp
menu/TournamentScoreboardMenu.h
menu/TourStopMenu.cpp
menu/TourStopMenu.h
menu/WorldMenu.cpp
menu/WorldMenu.h

menu/options/EyeCandyOptionsMenu.cpp
menu/options/EyeCandyOptionsMenu.h
menu/options/GameplayOptionsMenu.cpp
menu/options/GameplayOptionsMenu.h
menu/options/GraphicsOptionsMenu.cpp
menu/options/GraphicsOptionsMenu.h
menu/options/PowerupDropRatesMenu.cpp
menu/options/PowerupDropRatesMenu.h
menu/options/PowerupSettingsMenu.cpp
menu/options/PowerupSettingsMenu.h
menu/options/ProjectileLimitsMenu.cpp
menu/options/ProjectileLimitsMenu.h
menu/options/ProjectileOptionsMenu.cpp
menu/options/ProjectileOptionsMenu.h
menu/options/SoundOptionsMenu.cpp
menu/options/SoundOptionsMenu.h
menu/options/TeamOptionsMenu.cpp
menu/options/TeamOptionsMenu.h

menu/network/NetEditServersMenu.cpp
menu/network/NetEditServersMenu.h
menu/network/NetLobbyMenu.cpp
menu/network/NetLobbyMenu.h
menu/network/NetNewRoomMenu.cpp
menu/network/NetNewRoomMenu.h
menu/network/NetNewRoomSettingsMenu.cpp
menu/network/NetNewRoomSettingsMenu.h
menu/network/NetRoomMenu.cpp
menu/network/NetRoomMenu.h
menu/network/NetServersMenu.cpp
menu/network/NetServersMenu.h
)

add_subdirectory(player_components)
add_subdirectory(menu)
add_subdirectory(gamemodes)
add_subdirectory(objects)
add_subdirectory(ui)
Expand Down
60 changes: 60 additions & 0 deletions src/smw/menu/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
target_sources(smw PRIVATE
MainMenu.cpp
MainMenu.h
BonusWheelMenu.cpp
BonusWheelMenu.h
GameSettingsMenu.cpp
GameSettingsMenu.h
ModeOptionsMenu.cpp
ModeOptionsMenu.h
MapFilterEditMenu.cpp
MapFilterEditMenu.h
MatchSelectionMenu.cpp
MatchSelectionMenu.h
OptionsMenu.cpp
OptionsMenu.h
PlayerControlsMenu.cpp
PlayerControlsMenu.h
PlayerControlsSelectMenu.cpp
PlayerControlsSelectMenu.h
TeamSelectMenu.cpp
TeamSelectMenu.h
TournamentScoreboardMenu.cpp
TournamentScoreboardMenu.h
TourStopMenu.cpp
TourStopMenu.h
WorldMenu.cpp
WorldMenu.h

options/EyeCandyOptionsMenu.cpp
options/EyeCandyOptionsMenu.h
options/GameplayOptionsMenu.cpp
options/GameplayOptionsMenu.h
options/GraphicsOptionsMenu.cpp
options/GraphicsOptionsMenu.h
options/PowerupDropRatesMenu.cpp
options/PowerupDropRatesMenu.h
options/PowerupSettingsMenu.cpp
options/PowerupSettingsMenu.h
options/ProjectileLimitsMenu.cpp
options/ProjectileLimitsMenu.h
options/ProjectileOptionsMenu.cpp
options/ProjectileOptionsMenu.h
options/SoundOptionsMenu.cpp
options/SoundOptionsMenu.h
options/TeamOptionsMenu.cpp
options/TeamOptionsMenu.h

network/NetEditServersMenu.cpp
network/NetEditServersMenu.h
network/NetLobbyMenu.cpp
network/NetLobbyMenu.h
network/NetNewRoomMenu.cpp
network/NetNewRoomMenu.h
network/NetNewRoomSettingsMenu.cpp
network/NetNewRoomSettingsMenu.h
network/NetRoomMenu.cpp
network/NetRoomMenu.h
network/NetServersMenu.cpp
network/NetServersMenu.h
)
38 changes: 38 additions & 0 deletions src/smw/player_components/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
target_sources(smw PRIVATE
PlayerAwardEffects.cpp
PlayerAwardEffects.h
PlayerBurnupTimer.cpp
PlayerBurnupTimer.h
PlayerCollisions.cpp
PlayerCollisions.h
PlayerCape.cpp
PlayerCape.h
PlayerCardCollection.cpp
PlayerCardCollection.h
PlayerInvincibility.cpp
PlayerInvincibility.h
PlayerJail.cpp
PlayerJail.h
PlayerKuriboShoe.cpp
PlayerKuriboShoe.h
PlayerOutOfArenaTimer.cpp
PlayerOutOfArenaTimer.h
PlayerSecretCode.cpp
PlayerSecretCode.h
PlayerShield.cpp
PlayerShield.h
PlayerSpinStatus.cpp
PlayerSpinStatus.h
PlayerSuicideTimer.cpp
PlayerSuicideTimer.h
PlayerSuperStomp.cpp
PlayerSuperStomp.h
PlayerTail.cpp
PlayerTail.h
PlayerTanookiSuit.cpp
PlayerTanookiSuit.h
PlayerWarpStatus.cpp
PlayerWarpStatus.h
PlayerWings.cpp
PlayerWings.h
)

0 comments on commit 09e8cc2

Please sign in to comment.