From 441db99d5defcb273c08017d88c015d925ab2c33 Mon Sep 17 00:00:00 2001 From: nullsystem <15316579+nullsystem@users.noreply.github.com> Date: Sun, 7 Jun 2026 13:33:20 +0100 Subject: [PATCH 1/4] cmake unity build * Improve compile times, tested no ccache full compile: * Linux debug 9800x3d: 1m13s to 23s (3.2x speedup) * Linux release 9800x3d: 1m36s to 1m21s (1.2x speedup) * Windows debug 9800x3d: 1m21s to 13s (6.2x speedup) * Windows release 9800x3d: 1m24s to 18s (4.6x speedup) * Time VS in CMake library build stage: * Non-unity: https://github.com/NeotokyoRebuild/neo/actions/runs/27134842462 * Unity: https://github.com/NeotokyoRebuild/neo/actions/runs/27162359918 * Linux debug github runner: 12m16s to 2m5s (5.8x speedup) * Linux release github runner: 14m3s to 5m4s (2.8x speedup) * Windows debug github runner: 10m56s to 1m30s (7.2x speedup) * Windows release github runner: 11m22s to 2m6s (5.3x speedup) * From ~1.4k obj to 150-166 * Lots of files not unity build due to IInput vs vgui::IInput ambiguity * Some files left out cause easier to leave it out than dealing with it * Not doing materialsystem as it .inc relies on 1-file-per-obj * Few files left out of unity due to issues shown up in runtime * Windows cmd to measure: * powershell -Command "Measure-Command {cmake --build --preset windows-[debug/release] | Out-Default}" * fixes #1981 --- src/CMakeLists.txt | 4 +- src/game/client/CMakeLists.txt | 620 ++++---- src/game/client/c_fire_smoke.cpp | 11 + src/game/client/c_impact_effects.cpp | 18 + src/game/client/c_lightglow.cpp | 8 + src/game/client/c_plasma.cpp | 16 + src/game/client/c_sun.cpp | 8 + src/game/client/c_te_explosion.cpp | 4 + src/game/client/c_te_glassshatter.cpp | 18 + src/game/client/clientsteamcontext.cpp | 6 +- src/game/client/fx_sparks.h | 4 + src/game/client/menu.cpp | 5 + src/game/client/mp3player.cpp | 40 +- src/game/client/mp3player.h | 4 + src/game/client/neo/ui/IOverrideInterface.h | 2 + src/game/client/neo/ui/neo_loading.cpp | 2 +- src/game/client/vgui_avatarimage.cpp | 3 + src/game/client/viewpostprocess.cpp | 4 + src/game/server/CMakeLists.txt | 1268 +++++++++-------- src/game/server/ServerNetworkProperty.cpp | 6 + src/game/server/ServerNetworkProperty.h | 6 + src/game/server/ai_basenpc.h | 7 + src/game/server/hl2/grenade_frag.cpp | 5 +- src/game/server/hl2/item_healthkit.cpp | 8 + src/game/server/hl2/npc_combine.cpp | 6 + src/game/server/hl2/npc_combinecamera.cpp | 12 + src/game/server/hl2/npc_combinedropship.cpp | 12 + src/game/server/hl2/npc_metropolice.cpp | 6 + src/game/server/hl2/npc_scanner.cpp | 3 + src/game/server/hl2/npc_stalker.cpp | 4 + src/game/server/hl2/npc_strider.cpp | 8 + src/game/server/hl2/npc_turret_ceiling.cpp | 26 +- .../server/hl2/npc_vortigaunt_episodic.cpp | 4 + src/game/server/hl2/vehicle_apc.cpp | 16 + src/game/server/physconstraint.cpp | 5 + src/game/server/triggers.cpp | 8 + src/game/shared/activitylist.cpp | 16 + src/game/shared/eventlist.cpp | 18 +- src/game/shared/gamemovement.cpp | 2 + src/mathlib/CMakeLists.txt | 57 +- src/mathlib/noisedata.h | 3 + src/public/edict.h | 6 + src/public/filesystem.h | 6 + src/public/iservernetworkable.h | 6 +- src/public/server_class.h | 12 + src/public/tier1/datamanager.h | 3 + src/public/tier1/fmtstr.h | 6 + src/public/vgui/IPanel.h | 6 + src/public/vgui_controls/MessageMap.h | 6 + src/public/vgui_controls/PropertyDialog.h | 4 + src/public/vgui_controls/PropertySheet.h | 6 + src/tier1/CMakeLists.txt | 34 +- src/tier1/kvpacker.cpp | 5 + src/tier1/snappy.cpp | 7 + src/vgui2/vgui_controls/CMakeLists.txt | 29 +- src/vgui2/vgui_controls/Common.h | 148 ++ src/vgui2/vgui_controls/FileOpenDialog.cpp | 24 +- .../vgui_controls/KeyBindingHelpDialog.cpp | 5 + .../vgui_controls/KeyBoardEditorDialog.cpp | 7 + src/vgui2/vgui_controls/ListPanel.cpp | 6 +- src/vgui2/vgui_controls/ListViewPanel.cpp | 6 +- src/vgui2/vgui_controls/Panel.cpp | 6 + src/vgui2/vgui_controls/PerforceFileList.cpp | 17 + src/vgui2/vgui_controls/PropertyDialog.cpp | 4 + src/vgui2/vgui_controls/ToolWindow.cpp | 4 + src/vgui2/vgui_controls/TreeView.cpp | 5 + src/vgui2/vgui_controls/URLLabel.cpp | 4 + 67 files changed, 1766 insertions(+), 889 deletions(-) create mode 100644 src/vgui2/vgui_controls/Common.h diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index b24fad617a..dbd91d9613 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -7,7 +7,8 @@ set(CMAKE_VERBOSE_MAKEFILE TRUE) message(STATUS "CMAKE_VERSION: ${CMAKE_VERSION}") string(TIMESTAMP BUILD_DATETIME UTC) -message(STATUS "TIMESTAMP: ${BUILD_DATETIME}") +# NEO TODO (nullsystem): This screwed up nvim's :make +# message(STATUS "TIMESTAMP: ${BUILD_DATETIME}") list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake") @@ -179,6 +180,7 @@ if(OS_WINDOWS) /errorReport:prompt # ErrorReporting - Prompt Immediately /W4 /Gw # Optimize Global Data + /bigobj # Required for unity build /wd4456 /wd4457 diff --git a/src/game/client/CMakeLists.txt b/src/game/client/CMakeLists.txt index bc970f3a15..da2a57fca7 100644 --- a/src/game/client/CMakeLists.txt +++ b/src/game/client/CMakeLists.txt @@ -1,6 +1,10 @@ add_library(client SHARED) -set_target_properties(client PROPERTIES PREFIX "") +set_target_properties(client PROPERTIES + PREFIX "" + UNITY_BUILD ON + UNITY_BUILD_MODE GROUP +) if(NEO_USE_SEPARATE_BUILD_INFO) split_debug_information(TARGET client) @@ -299,15 +303,13 @@ if(NEO_BUILD_REPLAY) endif() endif() -set(SOURCE_FILES_WITHOUT_PCH +set(UNITY_SOURCE_FILES_WITHOUT_PCH ${CMAKE_SOURCE_DIR}/common/compiledcaptionswap.cpp ${CMAKE_SOURCE_DIR}/common/language.cpp ${CMAKE_SOURCE_DIR}/common/randoverride.cpp ${CMAKE_SOURCE_DIR}/game/shared/interval.cpp ${CMAKE_SOURCE_DIR}/game/shared/sheetsimulator.cpp - ${CMAKE_SOURCE_DIR}/public/tier0/memoverride.cpp ${CMAKE_SOURCE_DIR}/public/ScratchPadUtils.cpp - ${CMAKE_SOURCE_DIR}/public/bone_setup.cpp ${CMAKE_SOURCE_DIR}/public/client_class.cpp ${CMAKE_SOURCE_DIR}/public/collisionutils.cpp ${CMAKE_SOURCE_DIR}/public/crtmemdebug.cpp @@ -321,7 +323,6 @@ set(SOURCE_FILES_WITHOUT_PCH ${CMAKE_SOURCE_DIR}/public/posedebugger.cpp ${CMAKE_SOURCE_DIR}/public/renamed_recvtable_compat.cpp ${CMAKE_SOURCE_DIR}/public/rope_physics.cpp - ${CMAKE_SOURCE_DIR}/public/scratchpad3d.cpp ${CMAKE_SOURCE_DIR}/public/sentence.cpp ${CMAKE_SOURCE_DIR}/public/simple_physics.cpp ${CMAKE_SOURCE_DIR}/public/stringregistry.cpp @@ -329,53 +330,49 @@ set(SOURCE_FILES_WITHOUT_PCH ${CMAKE_SOURCE_DIR}/public/vallocator.cpp ${CMAKE_SOURCE_DIR}/public/vgui_controls/vgui_controls.cpp hud_lcd.cpp - in_mouse.cpp mumble.cpp rendertexture.cpp ) -target_sources_grouped( - TARGET client - NAME "Source Files" - FILES +set_source_files_properties( + ${UNITY_SOURCE_FILES_WITHOUT_PCH} + PROPERTIES + UNITY_GROUP without_pch_client +) + +set(SOURCE_FILES_WITHOUT_PCH + ${UNITY_SOURCE_FILES_WITHOUT_PCH} + in_mouse.cpp + ${CMAKE_SOURCE_DIR}/public/bone_setup.cpp + ${CMAKE_SOURCE_DIR}/public/tier0/memoverride.cpp + ${CMAKE_SOURCE_DIR}/public/scratchpad3d.cpp +) + +set(UNITY_SOURCE_SHARED #${CMAKE_SOURCE_DIR}/game/shared/weapon_parse_default.cpp - ${CMAKE_SOURCE_DIR}/game/client/c_vote_controller.cpp - ${CMAKE_SOURCE_DIR}/game/client/c_vote_controller.h - ${CMAKE_SOURCE_DIR}/game/client/steamshare.cpp - ${CMAKE_SOURCE_DIR}/game/client/steamshare.h - ${CMAKE_SOURCE_DIR}/game/client/in_steamcontroller.cpp ${CMAKE_SOURCE_DIR}/game/shared/EntityParticleTrail_Shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/GameStats.cpp ${CMAKE_SOURCE_DIR}/game/shared/SoundEmitterSystem.cpp ${CMAKE_SOURCE_DIR}/game/shared/Sprite.cpp ${CMAKE_SOURCE_DIR}/game/shared/SpriteTrail.cpp ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.cpp - ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.h ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.cpp - ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.h - ${CMAKE_SOURCE_DIR}/game/shared/achievements_and_stats_interface.h ${CMAKE_SOURCE_DIR}/game/shared/achievements_hlx.cpp ${CMAKE_SOURCE_DIR}/game/shared/activitylist.cpp ${CMAKE_SOURCE_DIR}/game/shared/ammodef.cpp ${CMAKE_SOURCE_DIR}/game/shared/animation.cpp ${CMAKE_SOURCE_DIR}/game/shared/base_playeranimstate.cpp ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.h ${CMAKE_SOURCE_DIR}/game/shared/basecombatcharacter_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/basecombatweapon_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/baseentity_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.h ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.cpp - ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.h ${CMAKE_SOURCE_DIR}/game/shared/baseparticleentity.cpp ${CMAKE_SOURCE_DIR}/game/shared/baseplayer_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.h ${CMAKE_SOURCE_DIR}/game/shared/baseviewmodel_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/beam_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/cam_thirdperson.cpp - ${CMAKE_SOURCE_DIR}/game/shared/cam_thirdperson.h ${CMAKE_SOURCE_DIR}/game/shared/collisionproperty.cpp ${CMAKE_SOURCE_DIR}/game/shared/death_pose.cpp ${CMAKE_SOURCE_DIR}/game/shared/debugoverlay_shared.cpp @@ -401,15 +398,12 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/multiplay_gamerules.cpp ${CMAKE_SOURCE_DIR}/game/shared/obstacle_pushaway.cpp ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.cpp - ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.h ${CMAKE_SOURCE_DIR}/game/shared/particle_property.cpp - ${CMAKE_SOURCE_DIR}/game/shared/particle_property.h ${CMAKE_SOURCE_DIR}/game/shared/particlesystemquery.cpp ${CMAKE_SOURCE_DIR}/game/shared/physics_main_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/physics_saverestore.cpp ${CMAKE_SOURCE_DIR}/game/shared/physics_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.cpp - ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.h ${CMAKE_SOURCE_DIR}/game/shared/point_posecontroller.cpp ${CMAKE_SOURCE_DIR}/game/shared/precache_register.cpp ${CMAKE_SOURCE_DIR}/game/shared/predictableid.cpp @@ -436,11 +430,14 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/voice_status.cpp ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse.cpp ${CMAKE_SOURCE_DIR}/game/shared/secure_command_line.cpp - ${CMAKE_SOURCE_DIR}/game/shared/secure_command_line.h - ${CMAKE_SOURCE_DIR}/public/SoundParametersInternal.cpp - ${CMAKE_SOURCE_DIR}/public/bone_accessor.cpp - ${CMAKE_SOURCE_DIR}/public/haptics/haptic_msgs.cpp - ${SOURCE_FILES_WITHOUT_PCH} +) + +set_source_files_properties( + ${UNITY_SOURCE_SHARED} + PROPERTIES UNITY_GROUP shared_client +) + +set(UNITY_SOURCE_SRC_CLIENT AnimateSpecificTextureProxy.cpp C_MaterialModifyControl.cpp C_WaterLODControl.cpp @@ -452,7 +449,6 @@ target_sources_grouped( WaterLODMaterialProxy.cpp WorldDimsProxy.cpp achievement_notification_panel.cpp - achievement_notification_panel.h alphamaterialproxy.cpp animatedentitytextureproxy.cpp animatedoffsettextureproxy.cpp @@ -464,14 +460,11 @@ target_sources_grouped( bone_merge_cache.cpp c_ai_basehumanoid.cpp c_ai_basenpc.cpp - c_baseanimating.cpp c_baseanimatingoverlay.cpp c_basecombatcharacter.cpp c_basecombatweapon.cpp c_basedoor.cpp - c_baseentity.cpp c_baseflex.cpp - c_baseplayer.cpp c_baseviewmodel.cpp c_breakableprop.cpp c_colorcorrection.cpp @@ -510,16 +503,11 @@ target_sources_grouped( c_point_camera.cpp c_point_commentary_node.cpp c_point_worldtext.cpp - c_point_worldtext.h c_props.cpp - c_props.h c_ragdoll_manager.cpp - c_rope.cpp c_rumble.cpp - c_sceneentity.cpp c_shadowcontrol.cpp c_slideshow_display.cpp - c_slideshow_display.h c_soundscape.cpp c_spotlight_end.cpp c_sprite.cpp @@ -529,37 +517,27 @@ target_sources_grouped( c_tesla.cpp c_test_proxytoggle.cpp c_user_message_register.cpp - c_vehicle_choreo_generic.cpp - c_vehicle_jeep.cpp c_vguiscreen.cpp c_world.cpp camomaterialproxy.cpp cdll_bounded_cvars.cpp - cdll_bounded_cvars.h - cdll_client_int.cpp cdll_util.cpp cl_mat_stub.cpp classmap.cpp client_factorylist.cpp client_thinklist.cpp client_virtualreality.cpp - client_virtualreality.h clienteffectprecachesystem.cpp cliententitylist.cpp clientleafsystem.cpp clientmode_shared.cpp - clientshadowmgr.cpp clientsideeffects.cpp clientsideeffects_test.cpp clientsteamcontext.cpp - clientsteamcontext.h colorcorrectionmgr.cpp - commentary_modelviewer.cpp - commentary_modelviewer.h detailobjectsystem.cpp dummyproxy.cpp entityoriginmaterialproxy.cpp - flashlighteffect.cpp functionproxy.cpp fx_blood.cpp fx_cube.cpp @@ -583,8 +561,6 @@ target_sources_grouped( hl2/hud_autoaim.cpp hl2/hud_filmdemo.cpp hl2/hud_hdrdemo.cpp - hltvcamera.cpp - hud.cpp hud_animationinfo.cpp hud_basechat.cpp hud_basetimer.cpp @@ -597,11 +573,7 @@ target_sources_grouped( hud_numericdisplay.cpp hud_pdump.cpp hud_redraw.cpp - hud_vehicle.cpp hud_weapon.cpp - in_camera.cpp - in_joystick.cpp - in_main.cpp initializer.cpp interpolatedvar.cpp lampbeamproxy.cpp @@ -620,7 +592,6 @@ target_sources_grouped( particles_attractor.cpp particles_ez.cpp particles_localspace.cpp - particles_new.cpp particles_simple.cpp perfvisualbenchmark.cpp physics.cpp @@ -628,9 +599,7 @@ target_sources_grouped( physpropclientside.cpp playerandobjectenumerator.cpp playerspawncache.cpp - prediction.cpp proxyentity.cpp - proxyplayer.cpp proxypupil.cpp ragdoll.cpp recvproxy.cpp @@ -638,14 +607,12 @@ target_sources_grouped( splinepatch.cpp spritemodel.cpp studio_stats.cpp - studio_stats.h text_message.cpp texturescrollmaterialproxy.cpp timematerialproxy.cpp toggletextureproxy.cpp train.cpp vgui_avatarimage.cpp - vgui_avatarimage.h vgui_basepanel.cpp vgui_bitmapbutton.cpp vgui_bitmapimage.cpp @@ -656,27 +623,106 @@ target_sources_grouped( vgui_fpspanel.cpp vgui_game_viewport.cpp vgui_grid.cpp - vgui_int.cpp vgui_loadingdiscpanel.cpp vgui_messagechars.cpp - vgui_netgraphpanel.cpp vgui_schemevisualizer.cpp vgui_slideshow_display_screen.cpp vgui_video.cpp vgui_video_player.cpp - view.cpp view_beams.cpp view_effects.cpp view_scene.cpp viewangleanim.cpp viewdebug.cpp - viewdebug.h viewpostprocess.cpp + warp_overlay.cpp + weapons_resource.cpp + + ${CMAKE_SOURCE_DIR}/common/steamid.cpp + # ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse_default.cpp + ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.cpp + ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.cpp + c_team_objectiveresource.cpp + c_team_train_watcher.cpp + hud_voicestatus.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_SRC_CLIENT} + PROPERTIES UNITY_GROUP src_client +) + +target_sources_grouped( + TARGET client + NAME "Source Files" + FILES + ${CMAKE_SOURCE_DIR}/game/client/c_vote_controller.cpp + ${CMAKE_SOURCE_DIR}/game/client/c_vote_controller.h + ${CMAKE_SOURCE_DIR}/game/client/steamshare.cpp + ${CMAKE_SOURCE_DIR}/game/client/steamshare.h + ${CMAKE_SOURCE_DIR}/game/client/in_steamcontroller.cpp + ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.h + ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.h + ${CMAKE_SOURCE_DIR}/game/shared/achievements_and_stats_interface.h + ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.h + ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.h + ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.h + ${CMAKE_SOURCE_DIR}/game/shared/cam_thirdperson.h + ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.h + ${CMAKE_SOURCE_DIR}/game/shared/particle_property.h + ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.h + ${CMAKE_SOURCE_DIR}/game/shared/secure_command_line.h + ${UNITY_SOURCE_SHARED} + ${CMAKE_SOURCE_DIR}/game/shared/cam_thirdperson.cpp + ${CMAKE_SOURCE_DIR}/public/SoundParametersInternal.cpp + ${CMAKE_SOURCE_DIR}/public/bone_accessor.cpp + ${CMAKE_SOURCE_DIR}/public/haptics/haptic_msgs.cpp + ${SOURCE_FILES_WITHOUT_PCH} + achievement_notification_panel.h + c_point_worldtext.h + c_props.h + c_slideshow_display.h + cdll_bounded_cvars.h + client_virtualreality.h + clientsteamcontext.h + commentary_modelviewer.h + studio_stats.h + vgui_avatarimage.h + viewdebug.h viewpostprocess.h + + ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.h + ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.h + c_team_objectiveresource.h + c_team_train_watcher.h + + ${UNITY_SOURCE_SRC_CLIENT} + c_baseanimating.cpp + c_baseentity.cpp + c_baseplayer.cpp + c_rope.cpp + c_sceneentity.cpp + c_vehicle_choreo_generic.cpp + c_vehicle_jeep.cpp + cdll_client_int.cpp + clientshadowmgr.cpp + commentary_modelviewer.cpp + flashlighteffect.cpp + hltvcamera.cpp + hud.cpp + hud_vehicle.cpp + in_camera.cpp + in_joystick.cpp + in_main.cpp + particles_new.cpp + prediction.cpp + proxyplayer.cpp + vgui_int.cpp + vgui_netgraphpanel.cpp + view.cpp viewrender.cpp - warp_overlay.cpp weapon_selection.cpp - weapons_resource.cpp ) set_source_files_properties(cdll_client_int.cpp PROPERTIES @@ -720,10 +766,7 @@ target_sources_grouped( sixense/in_sixense_gesture_bindings.h ) -target_sources_grouped( - TARGET client - NAME "Temporary Entities" - FILES +set(UNITY_SOURCE_TEMPORARY_ENTITIES c_basetempentity.cpp c_effects.cpp c_impact_effects.cpp @@ -789,19 +832,25 @@ target_sources_grouped( smoke_fog_overlay.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_TEMPORARY_ENTITIES} + PROPERTIES UNITY_GROUP temporary_entities_client +) + target_sources_grouped( TARGET client - NAME "Game Controls" + NAME "Temporary Entities" FILES + ${UNITY_SOURCE_TEMPORARY_ENTITIES} +) + +set(UNITY_SOURCE_GAMECONTROLS game_controls/ClientScoreBoardDialog.cpp game_controls/IconPanel.cpp game_controls/MapOverview.cpp game_controls/NavProgress.cpp - game_controls/SpectatorGUI.cpp game_controls/basemodel_panel.cpp - game_controls/basemodel_panel.h game_controls/basemodelpanel.cpp - game_controls/basemodelpanel.h game_controls/baseviewport.cpp game_controls/commandmenu.cpp game_controls/intromenu.cpp @@ -809,6 +858,21 @@ target_sources_grouped( game_controls/vguitextwindow.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_GAMECONTROLS} + PROPERTIES UNITY_GROUP gamecontrols_client +) + +target_sources_grouped( + TARGET client + NAME "Game Controls" + FILES + game_controls/basemodel_panel.h + game_controls/basemodelpanel.h + ${UNITY_SOURCE_GAMECONTROLS} + game_controls/SpectatorGUI.cpp +) + target_sources_grouped( TARGET client NAME "MP3" @@ -1410,68 +1474,32 @@ target_sources_grouped( game_controls/vguitextwindow.h ) -target_sources_grouped( - TARGET client - NAME "Source Files" - FILES - ${CMAKE_SOURCE_DIR}/common/steamid.cpp - # ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse_default.cpp - ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.cpp - ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.h - ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.cpp - ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.h - c_team_objectiveresource.cpp - c_team_objectiveresource.h - c_team_train_watcher.cpp - c_team_train_watcher.h - hud_voicestatus.cpp -) - -target_sources_grouped( - TARGET client - NAME "Source Files\\HL2 DLL" - FILES +set(UNITY_SOURCE_HL2DLL ${CMAKE_SOURCE_DIR}/game/shared/hl2/basehlcombatweapon_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/citadel_effects_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_shareddefs.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_usermessages.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.h ${CMAKE_SOURCE_DIR}/game/shared/script_intro_shared.cpp episodic/c_vort_charge_token.cpp episodic/episodic_screenspaceeffects.cpp - episodic/episodic_screenspaceeffects.h hl2/c_antlion_dust.cpp hl2/c_ar2_explosion.cpp hl2/c_barnacle.cpp hl2/c_barney.cpp hl2/c_basehelicopter.cpp - hl2/c_basehelicopter.h hl2/c_basehlcombatweapon.cpp - hl2/c_basehlcombatweapon.h - hl2/c_basehlplayer.cpp - hl2/c_basehlplayer.h hl2/c_citadel_effects.cpp hl2/c_corpse.cpp - hl2/c_corpse.h hl2/c_env_alyxtemp.cpp hl2/c_env_headcrabcanister.cpp hl2/c_env_starfield.cpp hl2/c_func_tankmortar.cpp - hl2/c_hl2_playerlocaldata.cpp - hl2/c_hl2_playerlocaldata.h hl2/c_info_teleporter_countdown.cpp hl2/c_npc_antlionguard.cpp - hl2/c_npc_combinegunship.cpp hl2/c_npc_manhack.cpp hl2/c_npc_rollermine.cpp hl2/c_plasma_beam_node.cpp hl2/c_prop_combine_ball.cpp - hl2/c_prop_combine_ball.h hl2/c_rotorwash.cpp hl2/c_script_intro.cpp hl2/c_strider.cpp @@ -1481,7 +1509,6 @@ target_sources_grouped( hl2/c_vehicle_airboat.cpp hl2/c_vehicle_cannon.cpp hl2/c_vehicle_crane.cpp - hl2/c_vehicle_crane.h hl2/c_vehicle_prisoner_pod.cpp hl2/c_weapon__stubs_hl2.cpp hl2/c_weapon_crossbow.cpp @@ -1490,7 +1517,6 @@ target_sources_grouped( hl2/fx_hl2_impacts.cpp hl2/fx_hl2_tracers.cpp hl2/hl2_clientmode.cpp - hl2/hl_in_main.cpp hl2/hl_prediction.cpp hl2/hud_ammo.cpp hl2/hud_battery.cpp @@ -1501,57 +1527,105 @@ target_sources_grouped( hl2/hud_poisondamageindicator.cpp hl2/hud_quickinfo.cpp hl2/hud_suitpower.cpp - hl2/hud_suitpower.h - hl2/hud_weaponselection.cpp hl2/hud_zoom.cpp hl2/shieldproxy.cpp hl2/vgui_rootpanel_hl2.cpp hud_squadstatus.cpp ) -target_sources_grouped( - TARGET client - NAME "Source Files\\NEO" - FILES - neo/c_neo_message.cpp - neo/c_neo_message.h - neo/c_neo_npc_dummy.cpp - neo/c_neo_npc_dummy.h - neo/c_neo_player.cpp - neo/c_neo_player.h - neo/c_neo_te_tocflash.cpp - neo/c_neo_te_tocflash.h - neo/neo_fixup_glshaders.cpp - neo/neo_fixup_glshaders.h - neo/c_neo_bloom_controller.cpp - neo/c_neo_killer_damage_infos.h +set_source_files_properties( + ${UNITY_SOURCE_HL2DLL} + PROPERTIES UNITY_GROUP hl2dll_client ) target_sources_grouped( TARGET client - NAME "Source Files\\NEO_Vendor" + NAME "Source Files\\HL2 DLL" FILES - neo/vendor_impl.cpp - ${CMAKE_SOURCE_DIR}/vendor/stb_image.h - ${CMAKE_SOURCE_DIR}/vendor/stb_image_resize2.h - ${CMAKE_SOURCE_DIR}/vendor/stb_dxt.h - ${CMAKE_SOURCE_DIR}/vendor/miniaudio.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/citadel_effects_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_shareddefs.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.h + episodic/episodic_screenspaceeffects.h + hl2/c_basehelicopter.h + hl2/c_basehlcombatweapon.h + hl2/c_basehlplayer.h + hl2/c_corpse.h + hl2/c_hl2_playerlocaldata.h + hl2/c_prop_combine_ball.h + hl2/c_vehicle_crane.h + hl2/hud_suitpower.h + hl2/c_hl2_playerlocaldata.cpp + hl2/c_basehlplayer.cpp + ${UNITY_SOURCE_HL2DLL} + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.cpp + hl2/c_npc_combinegunship.cpp + hl2/hl_in_main.cpp + hl2/hud_weaponselection.cpp +) + +set(UNITY_SOURCE_NEO_SRC_CLIENT + neo/c_neo_message.cpp + neo/c_neo_npc_dummy.cpp + neo/c_neo_player.cpp + neo/c_neo_te_tocflash.cpp + neo/neo_fixup_glshaders.cpp + neo/c_neo_bloom_controller.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_SRC_CLIENT} + PROPERTIES UNITY_GROUP neo_src_client ) target_sources_grouped( TARGET client - NAME "Source Files\\NEO\\Game_Controls" + NAME "Source Files\\NEO" + FILES + neo/c_neo_message.h + neo/c_neo_npc_dummy.h + neo/c_neo_player.h + neo/c_neo_te_tocflash.h + neo/neo_fixup_glshaders.h + neo/c_neo_killer_damage_infos.h + ${UNITY_SOURCE_NEO_SRC_CLIENT} +) + +target_sources_grouped( + TARGET client + NAME "Source Files\\NEO_Vendor" FILES + neo/vendor_impl.cpp + ${CMAKE_SOURCE_DIR}/vendor/stb_image.h + ${CMAKE_SOURCE_DIR}/vendor/stb_image_resize2.h + ${CMAKE_SOURCE_DIR}/vendor/stb_dxt.h + ${CMAKE_SOURCE_DIR}/vendor/miniaudio.h +) + +set(UNITY_SOURCE_NEO_GAMECONTROLS neo/game_controls/neo_button.cpp - neo/game_controls/neo_button.h neo/game_controls/neo_classmenu.cpp - neo/game_controls/neo_classmenu.h neo/game_controls/neo_image_button.cpp - neo/game_controls/neo_image_button.h neo/game_controls/neo_loadoutmenu.cpp - neo/game_controls/neo_loadoutmenu.h neo/game_controls/neo_teammenu.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_GAMECONTROLS} + PROPERTIES UNITY_GROUP neo_gamecontrols_client +) + +target_sources_grouped( + TARGET client + NAME "Source Files\\NEO\\Game_Controls" + FILES + neo/game_controls/neo_button.h + neo/game_controls/neo_classmenu.h + neo/game_controls/neo_image_button.h + neo/game_controls/neo_loadoutmenu.h neo/game_controls/neo_teammenu.h + ${UNITY_SOURCE_NEO_GAMECONTROLS} ) target_sources_grouped( @@ -1563,181 +1637,208 @@ target_sources_grouped( neo/material_proxies/neo_matproxy_teamnum.cpp ) +set(UNITY_SOURCE_NEO_UI + neo/ui/neo_root.cpp + neo/ui/neo_root_serverbrowser.cpp + neo/ui/neo_root_settings.cpp + neo/ui/neo_loading.cpp + neo/ui/neo_ui.cpp + neo/ui/neo_theme.cpp + neo/ui/neo_utils.cpp + neo/ui/OverrideInterface.cpp + neo/ui/neo_hud_ammo.cpp + neo/ui/neo_hud_childelement.cpp + neo/ui/neo_hud_compass.cpp + neo/ui/neo_hud_damage_indicator.cpp + neo/ui/neo_hud_deathnotice.cpp + neo/ui/neo_hud_friendly_marker.cpp + neo/ui/neo_hud_game_event.cpp + neo/ui/neo_hud_ghost_beacons.cpp + neo/ui/neo_hud_ghost_cap_point.cpp + neo/ui/neo_hud_ghost_marker.cpp + neo/ui/neo_hud_killer_damage_info.cpp + neo/ui/neo_hud_ghost_uplink_state.cpp + neo/ui/neo_hud_health_thermoptic_aux.cpp + neo/ui/neo_hud_hint.cpp + neo/ui/neo_hud_message.cpp + neo/ui/neo_hud_player_ping.cpp + neo/ui/neo_hud_round_state.cpp + neo/ui/neo_hud_startup_sequence.cpp + neo/ui/neo_hud_worldpos_marker.cpp + neo/ui/neo_hud_worldpos_marker_generic.cpp + neo/ui/neo_scoreboard.cpp + neo/ui/neo_hud_context_hint.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_UI} + PROPERTIES UNITY_GROUP neo_ui_client +) + target_sources_grouped( TARGET client NAME "Source Files\\NEO\\UI" FILES - neo/ui/neo_root.cpp neo/ui/neo_root.h - neo/ui/neo_root_serverbrowser.cpp neo/ui/neo_root_serverbrowser.h - neo/ui/neo_root_settings.cpp neo/ui/neo_root_settings.h - neo/ui/neo_loading.cpp neo/ui/neo_loading.h - neo/ui/neo_ui.cpp neo/ui/neo_ui.h - neo/ui/neo_theme.cpp neo/ui/neo_theme.h - neo/ui/neo_utils.cpp neo/ui/neo_utils.h neo/ui/IOverrideInterface.h - neo/ui/OverrideInterface.cpp - neo/ui/neo_hud_ammo.cpp neo/ui/neo_hud_ammo.h - neo/ui/neo_hud_childelement.cpp neo/ui/neo_hud_childelement.h - neo/ui/neo_hud_compass.cpp neo/ui/neo_hud_compass.h - neo/ui/neo_hud_damage_indicator.cpp - neo/ui/neo_hud_deathnotice.cpp - neo/ui/neo_hud_friendly_marker.cpp neo/ui/neo_hud_friendly_marker.h - neo/ui/neo_hud_game_event.cpp neo/ui/neo_hud_game_event.h - neo/ui/neo_hud_ghost_beacons.cpp neo/ui/neo_hud_ghost_beacons.h - neo/ui/neo_hud_ghost_cap_point.cpp neo/ui/neo_hud_ghost_cap_point.h - neo/ui/neo_hud_ghost_marker.cpp neo/ui/neo_hud_ghost_marker.h - neo/ui/neo_hud_killer_damage_info.cpp neo/ui/neo_hud_killer_damage_info.h - neo/ui/neo_hud_ghost_uplink_state.cpp neo/ui/neo_hud_ghost_uplink_state.h - neo/ui/neo_hud_health_thermoptic_aux.cpp neo/ui/neo_hud_health_thermoptic_aux.h - neo/ui/neo_hud_hint.cpp neo/ui/neo_hud_hint.h - neo/ui/neo_hud_message.cpp neo/ui/neo_hud_message.h - neo/ui/neo_hud_player_ping.cpp neo/ui/neo_hud_player_ping.h - neo/ui/neo_hud_round_state.cpp neo/ui/neo_hud_round_state.h - neo/ui/neo_hud_startup_sequence.cpp neo/ui/neo_hud_startup_sequence.h - neo/ui/neo_hud_worldpos_marker.cpp neo/ui/neo_hud_worldpos_marker.h - neo/ui/neo_hud_worldpos_marker_generic.cpp neo/ui/neo_hud_worldpos_marker_generic.h - neo/ui/neo_scoreboard.cpp neo/ui/neo_scoreboard.h - neo/ui/neo_hud_context_hint.cpp neo/ui/neo_hud_context_hint.h + ${UNITY_SOURCE_NEO_UI} +) + +set(UNITY_SOURCE_NEO_SHARED + ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_SHARED} + PROPERTIES UNITY_GROUP neo_shared_client ) target_sources_grouped( TARGET client NAME "Source Files\\Shared" FILES - ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_enums.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.h + ${UNITY_SOURCE_NEO_SHARED} +) + +set(UNITY_SOURCE_NEO_WEAPONS + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_WEAPONS} + PROPERTIES UNITY_GROUP neo_weapons_client ) target_sources_grouped( TARGET client NAME "Source Files\\Shared\\Weapons" FILES - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.h ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_types.h + ${UNITY_SOURCE_NEO_WEAPONS} ) if(NEO_BUILD_WEAPON_PBK56S) @@ -1758,68 +1859,95 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/Multiplayer/multiplayer_animstate.h ) -target_sources_grouped( - TARGET client - NAME "HL2MP" - FILES +set(UNITY_SOURCE_HL2MP ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.h hl2mp/c_hl2mp_player.cpp - hl2mp/c_hl2mp_player.h hl2mp/c_te_hl2mp_shotgun_shot.cpp hl2mp/clientmode_hl2mpnormal.cpp - hl2mp/clientmode_hl2mpnormal.h +) + +set_source_files_properties( + ${UNITY_SOURCE_HL2MP} + PROPERTIES UNITY_GROUP hl2mp_client ) target_sources_grouped( TARGET client - NAME "HL2MP\\Weapons" + NAME "HL2MP" FILES + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.h + hl2mp/c_hl2mp_player.h + hl2mp/clientmode_hl2mpnormal.h + ${UNITY_SOURCE_HL2MP} +) + +set(UNITY_SOURCE_HL2MP_WEAPONS #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_357.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.cpp - #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_crossbow.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_crowbar.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_frag.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasebasebludgeon.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_pistol.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_shotgun.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.cpp - #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_smg1.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_stunstick.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_HL2MP_WEAPONS} + PROPERTIES UNITY_GROUP hl2mp_weapons_client +) + target_sources_grouped( TARGET client - NAME "HL2MP\\UI" + NAME "HL2MP\\Weapons" FILES + #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.h + #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.h + ${UNITY_SOURCE_HL2MP_WEAPONS} +) + +set(UNITY_SOURCE_HL2MP_UI hl2mp/hl2mp_hud_chat.cpp - hl2mp/hl2mp_hud_chat.h #hl2mp/hl2mp_hud_target_id.cpp hl2mp/hl2mp_hud_team.cpp hl2mp/ui/backgroundpanel.cpp - hl2mp/ui/backgroundpanel.h hl2mp/ui/hl2mpclientscoreboard.cpp - hl2mp/ui/hl2mpclientscoreboard.h hl2mp/ui/hl2mptextwindow.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_HL2MP_UI} + PROPERTIES UNITY_GROUP hl2mp_ui_client +) + +target_sources_grouped( + TARGET client + NAME "HL2MP\\UI" + FILES + hl2mp/hl2mp_hud_chat.h + hl2mp/ui/backgroundpanel.h + hl2mp/ui/hl2mpclientscoreboard.h hl2mp/ui/hl2mptextwindow.h + ${UNITY_SOURCE_HL2MP_UI} ) target_sources_grouped( diff --git a/src/game/client/c_fire_smoke.cpp b/src/game/client/c_fire_smoke.cpp index 7e2aa05496..43c3c1d7cb 100644 --- a/src/game/client/c_fire_smoke.cpp +++ b/src/game/client/c_fire_smoke.cpp @@ -116,6 +116,17 @@ void C_FireSmoke::Simulate( void ) { } +#ifdef NEO // Unity build +#ifdef FLAME_ALPHA_START +#undef FLAME_ALPHA_START +#endif +#ifdef FLAME_ALPHA_END +#undef FLAME_ALPHA_END +#endif +#ifdef FLAME_TRANS_START +#undef FLAME_TRANS_START +#endif +#endif // NEO #define FLAME_ALPHA_START 0.9f #define FLAME_ALPHA_END 1.0f diff --git a/src/game/client/c_impact_effects.cpp b/src/game/client/c_impact_effects.cpp index 6a44385a84..7b11aa3743 100644 --- a/src/game/client/c_impact_effects.cpp +++ b/src/game/client/c_impact_effects.cpp @@ -478,6 +478,24 @@ void FX_DebrisFlecks( const Vector& origin, trace_t *tr, char materialType, int #endif } +#ifdef NEO // Unity build +#ifdef GLASS_SHARD_MIN_LIFE +#undef GLASS_SHARD_MIN_LIFE +#endif +#ifdef GLASS_SHARD_MAX_LIFE +#undef GLASS_SHARD_MAX_LIFE +#endif +#ifdef GLASS_SHARD_NOISE +#undef GLASS_SHARD_NOISE +#endif +#ifdef GLASS_SHARD_GRAVITY +#undef GLASS_SHARD_GRAVITY +#endif +#ifdef GLASS_SHARD_DAMPING +#undef GLASS_SHARD_DAMPING +#endif +#endif // NEO + #define GLASS_SHARD_MIN_LIFE 2.5f #define GLASS_SHARD_MAX_LIFE 5.0f #define GLASS_SHARD_NOISE 0.8 diff --git a/src/game/client/c_lightglow.cpp b/src/game/client/c_lightglow.cpp index 06f20a6cf2..4ebcdf185f 100644 --- a/src/game/client/c_lightglow.cpp +++ b/src/game/client/c_lightglow.cpp @@ -104,7 +104,11 @@ class C_LightGlow : public C_BaseEntity float m_flGlowProxySize; }; +#ifdef NEO // Unity build +static void RecvProxy_HDRColorScaleLightGlow( const CRecvProxyData *pData, void *pStruct, void *pOut ) +#else static void RecvProxy_HDRColorScale( const CRecvProxyData *pData, void *pStruct, void *pOut ) +#endif { C_LightGlow *pLightGlow = ( C_LightGlow * )pStruct; @@ -123,7 +127,11 @@ IMPLEMENT_CLIENTCLASS_DT_NOBASE( C_LightGlow, DT_LightGlow, CLightGlow ) RecvPropQAngles( RECVINFO_NAME( m_angNetworkAngles, m_angRotation ) ), RecvPropInt( RECVINFO_NAME(m_hNetworkMoveParent, moveparent), 0, RecvProxy_IntToMoveParent ), RecvPropFloat(RECVINFO(m_flGlowProxySize)), +#ifdef NEO // Unity build + RecvPropFloat("HDRColorScale", 0, SIZEOF_IGNORE, 0, RecvProxy_HDRColorScaleLightGlow), +#else RecvPropFloat("HDRColorScale", 0, SIZEOF_IGNORE, 0, RecvProxy_HDRColorScale), +#endif END_RECV_TABLE() //----------------------------------------------------------------------------- diff --git a/src/game/client/c_plasma.cpp b/src/game/client/c_plasma.cpp index 01c85ed5f4..a735374eda 100644 --- a/src/game/client/c_plasma.cpp +++ b/src/game/client/c_plasma.cpp @@ -17,6 +17,11 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#ifdef NEO // Unity build +#ifdef NUM_CHILD_FLAMES +#undef NUM_CHILD_FLAMES +#endif +#endif #define NUM_CHILD_FLAMES 6 #define CHILD_SPREAD 40 @@ -239,6 +244,17 @@ void C_Plasma::AddEntity( void ) m_entGlow.SetLocalOriginDim( Z_INDEX, m_entGlow.GetLocalOriginDim( Z_INDEX ) + ( dScale * 32.0f ) ); } +#ifdef NEO // Unity build +#ifdef FLAME_ALPHA_START +#undef FLAME_ALPHA_START +#endif +#ifdef FLAME_ALPHA_END +#undef FLAME_ALPHA_END +#endif +#ifdef FLAME_TRANS_START +#undef FLAME_TRANS_START +#endif +#endif // NEO #define FLAME_ALPHA_START 0.8f #define FLAME_ALPHA_END 1.0f diff --git a/src/game/client/c_sun.cpp b/src/game/client/c_sun.cpp index 265bb53a58..e59bfea6a1 100644 --- a/src/game/client/c_sun.cpp +++ b/src/game/client/c_sun.cpp @@ -10,7 +10,11 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#ifdef NEO // Unity build +static void RecvProxy_HDRColorScaleSun( const CRecvProxyData *pData, void *pStruct, void *pOut ) +#else static void RecvProxy_HDRColorScale( const CRecvProxyData *pData, void *pStruct, void *pOut ) +#endif { C_Sun *pSun = ( C_Sun * )pStruct; @@ -28,7 +32,11 @@ IMPLEMENT_CLIENTCLASS_DT_NOBASE( C_Sun, DT_Sun, CSun ) RecvPropInt( RECVINFO( m_nOverlaySize ) ), RecvPropInt( RECVINFO( m_nMaterial ) ), RecvPropInt( RECVINFO( m_nOverlayMaterial ) ), +#ifdef NEO // Unity build + RecvPropFloat("HDRColorScale", 0, SIZEOF_IGNORE, 0, RecvProxy_HDRColorScaleSun), +#else RecvPropFloat("HDRColorScale", 0, SIZEOF_IGNORE, 0, RecvProxy_HDRColorScale), +#endif END_RECV_TABLE() diff --git a/src/game/client/c_te_explosion.cpp b/src/game/client/c_te_explosion.cpp index 3424bf00c3..c028e14976 100644 --- a/src/game/client/c_te_explosion.cpp +++ b/src/game/client/c_te_explosion.cpp @@ -293,7 +293,11 @@ void C_TEExplosion::SimulateParticles( CParticleSimulateIterator *pIterator ) void TE_Explosion( IRecipientFilter& filter, float delay, const Vector* pos, int modelindex, float scale, int framerate, int flags, int radius, int magnitude, +#ifdef NEO // Unity build + const Vector* normal, unsigned char materialType, bool bShouldAffectRagdolls ) +#else const Vector* normal = NULL, unsigned char materialType = 'C', bool bShouldAffectRagdolls = true ) +#endif { // Major hack to access singleton object for doing this event (simulate receiving network message) __g_C_TEExplosion.m_nModelIndex = modelindex; diff --git a/src/game/client/c_te_glassshatter.cpp b/src/game/client/c_te_glassshatter.cpp index 9cd5cd6f72..9997b8c4ca 100644 --- a/src/game/client/c_te_glassshatter.cpp +++ b/src/game/client/c_te_glassshatter.cpp @@ -17,6 +17,24 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#ifdef NEO // Unity build +#ifdef GLASS_SHARD_MIN_LIFE +#undef GLASS_SHARD_MIN_LIFE +#endif +#ifdef GLASS_SHARD_MAX_LIFE +#undef GLASS_SHARD_MAX_LIFE +#endif +#ifdef GLASS_SHARD_NOISE +#undef GLASS_SHARD_NOISE +#endif +#ifdef GLASS_SHARD_GRAVITY +#undef GLASS_SHARD_GRAVITY +#endif +#ifdef GLASS_SHARD_DAMPING +#undef GLASS_SHARD_DAMPING +#endif +#endif // NEO + #define PI 3.14159265359 #define GLASS_SHARD_MIN_LIFE 2 #define GLASS_SHARD_MAX_LIFE 5 diff --git a/src/game/client/clientsteamcontext.cpp b/src/game/client/clientsteamcontext.cpp index 62376d1847..bde6970a05 100644 --- a/src/game/client/clientsteamcontext.cpp +++ b/src/game/client/clientsteamcontext.cpp @@ -5,6 +5,10 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#if defined(NEO) && defined(_WIN32) // Unity build +#pragma warning(disable : 4355) // warning C4355: 'this': used in base member initializer list +#endif + static CClientSteamContext g_ClientSteamContext; CClientSteamContext &ClientSteamContext() { @@ -132,4 +136,4 @@ void CClientSteamContext::InvokeCallbacks( const SteamLoggedOnChange_t &loggedOn { m_LoggedOnCallbacks[i]( loggedOnStatus ); } -} \ No newline at end of file +} diff --git a/src/game/client/fx_sparks.h b/src/game/client/fx_sparks.h index ef8e2911e4..9b4269b403 100644 --- a/src/game/client/fx_sparks.h +++ b/src/game/client/fx_sparks.h @@ -11,6 +11,10 @@ // $NoKeywords: $ //=============================================================================// +#ifdef NEO // Unity build +#pragma once +#endif + #include "particles_simple.h" #include "particlemgr.h" #include "c_pixel_visibility.h" diff --git a/src/game/client/menu.cpp b/src/game/client/menu.cpp index fcabe7a5b1..5cd4738d0c 100644 --- a/src/game/client/menu.cpp +++ b/src/game/client/menu.cpp @@ -21,6 +21,9 @@ #include #include #include +#ifdef NEO // Unity build +#include "hud_basechat.h" +#endif #define MAX_MENU_STRING 512 wchar_t g_szMenuString[MAX_MENU_STRING]; @@ -42,6 +45,7 @@ DECLARE_HUD_MESSAGE( CHudMenu, ShowMenu ); //----------------------------------------------------- // +#ifndef NEO // Unity build | Defined in hud_basechat.h/cpp static char* ConvertCRtoNL( char *str ) { for ( char *ch = str; *ch != 0; ch++ ) @@ -49,6 +53,7 @@ static char* ConvertCRtoNL( char *str ) *ch = '\n'; return str; } +#endif //----------------------------------------------------------------------------- diff --git a/src/game/client/mp3player.cpp b/src/game/client/mp3player.cpp index 6fb3385d86..c72161cd87 100644 --- a/src/game/client/mp3player.cpp +++ b/src/game/client/mp3player.cpp @@ -24,7 +24,9 @@ #include "vgui/ILocalize.h" #include "vgui_controls/PHandle.h" +#ifndef NEO #include "vgui_controls/PropertySheet.h" +#endif // NEO #include "vgui_controls/PropertyPage.h" #include "vgui_controls/TreeView.h" #include "vgui_controls/FileOpenDialog.h" @@ -522,6 +524,7 @@ void CMP3PlayListPage::OnCommand( char const *cmd ) } } +#ifndef NEO class CMP3FileSheet : public PropertySheet { DECLARE_CLASS_SIMPLE( CMP3FileSheet, PropertySheet ); @@ -579,13 +582,6 @@ class CMP3FileSheet : public PropertySheet } } -#ifdef NEO - CMP3PlayListPage* GetPlayList() - { - return m_pPlayList; - } -#endif // NEO - protected: CMP3Player *m_pPlayer; @@ -612,6 +608,7 @@ CMP3FileSheet::CMP3FileSheet( CMP3Player *player, char const *panelName ) : SetActivePage( m_pPlayList ); } +#endif // NEO class CMP3TreeControl : public TreeView { @@ -825,8 +822,10 @@ CMP3Player::CMP3Player( VPANEL parent, char const *panelName ) : HFont treeFont = pscheme->GetFont( "DefaultVerySmall" ); m_pTree->SetFont( treeFont ); +#ifndef NEO m_pFileSheet = new CMP3FileSheet( this, "FileSheet" ); m_pFileSheet->SetTabWidth(0); +#endif m_pPlay = new Button( this, "Play", "#Play", this, "play" ); #ifdef NEO @@ -900,11 +899,6 @@ CMP3Player::CMP3Player( VPANEL parent, char const *panelName ) : PopulateTree(); m_bFirstTime = false; - int randomSong = m_pFileSheet->GetPlayList()->GetSong(); - if (randomSong >= 0) - { - PlaySong(randomSong); - } #endif // NEO } @@ -1702,16 +1696,6 @@ void CMP3Player::OnPlay() AddToPlayList( songIndex, i == 0 ); } } -#ifdef NEO - if (c == 0) - { // play a random song from the playlist, if any - int randomSong = m_pFileSheet->GetPlayList()->GetSong(); - if (randomSong >= 0) - { - PlaySong(randomSong); - } - } -#endif // NEO } #ifdef NEO @@ -1968,7 +1952,9 @@ void CMP3Player::GoToNextSong( int skip ) } nextSong = m_PlayList[ m_nCurrentPlaylistSong ]; +#ifndef NEO m_pFileSheet->OnPlayListItemPlaying( m_nCurrentPlaylistSong ); +#endif } else { @@ -2116,7 +2102,9 @@ MP3File_t *CMP3Player::GetSongInfo( int songIndex ) void CMP3Player::AddToPlayList( int songIndex, bool playNow ) { +#ifndef NEO m_pFileSheet->AddSongToPlayList( songIndex ); +#endif m_PlayList.AddToTail( songIndex ); if ( playNow ) @@ -2130,7 +2118,9 @@ void CMP3Player::AddToPlayList( int songIndex, bool playNow ) void CMP3Player::RemoveFromPlayList( int songIndex ) { +#ifndef NEO m_pFileSheet->RemoveSongFromPlayList( songIndex ); +#endif m_PlayList.FindAndRemove( songIndex ); SetPlayListSong( m_nCurrentPlaylistSong ); @@ -2138,7 +2128,9 @@ void CMP3Player::RemoveFromPlayList( int songIndex ) void CMP3Player::ClearPlayList() { +#ifndef NEO m_pFileSheet->ResetPlayList(); +#endif m_PlayList.RemoveAll(); m_nCurrentPlaylistSong = 0; } @@ -2476,7 +2468,6 @@ void CMP3Player::LoadPlayList( char const *filename ) #ifdef NEO // Clear existing playlist m_PlayList.RemoveAll(); - m_pFileSheet->ResetPlayList(); // Update most recent playlist SetMostRecentPlayList(filename); @@ -2543,9 +2534,6 @@ void CMP3Player::LoadPlayList( char const *filename ) if ( songIndex >= 0 ) { m_PlayList.AddToTail( songIndex ); -#ifdef NEO - m_pFileSheet->AddSongToPlayList( songIndex ); -#endif // NEO } } } diff --git a/src/game/client/mp3player.h b/src/game/client/mp3player.h index 2229ca91d2..f88111f132 100644 --- a/src/game/client/mp3player.h +++ b/src/game/client/mp3player.h @@ -34,7 +34,9 @@ namespace vgui class DirectorySelectDialog; }; +#ifndef NEO class CMP3FileSheet; +#endif class CMP3TreeControl; class CMP3SongProgress; @@ -341,7 +343,9 @@ class CMP3Player : public vgui::Frame // UI elements vgui::MenuButton *m_pOptions; CMP3TreeControl *m_pTree; +#ifndef NEO CMP3FileSheet *m_pFileSheet; +#endif vgui::Label *m_pCurrentSong; vgui::Label *m_pDuration; CMP3SongProgress *m_pSongProgress; diff --git a/src/game/client/neo/ui/IOverrideInterface.h b/src/game/client/neo/ui/IOverrideInterface.h index c3d07cdd5d..49bd072232 100644 --- a/src/game/client/neo/ui/IOverrideInterface.h +++ b/src/game/client/neo/ui/IOverrideInterface.h @@ -1,3 +1,5 @@ +#pragma once + #include namespace vgui diff --git a/src/game/client/neo/ui/neo_loading.cpp b/src/game/client/neo/ui/neo_loading.cpp index 2a3cd32e16..bb4159598a 100644 --- a/src/game/client/neo/ui/neo_loading.cpp +++ b/src/game/client/neo/ui/neo_loading.cpp @@ -15,7 +15,7 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" -inline NeoUI::Context g_uiCtx; +extern NeoUI::Context g_uiCtx; CNeoLoading::CNeoLoading() : vgui::EditablePanel(nullptr, "NeoLoadingPanel") diff --git a/src/game/client/vgui_avatarimage.cpp b/src/game/client/vgui_avatarimage.cpp index 18f8d635d8..3756ba940d 100644 --- a/src/game/client/vgui_avatarimage.cpp +++ b/src/game/client/vgui_avatarimage.cpp @@ -17,6 +17,9 @@ DECLARE_BUILD_FACTORY( CAvatarImagePanel ); +#if defined(NEO) && defined(_WIN32) // Unity build +#pragma warning(disable : 4355) // warning C4355: 'this': used in base member initializer list +#endif CUtlMap< AvatarImagePair_t, int> CAvatarImage::s_AvatarImageCache; // cache of steam id's to textureids to use for images bool CAvatarImage::m_sbInitializedAvatarCache = false; diff --git a/src/game/client/viewpostprocess.cpp b/src/game/client/viewpostprocess.cpp index 75592feb32..c6bcb2713f 100644 --- a/src/game/client/viewpostprocess.cpp +++ b/src/game/client/viewpostprocess.cpp @@ -87,7 +87,11 @@ ConVar mat_tonemap_algorithm( "mat_tonemap_algorithm", "1", FCVAR_CHEAT, "0 = Or ConVar mat_tonemap_percent_target( "mat_tonemap_percent_target", "60.0", FCVAR_CHEAT ); ConVar mat_tonemap_percent_bright_pixels( "mat_tonemap_percent_bright_pixels", "2.0", FCVAR_CHEAT ); ConVar mat_tonemap_min_avglum( "mat_tonemap_min_avglum", "3.0", FCVAR_CHEAT ); +#ifdef NEO // Unity build +extern ConVar mat_fullbright; +#else ConVar mat_fullbright( "mat_fullbright", "0", FCVAR_CHEAT ); +#endif #ifdef NEO ConVar mat_neo_ssao_enable("mat_neo_ssao_enable", "0", FCVAR_ARCHIVE, "Whether to use SSAO.", true, 0.0f, true, 1.0f); diff --git a/src/game/server/CMakeLists.txt b/src/game/server/CMakeLists.txt index 48b93f0ca3..1e94e2605c 100644 --- a/src/game/server/CMakeLists.txt +++ b/src/game/server/CMakeLists.txt @@ -1,6 +1,10 @@ add_library(server SHARED) -set_target_properties(server PROPERTIES PREFIX "") +set_target_properties(server PROPERTIES + PREFIX "" + UNITY_BUILD ON + UNITY_BUILD_MODE GROUP +) if(NEO_DEDICATED AND OS_LINUX) set_target_properties(server PROPERTIES OUTPUT_NAME server_srv) @@ -128,14 +132,12 @@ if(NEO_BUILD_REPLAY) ) endif() -set(SOURCE_FILES_WITHOUT_PCH +set(UNITY_SOURCE_FILES_WITHOUT_PCH ${CMAKE_SOURCE_DIR}/common/language.cpp ${CMAKE_SOURCE_DIR}/common/randoverride.cpp ${CMAKE_SOURCE_DIR}/game/shared/interval.cpp ${CMAKE_SOURCE_DIR}/game/shared/sheetsimulator.cpp - ${CMAKE_SOURCE_DIR}/public/tier0/memoverride.cpp ${CMAKE_SOURCE_DIR}/public/ScratchPadUtils.cpp - ${CMAKE_SOURCE_DIR}/public/bone_setup.cpp ${CMAKE_SOURCE_DIR}/public/collisionutils.cpp ${CMAKE_SOURCE_DIR}/public/dt_send.cpp ${CMAKE_SOURCE_DIR}/public/dt_utlvector_common.cpp @@ -148,7 +150,6 @@ set(SOURCE_FILES_WITHOUT_PCH ${CMAKE_SOURCE_DIR}/public/networkvar.cpp ${CMAKE_SOURCE_DIR}/public/registry.cpp ${CMAKE_SOURCE_DIR}/public/rope_physics.cpp - ${CMAKE_SOURCE_DIR}/public/scratchpad3d.cpp ${CMAKE_SOURCE_DIR}/public/server_class.cpp ${CMAKE_SOURCE_DIR}/public/simple_physics.cpp ${CMAKE_SOURCE_DIR}/public/stringregistry.cpp @@ -159,473 +160,282 @@ set(SOURCE_FILES_WITHOUT_PCH init_factory.cpp ) -target_sources_grouped( - TARGET server - NAME "Source Files" - FILES - ${CMAKE_SOURCE_DIR}/common/steamid.cpp - ${CMAKE_SOURCE_DIR}/common/hl2orange.spa.h - ${CMAKE_SOURCE_DIR}/game/server/serverbenchmark_base.cpp - ${CMAKE_SOURCE_DIR}/game/server/serverbenchmark_base.h - ${CMAKE_SOURCE_DIR}/game/server/vote_controller.cpp - ${CMAKE_SOURCE_DIR}/game/server/vote_controller.h - ${CMAKE_SOURCE_DIR}/game/server/player_voice_listener.cpp - ${CMAKE_SOURCE_DIR}/game/server/player_voice_listener.h +set_source_files_properties( + ${UNITY_SOURCE_FILES_WITHOUT_PCH} + PROPERTIES + UNITY_GROUP without_pch_server +) + +set(SOURCE_FILES_WITHOUT_PCH + ${UNITY_SOURCE_FILES_WITHOUT_PCH} + ${CMAKE_SOURCE_DIR}/public/bone_setup.cpp + ${CMAKE_SOURCE_DIR}/public/tier0/memoverride.cpp + ${CMAKE_SOURCE_DIR}/public/scratchpad3d.cpp +) + +set(UNITY_SOURCE_SHARED ${CMAKE_SOURCE_DIR}/game/shared/EntityParticleTrail_Shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/GameStats.cpp ${CMAKE_SOURCE_DIR}/game/shared/ModelSoundsCache.cpp ${CMAKE_SOURCE_DIR}/game/shared/SceneCache.cpp - ${CMAKE_SOURCE_DIR}/game/shared/SharedFunctorUtils.h ${CMAKE_SOURCE_DIR}/game/shared/SoundEmitterSystem.cpp ${CMAKE_SOURCE_DIR}/game/shared/Sprite.cpp - ${CMAKE_SOURCE_DIR}/game/shared/Sprite.h - ${CMAKE_SOURCE_DIR}/game/shared/SpriteTrail.h ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.cpp - ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.h ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.cpp - ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.h ${CMAKE_SOURCE_DIR}/game/shared/achievements_hlx.cpp ${CMAKE_SOURCE_DIR}/game/shared/activitylist.cpp - ${CMAKE_SOURCE_DIR}/game/shared/activitylist.h - ${CMAKE_SOURCE_DIR}/game/shared/ai_activity.h - ${CMAKE_SOURCE_DIR}/game/shared/ai_debug_shared.h ${CMAKE_SOURCE_DIR}/game/shared/ammodef.cpp ${CMAKE_SOURCE_DIR}/game/shared/animation.cpp - ${CMAKE_SOURCE_DIR}/game/shared/animation.h - ${CMAKE_SOURCE_DIR}/game/shared/apparent_velocity_helper.h ${CMAKE_SOURCE_DIR}/game/shared/base_playeranimstate.cpp ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.h ${CMAKE_SOURCE_DIR}/game/shared/basecombatcharacter_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/basecombatweapon_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/basecombatweapon_shared.h ${CMAKE_SOURCE_DIR}/game/shared/baseentity_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseentity_shared.h ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.h ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.cpp - ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.h ${CMAKE_SOURCE_DIR}/game/shared/baseparticleentity.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseparticleentity.h ${CMAKE_SOURCE_DIR}/game/shared/baseplayer_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseplayer_shared.h ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.h ${CMAKE_SOURCE_DIR}/game/shared/baseviewmodel_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/baseviewmodel_shared.h ${CMAKE_SOURCE_DIR}/game/shared/beam_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/beam_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/choreoactor.h - ${CMAKE_SOURCE_DIR}/game/shared/choreochannel.h - ${CMAKE_SOURCE_DIR}/game/shared/choreoevent.h - ${CMAKE_SOURCE_DIR}/game/shared/choreoscene.h ${CMAKE_SOURCE_DIR}/game/shared/collisionproperty.cpp - ${CMAKE_SOURCE_DIR}/game/shared/collisionproperty.h ${CMAKE_SOURCE_DIR}/game/shared/death_pose.cpp ${CMAKE_SOURCE_DIR}/game/shared/debugoverlay_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/debugoverlay_shared.h ${CMAKE_SOURCE_DIR}/game/shared/decals.cpp - ${CMAKE_SOURCE_DIR}/game/shared/effect_color_tables.h ${CMAKE_SOURCE_DIR}/game/shared/effect_dispatch_data.cpp ${CMAKE_SOURCE_DIR}/game/shared/ehandle.cpp ${CMAKE_SOURCE_DIR}/game/shared/entitylist_base.cpp - ${CMAKE_SOURCE_DIR}/game/shared/entityparticletrail_shared.h ${CMAKE_SOURCE_DIR}/game/shared/env_detail_controller.cpp ${CMAKE_SOURCE_DIR}/game/shared/env_wind_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/env_wind_shared.h ${CMAKE_SOURCE_DIR}/game/shared/eventlist.cpp - ${CMAKE_SOURCE_DIR}/game/shared/eventlist.h - ${CMAKE_SOURCE_DIR}/game/shared/func_dust_shared.h ${CMAKE_SOURCE_DIR}/game/shared/func_ladder.cpp ${CMAKE_SOURCE_DIR}/game/shared/gamemovement.cpp - ${CMAKE_SOURCE_DIR}/game/shared/gamemovement.h ${CMAKE_SOURCE_DIR}/game/shared/gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/gamerules_register.cpp - ${CMAKE_SOURCE_DIR}/game/shared/gamestats.h ${CMAKE_SOURCE_DIR}/game/shared/gamestringpool.cpp - ${CMAKE_SOURCE_DIR}/game/shared/gamestringpool.h ${CMAKE_SOURCE_DIR}/game/shared/gamevars_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/gamevars_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hintmessage.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hintmessage.h ${CMAKE_SOURCE_DIR}/game/shared/hintsystem.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hintsystem.h - ${CMAKE_SOURCE_DIR}/game/shared/ichoreoeventcallback.h ${CMAKE_SOURCE_DIR}/game/shared/igamesystem.cpp - ${CMAKE_SOURCE_DIR}/game/shared/igamesystem.h - ${CMAKE_SOURCE_DIR}/game/shared/interval.h - ${CMAKE_SOURCE_DIR}/game/shared/iscenetokenprocessor.h ${CMAKE_SOURCE_DIR}/game/shared/mapentities_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/movevars_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/mp_shareddefs.cpp ${CMAKE_SOURCE_DIR}/game/shared/multiplay_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/multiplay_gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/obstacle_pushaway.cpp - ${CMAKE_SOURCE_DIR}/game/shared/obstacle_pushaway.h ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.cpp - ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.h ${CMAKE_SOURCE_DIR}/game/shared/particlesystemquery.cpp ${CMAKE_SOURCE_DIR}/game/shared/physics_main_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/physics_saverestore.cpp - ${CMAKE_SOURCE_DIR}/game/shared/physics_saverestore.h ${CMAKE_SOURCE_DIR}/game/shared/physics_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/physics_shared.h ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.cpp - ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.h ${CMAKE_SOURCE_DIR}/game/shared/point_posecontroller.cpp - ${CMAKE_SOURCE_DIR}/game/shared/point_posecontroller.h - ${CMAKE_SOURCE_DIR}/game/shared/positionwatcher.h ${CMAKE_SOURCE_DIR}/game/shared/precache_register.cpp - ${CMAKE_SOURCE_DIR}/game/shared/precache_register.h ${CMAKE_SOURCE_DIR}/game/shared/predictableid.cpp - ${CMAKE_SOURCE_DIR}/game/shared/predictableid.h ${CMAKE_SOURCE_DIR}/game/shared/props_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/querycache.cpp ${CMAKE_SOURCE_DIR}/game/shared/ragdoll_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/rope_helpers.cpp ${CMAKE_SOURCE_DIR}/game/shared/saverestore.cpp - ${CMAKE_SOURCE_DIR}/game/shared/saverestore.h - ${CMAKE_SOURCE_DIR}/game/shared/saverestore_bitstring.h - ${CMAKE_SOURCE_DIR}/game/shared/saverestore_utlsymbol.h - ${CMAKE_SOURCE_DIR}/game/shared/saverestore_utlvector.h ${CMAKE_SOURCE_DIR}/game/shared/sceneentity_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/scriptevent.h ${CMAKE_SOURCE_DIR}/game/shared/sequence_Transitioner.cpp - ${CMAKE_SOURCE_DIR}/game/shared/sheetsimulator.h ${CMAKE_SOURCE_DIR}/game/shared/simtimer.cpp - ${CMAKE_SOURCE_DIR}/game/shared/simtimer.h ${CMAKE_SOURCE_DIR}/game/shared/singleplay_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/singleplay_gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/soundenvelope.cpp ${CMAKE_SOURCE_DIR}/game/shared/studio_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/takedamageinfo.cpp ${CMAKE_SOURCE_DIR}/game/shared/teamplay_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/teamplay_gamerules.h - ${CMAKE_SOURCE_DIR}/game/shared/tempentity.h ${CMAKE_SOURCE_DIR}/game/shared/test_ehandle.cpp ${CMAKE_SOURCE_DIR}/game/shared/usercmd.cpp ${CMAKE_SOURCE_DIR}/game/shared/util_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/vehicle_viewblend_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/voice_common.h ${CMAKE_SOURCE_DIR}/game/shared/voice_gamemgr.cpp - ${CMAKE_SOURCE_DIR}/game/shared/voice_gamemgr.h ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse.cpp - ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse.h ${CMAKE_SOURCE_DIR}/game/shared/weapon_proficiency.cpp - ${CMAKE_SOURCE_DIR}/game/shared/weapon_proficiency.h - ${CMAKE_SOURCE_DIR}/public/SoundParametersInternal.cpp - ${CMAKE_SOURCE_DIR}/public/bone_setup.h - ${CMAKE_SOURCE_DIR}/public/collisionutils.h - ${CMAKE_SOURCE_DIR}/public/edict.h - ${CMAKE_SOURCE_DIR}/public/editor_sendcommand.h - ${CMAKE_SOURCE_DIR}/public/eiface.h - ${CMAKE_SOURCE_DIR}/public/event_flags.h - ${CMAKE_SOURCE_DIR}/public/haptics/haptic_msgs.cpp - ${CMAKE_SOURCE_DIR}/public/interpolatortypes.h - ${CMAKE_SOURCE_DIR}/public/iregistry.h - ${CMAKE_SOURCE_DIR}/public/ivoiceserver.h - ${CMAKE_SOURCE_DIR}/public/keyframe/keyframe.h - ${CMAKE_SOURCE_DIR}/public/mathlib/mathlib.h - ${CMAKE_SOURCE_DIR}/public/mathlib/polyhedron.h - ${CMAKE_SOURCE_DIR}/public/mathlib/vmatrix.h - ${CMAKE_SOURCE_DIR}/public/model_types.h - ${CMAKE_SOURCE_DIR}/public/networkstringtabledefs.h - ${CMAKE_SOURCE_DIR}/public/rope_physics.h - ${CMAKE_SOURCE_DIR}/public/rope_shared.h - ${CMAKE_SOURCE_DIR}/public/server_class.h - ${CMAKE_SOURCE_DIR}/public/shattersurfacetypes.h - ${CMAKE_SOURCE_DIR}/public/simple_physics.h - ${CMAKE_SOURCE_DIR}/public/steam/steam_api.h - ${CMAKE_SOURCE_DIR}/public/steam/steamclientpublic.h - ${CMAKE_SOURCE_DIR}/public/stringregistry.h - ${CMAKE_SOURCE_DIR}/public/vphysics/performance.h - ${CMAKE_SOURCE_DIR}/public/vphysics/stats.h - ${SOURCE_FILES_WITHOUT_PCH} +) + +set_source_files_properties( + ${UNITY_SOURCE_SHARED} + PROPERTIES UNITY_GROUP shared_server +) + +set(UNITY_SOURCE_SRC_SERVER + ${CMAKE_SOURCE_DIR}/game/shared/hl2/survival_gamerules.cpp + ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.cpp + ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.cpp + ${CMAKE_SOURCE_DIR}/game/shared/teamplayroundbased_gamerules.cpp + ai_relationship.cpp + basegrenade_concussion.cpp + basegrenade_contact.cpp + basegrenade_timed.cpp + grenadethrown.cpp + h_cycler.cpp + hl2/Func_Monitor.cpp + monstermaker.cpp + team_control_point.cpp + team_control_point_master.cpp + team_control_point_round.cpp + team_objectiveresource.cpp + team_spawnpoint.cpp + team_train_watcher.cpp + trigger_area_capture.cpp + AI_Criteria.cpp - AI_Criteria.h AI_Interest_Target.cpp - AI_Interest_Target.h AI_ResponseSystem.cpp - AI_ResponseSystem.h BaseAnimatingOverlay.cpp - BaseAnimatingOverlay.h - BasePropDoor.h CRagdollMagnet.cpp - CRagdollMagnet.h CommentarySystem.cpp EffectsServer.cpp EntityDissolve.cpp - EntityDissolve.h EntityFlame.cpp EntityParticleTrail.cpp - EntityParticleTrail.h EnvBeam.cpp EnvFade.cpp EnvHudHint.cpp EnvLaser.cpp - EnvLaser.h EnvMessage.cpp - EnvMessage.h EnvShake.cpp EnvSpark.cpp EventLog.cpp MaterialModifyControl.cpp PointAngularVelocitySensor.cpp RagdollBoogie.cpp - RagdollBoogie.h ServerNetworkProperty.cpp - ServerNetworkProperty.h SkyCamera.cpp TemplateEntities.cpp - TemplateEntities.h WaterLODControl.cpp ai_activity.cpp ai_baseactor.cpp - ai_baseactor.h ai_basehumanoid.cpp - ai_basehumanoid.h ai_basenpc.cpp - ai_basenpc.h ai_basenpc_flyer.cpp - ai_basenpc_flyer.h ai_basenpc_flyer_new.cpp - ai_basenpc_flyer_new.h ai_basenpc_movement.cpp ai_basenpc_physicsflyer.cpp - ai_basenpc_physicsflyer.h ai_basenpc_schedule.cpp ai_basenpc_squad.cpp ai_behavior.cpp - ai_behavior.h ai_behavior_assault.cpp - ai_behavior_assault.h ai_behavior_fear.cpp - ai_behavior_fear.h ai_behavior_follow.cpp - ai_behavior_follow.h ai_behavior_lead.cpp - ai_behavior_lead.h ai_behavior_rappel.cpp - ai_behavior_rappel.h ai_behavior_standoff.cpp - ai_behavior_standoff.h ai_blended_movement.cpp - ai_blended_movement.h - ai_component.h ai_concommands.cpp ai_condition.cpp - ai_condition.h - ai_debug.h ai_default.cpp - ai_default.h ai_dynamiclink.cpp - ai_dynamiclink.h ai_event.cpp ai_goalentity.cpp - ai_goalentity.h ai_hint.cpp - ai_hint.h ai_hull.cpp - ai_hull.h ai_initutils.cpp - ai_initutils.h ai_link.cpp - ai_link.h ai_localnavigator.cpp - ai_localnavigator.h ai_looktarget.cpp - ai_looktarget.h ai_memory.cpp - ai_memory.h ai_motor.cpp - ai_motor.h ai_moveprobe.cpp - ai_moveprobe.h ai_moveshoot.cpp - ai_moveshoot.h ai_movesolver.cpp - ai_movesolver.h - ai_movetypes.h ai_namespaces.cpp - ai_namespaces.h - ai_navgoaltype.h ai_navigator.cpp - ai_navigator.h - ai_navtype.h ai_network.cpp - ai_network.h ai_networkmanager.cpp - ai_networkmanager.h ai_node.cpp - ai_node.h - ai_npcstate.h - ai_obstacle_type.h ai_pathfinder.cpp - ai_pathfinder.h ai_planesolver.cpp - ai_planesolver.h ai_playerally.cpp - ai_playerally.h ai_route.cpp - ai_route.h - ai_routedist.h ai_saverestore.cpp - ai_saverestore.h ai_schedule.cpp - ai_schedule.h ai_scriptconditions.cpp - ai_scriptconditions.h ai_senses.cpp - ai_senses.h ai_sentence.cpp - ai_sentence.h ai_speech.cpp - ai_speech.h ai_speechfilter.cpp - ai_speechfilter.h ai_squad.cpp - ai_squad.h ai_squadslot.cpp - ai_squadslot.h ai_tacticalservices.cpp - ai_tacticalservices.h ai_task.cpp - ai_task.h ai_trackpather.cpp - ai_trackpather.h ai_utils.cpp - ai_utils.h ai_waypoint.cpp - ai_waypoint.h base_transmit_proxy.cpp baseanimating.cpp - baseanimating.h basecombatcharacter.cpp - basecombatcharacter.h basecombatweapon.cpp - basecombatweapon.h - baseentity.cpp - baseentity.h baseflex.cpp - baseflex.h basemultiplayerplayer.cpp - basemultiplayerplayer.h - basetoggle.h baseviewmodel.cpp - baseviewmodel.h bitstring.cpp - bitstring.h bmodels.cpp buttons.cpp - buttons.h cbase.cpp - cbase.h client.cpp - client.h colorcorrection.cpp colorcorrectionvolume.cpp controlentities.cpp cplane.cpp damagemodifier.cpp doors.cpp - doors.h dynamiclight.cpp effects.cpp - effects.h - enginecallback.h - entityapi.h entityblocker.cpp - entityblocker.h - entityinput.h entitylist.cpp - entitylist.h - entityoutput.h env_debughistory.cpp - env_debughistory.h env_effectsscript.cpp env_entity_maker.cpp env_particlescript.cpp env_player_surface_trigger.cpp - env_player_surface_trigger.h env_projectedtexture.cpp env_screenoverlay.cpp env_texturetoggle.cpp env_tonemap_controller.cpp env_zoom.cpp - env_zoom.h envmicrophone.cpp - envmicrophone.h - envspark.h - event_tempentity_tester.h - eventqueue.h explode.cpp - explode.h filters.cpp - filters.h fire.cpp - fire.h fire_smoke.cpp - fire_smoke.h fish.cpp - fish.h fogcontroller.cpp fourwheelvehiclephysics.cpp - fourwheelvehiclephysics.h func_areaportal.cpp func_areaportalbase.cpp - func_areaportalbase.h func_areaportalwindow.cpp - func_areaportalwindow.h func_break.cpp - func_break.h func_breakablesurf.cpp - func_breakablesurf.h func_dust.cpp func_ladder_endpoint.cpp func_lod.cpp func_movelinear.cpp - func_movelinear.h func_occluder.cpp func_reflective_glass.cpp func_smokevolume.cpp game.cpp - game.h game_ui.cpp gameinterface.cpp - gameinterface.h gametrace_dll.cpp gameweaponmanager.cpp - gameweaponmanager.h genericactor.cpp genericmonster.cpp gib.cpp - gib.h globals.cpp globalstate.cpp - globalstate.h - globalstate_private.h guntarget.cpp h_ai.cpp hierarchy.cpp - hierarchy.h hltvdirector.cpp - hltvdirector.h info_camera_link.cpp - info_camera_link.h info_overlay_accessor.cpp - init_factory.h intermission.cpp - iservervehicle.h item_world.cpp - items.h lightglow.cpp lights.cpp - lights.h - locksounds.h logic_achievement.cpp logic_eventlistener.cpp - logic_eventlistener.h logic_measure_movement.cpp logic_navigation.cpp logicauto.cpp @@ -633,105 +443,68 @@ target_sources_grouped( logicrelay.cpp mapentities.cpp maprules.cpp - maprules.h message_entity.cpp modelentities.cpp movehelper_server.cpp - movehelper_server.h movement.cpp - movie_explosion.h ndebugoverlay.cpp - ndebugoverlay.h - networkstringtable_gamedll.h npc_vehicledriver.cpp - particle_fire.h particle_light.cpp - particle_light.h - particle_smokegrenade.h particle_system.cpp pathcorner.cpp pathtrack.cpp - pathtrack.h phys_controller.cpp - phys_controller.h physconstraint.cpp - physconstraint.h physics.cpp - physics.h physics_bone_follower.cpp physics_cannister.cpp - physics_collisionevent.h physics_fx.cpp physics_impact_damage.cpp physics_main.cpp physics_npc_solver.cpp - physics_npc_solver.h physics_prop_ragdoll.cpp - physics_prop_ragdoll.h physobj.cpp - physobj.h player.cpp - player.h player_command.cpp - player_command.h player_lagcompensation.cpp player_pickup.cpp - player_pickup.h player_resource.cpp - player_resource.h playerinfomanager.cpp playerlocaldata.cpp - playerlocaldata.h plugin_check.cpp point_camera.cpp - point_camera.h point_devshot_camera.cpp point_playermoveconstraint.cpp point_spotlight.cpp point_template.cpp - point_template.h point_worldtext.cpp - point_worldtext.h pointanglesensor.cpp pointhurt.cpp pointteleport.cpp props.cpp - props.h - pushentity.h ragdoll_manager.cpp recipientfilter.cpp - recipientfilter.h rope.cpp - rope.h saverestore_gamedll.cpp sceneentity.cpp - sceneentity.h scratchpad_gamedll_helpers.cpp scripted.cpp - scripted.h scriptedtarget.cpp - scriptedtarget.h sendproxy.cpp shadowcontrol.cpp skyboxswapper.cpp slideshow_display.cpp sound.cpp soundent.cpp - soundent.h soundscape.cpp - soundscape.h soundscape_system.cpp - spark.h spotlightend.cpp - spotlightend.h sprite_perfmonitor.cpp subs.cpp sun.cpp tactical_mission.cpp - tactical_mission.h tanktrain.cpp team.cpp - team.h tempmonster.cpp tesla.cpp test_proxytoggle.cpp @@ -741,23 +514,302 @@ target_sources_grouped( textstatsmgr.cpp timedeventmgr.cpp trains.cpp - trains.h triggers.cpp - triggers.h util.cpp - util.h variant_t.cpp vehicle_base.cpp vehicle_baseserver.cpp - vehicle_sounds.h vguiscreen.cpp - vguiscreen.h waterbullet.cpp - waterbullet.h wcedit.cpp - wcedit.h weight_button.cpp world.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_SRC_SERVER} + PROPERTIES UNITY_GROUP src_server +) + +target_sources_grouped( + TARGET server + NAME "Source Files" + FILES + ${CMAKE_SOURCE_DIR}/common/steamid.cpp + ${CMAKE_SOURCE_DIR}/common/hl2orange.spa.h + ${CMAKE_SOURCE_DIR}/game/server/serverbenchmark_base.cpp + ${CMAKE_SOURCE_DIR}/game/server/serverbenchmark_base.h + ${CMAKE_SOURCE_DIR}/game/server/vote_controller.cpp + ${CMAKE_SOURCE_DIR}/game/server/vote_controller.h + ${CMAKE_SOURCE_DIR}/game/server/player_voice_listener.cpp + ${CMAKE_SOURCE_DIR}/game/server/player_voice_listener.h + ${CMAKE_SOURCE_DIR}/game/shared/SharedFunctorUtils.h + ${CMAKE_SOURCE_DIR}/game/shared/Sprite.h + ${CMAKE_SOURCE_DIR}/game/shared/SpriteTrail.h + ${CMAKE_SOURCE_DIR}/game/shared/achievement_saverestore.h + ${CMAKE_SOURCE_DIR}/game/shared/achievementmgr.h + ${CMAKE_SOURCE_DIR}/game/shared/activitylist.h + ${CMAKE_SOURCE_DIR}/game/shared/ai_activity.h + ${CMAKE_SOURCE_DIR}/game/shared/ai_debug_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/animation.h + ${CMAKE_SOURCE_DIR}/game/shared/apparent_velocity_helper.h + ${CMAKE_SOURCE_DIR}/game/shared/baseachievement.h + ${CMAKE_SOURCE_DIR}/game/shared/basecombatweapon_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/baseentity_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/basegrenade_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/sdk/sdk_basegrenade_projectile.h + ${CMAKE_SOURCE_DIR}/game/shared/baseparticleentity.h + ${CMAKE_SOURCE_DIR}/game/shared/baseplayer_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/baseprojectile.h + ${CMAKE_SOURCE_DIR}/game/shared/baseviewmodel_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/beam_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/choreoactor.h + ${CMAKE_SOURCE_DIR}/game/shared/choreochannel.h + ${CMAKE_SOURCE_DIR}/game/shared/choreoevent.h + ${CMAKE_SOURCE_DIR}/game/shared/choreoscene.h + ${CMAKE_SOURCE_DIR}/game/shared/collisionproperty.h + ${CMAKE_SOURCE_DIR}/game/shared/debugoverlay_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/effect_color_tables.h + ${CMAKE_SOURCE_DIR}/game/shared/entityparticletrail_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/env_wind_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/eventlist.h + ${CMAKE_SOURCE_DIR}/game/shared/func_dust_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/gamemovement.h + ${CMAKE_SOURCE_DIR}/game/shared/gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/gamestats.h + ${CMAKE_SOURCE_DIR}/game/shared/gamestringpool.h + ${CMAKE_SOURCE_DIR}/game/shared/gamevars_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hintmessage.h + ${CMAKE_SOURCE_DIR}/game/shared/hintsystem.h + ${CMAKE_SOURCE_DIR}/game/shared/ichoreoeventcallback.h + ${CMAKE_SOURCE_DIR}/game/shared/igamesystem.h + ${CMAKE_SOURCE_DIR}/game/shared/interval.h + ${CMAKE_SOURCE_DIR}/game/shared/iscenetokenprocessor.h + ${CMAKE_SOURCE_DIR}/game/shared/multiplay_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/obstacle_pushaway.h + ${CMAKE_SOURCE_DIR}/game/shared/particle_parse.h + ${CMAKE_SOURCE_DIR}/game/shared/physics_saverestore.h + ${CMAKE_SOURCE_DIR}/game/shared/physics_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/point_bonusmaps_accessor.h + ${CMAKE_SOURCE_DIR}/game/shared/point_posecontroller.h + ${CMAKE_SOURCE_DIR}/game/shared/positionwatcher.h + ${CMAKE_SOURCE_DIR}/game/shared/precache_register.h + ${CMAKE_SOURCE_DIR}/game/shared/predictableid.h + ${CMAKE_SOURCE_DIR}/game/shared/saverestore.h + ${CMAKE_SOURCE_DIR}/game/shared/saverestore_bitstring.h + ${CMAKE_SOURCE_DIR}/game/shared/saverestore_utlsymbol.h + ${CMAKE_SOURCE_DIR}/game/shared/saverestore_utlvector.h + ${CMAKE_SOURCE_DIR}/game/shared/scriptevent.h + ${CMAKE_SOURCE_DIR}/game/shared/sheetsimulator.h + ${CMAKE_SOURCE_DIR}/game/shared/simtimer.h + ${CMAKE_SOURCE_DIR}/game/shared/singleplay_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/teamplay_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/tempentity.h + ${CMAKE_SOURCE_DIR}/game/shared/voice_common.h + ${CMAKE_SOURCE_DIR}/game/shared/voice_gamemgr.h + ${CMAKE_SOURCE_DIR}/game/shared/weapon_parse.h + ${CMAKE_SOURCE_DIR}/game/shared/weapon_proficiency.h + ${UNITY_SOURCE_SHARED} + baseentity.cpp # Due to gamedata-gen sdkhook + ${CMAKE_SOURCE_DIR}/public/SoundParametersInternal.cpp + ${CMAKE_SOURCE_DIR}/public/bone_setup.h + ${CMAKE_SOURCE_DIR}/public/collisionutils.h + ${CMAKE_SOURCE_DIR}/public/edict.h + ${CMAKE_SOURCE_DIR}/public/editor_sendcommand.h + ${CMAKE_SOURCE_DIR}/public/eiface.h + ${CMAKE_SOURCE_DIR}/public/event_flags.h + ${CMAKE_SOURCE_DIR}/public/haptics/haptic_msgs.cpp + ${CMAKE_SOURCE_DIR}/public/interpolatortypes.h + ${CMAKE_SOURCE_DIR}/public/iregistry.h + ${CMAKE_SOURCE_DIR}/public/ivoiceserver.h + ${CMAKE_SOURCE_DIR}/public/keyframe/keyframe.h + ${CMAKE_SOURCE_DIR}/public/mathlib/mathlib.h + ${CMAKE_SOURCE_DIR}/public/mathlib/polyhedron.h + ${CMAKE_SOURCE_DIR}/public/mathlib/vmatrix.h + ${CMAKE_SOURCE_DIR}/public/model_types.h + ${CMAKE_SOURCE_DIR}/public/networkstringtabledefs.h + ${CMAKE_SOURCE_DIR}/public/rope_physics.h + ${CMAKE_SOURCE_DIR}/public/rope_shared.h + ${CMAKE_SOURCE_DIR}/public/server_class.h + ${CMAKE_SOURCE_DIR}/public/shattersurfacetypes.h + ${CMAKE_SOURCE_DIR}/public/simple_physics.h + ${CMAKE_SOURCE_DIR}/public/steam/steam_api.h + ${CMAKE_SOURCE_DIR}/public/steam/steamclientpublic.h + ${CMAKE_SOURCE_DIR}/public/stringregistry.h + ${CMAKE_SOURCE_DIR}/public/vphysics/performance.h + ${CMAKE_SOURCE_DIR}/public/vphysics/stats.h + ${SOURCE_FILES_WITHOUT_PCH} + ${UNITY_SOURCE_SRC_SERVER} + AI_Criteria.h + AI_Interest_Target.h + AI_ResponseSystem.h + BaseAnimatingOverlay.h + BasePropDoor.h + CRagdollMagnet.h + EntityDissolve.h + EntityParticleTrail.h + EnvLaser.h + EnvMessage.h + RagdollBoogie.h + ai_behavior_rappel.h + ServerNetworkProperty.h + TemplateEntities.h + ai_baseactor.h + ai_basehumanoid.h + ai_basenpc.h + ai_basenpc_flyer.h + ai_basenpc_flyer_new.h + ai_basenpc_physicsflyer.h + ai_behavior.h + items.h + ai_behavior_assault.h + ai_behavior_fear.h + ai_behavior_follow.h + ai_behavior_lead.h + ai_behavior_standoff.h + ai_blended_movement.h + ai_component.h + ai_condition.h + ai_debug.h + ai_default.h + ai_dynamiclink.h + ai_goalentity.h + ai_hint.h + ai_hull.h + ai_initutils.h + ai_link.h + ai_localnavigator.h + ai_looktarget.h + ai_memory.h + ai_motor.h + ai_moveprobe.h + ai_moveshoot.h + ai_movesolver.h + ai_movetypes.h + ai_namespaces.h + ai_navgoaltype.h + ai_navigator.h + ai_navtype.h + ai_network.h + ai_networkmanager.h + ai_node.h + ai_npcstate.h + ai_obstacle_type.h + ai_pathfinder.h + ai_planesolver.h + ai_playerally.h + ai_route.h + ai_routedist.h + ai_saverestore.h + ai_schedule.h + ai_scriptconditions.h + ai_senses.h + ai_sentence.h + ai_speech.h + ai_speechfilter.h + ai_squad.h + ai_squadslot.h + ai_tacticalservices.h + ai_task.h + ai_trackpather.h + ai_utils.h + ai_waypoint.h + baseanimating.h + basecombatcharacter.h + basecombatweapon.h + baseentity.h + baseflex.h + basemultiplayerplayer.h + basetoggle.h + baseviewmodel.h + bitstring.h + buttons.h + cbase.h + client.h + doors.h + effects.h + enginecallback.h + entityapi.h + entityblocker.h + entityinput.h + entitylist.h + entityoutput.h + env_debughistory.h + env_player_surface_trigger.h + env_zoom.h + envmicrophone.h + envspark.h + event_tempentity_tester.h + eventqueue.h + explode.h + filters.h + fire.h + fire_smoke.h + fish.h + fourwheelvehiclephysics.h + func_areaportalbase.h + func_areaportalwindow.h + func_break.h + func_breakablesurf.h + func_movelinear.h + game.h + gameinterface.h + gameweaponmanager.h + gib.h + globalstate.h + globalstate_private.h + hierarchy.h + hltvdirector.h + info_camera_link.h + init_factory.h + iservervehicle.h + lights.h + locksounds.h + logic_eventlistener.h + maprules.h + movehelper_server.h + movie_explosion.h + ndebugoverlay.h + networkstringtable_gamedll.h + particle_fire.h + particle_light.h + particle_smokegrenade.h + pathtrack.h + phys_controller.h + physconstraint.h + physics.h + physics_collisionevent.h + physics_npc_solver.h + physics_prop_ragdoll.h + physobj.h + player.h + player_command.h + player_pickup.h + player_resource.h + playerlocaldata.h + point_camera.h + point_template.h + point_worldtext.h + props.h + pushentity.h + recipientfilter.h + rope.h + sceneentity.h + scripted.h + scriptedtarget.h + soundent.h + soundscape.h + spark.h + spotlightend.h + tactical_mission.h + team.h + trains.h + triggers.h + util.h + vehicle_sounds.h + vguiscreen.h + waterbullet.h + wcedit.h world.h ) @@ -790,10 +842,7 @@ if(OS_WINDOWS) ) endif() -target_sources_grouped( - TARGET server - NAME "Temporary Entities" - FILES +set(UNITY_SOURCE_TEMPORARY_ENTITIES ${CMAKE_SOURCE_DIR}/game/shared/SpriteTrail.cpp ${CMAKE_SOURCE_DIR}/game/shared/usermessages.cpp basetempentity.cpp @@ -803,18 +852,12 @@ target_sources_grouped( particle_fire.cpp particle_smokegrenade.cpp plasma.cpp - plasma.h smoke_trail.cpp - smoke_trail.h smokestack.cpp - smokestack.h steamjet.cpp - steamjet.h te.cpp - te.h te_armorricochet.cpp te_basebeam.cpp - te_basebeam.h te_beamentpoint.cpp te_beaments.cpp te_beamfollow.cpp @@ -844,7 +887,6 @@ target_sources_grouped( te_largefunnel.cpp te_muzzleflash.cpp te_particlesystem.cpp - te_particlesystem.h te_physicsprop.cpp te_playerdecal.cpp te_projecteddecal.cpp @@ -856,6 +898,25 @@ target_sources_grouped( te_worlddecal.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_TEMPORARY_ENTITIES} + PROPERTIES UNITY_GROUP temporary_entities_server +) + +target_sources_grouped( + TARGET server + NAME "Temporary Entities" + FILES + plasma.h + smoke_trail.h + smokestack.h + steamjet.h + te.h + te_basebeam.h + te_particlesystem.h + ${UNITY_SOURCE_TEMPORARY_ENTITIES} +) + target_sources_grouped( TARGET server NAME "Header Files" @@ -1085,513 +1146,552 @@ target_sources_grouped( toolframework_server.h ) -target_sources_grouped( - TARGET server - NAME "Source Files\\Navigation Mesh" - FILES - nav.h +set(UNITY_SOURCE_NAVIGATION_MESH nav_area.cpp - nav_area.h nav_colors.cpp - nav_colors.h nav_edit.cpp nav_entities.cpp - nav_entities.h nav_file.cpp nav_generate.cpp nav_ladder.cpp - nav_ladder.h nav_merge.cpp nav_mesh.cpp - nav_mesh.h nav_mesh_factory.cpp nav_node.cpp - nav_node.h - nav_pathfind.h nav_simplify.cpp ) -target_sources_grouped( - TARGET server - NAME "Source Files" - FILES - ${CMAKE_SOURCE_DIR}/game/shared/hl2/survival_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.cpp - ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.h - ${CMAKE_SOURCE_DIR}/game/shared/ragdoll_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/solidsetdefaults.h - ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.cpp - ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.h - ${CMAKE_SOURCE_DIR}/game/shared/teamplayroundbased_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/touchlink.h - EntityFlame.h - ai_relationship.cpp - basegrenade_concussion.cpp - basegrenade_contact.cpp - basegrenade_timed.cpp - grenadethrown.cpp - grenadethrown.h - h_cycler.cpp - h_cycler.h - hl2/Func_Monitor.cpp - monstermaker.cpp - monstermaker.h - physics_bone_follower.h - team_control_point.cpp - team_control_point.h - team_control_point_master.cpp - team_control_point_master.h - team_control_point_round.cpp - team_control_point_round.h - team_objectiveresource.cpp - team_objectiveresource.h - team_spawnpoint.cpp - team_spawnpoint.h - team_train_watcher.cpp - team_train_watcher.h - trigger_area_capture.cpp - trigger_area_capture.h +set_source_files_properties( + ${UNITY_SOURCE_NAVIGATION_MESH} + PROPERTIES UNITY_GROUP navigation_mesh_server ) target_sources_grouped( TARGET server - NAME "HL2 DLL" + NAME "Source Files\\Navigation Mesh" FILES + nav.h + nav_area.h + nav_colors.h + nav_entities.h + nav_ladder.h + nav_mesh.h + nav_node.h + nav_pathfind.h + ${UNITY_SOURCE_NAVIGATION_MESH} +) + +set(UNITY_SOURCE_HL2DLL ${CMAKE_SOURCE_DIR}/game/shared/hl2/basehlcombatweapon_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/basehlcombatweapon_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/citadel_effects_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_alyxemp_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_player_shared.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_shareddefs.h ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_usermessages.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.h - ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_movedata.h ${CMAKE_SOURCE_DIR}/game/shared/script_intro_shared.cpp ${CMAKE_SOURCE_DIR}/game/shared/vscript_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/vscript_shared.h - ${CMAKE_SOURCE_DIR}/game/server/vscript_server.cpp - ${CMAKE_SOURCE_DIR}/game/server/vscript_server.h ${CMAKE_SOURCE_DIR}/game/server/netpropmanager.cpp - ${CMAKE_SOURCE_DIR}/game/server/netpropmanager.h basebludgeonweapon.cpp - basebludgeonweapon.h hl2/ai_allymanager.cpp hl2/ai_behavior_actbusy.cpp - hl2/ai_behavior_actbusy.h hl2/ai_behavior_functank.cpp - hl2/ai_behavior_functank.h hl2/ai_behavior_holster.cpp - hl2/ai_behavior_holster.h hl2/ai_behavior_police.cpp - hl2/ai_behavior_police.h hl2/ai_goal_police.cpp - hl2/ai_goal_police.h - hl2/ai_interactions.h hl2/ai_spotlight.cpp - hl2/ai_spotlight.h hl2/antlion_dust.cpp - hl2/antlion_dust.h hl2/antlion_maker.cpp - hl2/antlion_maker.h hl2/ar2_explosion.cpp - hl2/ar2_explosion.h hl2/basehlcombatweapon.cpp - hl2/basehlcombatweapon.h hl2/cbasehelicopter.cpp - hl2/cbasehelicopter.h hl2/cbasespriteprojectile.cpp - hl2/cbasespriteprojectile.h hl2/citadel_effects.cpp hl2/combine_mine.cpp - hl2/combine_mine.h - hl2/energy_wave.h hl2/env_alyxemp.cpp hl2/env_headcrabcanister.cpp hl2/env_speaker.cpp hl2/env_starfield.cpp hl2/func_recharge.cpp hl2/func_tank.cpp - hl2/func_tank.h hl2/grenade_ar2.cpp - hl2/grenade_ar2.h hl2/grenade_bugbait.cpp - hl2/grenade_bugbait.h hl2/grenade_frag.cpp - hl2/grenade_frag.h hl2/hl2_ai_network.cpp hl2/hl2_eventlog.cpp - hl2/hl2_player.cpp - hl2/hl2_player.h - hl2/hl2_playerlocaldata.cpp - hl2/hl2_playerlocaldata.h hl2/hl2_triggers.cpp hl2/hl_playermove.cpp hl2/info_teleporter_countdown.cpp hl2/item_ammo.cpp hl2/item_battery.cpp hl2/item_dynamic_resupply.cpp - hl2/item_dynamic_resupply.h hl2/item_healthkit.cpp hl2/item_itemcrate.cpp hl2/item_suit.cpp hl2/look_door.cpp hl2/monster_dummy.cpp hl2/npc_BaseZombie.cpp - hl2/npc_BaseZombie.h hl2/npc_PoisonZombie.cpp hl2/npc_alyx.cpp - hl2/npc_alyx.h hl2/npc_antlion.cpp - hl2/npc_antlion.h hl2/npc_antlionguard.cpp hl2/npc_apcdriver.cpp hl2/npc_attackchopper.cpp - hl2/npc_attackchopper.h hl2/npc_barnacle.cpp - hl2/npc_barnacle.h hl2/npc_barney.cpp hl2/npc_basescanner.cpp - hl2/npc_basescanner.h hl2/npc_breen.cpp hl2/npc_bullseye.cpp - hl2/npc_bullseye.h #hl2/npc_citizen17.cpp - #hl2/npc_citizen17.h hl2/npc_combine.cpp - hl2/npc_combine.h hl2/npc_combinecamera.cpp hl2/npc_combinedropship.cpp hl2/npc_combinegunship.cpp hl2/npc_combines.cpp - hl2/npc_combines.h hl2/npc_cranedriver.cpp hl2/npc_crow.cpp - hl2/npc_crow.h hl2/npc_dog.cpp hl2/npc_eli.cpp hl2/npc_enemyfinder.cpp hl2/npc_fisherman.cpp hl2/npc_gman.cpp hl2/npc_headcrab.cpp - hl2/npc_headcrab.h hl2/npc_ichthyosaur.cpp hl2/npc_kleiner.cpp hl2/npc_launcher.cpp hl2/npc_manhack.cpp - hl2/npc_manhack.h hl2/npc_metropolice.cpp - hl2/npc_metropolice.h hl2/npc_monk.cpp hl2/npc_mossman.cpp hl2/npc_playercompanion.cpp - hl2/npc_playercompanion.h hl2/npc_rollermine.cpp - hl2/npc_rollermine.h hl2/npc_scanner.cpp hl2/npc_stalker.cpp - hl2/npc_stalker.h hl2/npc_strider.cpp - hl2/npc_strider.h - hl2/npc_turret_ceiling.cpp hl2/npc_turret_floor.cpp hl2/npc_turret_ground.cpp hl2/npc_vortigaunt_episodic.cpp - hl2/npc_vortigaunt_episodic.h hl2/npc_zombie.cpp hl2/point_apc_controller.cpp hl2/prop_combine_ball.cpp - hl2/prop_combine_ball.h hl2/prop_thumper.cpp hl2/proto_sniper.cpp hl2/rotorwash.cpp - hl2/rotorwash.h hl2/script_intro.cpp - hl2/script_intro.h hl2/vehicle_airboat.cpp - hl2/vehicle_apc.h hl2/vehicle_crane.cpp - hl2/vehicle_crane.h hl2/vehicle_prisoner_pod.cpp hl2/vehicle_viewcontroller.cpp - hl2/weapon_alyxgun.h #hl2/weapon_annabelle.cpp hl2/weapon_bugbait.cpp - #hl2/weapon_crowbar.h npc_talker.cpp - npc_talker.h weapon_cubemap.cpp + + ${CMAKE_SOURCE_DIR}/game/shared/predicted_viewmodel.h + ${CMAKE_SOURCE_DIR}/game/shared/ragdoll_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/solidsetdefaults.h + ${CMAKE_SOURCE_DIR}/game/shared/teamplay_round_timer.h + ${CMAKE_SOURCE_DIR}/game/shared/touchlink.h + EntityFlame.h + grenadethrown.h + h_cycler.h + monstermaker.h + physics_bone_follower.h + team_control_point.h + team_control_point_master.h + team_control_point_round.h + team_objectiveresource.h + team_spawnpoint.h + team_train_watcher.h + trigger_area_capture.h +) + +set_source_files_properties( + ${UNITY_SOURCE_HL2DLL} + PROPERTIES UNITY_GROUP hl2dll_server ) target_sources_grouped( TARGET server - NAME "Unused" + NAME "HL2 DLL" FILES + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.cpp + ${CMAKE_SOURCE_DIR}/game/server/vscript_server.cpp + hl2/npc_turret_ceiling.cpp + hl2/hl2_player.cpp + hl2/hl2_playerlocaldata.cpp + ${UNITY_SOURCE_HL2DLL} + ${CMAKE_SOURCE_DIR}/game/shared/hl2/basehlcombatweapon_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/citadel_effects_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_alyxemp_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/env_headcrabcanister_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_player_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl2_shareddefs.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_gamemovement.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2/hl_movedata.h + ${CMAKE_SOURCE_DIR}/game/shared/vscript_shared.h + ${CMAKE_SOURCE_DIR}/game/server/vscript_server.h + ${CMAKE_SOURCE_DIR}/game/server/netpropmanager.h + basebludgeonweapon.h + hl2/ai_behavior_actbusy.h + hl2/ai_behavior_functank.h + hl2/ai_behavior_holster.h + hl2/ai_behavior_police.h + hl2/ai_goal_police.h + hl2/ai_interactions.h + hl2/ai_spotlight.h + hl2/antlion_dust.h + hl2/antlion_maker.h + hl2/ar2_explosion.h + hl2/basehlcombatweapon.h + hl2/cbasehelicopter.h + hl2/cbasespriteprojectile.h + hl2/combine_mine.h + hl2/energy_wave.h + hl2/func_tank.h + hl2/grenade_ar2.h + hl2/grenade_bugbait.h + hl2/grenade_frag.h + hl2/hl2_player.h + hl2/hl2_playerlocaldata.h + hl2/item_dynamic_resupply.h + hl2/npc_BaseZombie.h + hl2/npc_alyx.h + hl2/npc_antlion.h + hl2/npc_attackchopper.h + hl2/npc_barnacle.h + hl2/npc_basescanner.h + hl2/npc_bullseye.h + #hl2/npc_citizen17.h + hl2/npc_combine.h + hl2/npc_combines.h + hl2/npc_crow.h + hl2/npc_headcrab.h + hl2/npc_manhack.h + hl2/npc_metropolice.h + hl2/npc_playercompanion.h + hl2/npc_rollermine.h + hl2/npc_stalker.h + hl2/npc_strider.h + hl2/npc_vortigaunt_episodic.h + hl2/prop_combine_ball.h + hl2/rotorwash.h + hl2/script_intro.h + hl2/vehicle_apc.h + hl2/vehicle_crane.h + hl2/weapon_alyxgun.h + #hl2/weapon_crowbar.h + npc_talker.h +) + +set(UNITY_SOURCE_UNUSED hl2/grenade_beam.cpp - hl2/grenade_beam.h hl2/grenade_homer.cpp - hl2/grenade_homer.h hl2/grenade_pathfollower.cpp - hl2/grenade_pathfollower.h hl2/npc_missiledefense.cpp hl2/vehicle_apc.cpp hl2/weapon_cguard.cpp hl2/weapon_flaregun.cpp - hl2/weapon_flaregun.h +) + +set_source_files_properties( + ${UNITY_SOURCE_UNUSED} + PROPERTIES UNITY_GROUP unused_server ) target_sources_grouped( TARGET server - NAME "NEO" + NAME "Unused" FILES + hl2/grenade_beam.h + hl2/grenade_homer.h + hl2/grenade_pathfollower.h + hl2/weapon_flaregun.h + ${UNITY_SOURCE_UNUSED} +) + +set(UNITY_SOURCE_NEO_SHARED ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_enums.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.h ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.h +) + +set(UNITY_SOURCE_NEO_SRC_SERVER neo/neo_bloom_controller.cpp neo/neo_client.cpp neo/neo_detpack.cpp - neo/neo_detpack.h neo/neo_game_config.cpp - neo/neo_game_config.h neo/neo_ghost_boundary.cpp - neo/neo_ghost_boundary.h neo/neo_ghost_spawn_point.cpp - neo/neo_ghost_spawn_point.h neo/neo_grenade.cpp - neo/neo_grenade.h neo/neo_message.cpp - neo/neo_message.h neo/neo_model_manager.cpp - neo/neo_model_manager.h neo/neo_npc_dummy.cpp - neo/neo_npc_dummy.h neo/neo_npc_targetsystem.cpp - neo/neo_npc_targetsystem.h neo/neo_player.cpp - neo/neo_player.h neo/neo_smokelineofsightblocker.cpp - neo/neo_smokelineofsightblocker.h neo/neo_spawn_manager.cpp - neo/neo_spawn_manager.h neo/neo_smokegrenade.cpp - neo/neo_smokegrenade.h neo/neo_te_tocflash.cpp - neo/neo_te_tocflash.h - neo/neo_tracefilter_collisiongroupdelta.h neo/neo_typeconverter.cpp neo/neo_dm_spawn.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_SHARED} + PROPERTIES UNITY_GROUP neo_shared_server +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_SRC_SERVER} + PROPERTIES UNITY_GROUP neo_src_server +) + +target_sources_grouped( + TARGET server + NAME "NEO" + FILES + ${CMAKE_SOURCE_DIR}/game/shared/neo/achievements_neo.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_ghost_cap_point.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_juggernaut.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_penetration_resistance.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_player_spawnpoint.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_predicted_viewmodel_muzzleflash.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_shot_manipulator.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_version_info.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_misc.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_weapon_loadout.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_worldpos_marker.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_enums.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_crosshair.h + ${CMAKE_SOURCE_DIR}/game/shared/neo/neo_serial.h + ${UNITY_SOURCE_NEO_SHARED} + neo/neo_detpack.h + neo/neo_game_config.h + neo/neo_ghost_boundary.h + neo/neo_ghost_spawn_point.h + neo/neo_grenade.h + neo/neo_message.h + neo/neo_model_manager.h + neo/neo_npc_dummy.h + neo/neo_npc_targetsystem.h + neo/neo_player.h + neo/neo_smokelineofsightblocker.h + neo/neo_spawn_manager.h + neo/neo_smokegrenade.h + neo/neo_te_tocflash.h + neo/neo_tracefilter_collisiongroupdelta.h neo/neo_dm_spawn.h + ${UNITY_SOURCE_NEO_SRC_SERVER} +) + +set(UNITY_SOURCE_NEO_BOT + neo/bot/neo_bot.cpp + neo/bot/neo_bot_path_compute.cpp + neo/bot/neo_bot_path_cost.cpp + neo/bot/neo_bot_path_reservation.cpp + neo/bot/neo_bot_body.cpp + neo/bot/neo_bot_locomotion.cpp + neo/bot/neo_bot_manager.cpp + neo/bot/neo_bot_profile.cpp + neo/bot/neo_bot_squad.cpp + neo/bot/neo_bot_vision.cpp + neo/bot/behavior/neo_bot_approach_object.cpp + neo/bot/behavior/neo_bot_attack.cpp + neo/bot/behavior/neo_bot_behavior.cpp + neo/bot/behavior/neo_bot_command_follow.cpp + neo/bot/behavior/neo_bot_ctg_capture.cpp + neo/bot/behavior/neo_bot_ctg_carrier.cpp + neo/bot/behavior/neo_bot_ctg_enemy.cpp + neo/bot/behavior/neo_bot_ctg_escort.cpp + neo/bot/behavior/neo_bot_ctg_lone_wolf.cpp + neo/bot/behavior/neo_bot_ctg_seek.cpp + neo/bot/behavior/neo_bot_dead.cpp + neo/bot/behavior/neo_bot_grenade_dispatch.cpp + neo/bot/behavior/neo_bot_grenade_throw.cpp + neo/bot/behavior/neo_bot_grenade_throw_frag.cpp + neo/bot/behavior/neo_bot_grenade_throw_smoke.cpp + neo/bot/behavior/neo_bot_jgr_capture.cpp + neo/bot/behavior/neo_bot_jgr_enemy.cpp + neo/bot/behavior/neo_bot_jgr_escort.cpp + neo/bot/behavior/neo_bot_jgr_juggernaut.cpp + neo/bot/behavior/neo_bot_jgr_seek.cpp + neo/bot/behavior/neo_bot_ladder_approach.cpp + neo/bot/behavior/neo_bot_ladder_climb.cpp + neo/bot/behavior/neo_bot_melee_attack.cpp + neo/bot/behavior/neo_bot_move_to_vantage_point.cpp + neo/bot/behavior/neo_bot_path_clear_breakable.cpp + neo/bot/behavior/neo_bot_pause.cpp + neo/bot/behavior/neo_bot_retreat_to_cover.cpp + neo/bot/behavior/neo_bot_retreat_from_grenade.cpp + neo/bot/behavior/neo_bot_scenario_monitor.cpp + neo/bot/behavior/neo_bot_seek_and_destroy.cpp + neo/bot/behavior/neo_bot_seek_weapon.cpp + neo/bot/behavior/neo_bot_tactical_monitor.cpp + neo/bot/behavior/neo_bot_throw_weapon_at_player.cpp + neo/bot/behavior/nav_entities/neo_bot_nav_ent_destroy_entity.cpp + neo/bot/behavior/nav_entities/neo_bot_nav_ent_move_to.cpp + neo/bot/behavior/nav_entities/neo_bot_nav_ent_wait.cpp + neo/bot/map_entities/neo_bot_generator.cpp + neo/bot/map_entities/neo_bot_proxy.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_BOT} + PROPERTIES UNITY_GROUP neo_bot_server ) target_sources_grouped( TARGET server NAME "NEO\\Bot" FILES - neo/bot/neo_bot.cpp neo/bot/neo_bot.h - neo/bot/neo_bot_path_compute.cpp neo/bot/neo_bot_path_compute.h - neo/bot/neo_bot_path_cost.cpp neo/bot/neo_bot_path_cost.h - neo/bot/neo_bot_path_reservation.cpp neo/bot/neo_bot_path_reservation.h - neo/bot/neo_bot_body.cpp neo/bot/neo_bot_body.h neo/bot/neo_bot_contextual_query_interface.h - neo/bot/neo_bot_locomotion.cpp neo/bot/neo_bot_locomotion.h - neo/bot/neo_bot_manager.cpp neo/bot/neo_bot_manager.h - neo/bot/neo_bot_profile.cpp neo/bot/neo_bot_profile.h - neo/bot/neo_bot_squad.cpp neo/bot/neo_bot_squad.h - neo/bot/neo_bot_vision.cpp neo/bot/neo_bot_vision.h - neo/bot/behavior/neo_bot_approach_object.cpp neo/bot/behavior/neo_bot_approach_object.h - neo/bot/behavior/neo_bot_attack.cpp neo/bot/behavior/neo_bot_attack.h - neo/bot/behavior/neo_bot_behavior.cpp neo/bot/behavior/neo_bot_behavior.h - neo/bot/behavior/neo_bot_command_follow.cpp neo/bot/behavior/neo_bot_command_follow.h - neo/bot/behavior/neo_bot_ctg_capture.cpp neo/bot/behavior/neo_bot_ctg_capture.h - neo/bot/behavior/neo_bot_ctg_carrier.cpp neo/bot/behavior/neo_bot_ctg_carrier.h - neo/bot/behavior/neo_bot_ctg_enemy.cpp neo/bot/behavior/neo_bot_ctg_enemy.h - neo/bot/behavior/neo_bot_ctg_escort.cpp neo/bot/behavior/neo_bot_ctg_escort.h - neo/bot/behavior/neo_bot_ctg_lone_wolf.cpp neo/bot/behavior/neo_bot_ctg_lone_wolf.h - neo/bot/behavior/neo_bot_ctg_seek.cpp neo/bot/behavior/neo_bot_ctg_seek.h - neo/bot/behavior/neo_bot_dead.cpp neo/bot/behavior/neo_bot_dead.h - neo/bot/behavior/neo_bot_grenade_dispatch.cpp neo/bot/behavior/neo_bot_grenade_dispatch.h - neo/bot/behavior/neo_bot_grenade_throw.cpp neo/bot/behavior/neo_bot_grenade_throw.h - neo/bot/behavior/neo_bot_grenade_throw_frag.cpp neo/bot/behavior/neo_bot_grenade_throw_frag.h - neo/bot/behavior/neo_bot_grenade_throw_smoke.cpp neo/bot/behavior/neo_bot_grenade_throw_smoke.h - neo/bot/behavior/neo_bot_jgr_capture.cpp neo/bot/behavior/neo_bot_jgr_capture.h - neo/bot/behavior/neo_bot_jgr_enemy.cpp neo/bot/behavior/neo_bot_jgr_enemy.h - neo/bot/behavior/neo_bot_jgr_escort.cpp neo/bot/behavior/neo_bot_jgr_escort.h - neo/bot/behavior/neo_bot_jgr_juggernaut.cpp neo/bot/behavior/neo_bot_jgr_juggernaut.h - neo/bot/behavior/neo_bot_jgr_seek.cpp neo/bot/behavior/neo_bot_jgr_seek.h - neo/bot/behavior/neo_bot_ladder_approach.cpp neo/bot/behavior/neo_bot_ladder_approach.h - neo/bot/behavior/neo_bot_ladder_climb.cpp neo/bot/behavior/neo_bot_ladder_climb.h - neo/bot/behavior/neo_bot_melee_attack.cpp neo/bot/behavior/neo_bot_melee_attack.h - neo/bot/behavior/neo_bot_move_to_vantage_point.cpp neo/bot/behavior/neo_bot_move_to_vantage_point.h - neo/bot/behavior/neo_bot_path_clear_breakable.cpp neo/bot/behavior/neo_bot_path_clear_breakable.h - neo/bot/behavior/neo_bot_pause.cpp neo/bot/behavior/neo_bot_pause.h - neo/bot/behavior/neo_bot_retreat_to_cover.cpp neo/bot/behavior/neo_bot_retreat_to_cover.h - neo/bot/behavior/neo_bot_retreat_from_grenade.cpp neo/bot/behavior/neo_bot_retreat_from_grenade.h - neo/bot/behavior/neo_bot_scenario_monitor.cpp neo/bot/behavior/neo_bot_scenario_monitor.h - neo/bot/behavior/neo_bot_seek_and_destroy.cpp neo/bot/behavior/neo_bot_seek_and_destroy.h - neo/bot/behavior/neo_bot_seek_weapon.cpp neo/bot/behavior/neo_bot_seek_weapon.h - neo/bot/behavior/neo_bot_tactical_monitor.cpp neo/bot/behavior/neo_bot_tactical_monitor.h - neo/bot/behavior/neo_bot_throw_weapon_at_player.cpp neo/bot/behavior/neo_bot_throw_weapon_at_player.h - neo/bot/behavior/nav_entities/neo_bot_nav_ent_destroy_entity.cpp neo/bot/behavior/nav_entities/neo_bot_nav_ent_destroy_entity.h - neo/bot/behavior/nav_entities/neo_bot_nav_ent_move_to.cpp neo/bot/behavior/nav_entities/neo_bot_nav_ent_move_to.h - neo/bot/behavior/nav_entities/neo_bot_nav_ent_wait.cpp neo/bot/behavior/nav_entities/neo_bot_nav_ent_wait.h - neo/bot/map_entities/neo_bot_generator.cpp neo/bot/map_entities/neo_bot_generator.h - neo/bot/map_entities/neo_bot_proxy.cpp neo/bot/map_entities/neo_bot_proxy.h + ${UNITY_SOURCE_NEO_BOT} +) + +set(UNITY_SOURCE_NEO_WEAPONS + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEO_WEAPONS} + PROPERTIES UNITY_GROUP neo_weapons_server ) target_sources_grouped( TARGET server NAME "NEO\\Weapons" FILES - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_detpack.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_ghost.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_grenade.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jitte.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_jittes.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_knife.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_kyla.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41l.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_m41s.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_milso.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpn.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smokegrenade.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srm.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srms.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_srs.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_supa7.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_tachi.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68c.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68l.h - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.h ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_types.h + ${UNITY_SOURCE_NEO_WEAPONS} ) if(NEO_BUILD_WEAPON_PBK56S) @@ -1612,107 +1712,136 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/Multiplayer/multiplayer_animstate.h ) -target_sources_grouped( - TARGET server - NAME "HL2MP" - FILES +set(UNITY_SOURCE_HL2MP ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.h hl2mp/hl2mp_client.cpp hl2mp/hl2mp_cvars.cpp hl2mp/hl2mp_gameinterface.cpp - hl2mp/hl2mp_gameinterface.h hl2mp/hl2mp_player.cpp - hl2mp/hl2mp_player.h ) + +set_source_files_properties( + ${UNITY_SOURCE_HL2MP} + PROPERTIES UNITY_GROUP hl2mp_server +) + target_sources_grouped( TARGET server - NAME "HL2MP\\Weapons" + NAME "HL2MP" FILES + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_gamerules.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_player_shared.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_playeranimstate.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/hl2mp_weapon_parse.h + hl2mp/hl2mp_gameinterface.h + hl2mp/hl2mp_player.h + ${UNITY_SOURCE_HL2MP} +) + +set(UNITY_SOURCE_HL2MP_WEAPONS #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_357.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.cpp - #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_crossbow.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_crowbar.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_frag.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasebasebludgeon.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.h ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_pistol.cpp ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.cpp - ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_shotgun.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.cpp - #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.h #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_smg1.cpp #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_stunstick.cpp hl2mp/grenade_satchel.cpp - hl2mp/grenade_satchel.h hl2mp/grenade_tripmine.cpp - hl2mp/grenade_tripmine.h hl2mp/te_hl2mp_shotgun_shot.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_HL2MP_WEAPONS} + PROPERTIES UNITY_GROUP hl2mp_weapons_server +) + +target_sources_grouped( + TARGET server + NAME "HL2MP\\Weapons" + FILES + #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_ar2.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbase_machinegun.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_hl2mpbasehlmpcombatweapon.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_physcannon.h + ${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_rpg.h + #${CMAKE_SOURCE_DIR}/game/shared/hl2mp/weapon_slam.h + hl2mp/grenade_satchel.h + hl2mp/grenade_tripmine.h hl2mp/te_hl2mp_shotgun_shot.h + ${UNITY_SOURCE_HL2MP_WEAPONS} +) + +set(UNITY_SOURCE_NEXTBOT + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBot.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotManager.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotGroundLocomotion.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/simple_bot.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotBodyInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotComponentInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotIntentionInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotLocomotionInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotVisionInterface.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotChasePath.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPath.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPathFollow.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerBody.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerLocomotion.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayer.cpp + ${CMAKE_SOURCE_DIR}/game/server/NextBot/NavMeshEntities/func_nav_prerequisite.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_NEXTBOT} + PROPERTIES UNITY_GROUP nextbot_server ) + target_sources_grouped( TARGET server NAME "NextBot" FILES - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBot.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBot.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotBehavior.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotManager.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotManager.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotUtil.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotKnownEntity.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotGroundLocomotion.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotGroundLocomotion.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/simple_bot.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/simple_bot.h # NextBotInterfaces - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotBodyInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotBodyInterface.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotComponentInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotComponentInterface.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotEventResponderInterface.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotHearingInterface.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotIntentionInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotIntentionInterface.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotInterface.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotLocomotionInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotLocomotionInterface.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotVisionInterface.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotVisionInterface.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/NextBotContextualQueryInterface.h # NextBotPath - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotChasePath.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotChasePath.h ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotRetreatPath.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPath.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPath.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPathFollow.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Path/NextBotPathFollow.h # NextBotPlayer - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerBody.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerBody.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerLocomotion.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayerLocomotion.h - ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayer.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/Player/NextBotPlayer.h # NextBotCommonBehaviors @@ -1720,6 +1849,7 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/server/NextBot/Behavior/BehaviorMoveTo.h # NextBotNavMeshEntities - ${CMAKE_SOURCE_DIR}/game/server/NextBot/NavMeshEntities/func_nav_prerequisite.cpp ${CMAKE_SOURCE_DIR}/game/server/NextBot/NavMeshEntities/func_nav_prerequisite.h + + ${UNITY_SOURCE_NEXTBOT} ) diff --git a/src/game/server/ServerNetworkProperty.cpp b/src/game/server/ServerNetworkProperty.cpp index 50641b2dca..6dcda310e3 100644 --- a/src/game/server/ServerNetworkProperty.cpp +++ b/src/game/server/ServerNetworkProperty.cpp @@ -13,6 +13,12 @@ // memdbgon must be the last include file in a .cpp file!!! #include "tier0/memdbgon.h" +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif + extern CTimedEventMgr g_NetworkPropertyEventMgr; diff --git a/src/game/server/ServerNetworkProperty.h b/src/game/server/ServerNetworkProperty.h index cb4c386641..2d01f9c08a 100644 --- a/src/game/server/ServerNetworkProperty.h +++ b/src/game/server/ServerNetworkProperty.h @@ -16,6 +16,12 @@ #include "edict.h" #include "timedeventmgr.h" +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif + // // Lightweight base class for networkable data on the server. // diff --git a/src/game/server/ai_basenpc.h b/src/game/server/ai_basenpc.h index 7c65c0cca4..e9dcf1a0d9 100644 --- a/src/game/server/ai_basenpc.h +++ b/src/game/server/ai_basenpc.h @@ -134,6 +134,13 @@ enum Interruptability_t #define bits_MEMORY_CUSTOM2 ( 1 << 30 ) // NPC-specific memory #define bits_MEMORY_CUSTOM1 ( 1 << 31 ) // NPC-specific memory +#ifdef NEO // Unity build +#define bits_MEMORY_PAIN_LIGHT_SOUND bits_MEMORY_CUSTOM1 +#define bits_MEMORY_PAIN_HEAVY_SOUND bits_MEMORY_CUSTOM2 +#define bits_MEMORY_PLAYER_HURT bits_MEMORY_CUSTOM3 +#define bits_MEMORY_PLAYER_HARASSED bits_MEMORY_CUSTOM4 +#endif + //------------------------------------- // Spawn flags //------------------------------------- diff --git a/src/game/server/hl2/grenade_frag.cpp b/src/game/server/hl2/grenade_frag.cpp index 6269311726..81640ce7eb 100644 --- a/src/game/server/hl2/grenade_frag.cpp +++ b/src/game/server/hl2/grenade_frag.cpp @@ -27,6 +27,9 @@ ConVar sk_plr_dmg_fraggrenade ( "sk_plr_dmg_fraggrenade","0"); ConVar sk_npc_dmg_fraggrenade ( "sk_npc_dmg_fraggrenade","0"); ConVar sk_fraggrenade_radius ( "sk_fraggrenade_radius", "0"); +#if defined(NEO) && defined(GRENADE_MODEL) // Unity build +#undef GRENADE_MODEL +#endif #define GRENADE_MODEL "models/Weapons/w_grenade.mdl" class CGrenadeFrag : public CBaseGrenade @@ -421,4 +424,4 @@ bool Fraggrenade_WasCreatedByCombine( const CBaseEntity *pEntity ) } return false; -} \ No newline at end of file +} diff --git a/src/game/server/hl2/item_healthkit.cpp b/src/game/server/hl2/item_healthkit.cpp index 460cc7b5ac..888bad9bc4 100644 --- a/src/game/server/hl2/item_healthkit.cpp +++ b/src/game/server/hl2/item_healthkit.cpp @@ -405,6 +405,14 @@ BEGIN_DATADESC( CNewWallHealth ) END_DATADESC() +#ifdef NEO // Unity build +#ifdef HEALTH_CHARGER_MODEL_NAME +#undef HEALTH_CHARGER_MODEL_NAME +#endif // HEALTH_CHARGER_MODEL_NAME +#ifdef CHARGES_PER_SECOND +#undef CHARGES_PER_SECOND +#endif // CHARGES_PER_SECOND +#endif // NEO #define HEALTH_CHARGER_MODEL_NAME "models/props_combine/health_charger001.mdl" #define CHARGE_RATE 0.25f #define CHARGES_PER_SECOND 1.0f / CHARGE_RATE diff --git a/src/game/server/hl2/npc_combine.cpp b/src/game/server/hl2/npc_combine.cpp index 296df740c7..e68804bd0f 100644 --- a/src/game/server/hl2/npc_combine.cpp +++ b/src/game/server/hl2/npc_combine.cpp @@ -101,7 +101,11 @@ Activity ACT_WALK_MARCH; // ----------------------------------------------- // > Squad slots // ----------------------------------------------- +#ifdef NEO // Unity build +enum SquadSlotNpcCombine_T +#else enum SquadSlot_T +#endif { SQUAD_SLOT_GRENADE1 = LAST_SHARED_SQUADSLOT, SQUAD_SLOT_GRENADE2, @@ -122,9 +126,11 @@ enum PathfindingVariant_T }; +#ifndef NEO // Unity build #define bits_MEMORY_PAIN_LIGHT_SOUND bits_MEMORY_CUSTOM1 #define bits_MEMORY_PAIN_HEAVY_SOUND bits_MEMORY_CUSTOM2 #define bits_MEMORY_PLAYER_HURT bits_MEMORY_CUSTOM3 +#endif LINK_ENTITY_TO_CLASS( npc_combine, CNPC_Combine ); diff --git a/src/game/server/hl2/npc_combinecamera.cpp b/src/game/server/hl2/npc_combinecamera.cpp index 021462bbd9..6ab4162774 100644 --- a/src/game/server/hl2/npc_combinecamera.cpp +++ b/src/game/server/hl2/npc_combinecamera.cpp @@ -92,7 +92,11 @@ enum cameraState_e // Eye states +#ifdef NEO // Unity build +enum eyeStateCombineCamera_t +#else enum eyeState_t +#endif { CAMERA_EYE_IDLE, // Nothing abnormal in the inner or outer viewcone, dim green. CAMERA_EYE_SEEKING_TARGET, // Something in the outer viewcone, flashes amber as it converges on the target. @@ -162,7 +166,11 @@ class CNPC_CombineCamera : public CAI_BaseNPC void TrackTarget(CBaseEntity *pTarget); bool PreThink(cameraState_e state); +#ifdef NEO // Unity build + void SetEyeState(eyeStateCombineCamera_t state); +#else void SetEyeState(eyeState_t state); +#endif void MaintainEye(); void Ping(); void Toggle(); @@ -828,7 +836,11 @@ bool CNPC_CombineCamera::PreThink(cameraState_e state) // Purpose: Sets the state of the glowing eye attached to the camera // Input : state - state the eye should be in //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +void CNPC_CombineCamera::SetEyeState(eyeStateCombineCamera_t state) +#else void CNPC_CombineCamera::SetEyeState(eyeState_t state) +#endif { // Must have a valid eye to affect if (m_pEyeGlow == NULL) diff --git a/src/game/server/hl2/npc_combinedropship.cpp b/src/game/server/hl2/npc_combinedropship.cpp index 7ef929de59..5dad928b09 100644 --- a/src/game/server/hl2/npc_combinedropship.cpp +++ b/src/game/server/hl2/npc_combinedropship.cpp @@ -150,7 +150,11 @@ enum LandingState_t #define DROPSHIP_CONTAINER_MODEL "models/combine_dropship_container.mdl" #define DROPSHIP_CONTAINER_MAX_CHUNKS 3 +#ifdef NEO // Unity build +static const char *s_pChunkModelNameNpcCDS[DROPSHIP_CONTAINER_MAX_CHUNKS] = +#else static const char *s_pChunkModelName[DROPSHIP_CONTAINER_MAX_CHUNKS] = +#endif { "models/gibs/helicopter_brokenpiece_01.mdl", "models/gibs/helicopter_brokenpiece_02.mdl", @@ -428,7 +432,11 @@ void CCombineDropshipContainer::Precache() int i; for ( i = 0; i < DROPSHIP_CONTAINER_MAX_CHUNKS; ++i ) { +#ifdef NEO // Unity build + PrecacheModel( s_pChunkModelNameNpcCDS[i] ); +#else PrecacheModel( s_pChunkModelName[i] ); +#endif } for ( i = 0; i < DROPSHIP_CONTAINER_MAX_GIBS; ++i ) @@ -544,7 +552,11 @@ void CCombineDropshipContainer::ThrowFlamingGib( void ) pChunk->SetAbsAngles( vecSpawnAngles ); int nGib = random->RandomInt( 0, DROPSHIP_CONTAINER_MAX_CHUNKS - 1 ); +#ifdef NEO // Unity build + pChunk->Spawn( s_pChunkModelNameNpcCDS[nGib] ); +#else pChunk->Spawn( s_pChunkModelName[nGib] ); +#endif pChunk->SetOwnerEntity( this ); pChunk->m_lifeTime = random->RandomFloat( 6.0f, 8.0f ); pChunk->SetCollisionGroup( COLLISION_GROUP_DEBRIS ); diff --git a/src/game/server/hl2/npc_metropolice.cpp b/src/game/server/hl2/npc_metropolice.cpp index 1175a96130..c0aab85207 100644 --- a/src/game/server/hl2/npc_metropolice.cpp +++ b/src/game/server/hl2/npc_metropolice.cpp @@ -89,6 +89,7 @@ enum }; +#ifndef NEO // Unity build enum SpeechMemory_t { bits_MEMORY_PAIN_LIGHT_SOUND = bits_MEMORY_CUSTOM1, @@ -96,6 +97,7 @@ enum SpeechMemory_t bits_MEMORY_PLAYER_HURT = bits_MEMORY_CUSTOM3, bits_MEMORY_PLAYER_HARASSED = bits_MEMORY_CUSTOM4, }; +#endif //Metrocop int g_interactionMetrocopStartedStitch = 0; @@ -133,7 +135,11 @@ int AE_METROPOLICE_DEPLOY_MANHACK; // was 51 // ----------------------------------------------- // > Squad slots // ----------------------------------------------- +#ifdef NEO // Unity build +enum SquadSlotMetroPolice_T +#else enum SquadSlot_T +#endif { SQUAD_SLOT_POLICE_CHARGE_ENEMY = LAST_SHARED_SQUADSLOT, SQUAD_SLOT_POLICE_HARASS, // Yell at the player with a megaphone, etc. diff --git a/src/game/server/hl2/npc_scanner.cpp b/src/game/server/hl2/npc_scanner.cpp index 2cc4f204d2..84e3a9f090 100644 --- a/src/game/server/hl2/npc_scanner.cpp +++ b/src/game/server/hl2/npc_scanner.cpp @@ -48,6 +48,9 @@ extern IMaterialSystemHardwareConfig *g_pMaterialSystemHardwareConfig; #define SCANNER_HINT_INSPECT_DELAY 15 // Check for hint nodes this often +#if defined(NEO) && defined(SPOTLIGHT_WIDTH) // Unity build +#undef SPOTLIGHT_WIDTH +#endif #define SPOTLIGHT_WIDTH 32 #define SCANNER_SPOTLIGHT_NEAR_DIST 64 diff --git a/src/game/server/hl2/npc_stalker.cpp b/src/game/server/hl2/npc_stalker.cpp index 204d7a55ee..a2e743376c 100644 --- a/src/game/server/hl2/npc_stalker.cpp +++ b/src/game/server/hl2/npc_stalker.cpp @@ -100,7 +100,11 @@ enum // ----------------------------------------------- // > Squad slots // ----------------------------------------------- +#ifdef NEO // Unity build +enum SquadSlotStalker_T +#else enum SquadSlot_T +#endif { SQUAD_SLOT_CHASE_ENEMY_1 = LAST_SHARED_SQUADSLOT, SQUAD_SLOT_CHASE_ENEMY_2, diff --git a/src/game/server/hl2/npc_strider.cpp b/src/game/server/hl2/npc_strider.cpp index 1a4471fbe0..198b924838 100644 --- a/src/game/server/hl2/npc_strider.cpp +++ b/src/game/server/hl2/npc_strider.cpp @@ -226,7 +226,11 @@ int ACT_STRIDER_SLEEP; // These bones have physics shadows // It allows a one-way interaction between the strider and // the physics world +#ifdef NEO // Unity build +static const char *pFollowerBoneNamesStrider[] = +#else static const char *pFollowerBoneNames[] = +#endif { // Head "Combine_Strider.Body_Bone", @@ -635,7 +639,11 @@ void CNPC_Strider::InitBoneFollowers( void ) return; // Init our followers +#ifdef NEO // Unity build + m_BoneFollowerManager.InitBoneFollowers( this, ARRAYSIZE(pFollowerBoneNamesStrider), pFollowerBoneNamesStrider ); +#else m_BoneFollowerManager.InitBoneFollowers( this, ARRAYSIZE(pFollowerBoneNames), pFollowerBoneNames ); +#endif } //--------------------------------------------------------- diff --git a/src/game/server/hl2/npc_turret_ceiling.cpp b/src/game/server/hl2/npc_turret_ceiling.cpp index be0b761d8d..6b4c5e5d14 100644 --- a/src/game/server/hl2/npc_turret_ceiling.cpp +++ b/src/game/server/hl2/npc_turret_ceiling.cpp @@ -63,7 +63,11 @@ int ACT_CEILING_TURRET_FIRE; int ACT_CEILING_TURRET_DRYFIRE; //Turret states +#ifdef NEO // Unity build +enum turretStateCeiling_e +#else enum turretState_e +#endif { TURRET_SEARCHING, TURRET_AUTO_SEARCHING, @@ -74,7 +78,11 @@ enum turretState_e }; //Eye states +#ifdef NEO // Unity build +enum eyeStateTurretCeiling_t +#else enum eyeState_t +#endif { TURRET_EYE_SEE_TARGET, //Sees the target, bright and big TURRET_EYE_SEEKING_TARGET, //Looking for a target, blinking (bright) @@ -148,9 +156,17 @@ class CNPC_CeilingTurret : public CAI_BaseNPC protected: +#ifdef NEO // Unity build + bool PreThink( turretStateCeiling_e state ); +#else bool PreThink( turretState_e state ); +#endif void Shoot( const Vector &vecSrc, const Vector &vecDirToEnemy ); +#ifdef NEO // Unity build + void SetEyeState( eyeStateTurretCeiling_t state ); +#else void SetEyeState( eyeState_t state ); +#endif void Ping( void ); void Toggle( void ); void Enable( void ); @@ -866,7 +882,11 @@ void CNPC_CeilingTurret::Shoot( const Vector &vecSrc, const Vector &vecDirToEnem // Purpose: Allows a generic think function before the others are called // Input : state - which state the turret is currently in //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +bool CNPC_CeilingTurret::PreThink( turretStateCeiling_e state ) +#else bool CNPC_CeilingTurret::PreThink( turretState_e state ) +#endif { CheckPVSCondition(); @@ -881,7 +901,11 @@ bool CNPC_CeilingTurret::PreThink( turretState_e state ) // Purpose: Sets the state of the glowing eye attached to the turret // Input : state - state the eye should be in //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +void CNPC_CeilingTurret::SetEyeState( eyeStateTurretCeiling_t state ) +#else void CNPC_CeilingTurret::SetEyeState( eyeState_t state ) +#endif { //Must have a valid eye to affect if ( m_pEyeGlow == NULL ) @@ -1126,4 +1150,4 @@ bool CNPC_CeilingTurret::CanBeAnEnemyOf( CBaseEntity *pEnemy ) } return BaseClass::CanBeAnEnemyOf( pEnemy ); -} \ No newline at end of file +} diff --git a/src/game/server/hl2/npc_vortigaunt_episodic.cpp b/src/game/server/hl2/npc_vortigaunt_episodic.cpp index cafa33a255..59c6e8e912 100644 --- a/src/game/server/hl2/npc_vortigaunt_episodic.cpp +++ b/src/game/server/hl2/npc_vortigaunt_episodic.cpp @@ -136,7 +136,11 @@ int AE_VORTIGAUNT_STOP_HEAL_GLOW; // ' //----------------------------------------------------------------------------- // Squad slots //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +enum SquadSlotVortigauntEpisodic_T +#else enum SquadSlot_T +#endif { SQUAD_SLOT_HEAL_PLAYER = LAST_SHARED_SQUADSLOT, }; diff --git a/src/game/server/hl2/vehicle_apc.cpp b/src/game/server/hl2/vehicle_apc.cpp index 80c4291f7d..2445006785 100644 --- a/src/game/server/hl2/vehicle_apc.cpp +++ b/src/game/server/hl2/vehicle_apc.cpp @@ -57,7 +57,11 @@ ConVar sk_apc_health( "sk_apc_health", "750" ); #define APC_MAX_CHUNKS 3 +#ifdef NEO // Unity build +static const char *s_pChunkModelNameApc[APC_MAX_CHUNKS] = +#else static const char *s_pChunkModelName[APC_MAX_CHUNKS] = +#endif { "models/gibs/helicopter_brokenpiece_01.mdl", "models/gibs/helicopter_brokenpiece_02.mdl", @@ -121,7 +125,11 @@ void CPropAPC::Precache( void ) int i; for ( i = 0; i < APC_MAX_CHUNKS; ++i ) { +#ifdef NEO // Unity build + PrecacheModel( s_pChunkModelNameApc[i] ); +#else PrecacheModel( s_pChunkModelName[i] ); +#endif } for ( i = 0; i < APC_MAX_GIBS; ++i ) @@ -365,7 +373,11 @@ void CPropAPC::ExplodeAndThrowChunk( const Vector &vecExplosionPos ) pChunk->SetAbsAngles( vecSpawnAngles ); int nGib = random->RandomInt( 0, APC_MAX_CHUNKS - 1 ); +#ifdef NEO // Unity build + pChunk->Spawn( s_pChunkModelNameApc[nGib] ); +#else pChunk->Spawn( s_pChunkModelName[nGib] ); +#endif pChunk->SetOwnerEntity( this ); pChunk->m_lifeTime = random->RandomFloat( 6.0f, 8.0f ); pChunk->SetCollisionGroup( COLLISION_GROUP_DEBRIS ); @@ -453,7 +465,11 @@ void CPropAPC::Event_Killed( const CTakeDamageInfo &info ) pChunk->SetAbsAngles( vecSpawnAngles ); int nGib = random->RandomInt( 0, APC_MAX_CHUNKS - 1 ); +#ifdef NEO // Unity build + pChunk->Spawn( s_pChunkModelNameApc[nGib] ); +#else pChunk->Spawn( s_pChunkModelName[nGib] ); +#endif pChunk->SetOwnerEntity( this ); pChunk->m_lifeTime = random->RandomFloat( 6.0f, 8.0f ); pChunk->SetCollisionGroup( COLLISION_GROUP_DEBRIS ); diff --git a/src/game/server/physconstraint.cpp b/src/game/server/physconstraint.cpp index 8fa25cdd83..8aa35e1faa 100644 --- a/src/game/server/physconstraint.cpp +++ b/src/game/server/physconstraint.cpp @@ -356,6 +356,11 @@ int CPhysConstraint::DrawDebugTextOverlays() if ( (params.bodyMassScale[0] != 1.0f && params.bodyMassScale[0] != 0.0f) || (params.bodyMassScale[1] != 1.0f && params.bodyMassScale[1] != 0.0f) ) { +#ifdef NEO // Unity build +#ifdef str +#undef str +#endif +#endif CFmtStr str("mass ratio %.4f:%.4f\n", params.bodyMassScale[0], params.bodyMassScale[1] ); NDebugOverlay::EntityTextAtPosition( GetAbsOrigin(), pos, str.Access(), 0, 255, 255, 0, 255 ); } diff --git a/src/game/server/triggers.cpp b/src/game/server/triggers.cpp index e46c3bca2c..32aa6a9ba6 100644 --- a/src/game/server/triggers.cpp +++ b/src/game/server/triggers.cpp @@ -4692,7 +4692,11 @@ void CTriggerVPhysicsMotion::StartTouch( CBaseEntity *pOther ) pPlayer->m_Local.m_bSlowMovement = true; } +#ifdef NEO // Unity build + triggerevent_t event = {}; +#else triggerevent_t event; +#endif PhysGetTriggerEvent( &event, this ); if ( event.pObject ) { @@ -4730,7 +4734,11 @@ void CTriggerVPhysicsMotion::EndTouch( CBaseEntity *pOther ) pPlayer->SetPhysicsFlag( PFLAG_VPHYSICS_MOTIONCONTROLLER, false ); pPlayer->m_Local.m_bSlowMovement = false; } +#ifdef NEO // Unity build + triggerevent_t event = {}; +#else triggerevent_t event; +#endif PhysGetTriggerEvent( &event, this ); if ( event.pObject && m_pController ) { diff --git a/src/game/shared/activitylist.cpp b/src/game/shared/activitylist.cpp index beda5c86b9..6fa0686235 100644 --- a/src/game/shared/activitylist.cpp +++ b/src/game/shared/activitylist.cpp @@ -80,7 +80,11 @@ activitylist_t *ActivityList_AddActivityEntry( const char *pName, int iActivityI } // get the database entry from a string +#ifdef NEO // Unity build +static activitylist_t *ActivityListFromString( const char *pString ) +#else static activitylist_t *ListFromString( const char *pString ) +#endif { // just use the string registry to do this search/map int stringID = g_ActivityStrings.GetStringID( pString ); @@ -118,7 +122,11 @@ bool ActivityList_RegisterSharedActivity( const char *pszActivityName, int iActi // first, check to make sure the slot we're asking for is free. It must be for // a shared activity. +#ifdef NEO // Unity build + activitylist_t *pList = ActivityListFromString( pszActivityName ); +#else activitylist_t *pList = ListFromString( pszActivityName ); +#endif if ( !pList ) { pList = ListFromActivity( iActivityIndex ); @@ -139,7 +147,11 @@ bool ActivityList_RegisterSharedActivity( const char *pszActivityName, int iActi Activity ActivityList_RegisterPrivateActivity( const char *pszActivityName ) { +#ifdef NEO // Unity build + activitylist_t *pList = ActivityListFromString( pszActivityName ); +#else activitylist_t *pList = ListFromString( pszActivityName ); +#endif if ( pList ) { // this activity is already in the list. If the activity we collided with is also private, @@ -166,7 +178,11 @@ Activity ActivityList_RegisterPrivateActivity( const char *pszActivityName ) int ActivityList_IndexForName( const char *pszActivityName ) { // this is a fast O(lgn) search (actually does 2 O(lgn) searches) +#ifdef NEO // Unity build + activitylist_t *pList = ActivityListFromString( pszActivityName ); +#else activitylist_t *pList = ListFromString( pszActivityName ); +#endif if ( pList ) { diff --git a/src/game/shared/eventlist.cpp b/src/game/shared/eventlist.cpp index 4218ff5684..d4049e8a5e 100644 --- a/src/game/shared/eventlist.cpp +++ b/src/game/shared/eventlist.cpp @@ -71,7 +71,11 @@ eventlist_t *EventList_AddEventEntry( const char *pName, int iEventIndex, bool i } // get the database entry from a string +#ifdef NEO // Unity build +static eventlist_t *EventListFromString( const char *pString ) +#else static eventlist_t *ListFromString( const char *pString ) +#endif { // just use the string registry to do this search/map int stringID = g_EventStrings.GetStringID( pString ); @@ -117,7 +121,11 @@ bool EventList_RegisterSharedEvent( const char *pszEventName, int iEventIndex, i // first, check to make sure the slot we're asking for is free. It must be for // a shared event. +#ifdef NEO // Unity build + eventlist_t *pList = EventListFromString( pszEventName ); +#else eventlist_t *pList = ListFromString( pszEventName ); +#endif if ( !pList ) { pList = ListFromEvent( iEventIndex ); @@ -136,7 +144,11 @@ bool EventList_RegisterSharedEvent( const char *pszEventName, int iEventIndex, i Animevent EventList_RegisterPrivateEvent( const char *pszEventName ) { +#ifdef NEO // Unity build + eventlist_t *pList = EventListFromString( pszEventName ); +#else eventlist_t *pList = ListFromString( pszEventName ); +#endif if ( pList ) { // this activity is already in the list. If the activity we collided with is also private, @@ -163,7 +175,11 @@ Animevent EventList_RegisterPrivateEvent( const char *pszEventName ) int EventList_IndexForName( const char *pszEventName ) { // this is a fast O(lgn) search (actually does 2 O(lgn) searches) +#ifdef NEO // Unity build + eventlist_t *pList = EventListFromString( pszEventName ); +#else eventlist_t *pList = ListFromString( pszEventName ); +#endif if ( pList ) { @@ -258,4 +274,4 @@ void EventList_RegisterSharedEvents( void ) REGISTER_SHARED_ANIMEVENT( AE_TAUNT_ADD_ATTRIBUTE, AE_TYPE_SERVER ); REGISTER_SHARED_ANIMEVENT( AE_SV_EXCLUDE_PLAYER_SOUND, AE_TYPE_SERVER ); REGISTER_SHARED_ANIMEVENT( AE_CL_EXCLUDE_PLAYER_SOUND, AE_TYPE_CLIENT ); -} \ No newline at end of file +} diff --git a/src/game/shared/gamemovement.cpp b/src/game/shared/gamemovement.cpp index 979aec66ee..3767d2859b 100644 --- a/src/game/shared/gamemovement.cpp +++ b/src/game/shared/gamemovement.cpp @@ -52,7 +52,9 @@ extern IFileSystem *filesystem; // gpGlobals->frametime are. We should probably set tickcount (to player->m_nTickBase), // but we're REALLY close to shipping, so we can change that later and people can use // player->CurrentCommandNumber() in the meantime. +#ifndef NEO // Unity build | NEO NOTE (nullsystem): This tickcount never used in this cpp file #define tickcount USE_PLAYER_CURRENT_COMMAND_NUMBER__INSTEAD_OF_TICKCOUNT +#endif #if defined( HL2_DLL ) ConVar xc_uncrouch_on_jump( "xc_uncrouch_on_jump", "1", FCVAR_ARCHIVE, "Uncrouch when jump occurs" ); diff --git a/src/mathlib/CMakeLists.txt b/src/mathlib/CMakeLists.txt index 5a4b679dd9..4856db4729 100644 --- a/src/mathlib/CMakeLists.txt +++ b/src/mathlib/CMakeLists.txt @@ -2,7 +2,11 @@ add_library(mathlib STATIC) add_library(mathlib::mathlib ALIAS mathlib) -set_target_properties(mathlib PROPERTIES PREFIX "") +set_target_properties(mathlib PROPERTIES + PREFIX "" + UNITY_BUILD ON + UNITY_BUILD_MODE GROUP +) target_include_directories(mathlib PRIVATE @@ -28,31 +32,40 @@ if (OS_LINUX) ) endif () +set(UNITY_SOURCE_MATHLIB + color_conversion.cpp + halton.cpp + lightdesc.cpp + mathlib_base.cpp + powsse.cpp + sparse_convolution_noise.cpp + sseconst.cpp + sse.cpp + ssenoise.cpp + anorms.cpp + bumpvects.cpp + IceKey.cpp + polyhedron.cpp + randsse.cpp + spherical.cpp + simdvectormatrix.cpp + vmatrix.cpp + almostequal.cpp +) + +set_source_files_properties( + ${UNITY_SOURCE_MATHLIB} + PROPERTIES UNITY_GROUP mathlib +) + target_sources_grouped( TARGET mathlib NAME "Source Files" FILES - color_conversion.cpp - halton.cpp - lightdesc.cpp - mathlib_base.cpp - powsse.cpp - sparse_convolution_noise.cpp - sseconst.cpp - sse.cpp - ssenoise.cpp - anorms.cpp - bumpvects.cpp - IceKey.cpp - imagequant.cpp - polyhedron.cpp - quantize.cpp - randsse.cpp - spherical.cpp - simdvectormatrix.cpp - vector.cpp - vmatrix.cpp - almostequal.cpp + ${UNITY_SOURCE_MATHLIB} + imagequant.cpp + quantize.cpp + #vector.cpp # Unused ) if(OS_LINUX OR OS_MACOS) diff --git a/src/mathlib/noisedata.h b/src/mathlib/noisedata.h index 2b63c1baa9..b5357e529c 100644 --- a/src/mathlib/noisedata.h +++ b/src/mathlib/noisedata.h @@ -8,6 +8,9 @@ // // **** DO NOT EDIT THIS FILE. GENERATED BY DATAGEN.PL **** // +#ifdef NEO // Unity build +#pragma once +#endif static int perm_a[]={ 66,147,106,213,89,115,239,25,171,175,9,114,141,226,118,128,41,208,4,56, diff --git a/src/public/edict.h b/src/public/edict.h index 37c701b4e3..1ce39d6956 100644 --- a/src/public/edict.h +++ b/src/public/edict.h @@ -20,6 +20,12 @@ #include "iservernetworkable.h" #include "bitvec.h" +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif + struct edict_t; diff --git a/src/public/filesystem.h b/src/public/filesystem.h index 560ea30174..0b2fbeb6a4 100644 --- a/src/public/filesystem.h +++ b/src/public/filesystem.h @@ -25,6 +25,12 @@ #pragma once #endif +#ifdef NEO // Unity build +#ifdef GetCurrentDirectory +#undef GetCurrentDirectory +#endif +#endif + //----------------------------------------------------------------------------- // Forward declarations //----------------------------------------------------------------------------- diff --git a/src/public/iservernetworkable.h b/src/public/iservernetworkable.h index cefa75346f..f838aaff17 100644 --- a/src/public/iservernetworkable.h +++ b/src/public/iservernetworkable.h @@ -18,7 +18,11 @@ #include "const.h" #include "bspfile.h" - +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif // Entities can span this many clusters before we revert to a slower area checking algorithm #define MAX_FAST_ENT_CLUSTERS 4 diff --git a/src/public/server_class.h b/src/public/server_class.h index b3517d50e9..26176ebaf5 100644 --- a/src/public/server_class.h +++ b/src/public/server_class.h @@ -114,6 +114,17 @@ class CBaseNetworkable; #ifdef VALIDATE_DECLARE_CLASS +#ifdef NEO // Unity build + #define CHECK_DECLARE_CLASS( DLLClassName, sendTable ) \ + template <> int CheckDeclareClass_Access(sendTable::ignored *, const char *pIgnored) \ + { \ + return DLLClassName::CheckDeclareClass( #DLLClassName ); \ + } \ + namespace sendTable \ + { \ + int verifyDeclareClass = CheckDeclareClass_Access( (sendTable::ignored*)0, "" ); \ + } +#else #define CHECK_DECLARE_CLASS( DLLClassName, sendTable ) \ template int CheckDeclareClass_Access(T *); \ template <> int CheckDeclareClass_Access(sendTable::ignored *, const char *pIgnored) \ @@ -124,6 +135,7 @@ class CBaseNetworkable; { \ int verifyDeclareClass = CheckDeclareClass_Access( (sendTable::ignored*)0 ); \ } +#endif #else #define CHECK_DECLARE_CLASS( DLLClassName, sendTable ) #endif diff --git a/src/public/tier1/datamanager.h b/src/public/tier1/datamanager.h index 856b825cf5..1a370668a2 100644 --- a/src/public/tier1/datamanager.h +++ b/src/public/tier1/datamanager.h @@ -13,6 +13,9 @@ #include "tier0/threadtools.h" #include "utlmultilist.h" #include "utlvector.h" +#ifdef NEO // Unity build +#include "basetypes.h" +#endif FORWARD_DECLARE_HANDLE( memhandle_t ); diff --git a/src/public/tier1/fmtstr.h b/src/public/tier1/fmtstr.h index 7ef8637b1d..17d9ab76c1 100644 --- a/src/public/tier1/fmtstr.h +++ b/src/public/tier1/fmtstr.h @@ -22,6 +22,12 @@ #pragma GCC visibility push(hidden) #endif +#ifdef NEO // Unity build +#ifdef sprintf +#undef sprintf +#endif +#endif + //============================================================================= // using macro to be compatable with GCC diff --git a/src/public/vgui/IPanel.h b/src/public/vgui/IPanel.h index a0313e00da..ce5d64e118 100644 --- a/src/public/vgui/IPanel.h +++ b/src/public/vgui/IPanel.h @@ -20,6 +20,12 @@ #undef SendMessage #endif +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif + class KeyValues; namespace vgui diff --git a/src/public/vgui_controls/MessageMap.h b/src/public/vgui_controls/MessageMap.h index e6570823bc..2f7fcd8a64 100644 --- a/src/public/vgui_controls/MessageMap.h +++ b/src/public/vgui_controls/MessageMap.h @@ -14,6 +14,12 @@ #include "tier1/utlvector.h" +#ifdef NEO // Unity build +#ifdef GetClassName +#undef GetClassName +#endif +#endif + // more flexible than default pointers to members code required for casting member function pointers //#pragma pointers_to_members( full_generality, virtual_inheritance ) diff --git a/src/public/vgui_controls/PropertyDialog.h b/src/public/vgui_controls/PropertyDialog.h index 32747f0aae..4d9bfd9a47 100644 --- a/src/public/vgui_controls/PropertyDialog.h +++ b/src/public/vgui_controls/PropertyDialog.h @@ -15,6 +15,10 @@ #include #include +#ifdef NEO // Unity build +#include +#endif + namespace vgui { diff --git a/src/public/vgui_controls/PropertySheet.h b/src/public/vgui_controls/PropertySheet.h index 13ce4d0555..2770a0ea3c 100644 --- a/src/public/vgui_controls/PropertySheet.h +++ b/src/public/vgui_controls/PropertySheet.h @@ -23,6 +23,12 @@ namespace vgui class PageTab; class ImagePanel; +#ifdef NEO // Unity build +#ifdef PropertySheet +#undef PropertySheet +#endif +#endif + //----------------------------------------------------------------------------- // Purpose: Tabbed property sheet. Holds and displays a set of Panel's //----------------------------------------------------------------------------- diff --git a/src/tier1/CMakeLists.txt b/src/tier1/CMakeLists.txt index e8f5c848c3..87f2ce6a92 100644 --- a/src/tier1/CMakeLists.txt +++ b/src/tier1/CMakeLists.txt @@ -4,6 +4,15 @@ add_library(tier1::tier1 ALIAS tier1) target_compile_definitions(tier1 PRIVATE TIER1_STATIC_LIB) +set(unity_before [[ +#include "tier0/memdbgoff.h" +]]) + +set_target_properties(tier1 PROPERTIES + UNITY_BUILD ON + UNITY_BUILD_MODE GROUP + UNITY_BUILD_CODE_BEFORE_INCLUDE "${unity_before}" +) if (OS_LINUX) set_target_properties(tier1 PROPERTIES POSITION_INDEPENDENT_CODE ON @@ -39,10 +48,7 @@ target_link_directories(tier1 ${LIBPUBLIC} ) -target_sources_grouped( - TARGET tier1 - NAME "Source Files" - FILES +set(UNITY_SOURCE_TIER1 bitbuf.cpp newbitbuf.cpp byteswap.cpp @@ -56,7 +62,6 @@ target_sources_grouped( diff.cpp generichash.cpp ilocalize.cpp - interface.cpp KeyValues.cpp kvpacker.cpp lzmaDecoder.cpp @@ -67,8 +72,6 @@ target_sources_grouped( rangecheckedvar.cpp reliabletimer.cpp stringpool.cpp - strtools.cpp - strtools_unicode.cpp tier1.cpp tokenreader.cpp sparsematrix.cpp @@ -76,13 +79,28 @@ target_sources_grouped( utlbuffer.cpp utlbufferutil.cpp utlstring.cpp - utlsymbol.cpp utlbinaryblock.cpp snappy.cpp snappy-sinksource.cpp snappy-stubs-internal.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_TIER1} + PROPERTIES UNITY_GROUP tier1 +) + +target_sources_grouped( + TARGET tier1 + NAME "Source Files" + FILES + ${UNITY_SOURCE_TIER1} + utlsymbol.cpp + interface.cpp + strtools.cpp + strtools_unicode.cpp +) + set_source_files_properties(interface.cpp PROPERTIES COMPILE_OPTIONS "-D_DLL_EXT=${SRV_SUFFIX}${CMAKE_SHARED_LIBRARY_SUFFIX};-D_EXTERNAL_DLL_EXT=${SRV_SUFFIX}${CMAKE_SHARED_LIBRARY_SUFFIX}" ) diff --git a/src/tier1/kvpacker.cpp b/src/tier1/kvpacker.cpp index 944bef7929..1e9271532a 100644 --- a/src/tier1/kvpacker.cpp +++ b/src/tier1/kvpacker.cpp @@ -15,6 +15,11 @@ // memdbgon must be the last include file in a .cpp file!!! #include +#ifdef NEO // Unity build +#ifdef KEYVALUES_TOKEN_SIZE +#undef KEYVALUES_TOKEN_SIZE +#endif +#endif #define KEYVALUES_TOKEN_SIZE 1024 // writes KeyValue as binary data to buffer diff --git a/src/tier1/snappy.cpp b/src/tier1/snappy.cpp index 72e26e01e9..38679ffff6 100644 --- a/src/tier1/snappy.cpp +++ b/src/tier1/snappy.cpp @@ -50,6 +50,13 @@ typedef int ssize_t; #endif //_WIN32 +#ifdef NEO // Unity build +#ifdef min +#undef min +#endif +#define min(a,b) (((a) < (b)) ? (a) : (b)) +#endif + namespace snappy { // Any hash function will produce a valid compressed bitstream, but a good diff --git a/src/vgui2/vgui_controls/CMakeLists.txt b/src/vgui2/vgui_controls/CMakeLists.txt index dd02e33bc4..94be59dcef 100644 --- a/src/vgui2/vgui_controls/CMakeLists.txt +++ b/src/vgui2/vgui_controls/CMakeLists.txt @@ -2,7 +2,11 @@ add_library(vgui_controls STATIC) add_library(vgui_controls::vgui_controls ALIAS vgui_controls) -set_target_properties(vgui_controls PROPERTIES PREFIX "") +set_target_properties(vgui_controls PROPERTIES + PREFIX "" + UNITY_BUILD ON + UNITY_BUILD_MODE GROUP +) target_include_directories(vgui_controls PRIVATE @@ -22,11 +26,7 @@ if (OS_LINUX) ) endif () -target_sources_grouped( - TARGET vgui_controls - NAME "Source Files" - FILES - ${CMAKE_SOURCE_DIR}/public/filesystem_helpers.cpp +set(UNITY_SOURCE_VGUI_CONTROLS ${CMAKE_SOURCE_DIR}/vgui2/src/vgui_key_translation.cpp AnalogBar.cpp AnimatingImagePanel.cpp @@ -75,7 +75,6 @@ target_sources_grouped( ProgressBox.cpp PropertyDialog.cpp PropertyPage.cpp - PropertySheet.cpp QueryBox.cpp RadioButton.cpp RichText.cpp @@ -105,6 +104,20 @@ target_sources_grouped( subrectimage.cpp ) +set_source_files_properties( + ${UNITY_SOURCE_VGUI_CONTROLS} + PROPERTIES UNITY_GROUP vgui2_vgui_controls +) + +target_sources_grouped( + TARGET vgui_controls + NAME "Source Files" + FILES + ${UNITY_SOURCE_VGUI_CONTROLS} + ${CMAKE_SOURCE_DIR}/public/filesystem_helpers.cpp + PropertySheet.cpp +) + target_sources_grouped( TARGET vgui_controls NAME "Public Header Files" @@ -199,4 +212,6 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/public/vgui_controls/perforcefilelistframe.h ${CMAKE_SOURCE_DIR}/public/vgui_controls/savedocumentquery.h ${CMAKE_SOURCE_DIR}/public/vgui_controls/subrectimage.h + + ${CMAKE_SOURCE_DIR}/vgui2/vgui_controls/Common.h # Unity build ) diff --git a/src/vgui2/vgui_controls/Common.h b/src/vgui2/vgui_controls/Common.h new file mode 100644 index 0000000000..c7ccefbff8 --- /dev/null +++ b/src/vgui2/vgui_controls/Common.h @@ -0,0 +1,148 @@ +#pragma once + +// Used for unity build + +namespace vgui +{ + +enum +{ + WINDOW_BORDER_WIDTH=2 // the width of the window's border +}; + +static bool BindingLessFunc( KeyValues * const & lhs, KeyValues * const &rhs ) +{ + KeyValues *p1, *p2; + + p1 = const_cast< KeyValues * >( lhs ); + p2 = const_cast< KeyValues * >( rhs ); + return ( Q_stricmp( p1->GetString( "Action" ), p2->GetString( "Action" ) ) < 0 ) ? true : false; +} + +static char *CopyString( const char *in ) +{ + if ( !in ) + return NULL; + + int len = V_strlen( in ); + char *n = new char[ len + 1 ]; + V_strncpy( n, in, len + 1 ); + return n; +} + +static int ListFileNameSortFunc([[maybe_unused]] ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) +{ + bool dir1 = item1.kv->GetInt("directory") == 1; + bool dir2 = item2.kv->GetInt("directory") == 1; + + // if they're both not directories of files, return if dir1 is a directory (before files) + if ( dir1 != dir2 ) + { + return dir1 ? -1 : 1; + } + + const char *string1 = item1.kv->GetString("text"); + const char *string2 = item2.kv->GetString("text"); + + // YWB: Mimic windows behavior where filenames starting with numbers are sorted based on numeric part + int num1 = Q_atoi( string1 ); + int num2 = Q_atoi( string2 ); + + if ( num1 != 0 && + num2 != 0 ) + { + if ( num1 < num2 ) + return -1; + else if ( num1 > num2 ) + return 1; + } + + // Push numbers before everything else + if ( num1 != 0 ) + { + return -1; + } + + // Push numbers before everything else + if ( num2 != 0 ) + { + return 1; + } + + return Q_stricmp( string1, string2 ); +} + +static int ListBaseStringSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2, char const *fieldName ) +{ + bool dir1 = item1.kv->GetInt("directory") == 1; + bool dir2 = item2.kv->GetInt("directory") == 1; + + // if they're both not directories of files, return if dir1 is a directory (before files) + if (dir1 != dir2) + { + return -1; + } + + const char *string1 = item1.kv->GetString(fieldName); + const char *string2 = item2.kv->GetString(fieldName); + int cval = Q_stricmp(string1, string2); + if ( cval == 0 ) + { + // Use filename to break ties + return ListFileNameSortFunc( pPanel, item1, item2 ); + } + + return cval; +} + +static int ListBaseIntegerSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2, char const *fieldName ) +{ + bool dir1 = item1.kv->GetInt("directory") == 1; + bool dir2 = item2.kv->GetInt("directory") == 1; + + // if they're both not directories of files, return if dir1 is a directory (before files) + if (dir1 != dir2) + { + return -1; + } + + int i1 = item1.kv->GetInt(fieldName); + int i2 = item2.kv->GetInt(fieldName); + if ( i1 == i2 ) + { + // Use filename to break ties + return ListFileNameSortFunc( pPanel, item1, item2 ); + } + + return ( i1 < i2 ) ? -1 : 1; +} + +static int ListFileSizeSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) +{ + return ListBaseIntegerSortFunc( pPanel, item1, item2, "filesizeint" ); +} + +static int ListFileAttributesSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) +{ + return ListBaseStringSortFunc( pPanel, item1, item2, "attributes" ); +} + +static int ListFileTypeSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) +{ + return ListBaseStringSortFunc( pPanel, item1, item2, "type" ); +} + +struct ColumnInfo_t +{ + char const *columnName; + char const *columnText; + int startingWidth; + int minWidth; + int maxWidth; + int flags; + SortFunc *pfnSort; + Label::Alignment alignment; +}; + +} // namespace vgui + diff --git a/src/vgui2/vgui_controls/FileOpenDialog.cpp b/src/vgui2/vgui_controls/FileOpenDialog.cpp index a411a99447..a7c36310aa 100644 --- a/src/vgui2/vgui_controls/FileOpenDialog.cpp +++ b/src/vgui2/vgui_controls/FileOpenDialog.cpp @@ -47,6 +47,9 @@ #include #include #include +#ifdef NEO // Unity build +#include "Common.h" +#endif #if defined( _X360 ) #include "xbox/xbox_win32stubs.h" @@ -60,6 +63,7 @@ using namespace vgui; static int s_nLastSortColumn = 0; +#ifndef NEO // Unity build static int ListFileNameSortFunc([[maybe_unused]] ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) { bool dir1 = item1.kv->GetInt("directory") == 1; @@ -147,6 +151,8 @@ static int ListBaseIntegerSortFunc(ListPanel *pPanel, const ListPanelItem &item1 return ( i1 < i2 ) ? -1 : 1; } +#endif // NEO + static int ListBaseInteger64SortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2, char const *lowfield, char const *highfield ) { bool dir1 = item1.kv->GetInt("directory") == 1; @@ -174,11 +180,12 @@ static int ListBaseInteger64SortFunc(ListPanel *pPanel, const ListPanelItem &ite return ( i1 < i2 ) ? -1 : 1; } - +#ifndef NEO // Unity build static int ListFileSizeSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) { return ListBaseIntegerSortFunc( pPanel, item1, item2, "filesizeint" ); } +#endif static int ListFileModifiedSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) { @@ -190,6 +197,7 @@ static int ListFileCreatedSortFunc(ListPanel *pPanel, const ListPanelItem &item1 // NOTE: Backward order to get most recent files first return ListBaseInteger64SortFunc( pPanel, item2, item1, "createdint_low", "createdint_high" ); } +#ifndef NEO // Unity build static int ListFileAttributesSortFunc(ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) { return ListBaseStringSortFunc( pPanel, item1, item2, "attributes" ); @@ -198,7 +206,7 @@ static int ListFileTypeSortFunc(ListPanel *pPanel, const ListPanelItem &item1, c { return ListBaseStringSortFunc( pPanel, item1, item2, "type" ); } - +#endif namespace vgui @@ -461,6 +469,7 @@ void FileCompletionEdit::OnMenuItemHighlight( int itemID ) //----------------------------------------------------------------------------- static CUtlDict< CUtlString, unsigned short > s_StartDirContexts; +#ifndef NEO // Unity build struct ColumnInfo_t { char const *columnName; @@ -472,8 +481,13 @@ struct ColumnInfo_t SortFunc *pfnSort; Label::Alignment alignment; }; +#endif +#ifdef NEO // Unity build +static ColumnInfo_t g_ColInfoFileOpenDl[] = +#else static ColumnInfo_t g_ColInfo[] = +#endif { { "text", "#FileOpenDialog_Col_Name", 175, 20, 10000, ListPanel::COLUMN_UNHIDABLE, &ListFileNameSortFunc , Label::a_west }, { "filesize", "#FileOpenDialog_Col_Size", 100, 20, 10000, 0, &ListFileSizeSortFunc , Label::a_east }, @@ -522,9 +536,15 @@ void FileOpenDialog::Init( const char *title, KeyValues *pContextKeyValues ) // list panel m_pFileList = new ListPanel(this, "FileList"); +#ifdef NEO // Unity build + for ( int i = 0; i < ARRAYSIZE( g_ColInfoFileOpenDl ); ++i ) + { + const ColumnInfo_t& info = g_ColInfoFileOpenDl[ i ]; +#else for ( int i = 0; i < ARRAYSIZE( g_ColInfo ); ++i ) { const ColumnInfo_t& info = g_ColInfo[ i ]; +#endif m_pFileList->AddColumnHeader( i, info.columnName, info.columnText, QuickPropScale( info.startingWidth ), QuickPropScale( info.minWidth ), QuickPropScale( info.maxWidth ), info.flags ); m_pFileList->SetSortFunc( i, info.pfnSort ); diff --git a/src/vgui2/vgui_controls/KeyBindingHelpDialog.cpp b/src/vgui2/vgui_controls/KeyBindingHelpDialog.cpp index 2e5b0ab0dc..993354121b 100644 --- a/src/vgui2/vgui_controls/KeyBindingHelpDialog.cpp +++ b/src/vgui2/vgui_controls/KeyBindingHelpDialog.cpp @@ -15,6 +15,9 @@ #include "vgui/Cursor.h" #include "tier1/utldict.h" #include "vgui_controls/KeyBoardEditorDialog.h" +#ifdef NEO // Unity build +#include "Common.h" +#endif // NOTE: This has to be the last file included! #include "tier0/memdbgon.h" @@ -25,6 +28,7 @@ using namespace vgui; // If the user holds the key bound to help down for this long, then the dialog will stay on automatically #define KB_HELP_CONTINUE_SHOWING_TIME 1.0 +#ifndef NEO // Unity build static bool BindingLessFunc( KeyValues * const & lhs, KeyValues * const &rhs ) { KeyValues *p1, *p2; @@ -33,6 +37,7 @@ static bool BindingLessFunc( KeyValues * const & lhs, KeyValues * const &rhs ) p2 = const_cast< KeyValues * >( rhs ); return ( Q_stricmp( p1->GetString( "Action" ), p2->GetString( "Action" ) ) < 0 ) ? true : false; } +#endif CKeyBindingHelpDialog::CKeyBindingHelpDialog( Panel *parent, Panel *panelToView, KeyBindingContextHandle_t handle, KeyCode code, int modifiers ) : BaseClass( parent, "KeyBindingHelpDialog" ), diff --git a/src/vgui2/vgui_controls/KeyBoardEditorDialog.cpp b/src/vgui2/vgui_controls/KeyBoardEditorDialog.cpp index 629c692737..c4d0f45163 100644 --- a/src/vgui2/vgui_controls/KeyBoardEditorDialog.cpp +++ b/src/vgui2/vgui_controls/KeyBoardEditorDialog.cpp @@ -15,6 +15,9 @@ #include "KeyValues.h" #include "vgui/Cursor.h" #include "tier1/utldict.h" +#ifdef NEO // Unity build +#include "Common.h" +#endif // NOTE: This has to be the last file included! #include "tier0/memdbgon.h" @@ -22,6 +25,7 @@ using namespace vgui; +#ifndef NEO // Unity build static char *CopyString( const char *in ) { if ( !in ) @@ -32,6 +36,7 @@ static char *CopyString( const char *in ) V_strncpy( n, in, len + 1 ); return n; } +#endif CKeyBoardEditorPage::SaveMapping_t::SaveMapping_t() : map( 0 ) { @@ -549,6 +554,7 @@ void CKeyBoardEditorPage::GetMappingList( Panel *panel, CUtlVector< PanelKeyBind } } +#ifndef NEO // Unity build static bool BindingLessFunc( KeyValues * const & lhs, KeyValues * const &rhs ) { KeyValues *p1, *p2; @@ -557,6 +563,7 @@ static bool BindingLessFunc( KeyValues * const & lhs, KeyValues * const &rhs ) p2 = const_cast< KeyValues * >( rhs ); return ( Q_stricmp( p1->GetString( "Action" ), p2->GetString( "Action" ) ) < 0 ) ? true : false; } +#endif void CKeyBoardEditorPage::AnsiText( char const *token, char *out, int nBuflen ) { diff --git a/src/vgui2/vgui_controls/ListPanel.cpp b/src/vgui2/vgui_controls/ListPanel.cpp index 3e991a01e4..c281ece625 100644 --- a/src/vgui2/vgui_controls/ListPanel.cpp +++ b/src/vgui2/vgui_controls/ListPanel.cpp @@ -31,16 +31,20 @@ #include #include #include +#ifdef NEO // Unity build +#include "Common.h" +#endif // memdbgon must be the last include file in a .cpp file #include "tier0/memdbgon.h" using namespace vgui; - +#ifndef NEO // Unity build enum { WINDOW_BORDER_WIDTH=2 // the width of the window's border }; +#endif #ifndef NEO // Please use Max/Min/Clamp from basetypes.h instead diff --git a/src/vgui2/vgui_controls/ListViewPanel.cpp b/src/vgui2/vgui_controls/ListViewPanel.cpp index 59f05ab6a0..51ae830df8 100644 --- a/src/vgui2/vgui_controls/ListViewPanel.cpp +++ b/src/vgui2/vgui_controls/ListViewPanel.cpp @@ -24,16 +24,20 @@ #include #include #include +#ifdef NEO // Unity build +#include "Common.h" +#endif // memdbgon must be the last include file in a .cpp file!!! #include using namespace vgui; - +#ifndef NEO // Unity build enum { WINDOW_BORDER_WIDTH=2 // the width of the window's border }; +#endif namespace vgui { diff --git a/src/vgui2/vgui_controls/Panel.cpp b/src/vgui2/vgui_controls/Panel.cpp index 61f080984f..354e0ce0dd 100644 --- a/src/vgui2/vgui_controls/Panel.cpp +++ b/src/vgui2/vgui_controls/Panel.cpp @@ -44,6 +44,10 @@ #include "tier0/vprof.h" +#ifdef NEO // Unity build +#include "Common.h" +#endif + // memdbgon must be the last include file in a .cpp file!!! #include @@ -68,6 +72,7 @@ COMPILE_TIME_ASSERT( Panel::PIN_LAST == ARRAYSIZE( g_PinCornerStrings ) ); extern int GetBuildModeDialogCount(); +#ifndef NEO // Unity build static char *CopyString( const char *in ) { if ( !in ) @@ -78,6 +83,7 @@ static char *CopyString( const char *in ) V_strncpy( n, in, len + 1 ); return n; } +#endif // Temporary convar to help debug why the MvMVictoryMannUpPanel TabContainer is sometimes way off to the left. diff --git a/src/vgui2/vgui_controls/PerforceFileList.cpp b/src/vgui2/vgui_controls/PerforceFileList.cpp index a30cd1e5b0..09cf2d65fe 100644 --- a/src/vgui2/vgui_controls/PerforceFileList.cpp +++ b/src/vgui2/vgui_controls/PerforceFileList.cpp @@ -14,6 +14,9 @@ #include "filesystem.h" #include "p4lib/ip4.h" #include "tier2/tier2.h" +#ifdef NEO // Unity build +#include "Common.h" +#endif // memdbgon must be the last include file in a .cpp file!!! #include @@ -22,6 +25,7 @@ using namespace vgui; +#ifndef NEO // Unity build static int ListFileNameSortFunc([[maybe_unused]] ListPanel *pPanel, const ListPanelItem &item1, const ListPanelItem &item2 ) { bool dir1 = item1.kv->GetInt("directory") == 1; @@ -123,11 +127,13 @@ static int ListFileTypeSortFunc(ListPanel *pPanel, const ListPanelItem &item1, c { return ListBaseStringSortFunc( pPanel, item1, item2, "type" ); } +#endif // NEO //----------------------------------------------------------------------------- // Dictionary of start dir contexts //----------------------------------------------------------------------------- +#ifndef NEO // Unity build struct ColumnInfo_t { char const *columnName; @@ -139,8 +145,13 @@ struct ColumnInfo_t SortFunc *pfnSort; Label::Alignment alignment; }; +#endif +#ifdef NEO // Unity build +static ColumnInfo_t g_ColInfoPerforce[] = +#else static ColumnInfo_t g_ColInfo[] = +#endif { { "text", "#PerforceFileList_Col_Name", 175, 20, 10000, ListPanel::COLUMN_UNHIDABLE, &ListFileNameSortFunc , Label::a_west }, { "type", "#PerforceFileList_Col_Type", 150, 20, 10000, 0, &ListFileTypeSortFunc , Label::a_west }, @@ -161,9 +172,15 @@ PerforceFileList::PerforceFileList( Panel *pParent, const char *pPanelName ) : m_bShowDeletedFiles = false; // list panel +#ifdef NEO // Unity build + for ( int i = 0; i < ARRAYSIZE( g_ColInfoPerforce ); ++i ) + { + const ColumnInfo_t& info = g_ColInfoPerforce[ i ]; +#else for ( int i = 0; i < ARRAYSIZE( g_ColInfo ); ++i ) { const ColumnInfo_t& info = g_ColInfo[ i ]; +#endif AddColumnHeader( i, info.columnName, info.columnText, info.startingWidth, info.minWidth, info.maxWidth, info.flags ); SetSortFunc( i, info.pfnSort ); diff --git a/src/vgui2/vgui_controls/PropertyDialog.cpp b/src/vgui2/vgui_controls/PropertyDialog.cpp index b5d091957a..eb11c9897d 100644 --- a/src/vgui2/vgui_controls/PropertyDialog.cpp +++ b/src/vgui2/vgui_controls/PropertyDialog.cpp @@ -60,7 +60,11 @@ PropertyDialog::~PropertyDialog() // Purpose: Returns a pointer to the PropertySheet this dialog encapsulates // Output : PropertySheet * //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +vgui::PropertySheet *PropertyDialog::GetPropertySheet() +#else PropertySheet *PropertyDialog::GetPropertySheet() +#endif { return _propertySheet; } diff --git a/src/vgui2/vgui_controls/ToolWindow.cpp b/src/vgui2/vgui_controls/ToolWindow.cpp index 51109c6433..092c0c40fc 100644 --- a/src/vgui2/vgui_controls/ToolWindow.cpp +++ b/src/vgui2/vgui_controls/ToolWindow.cpp @@ -108,7 +108,11 @@ bool ToolWindow::IsDraggableTabContainer() const // Purpose: Returns a pointer to the PropertySheet this dialog encapsulates // Output : PropertySheet * //----------------------------------------------------------------------------- +#ifdef NEO // Unity build +vgui::PropertySheet *ToolWindow::GetPropertySheet() +#else PropertySheet *ToolWindow::GetPropertySheet() +#endif { return m_pPropertySheet; } diff --git a/src/vgui2/vgui_controls/TreeView.cpp b/src/vgui2/vgui_controls/TreeView.cpp index b7ad4d3b84..937c4cd9dd 100644 --- a/src/vgui2/vgui_controls/TreeView.cpp +++ b/src/vgui2/vgui_controls/TreeView.cpp @@ -28,6 +28,9 @@ #include #include #include +#ifdef NEO // Unity build +#include "Common.h" +#endif #include "tier1/utlstring.h" @@ -39,10 +42,12 @@ #endif using namespace vgui; +#ifndef NEO // Unity build enum { WINDOW_BORDER_WIDTH=2 // the width of the window's border }; +#endif #define TREE_INDENT_AMOUNT 20 diff --git a/src/vgui2/vgui_controls/URLLabel.cpp b/src/vgui2/vgui_controls/URLLabel.cpp index ef77eb8884..cd132c67cb 100644 --- a/src/vgui2/vgui_controls/URLLabel.cpp +++ b/src/vgui2/vgui_controls/URLLabel.cpp @@ -168,7 +168,11 @@ void URLLabel::GetSettings( KeyValues *outResourceData ) const char *URLLabel::GetDescription( void ) { static char buf[1024]; +#ifdef NEO // Unity build + V_sprintf_safe(buf, "%s, string URLText", BaseClass::GetDescription()); +#else _snprintf(buf, sizeof(buf), "%s, string URLText", BaseClass::GetDescription()); +#endif return buf; } From d5a04e886e6e3ca4aa131424d848d92cc481a729 Mon Sep 17 00:00:00 2001 From: nullsystem <15316579+nullsystem@users.noreply.github.com> Date: Tue, 9 Jun 2026 19:32:01 +0100 Subject: [PATCH 2/4] fix windows debug --- src/game/client/CMakeLists.txt | 6 +++--- src/game/server/CMakeLists.txt | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/game/client/CMakeLists.txt b/src/game/client/CMakeLists.txt index da2a57fca7..8071cb22d6 100644 --- a/src/game/client/CMakeLists.txt +++ b/src/game/client/CMakeLists.txt @@ -1760,7 +1760,6 @@ target_sources_grouped( ) set(UNITY_SOURCE_NEO_WEAPONS - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp @@ -1779,8 +1778,6 @@ set(UNITY_SOURCE_NEO_WEAPONS ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp @@ -1839,6 +1836,9 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.h ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_types.h ${UNITY_SOURCE_NEO_WEAPONS} + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ) if(NEO_BUILD_WEAPON_PBK56S) diff --git a/src/game/server/CMakeLists.txt b/src/game/server/CMakeLists.txt index 1e94e2605c..a58b193f86 100644 --- a/src/game/server/CMakeLists.txt +++ b/src/game/server/CMakeLists.txt @@ -1613,7 +1613,6 @@ target_sources_grouped( ) set(UNITY_SOURCE_NEO_WEAPONS - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_aa13.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_balc.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_bits.cpp @@ -1632,8 +1631,6 @@ set(UNITY_SOURCE_NEO_WEAPONS ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mpns.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mx.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_mxs.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp - ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_proxmine.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_pz.cpp ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_smac.cpp @@ -1692,6 +1689,9 @@ target_sources_grouped( ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_zr68s.h ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_types.h ${UNITY_SOURCE_NEO_WEAPONS} + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/neo_weapon_parse.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobasecombatweapon.cpp + ${CMAKE_SOURCE_DIR}/game/shared/neo/weapons/weapon_neobaseprojectile.cpp ) if(NEO_BUILD_WEAPON_PBK56S) From e644ed6e0ae12435df9a0512b4264ee436cdf1c7 Mon Sep 17 00:00:00 2001 From: nullsystem <15316579+nullsystem@users.noreply.github.com> Date: Wed, 10 Jun 2026 18:30:47 +0100 Subject: [PATCH 3/4] fix warn for gcc 13.3.0 --- src/game/server/ai_trackpather.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/game/server/ai_trackpather.cpp b/src/game/server/ai_trackpather.cpp index 77bc49c760..57ee423d1f 100644 --- a/src/game/server/ai_trackpather.cpp +++ b/src/game/server/ai_trackpather.cpp @@ -693,7 +693,11 @@ void CAI_TrackPather::CurrentPathDirection( Vector *pVecPathDir ) //----------------------------------------------------------------------------- void CAI_TrackPather::ComputePointAlongCurrentPath( float flDistance, float flPerpDist, Vector *pTarget ) { +#ifdef NEO // Unity build + Vector vecPathDir(0, 0, 0); +#else Vector vecPathDir; +#endif Vector vecStartPoint; ClosestPointToCurrentPath( &vecStartPoint ); *pTarget = vecStartPoint; From d9cf68fec77000a7ccd45591982f6fa025bf1662 Mon Sep 17 00:00:00 2001 From: nullsystem <15316579+nullsystem@users.noreply.github.com> Date: Thu, 11 Jun 2026 17:50:03 +0100 Subject: [PATCH 4/4] Differ triggers.cpp unity change --- src/game/server/triggers.cpp | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/src/game/server/triggers.cpp b/src/game/server/triggers.cpp index 32aa6a9ba6..1014cfa268 100644 --- a/src/game/server/triggers.cpp +++ b/src/game/server/triggers.cpp @@ -4693,11 +4693,15 @@ void CTriggerVPhysicsMotion::StartTouch( CBaseEntity *pOther ) } #ifdef NEO // Unity build - triggerevent_t event = {}; + triggerevent_t event; + if ( !PhysGetTriggerEvent( &event, this ) ) + { + event = {}; + } #else triggerevent_t event; -#endif PhysGetTriggerEvent( &event, this ); +#endif if ( event.pObject ) { // these all get done again on save/load, so check @@ -4735,11 +4739,15 @@ void CTriggerVPhysicsMotion::EndTouch( CBaseEntity *pOther ) pPlayer->m_Local.m_bSlowMovement = false; } #ifdef NEO // Unity build - triggerevent_t event = {}; + triggerevent_t event; + if ( !PhysGetTriggerEvent( &event, this ) ) + { + event = {}; + } #else triggerevent_t event; -#endif PhysGetTriggerEvent( &event, this ); +#endif if ( event.pObject && m_pController ) { m_pController->DetachObject( event.pObject );