From f7b49a6ab2ff5c7a3521832d328515a54fa5bf35 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 18:55:36 -0400 Subject: [PATCH 01/75] first crack at the demotester in ci/cd --- .github/workflows/windows.yml | 21 ++++++++++++++++++++- ci/win-get-demotester.ps1 | 15 +++++++++++++++ 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 ci/win-get-demotester.ps1 diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index aa070340d..996f77763 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -37,6 +37,25 @@ jobs: run: cmake --build .\build\ --config RelWithDebInfo --parallel - name: Prepare artifact run: .\ci\win-artifact.ps1 + - name: Download DemoTester + run: .\ci\win-get-demotester.ps1 + continue-on-error: true + - name: Decrypt IWADs + run: | + python .\build\demotester\secret.py decrypt plutonia + python .\build\demotester\secret.py decrypt tnt + python .\build\demotester\secret.py decrypt doom + python .\build\demotester\secret.py decrypt doom1 + python .\build\demotester\secret.py decrypt doom2 + python .\build\demotester\secret.py decrypt hacx + env: + SECRET_KEY: ${{ secrets.DEMOTESTER_IWAD_KEY }} + continue-on-error: true + - name: Run DemoTester + run: python -m unittest .\build\demotester\odatestcases.py + env: + ODAMEX_BIN: .\build\artifact\client\RelWithDebInfo\odamex.exe + continue-on-error: true - name: Upload artifact to B2 run: python .\ci\upload-b2.py .\build\archive Win-x64 env: @@ -93,4 +112,4 @@ jobs: - name: Prepare build run: .\ci\win-mingw-buildgen.ps1 - name: Run build - run: cmake --build .\build-gcc\ + run: cmake --build .\build-gcc\ \ No newline at end of file diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 new file mode 100644 index 000000000..8cdfc46b1 --- /dev/null +++ b/ci/win-get-demotester.ps1 @@ -0,0 +1,15 @@ +Set-PSDebug -Trace 1 + +$DemoTesterPath = "https://github.com/bcahue/odatests/releases/download/1.0.0/odatests-v1.0.0.zip" +$DemoResourcePath = "https://github.com/bcahue/odatests-resources/releases/download/1.0.0/odatests-resources-v1.0.0.zip" + +Set-Location "build" +New-Item -Name "demotester" -ItemType "directory" | Out-Null + +Invoke-WebRequest -Uri $DemoTesterPath -OutFile . +Invoke-WebRequest -Uri $DemoResourcePath -OutFile . + +Expand-Archive $DemoTesterPath -Destination .demotester/ +Expand-Archive $DemoResourcePath -Destination .demotester/ + +Set-Location .. From 796fba89e3b4e496a019aef8759963098630af73 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 19:23:24 -0400 Subject: [PATCH 02/75] fix small oopsie on demotester get --- ci/win-get-demotester.ps1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index 8cdfc46b1..798ecccaf 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -6,10 +6,10 @@ $DemoResourcePath = "https://github.com/bcahue/odatests-resources/releases/downl Set-Location "build" New-Item -Name "demotester" -ItemType "directory" | Out-Null -Invoke-WebRequest -Uri $DemoTesterPath -OutFile . -Invoke-WebRequest -Uri $DemoResourcePath -OutFile . +Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip +Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip -Expand-Archive $DemoTesterPath -Destination .demotester/ -Expand-Archive $DemoResourcePath -Destination .demotester/ +Expand-Archive .\odatests.zip -Destination .\demotester +Expand-Archive .\odatests-resources.zip -Destination .\demotester Set-Location .. From 686460cdaec3bebed3b2c7c6e63be510aae92a25 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 19:54:24 -0400 Subject: [PATCH 03/75] try 7z instead of ps --- ci/win-get-demotester.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index 798ecccaf..630362d67 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -9,7 +9,7 @@ New-Item -Name "demotester" -ItemType "directory" | Out-Null Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip -Expand-Archive .\odatests.zip -Destination .\demotester -Expand-Archive .\odatests-resources.zip -Destination .\demotester +7z.exe e odatests.zip -o./demotester +7z.exe e odatests-resources.zip -o./demotester Set-Location .. From 58d158a7b5560c5099a64be79b25f948a8993ea9 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 21:44:22 -0400 Subject: [PATCH 04/75] use proper 7z commands --- ci/win-get-demotester.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index 630362d67..37e2d5b36 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -9,7 +9,7 @@ New-Item -Name "demotester" -ItemType "directory" | Out-Null Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip -7z.exe e odatests.zip -o./demotester -7z.exe e odatests-resources.zip -o./demotester +7z.exe e odatests.zip -odemotester -y +7z.exe e odatests-resources.zip -odemotester -y Set-Location .. From 8ea43615d5cbf67af1fcb86f6d7595a750a54d80 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 22:35:37 -0400 Subject: [PATCH 05/75] attempt to fix lost py files --- .github/workflows/windows.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 996f77763..e3ebe2b60 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -52,9 +52,10 @@ jobs: SECRET_KEY: ${{ secrets.DEMOTESTER_IWAD_KEY }} continue-on-error: true - name: Run DemoTester - run: python -m unittest .\build\demotester\odatestcases.py + run: python -m unittest odatestcases.py env: - ODAMEX_BIN: .\build\artifact\client\RelWithDebInfo\odamex.exe + ODAMEX_BIN: ..\..\build\artifact\client\RelWithDebInfo\odamex.exe + working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 run: python .\ci\upload-b2.py .\build\archive Win-x64 From 6db0b63411c8ec9cb8f9a044ba25ec22166cf6fe Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 22:51:55 -0400 Subject: [PATCH 06/75] update py packages --- .github/workflows/windows.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index e3ebe2b60..0aa1735b5 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -29,6 +29,7 @@ jobs: with: packages: | b2sdk + PyNaCl - name: Prepare build run: .\ci\win-buildgen.ps1 - name: Turn on problem matcher From 00fea7a6d0ac794265a4cdc7ac852f2a8972f6c2 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 23:15:10 -0400 Subject: [PATCH 07/75] change cwd for iwad decrypting --- .github/workflows/windows.yml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 0aa1735b5..c82644acd 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -43,14 +43,15 @@ jobs: continue-on-error: true - name: Decrypt IWADs run: | - python .\build\demotester\secret.py decrypt plutonia - python .\build\demotester\secret.py decrypt tnt - python .\build\demotester\secret.py decrypt doom - python .\build\demotester\secret.py decrypt doom1 - python .\build\demotester\secret.py decrypt doom2 - python .\build\demotester\secret.py decrypt hacx + python .\secret.py decrypt plutonia + python .\secret.py decrypt tnt + python .\secret.py decrypt doom + python .\secret.py decrypt doom1 + python .\secret.py decrypt doom2 + python .\secret.py decrypt hacx env: SECRET_KEY: ${{ secrets.DEMOTESTER_IWAD_KEY }} + working-directory: .\build\demotester continue-on-error: true - name: Run DemoTester run: python -m unittest odatestcases.py From 05fa09ecf53740828053707297a9e2a12d7ca93f Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 23:16:49 -0400 Subject: [PATCH 08/75] fix redundant path --- .github/workflows/windows.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index c82644acd..3e2c88b92 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -56,7 +56,7 @@ jobs: - name: Run DemoTester run: python -m unittest odatestcases.py env: - ODAMEX_BIN: ..\..\build\artifact\client\RelWithDebInfo\odamex.exe + ODAMEX_BIN: ..\artifact\client\RelWithDebInfo\odamex.exe working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From a31dc2a9f4dbab3608c2c90c1510efb82c932ca3 Mon Sep 17 00:00:00 2001 From: bcahue Date: Mon, 11 Apr 2022 23:35:37 -0400 Subject: [PATCH 09/75] 7z x gonna give it to ya, and by it, i mean a working pipeline (hopefully) --- ci/win-get-demotester.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index 37e2d5b36..f92659a59 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -9,7 +9,7 @@ New-Item -Name "demotester" -ItemType "directory" | Out-Null Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip -7z.exe e odatests.zip -odemotester -y -7z.exe e odatests-resources.zip -odemotester -y +7z.exe x odatests.zip -odemotester -y +7z.exe x odatests-resources.zip -odemotester -y Set-Location .. From 488a74d57f095892bf3dbe15e7e2029978ef7793 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 00:08:30 -0400 Subject: [PATCH 10/75] try to run one after to see whats up --- .github/workflows/windows.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 3e2c88b92..23d1d0145 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -59,6 +59,10 @@ jobs: ODAMEX_BIN: ..\artifact\client\RelWithDebInfo\odamex.exe working-directory: .\build\demotester continue-on-error: true + - name: Run DemoTester + run: ..\artifact\client\RelWithDebInfo\odamex.exe -iwad wads\doom2.wad +demotest .\demos\impmiss.lmp + working-directory: .\build\demotester + continue-on-error: true - name: Upload artifact to B2 run: python .\ci\upload-b2.py .\build\archive Win-x64 env: From ba261021c61eb9b95c0816fbf34e66c476e96e04 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 00:08:40 -0400 Subject: [PATCH 11/75] more changes --- .github/workflows/windows.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 23d1d0145..5706a20b9 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -59,7 +59,7 @@ jobs: ODAMEX_BIN: ..\artifact\client\RelWithDebInfo\odamex.exe working-directory: .\build\demotester continue-on-error: true - - name: Run DemoTester + - name: Run Odamex Demo Test without Tester run: ..\artifact\client\RelWithDebInfo\odamex.exe -iwad wads\doom2.wad +demotest .\demos\impmiss.lmp working-directory: .\build\demotester continue-on-error: true From 1671d7b39142ceccb87e11e28bdb10186dfb9ee9 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 00:09:54 -0400 Subject: [PATCH 12/75] use oda that actually has all the dlls --- .github/workflows/windows.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 5706a20b9..a12540e13 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -56,11 +56,11 @@ jobs: - name: Run DemoTester run: python -m unittest odatestcases.py env: - ODAMEX_BIN: ..\artifact\client\RelWithDebInfo\odamex.exe + ODAMEX_BIN: ..\artifact\odamex.exe working-directory: .\build\demotester continue-on-error: true - name: Run Odamex Demo Test without Tester - run: ..\artifact\client\RelWithDebInfo\odamex.exe -iwad wads\doom2.wad +demotest .\demos\impmiss.lmp + run: ..\artifact\odamex.exe -iwad wads\doom2.wad +demotest .\demos\impmiss.lmp working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From d452515e9116b1c14b05a1248b7f9f4812a1c648 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 00:32:44 -0400 Subject: [PATCH 13/75] remove testing step --- .github/workflows/windows.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index a12540e13..48da0c0a2 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -59,10 +59,6 @@ jobs: ODAMEX_BIN: ..\artifact\odamex.exe working-directory: .\build\demotester continue-on-error: true - - name: Run Odamex Demo Test without Tester - run: ..\artifact\odamex.exe -iwad wads\doom2.wad +demotest .\demos\impmiss.lmp - working-directory: .\build\demotester - continue-on-error: true - name: Upload artifact to B2 run: python .\ci\upload-b2.py .\build\archive Win-x64 env: From bb742b068c92838fecf625b8a9bd4ab1aa495376 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 01:03:38 -0400 Subject: [PATCH 14/75] try 8 max procs --- .github/workflows/windows.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 48da0c0a2..7c1b654f1 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -57,6 +57,7 @@ jobs: run: python -m unittest odatestcases.py env: ODAMEX_BIN: ..\artifact\odamex.exe + MAX_ODAMEX_PROCS: 8 working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From 489f95905120e09ebf3ed4b62dba37ec2c8cf61a Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 12 Apr 2022 01:28:52 -0400 Subject: [PATCH 15/75] Revert "try 8 max procs" This reverts commit bb742b068c92838fecf625b8a9bd4ab1aa495376. --- .github/workflows/windows.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 7c1b654f1..48da0c0a2 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -57,7 +57,6 @@ jobs: run: python -m unittest odatestcases.py env: ODAMEX_BIN: ..\artifact\odamex.exe - MAX_ODAMEX_PROCS: 8 working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From 546595824355aeb9d642d1c7ab4d18a4c0b6dcdb Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 13 Apr 2022 01:38:17 -0400 Subject: [PATCH 16/75] update odatests version --- ci/win-get-demotester.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index f92659a59..a2c1aa159 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -1,6 +1,6 @@ Set-PSDebug -Trace 1 -$DemoTesterPath = "https://github.com/bcahue/odatests/releases/download/1.0.0/odatests-v1.0.0.zip" +$DemoTesterPath = "https://github.com/bcahue/odatests/releases/download/1.0.1/OdaTests-v1.0.1.zip" $DemoResourcePath = "https://github.com/bcahue/odatests-resources/releases/download/1.0.0/odatests-resources-v1.0.0.zip" Set-Location "build" From d31f1a88f676ba71539d7bb7121fbdd37ad158e6 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 13 Apr 2022 01:39:20 -0400 Subject: [PATCH 17/75] try 8 procs again now that the tester is fixed --- .github/workflows/windows.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 48da0c0a2..7c1b654f1 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -57,6 +57,7 @@ jobs: run: python -m unittest odatestcases.py env: ODAMEX_BIN: ..\artifact\odamex.exe + MAX_ODAMEX_PROCS: 8 working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From d264447b6210c1dec27cc58efc26a86020cd4a1c Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 13 Apr 2022 02:11:11 -0400 Subject: [PATCH 18/75] fix how the tests are called --- .github/workflows/windows.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 7c1b654f1..76653257d 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -54,7 +54,7 @@ jobs: working-directory: .\build\demotester continue-on-error: true - name: Run DemoTester - run: python -m unittest odatestcases.py + run: python .\odatestcases.py env: ODAMEX_BIN: ..\artifact\odamex.exe MAX_ODAMEX_PROCS: 8 From 7bed8f5a23705ed9de3db5b2161c318808eb8a80 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 13 Apr 2022 02:37:35 -0400 Subject: [PATCH 19/75] use default proc limit --- .github/workflows/windows.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 76653257d..caa02afd4 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -57,7 +57,6 @@ jobs: run: python .\odatestcases.py env: ODAMEX_BIN: ..\artifact\odamex.exe - MAX_ODAMEX_PROCS: 8 working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 From c472e24e4ded9e5ae987f5c6ea4b641979d0dcc5 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sat, 27 May 2023 14:34:00 -0400 Subject: [PATCH 20/75] Add tab and buttons for respawn, fast, and no monsters --- client/gui/gui_boot.cpp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 35cd3d8c9..f1194c4f8 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -112,6 +112,9 @@ class BootWindow : public Fl_Window Fl_Hold_Browser* m_IWADBrowser; Fl_Check_Browser* m_PWADSelectBrowser; Fl_Hold_Browser* m_PWADOrderBrowser; + Fl_Check_Button* m_nomonstersCheckButton; + Fl_Check_Button* m_fastCheckButton; + Fl_Check_Button* m_respawnCheckButton; StringTokens m_WADDirs; Fl_Hold_Browser* m_WADDirList; @@ -165,6 +168,24 @@ class BootWindow : public Fl_Window } // Fl_Button* doWADRemove m_tabPWADs->end(); } // Fl_Group* tabPWADs + { + Fl_Group* tabGameOptions = + new Fl_Group(0, 25, 425, 175, "Game Options"); + { + m_nomonstersCheckButton = new Fl_Check_Button(10, 50, 20, 20, " No Monsters"); + m_nomonstersCheckButton->down_box(FL_DOWN_BOX); + } + { + m_fastCheckButton = new Fl_Check_Button(10, 100, 20, 20, " Fast Monsters"); + m_fastCheckButton->down_box(FL_DOWN_BOX); + } + { + m_respawnCheckButton = new Fl_Check_Button(10, 150, 20, 20, " Respawn Monsters"); + m_respawnCheckButton->down_box(FL_DOWN_BOX); + } + tabGameOptions->end(); + + } // Fl_Group* tabGameOptions { Fl_Group* tabWADDirs = new Fl_Group(0, 25, 425, 175, "Resource Locations"); From fe9f07ddf4d7f8a2cdccb463e905419be0261b87 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 28 May 2023 01:30:20 -0400 Subject: [PATCH 21/75] Return values of options alongside wads when using boot gui --- client/gui/gui_boot.cpp | 8 ++++++++ client/gui/gui_boot.h | 3 +++ client/src/d_main.cpp | 12 +++++++++--- 3 files changed, 20 insertions(+), 3 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index f1194c4f8..6c61784aa 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -293,6 +293,7 @@ class BootWindow : public Fl_Window } boot->selectedWADs(); + boot->setOptions(); Fl::delete_widget(boot); } @@ -518,6 +519,13 @@ class BootWindow : public Fl_Window } } + void setOptions() + { + g_SelectedWADs.fast = m_fastCheckButton->value(); + g_SelectedWADs.nomonsters = m_nomonstersCheckButton->value(); + g_SelectedWADs.respawn = m_respawnCheckButton->value(); + } + /** * @brief Update the WAD dir browser widget from the vector. */ diff --git a/client/gui/gui_boot.h b/client/gui/gui_boot.h index e70fede4e..506c74aa5 100644 --- a/client/gui/gui_boot.h +++ b/client/gui/gui_boot.h @@ -27,6 +27,9 @@ struct scannedWADs_t { std::string iwad; StringTokens pwads; + bool nomonsters; + bool respawn; + bool fast; }; scannedWADs_t GUI_BootWindow(); diff --git a/client/src/d_main.cpp b/client/src/d_main.cpp index d6d966b35..feae6cde2 100644 --- a/client/src/d_main.cpp +++ b/client/src/d_main.cpp @@ -801,6 +801,12 @@ void D_DoomMain() scannedWADs_t wads = GUI_BootWindow(); iwad = wads.iwad; pwads = wads.pwads; + // Nomonsters + sv_nomonsters = wads.nomonsters; + // Respawn + sv_monstersrespawn = wads.respawn; + // Fast + sv_fastmonsters = wads.fast; } } @@ -860,13 +866,13 @@ void D_DoomMain() vid_ticker.SetDefault("1"); // Nomonsters - sv_nomonsters = Args.CheckParm("-nomonsters"); + //sv_nomonsters = Args.CheckParm("-nomonsters"); // Respawn - sv_monstersrespawn = Args.CheckParm("-respawn"); + //sv_monstersrespawn = Args.CheckParm("-respawn"); // Fast - sv_fastmonsters = Args.CheckParm("-fast"); + //sv_fastmonsters = Args.CheckParm("-fast"); // Pistol start g_resetinvonexit = Args.CheckParm("-pistolstart"); From 493a68704b292bc232a3a0309784a29759f4a429 Mon Sep 17 00:00:00 2001 From: Ralph Vickers Date: Mon, 29 May 2023 19:40:18 -0400 Subject: [PATCH 22/75] Improve messaging in Horde and Survival coop modes. --- client/src/st_new.cpp | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/client/src/st_new.cpp b/client/src/st_new.cpp index 8e12ce198..ac59c38bb 100644 --- a/client/src/st_new.cpp +++ b/client/src/st_new.cpp @@ -1368,9 +1368,14 @@ void LevelStateHUD() break; } case LevelState::ENDROUND_COUNTDOWN: { - StrFormat(lines.title, - "Round " TEXTCOLOR_YELLOW "%d " TEXTCOLOR_GREY "complete\n", - ::levelstate.getRound()); + if (G_IsCoopGame() | G_IsHordeMode()) + StrFormat(lines.title, + "Attempt " TEXTCOLOR_YELLOW "%d " TEXTCOLOR_GREY "complete\n", + ::levelstate.getRound()); + else + StrFormat(lines.title, + "Round " TEXTCOLOR_YELLOW "%d " TEXTCOLOR_GREY "complete\n", + ::levelstate.getRound()); WinInfo win = ::levelstate.getWinInfo(); if (win.type == WinInfo::WIN_DRAW) @@ -1381,15 +1386,27 @@ void LevelStateHUD() else if (win.type == WinInfo::WIN_TEAM) StrFormat(lines.subtitle[0], "%s team wins the round", WinToColorString(win).c_str()); + else if (G_IsCoopGame() | G_IsHordeMode()) + StrFormat(lines.subtitle[0], "Next attempt in " TEXTCOLOR_GREEN "%d", + ::levelstate.getCountdown()); else StrFormat(lines.subtitle[0], "Next round in " TEXTCOLOR_GREEN "%d", ::levelstate.getCountdown()); break; } case LevelState::ENDGAME_COUNTDOWN: { - StrFormat(lines.title, "Match complete"); - WinInfo win = ::levelstate.getWinInfo(); + //Upper Text + if + (win.type == WinInfo::WIN_EVERYBODY) + StrFormat(lines.title, TEXTCOLOR_YELLOW "Mission Success!"); + else if + (win.type == WinInfo::WIN_NOBODY) + StrFormat(lines.title, TEXTCOLOR_RED "Mission Failed!"); + else + StrFormat(lines.title, "Match complete"); + + // Lower Text if (win.type == WinInfo::WIN_DRAW) StrFormat(lines.subtitle[0], "The game ends in a tie"); else if (win.type == WinInfo::WIN_PLAYER) From a4623454300dc72de8f7bbce92a03939013afe91 Mon Sep 17 00:00:00 2001 From: ceski <56656010+ceski-1@users.noreply.github.com> Date: Thu, 1 Jun 2023 23:12:03 -0700 Subject: [PATCH 23/75] macOS Audio Unit: Fix multitrack MIDI looping --- client/sdl/i_musicsystem_au.cpp | 41 +++++++++++++++++++++------------ 1 file changed, 26 insertions(+), 15 deletions(-) diff --git a/client/sdl/i_musicsystem_au.cpp b/client/sdl/i_musicsystem_au.cpp index c6c97ad40..70cae2f79 100644 --- a/client/sdl/i_musicsystem_au.cpp +++ b/client/sdl/i_musicsystem_au.cpp @@ -180,9 +180,12 @@ void AuMusicSystem::startSong(byte* data, size_t length, bool loop) return; } + MusicTimeStamp maxtime = 0; for (UInt32 i = 0; i < outNumberOfTracks; i++) { MusicTrack track; + MusicTimeStamp time; + UInt32 size = sizeof(time); if (MusicSequenceGetIndTrack(m_sequence, i, &track) != noErr) { @@ -190,31 +193,39 @@ void AuMusicSystem::startSong(byte* data, size_t length, bool loop) return; } - struct s_loopinfo - { - MusicTimeStamp time; - long loops; - } LoopInfo; - - UInt32 inLength = sizeof(LoopInfo); - - if (MusicTrackGetProperty(track, kSequenceTrackProperty_LoopInfo, &LoopInfo, - &inLength) != noErr) + if (MusicTrackGetProperty(track, kSequenceTrackProperty_TrackLength, &time, + &size) != noErr) { Printf(PRINT_HIGH, "I_PlaySong: MusicTrackGetProperty failed\n"); return; } - inLength = sizeof(LoopInfo.time); + if (time > maxtime) + { + maxtime = time; + } + } + + for (UInt32 i = 0; i < outNumberOfTracks; i++) + { + MusicTrack track; +#if MAC_OS_X_VERSION_MIN_REQUIRED < 1050 + typedef struct + { + MusicTimeStamp loopDuration; + SInt32 numberOfLoops; + } MusicTrackLoopInfo; +#endif + MusicTrackLoopInfo LoopInfo; - if (MusicTrackGetProperty(track, kSequenceTrackProperty_TrackLength, - &LoopInfo.time, &inLength) != noErr) + if (MusicSequenceGetIndTrack(m_sequence, i, &track) != noErr) { - Printf(PRINT_HIGH, "I_PlaySong: MusicTrackGetProperty failed\n"); + Printf(PRINT_HIGH, "I_PlaySong: MusicSequenceGetIndTrack failed\n"); return; } - LoopInfo.loops = loop ? 0 : 1; + LoopInfo.loopDuration = maxtime; + LoopInfo.numberOfLoops = (loop ? 0 : 1); if (MusicTrackSetProperty(track, kSequenceTrackProperty_LoopInfo, &LoopInfo, sizeof(LoopInfo)) != noErr) From bafd9f7f23b3ed76fc5a1c6e0c209b50ae120fba Mon Sep 17 00:00:00 2001 From: bcahue Date: Fri, 9 Jun 2023 18:10:14 -0400 Subject: [PATCH 24/75] initial commit to fix players collecting not collecting items when not moving --- common/p_map.cpp | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/common/p_map.cpp b/common/p_map.cpp index bde33b11f..18d4041aa 100644 --- a/common/p_map.cpp +++ b/common/p_map.cpp @@ -697,12 +697,31 @@ static BOOL PIT_CheckThing (AActor *thing) // [SL] Work-around the additional height added to players // in P_CheckPosition. Don't let players grab items above // their real height! - if (!P_AllowPassover() || !tmthing->player || - thing->z < tmthing->z + tmthing->height - 24*FRACUNIT) + if (!P_AllowPassover() || thing->z < tmthing->z + tmthing->height - 24*FRACUNIT) P_TouchSpecialThing (thing, tmthing); // can remove thing + + return !solid; } - return !solid; + // killough 3/16/98: Allow non-solid moving objects to move through solid + // ones, by allowing the moving thing (tmthing) to move if it's non-solid, + // despite another solid thing being in the way. + // killough 4/11/98: Treat no-clipping things as not blocking + // ...but not in demo_compatibility mode + + // e6y + // Correction of wrong return value with demo_compatibility. + // There is no more synch on http://www.doomworld.com/sda/dwdemo/w303-115.zip + // (with correction in setMobjInfoValue) + if (demoplayback || !co_boomphys + //&& !prboom_comp[PC_TREAT_NO_CLIPPING_THINGS_AS_NOT_BLOCKING].state + ) + return !(thing->flags & MF_SOLID); + else + return !((thing->flags & MF_SOLID && !(thing->flags & MF_NOCLIP)) && + (tmthing->flags & MF_SOLID || (demoplayback || !co_boomphys))); + + // return !(thing->flags & MF_SOLID); // old code -- killough } // This routine checks for Lost Souls trying to be spawned // phares From c56c16c0a8156771956b89f55efd1f4297d1c3c2 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 10 Jun 2023 13:05:49 -0400 Subject: [PATCH 25/75] gross hack do not judge --- common/actor.h | 1 + common/p_mobj.cpp | 69 +++++++++++++++++++++++++++++++++++------- common/p_spec.cpp | 1 + server/src/sv_main.cpp | 8 +++++ 4 files changed, 68 insertions(+), 11 deletions(-) diff --git a/common/actor.h b/common/actor.h index c8fcaa724..112633616 100644 --- a/common/actor.h +++ b/common/actor.h @@ -521,6 +521,7 @@ class AActor : public DThinker SWORD gear; // killough 11/98: used in torque simulation bool onground; // NES - Fixes infinite jumping bug like a charm. + bool on_conveyer; // Blair - Update items on conveyers more often // a linked list of sectors where this object appears struct msecnode_s *touching_sectorlist; // phares 3/14/98 diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index e9ad3efd6..2938a3ebc 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -127,8 +127,8 @@ AActor::AActor() prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), - special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), + info(NULL), tics(0), on_conveyer(true),state(NULL), damage(0), flags(0), flags2(0), + flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), gear(0), onground(false), touching_sectorlist(NULL), deadtic(0), oldframe(0), @@ -148,8 +148,9 @@ AActor::AActor(const AActor& other) dropoffz(other.dropoffz), floorsector(other.floorsector), radius(other.radius), height(other.height), momx(other.momx), momy(other.momy), momz(other.momz), validcount(other.validcount), type(other.type), info(other.info), tics(other.tics), - state(other.state), damage(other.damage), flags(other.flags), flags2(other.flags2), - flags3(other.flags3), oflags(other.oflags), special1(other.special1), special2(other.special2), + state(other.state), on_conveyer(other.on_conveyer), damage(other.damage), + flags(other.flags), flags2(other.flags2), flags3(other.flags3), oflags(other.oflags), + special1(other.special1), special2(other.special2), health(other.health), movedir(other.movedir), movecount(other.movecount), visdir(other.visdir), reactiontime(other.reactiontime), threshold(other.threshold), player(other.player), lastlook(other.lastlook), special(other.special), @@ -196,6 +197,7 @@ AActor &AActor::operator= (const AActor &other) info = other.info; tics = other.tics; state = other.state; + on_conveyer = other.on_conveyer; damage = other.damage; flags = other.flags; flags2 = other.flags2; @@ -244,7 +246,7 @@ AActor::AActor(fixed_t ix, fixed_t iy, fixed_t iz, mobjtype_t itype) prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), + info(NULL), tics(0), on_conveyer(true), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -675,18 +677,63 @@ void AActor::RunThink () prevx = x; prevy = y; prevz = z; + if (!player) { prevangle = angle; prevpitch = pitch; } - // server removal of corpses only - if (!clientside && serverside) - { - if (type == MT_PLAYER && health <= 0) - deadtic++; - } + if (on_conveyer) + { + bool still_on = false; + + TThinkerIterator scrollIter; + DScroller* scroller; + while ((scroller = scrollIter.Next())) + { + if (scroller->GetType() == DScroller::sc_carry) + { + sector_t* sec = sectors + scroller->GetAffectee(); + msecnode_t* node; + AActor* thing; + fixed_t height = P_HighestHeightOfFloor(sec); + fixed_t waterheight = + sec->heightsec && P_HighestHeightOfFloor(sec->heightsec) > height + ? P_HighestHeightOfFloor(sec->heightsec) + : MININT; + + if ((subsector->sector - sectors) == scroller->GetAffectee()) + { + for (node = sec->touching_thinglist; node; node = node->m_snext) + { + if (!((thing = node->m_thing)->flags & MF_NOCLIP) && + (!(thing->flags & MF_NOGRAVITY || thing->z > height) || + thing->z < waterheight) && + thing == this) + { + still_on = true; + break; + } + } + } + + if (still_on) + { + break; + } + } + } + + on_conveyer = still_on; + } + + // server removal of corpses only + if (!clientside && serverside) + { + if (type == MT_PLAYER && health <= 0) + deadtic++; + } // GhostlyDeath -- Was a spectator but now it's nothing! if ((this->oflags & MFO_SPECTATOR ) && !player) diff --git a/common/p_spec.cpp b/common/p_spec.cpp index 4fdcf4407..002f4ccff 100644 --- a/common/p_spec.cpp +++ b/common/p_spec.cpp @@ -2556,6 +2556,7 @@ void DScroller::RunThink () { // Move objects only if on floor or underwater, // non-floating, and clipped. + thing->on_conveyer = true; thing->momx += dx; thing->momy += dy; } diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index c718dc010..51b3791e9 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -1165,6 +1165,14 @@ bool SV_AwarenessUpdate(player_t &player, AActor *mo) return true; } + else if (previously_ok && ok + && player.mo && !mo->player && mo->on_conveyer && + (gametic + mo->netid) % 120) // Update items on conveyers every 120 tics + { + SV_SendMobjToClient(mo, cl); + return true; + } + return false; } From 94f4d50fad9f008eca32b1d48e2bc16cf08658c2 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 10 Jun 2023 14:02:34 -0400 Subject: [PATCH 26/75] spell conveyor right --- common/actor.h | 2 +- common/p_mobj.cpp | 12 ++++++------ common/p_spec.cpp | 2 +- server/src/sv_main.cpp | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/common/actor.h b/common/actor.h index 112633616..13ea46063 100644 --- a/common/actor.h +++ b/common/actor.h @@ -521,7 +521,7 @@ class AActor : public DThinker SWORD gear; // killough 11/98: used in torque simulation bool onground; // NES - Fixes infinite jumping bug like a charm. - bool on_conveyer; // Blair - Update items on conveyers more often + bool on_conveyor; // Blair - Update items on conveyors more often // a linked list of sectors where this object appears struct msecnode_s *touching_sectorlist; // phares 3/14/98 diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index 2938a3ebc..94a555467 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -127,7 +127,7 @@ AActor::AActor() prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyer(true),state(NULL), damage(0), flags(0), flags2(0), + info(NULL), tics(0), on_conveyor(true),state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -148,7 +148,7 @@ AActor::AActor(const AActor& other) dropoffz(other.dropoffz), floorsector(other.floorsector), radius(other.radius), height(other.height), momx(other.momx), momy(other.momy), momz(other.momz), validcount(other.validcount), type(other.type), info(other.info), tics(other.tics), - state(other.state), on_conveyer(other.on_conveyer), damage(other.damage), + state(other.state), on_conveyor(other.on_conveyor), damage(other.damage), flags(other.flags), flags2(other.flags2), flags3(other.flags3), oflags(other.oflags), special1(other.special1), special2(other.special2), health(other.health), movedir(other.movedir), movecount(other.movecount), @@ -197,7 +197,7 @@ AActor &AActor::operator= (const AActor &other) info = other.info; tics = other.tics; state = other.state; - on_conveyer = other.on_conveyer; + on_conveyor = other.on_conveyor; damage = other.damage; flags = other.flags; flags2 = other.flags2; @@ -246,7 +246,7 @@ AActor::AActor(fixed_t ix, fixed_t iy, fixed_t iz, mobjtype_t itype) prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyer(true), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), + info(NULL), tics(0), on_conveyor(true), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -684,7 +684,7 @@ void AActor::RunThink () prevpitch = pitch; } - if (on_conveyer) + if (on_conveyor) { bool still_on = false; @@ -725,7 +725,7 @@ void AActor::RunThink () } } - on_conveyer = still_on; + on_conveyor = still_on; } // server removal of corpses only diff --git a/common/p_spec.cpp b/common/p_spec.cpp index 002f4ccff..df1a42a6a 100644 --- a/common/p_spec.cpp +++ b/common/p_spec.cpp @@ -2556,7 +2556,7 @@ void DScroller::RunThink () { // Move objects only if on floor or underwater, // non-floating, and clipped. - thing->on_conveyer = true; + thing->on_conveyor = true; thing->momx += dx; thing->momy += dy; } diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index 51b3791e9..a5259ebe6 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -1166,7 +1166,7 @@ bool SV_AwarenessUpdate(player_t &player, AActor *mo) return true; } else if (previously_ok && ok - && player.mo && !mo->player && mo->on_conveyer && + && player.mo && !mo->player && mo->on_conveyor && (gametic + mo->netid) % 120) // Update items on conveyers every 120 tics { SV_SendMobjToClient(mo, cl); From b95ae08fc63cc5695f97b4b0b40d144c426f16ba Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 10 Jun 2023 14:38:27 -0400 Subject: [PATCH 27/75] don't start every actor assuming they're on a conveyor --- common/p_mobj.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index 94a555467..9b5bfee6c 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -127,7 +127,7 @@ AActor::AActor() prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyor(true),state(NULL), damage(0), flags(0), flags2(0), + info(NULL), tics(0), on_conveyor(false),state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -246,7 +246,7 @@ AActor::AActor(fixed_t ix, fixed_t iy, fixed_t iz, mobjtype_t itype) prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyor(true), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), + info(NULL), tics(0), on_conveyor(false), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), From a530bacd259b9574a502e57e14b7ab16633e49f6 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 10 Jun 2023 14:57:33 -0400 Subject: [PATCH 28/75] clean up the conveyor detection loop --- common/p_mobj.cpp | 47 ++++++++++++++++++++++++++--------------------- 1 file changed, 26 insertions(+), 21 deletions(-) diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index 9b5bfee6c..d62666ba8 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -684,44 +684,49 @@ void AActor::RunThink () prevpitch = pitch; } + // Check to see if this actor is still on a conveyor. if (on_conveyor) { bool still_on = false; TThinkerIterator scrollIter; DScroller* scroller; + while ((scroller = scrollIter.Next())) { - if (scroller->GetType() == DScroller::sc_carry) + if (scroller->GetType() != DScroller::sc_carry) + { + continue; + } + + sector_t* sec = sectors + scroller->GetAffectee(); + fixed_t height = P_HighestHeightOfFloor(sec); + fixed_t waterheight = + sec->heightsec && P_HighestHeightOfFloor(sec->heightsec) > height + ? P_HighestHeightOfFloor(sec->heightsec) + : MININT; + + if ((subsector->sector - sectors) == scroller->GetAffectee()) { - sector_t* sec = sectors + scroller->GetAffectee(); msecnode_t* node; AActor* thing; - fixed_t height = P_HighestHeightOfFloor(sec); - fixed_t waterheight = - sec->heightsec && P_HighestHeightOfFloor(sec->heightsec) > height - ? P_HighestHeightOfFloor(sec->heightsec) - : MININT; - if ((subsector->sector - sectors) == scroller->GetAffectee()) + for (node = sec->touching_thinglist; node; node = node->m_snext) { - for (node = sec->touching_thinglist; node; node = node->m_snext) + if (!((thing = node->m_thing)->flags & MF_NOCLIP) && + (!(thing->flags & MF_NOGRAVITY || thing->z > height) || + thing->z < waterheight) && + thing == this) { - if (!((thing = node->m_thing)->flags & MF_NOCLIP) && - (!(thing->flags & MF_NOGRAVITY || thing->z > height) || - thing->z < waterheight) && - thing == this) - { - still_on = true; - break; - } + still_on = true; + break; } } + } - if (still_on) - { - break; - } + if (still_on) + { + break; } } From 5663eac6cbbb4d1a35b6c2053f8c4b5fa7449604 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sun, 11 Jun 2023 01:22:56 -0400 Subject: [PATCH 29/75] don't update player or avatars on conveyers as it's handled elsewhere --- server/src/sv_main.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index a5259ebe6..9dfcda9dd 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -1166,8 +1166,9 @@ bool SV_AwarenessUpdate(player_t &player, AActor *mo) return true; } else if (previously_ok && ok - && player.mo && !mo->player && mo->on_conveyor && - (gametic + mo->netid) % 120) // Update items on conveyers every 120 tics + && player.mo && !mo->player && mo->type != MT_AVATAR && mo->type != MT_PLAYER + && mo->on_conveyor + && (gametic + mo->netid) % 120) // Update items on conveyers every 120 tics { SV_SendMobjToClient(mo, cl); return true; From 4f947b1a4914c8078e95b23ae8be739dba53d603 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Thu, 15 Jun 2023 18:06:21 -0400 Subject: [PATCH 30/75] Use browser instead of individual check buttons for options gui --- client/gui/gui_boot.cpp | 28 +++++++++++++--------------- client/gui/gui_boot.h | 5 ++--- client/src/d_main.cpp | 8 ++++---- 3 files changed, 19 insertions(+), 22 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 6c61784aa..c0051e690 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -112,9 +112,7 @@ class BootWindow : public Fl_Window Fl_Hold_Browser* m_IWADBrowser; Fl_Check_Browser* m_PWADSelectBrowser; Fl_Hold_Browser* m_PWADOrderBrowser; - Fl_Check_Button* m_nomonstersCheckButton; - Fl_Check_Button* m_fastCheckButton; - Fl_Check_Button* m_respawnCheckButton; + Fl_Check_Browser* m_gameOptionsBrowser; StringTokens m_WADDirs; Fl_Hold_Browser* m_WADDirList; @@ -172,16 +170,16 @@ class BootWindow : public Fl_Window Fl_Group* tabGameOptions = new Fl_Group(0, 25, 425, 175, "Game Options"); { - m_nomonstersCheckButton = new Fl_Check_Button(10, 50, 20, 20, " No Monsters"); - m_nomonstersCheckButton->down_box(FL_DOWN_BOX); - } - { - m_fastCheckButton = new Fl_Check_Button(10, 100, 20, 20, " Fast Monsters"); - m_fastCheckButton->down_box(FL_DOWN_BOX); - } + Fl_Box* o = new Fl_Box( + 10, 35, 405, 20, + "Set options idk."); + o->align(Fl_Align(132 | FL_ALIGN_INSIDE)); + } // Fl_Box* o { - m_respawnCheckButton = new Fl_Check_Button(10, 150, 20, 20, " Respawn Monsters"); - m_respawnCheckButton->down_box(FL_DOWN_BOX); + m_gameOptionsBrowser = new Fl_Check_Browser(10, 65, 405, 125); + m_gameOptionsBrowser->add("No Monsters"); + m_gameOptionsBrowser->add("Fast Monsters"); + m_gameOptionsBrowser->add("Respawn Monsters"); } tabGameOptions->end(); @@ -521,9 +519,9 @@ class BootWindow : public Fl_Window void setOptions() { - g_SelectedWADs.fast = m_fastCheckButton->value(); - g_SelectedWADs.nomonsters = m_nomonstersCheckButton->value(); - g_SelectedWADs.respawn = m_respawnCheckButton->value(); + for (int i = 1; i <= m_gameOptionsBrowser->nitems(); i++) { + g_SelectedWADs.options.push_back(m_gameOptionsBrowser->checked(i)); + } } /** diff --git a/client/gui/gui_boot.h b/client/gui/gui_boot.h index 506c74aa5..5b42674ca 100644 --- a/client/gui/gui_boot.h +++ b/client/gui/gui_boot.h @@ -22,14 +22,13 @@ //----------------------------------------------------------------------------- #pragma once +#include struct scannedWADs_t { std::string iwad; StringTokens pwads; - bool nomonsters; - bool respawn; - bool fast; + std::vector options; }; scannedWADs_t GUI_BootWindow(); diff --git a/client/src/d_main.cpp b/client/src/d_main.cpp index feae6cde2..d2f63df13 100644 --- a/client/src/d_main.cpp +++ b/client/src/d_main.cpp @@ -802,11 +802,11 @@ void D_DoomMain() iwad = wads.iwad; pwads = wads.pwads; // Nomonsters - sv_nomonsters = wads.nomonsters; - // Respawn - sv_monstersrespawn = wads.respawn; + sv_nomonsters = wads.options[0]; // Fast - sv_fastmonsters = wads.fast; + sv_fastmonsters = wads.options[1]; + // Respawn + sv_monstersrespawn = wads.options[2]; } } From c3acda47c2079d5f4f8b625e551ec72fc6b90dba Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Thu, 15 Jun 2023 18:27:49 -0400 Subject: [PATCH 31/75] Append to Args instead of directly setting variables --- client/gui/gui_boot.cpp | 1 + client/gui/gui_boot.h | 3 ++- client/src/d_main.cpp | 24 +++++++++++++++++------- 3 files changed, 20 insertions(+), 8 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index c0051e690..3e368edc0 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -180,6 +180,7 @@ class BootWindow : public Fl_Window m_gameOptionsBrowser->add("No Monsters"); m_gameOptionsBrowser->add("Fast Monsters"); m_gameOptionsBrowser->add("Respawn Monsters"); + m_gameOptionsBrowser->add("Pistol Start"); } tabGameOptions->end(); diff --git a/client/gui/gui_boot.h b/client/gui/gui_boot.h index 5b42674ca..084c707fd 100644 --- a/client/gui/gui_boot.h +++ b/client/gui/gui_boot.h @@ -22,7 +22,8 @@ //----------------------------------------------------------------------------- #pragma once -#include + +#include "m_argv.h" struct scannedWADs_t { diff --git a/client/src/d_main.cpp b/client/src/d_main.cpp index d2f63df13..87a2829ca 100644 --- a/client/src/d_main.cpp +++ b/client/src/d_main.cpp @@ -801,12 +801,22 @@ void D_DoomMain() scannedWADs_t wads = GUI_BootWindow(); iwad = wads.iwad; pwads = wads.pwads; + // Nomonsters - sv_nomonsters = wads.options[0]; + if(wads.options[0]) + Args.AppendArg("-nomonsters"); + // Fast - sv_fastmonsters = wads.options[1]; + if(wads.options[1]) + Args.AppendArg("-fast"); + // Respawn - sv_monstersrespawn = wads.options[2]; + if(wads.options[2]) + Args.AppendArg("-respawn"); + + //Pistol start + if(wads.options[3]) + Args.AppendArg("-pistolstart"); } } @@ -864,15 +874,15 @@ void D_DoomMain() // set the default value for vid_ticker based on the presence of -devparm if (devparm) vid_ticker.SetDefault("1"); - + // Nomonsters - //sv_nomonsters = Args.CheckParm("-nomonsters"); + sv_nomonsters = Args.CheckParm("-nomonsters"); // Respawn - //sv_monstersrespawn = Args.CheckParm("-respawn"); + sv_monstersrespawn = Args.CheckParm("-respawn"); // Fast - //sv_fastmonsters = Args.CheckParm("-fast"); + sv_fastmonsters = Args.CheckParm("-fast"); // Pistol start g_resetinvonexit = Args.CheckParm("-pistolstart"); From 7b624cc43536cd5dbe9152a9459a529c8500ac7a Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Thu, 15 Jun 2023 19:52:47 -0400 Subject: [PATCH 32/75] Add doubleclick on IWAD to start it --- client/gui/gui_boot.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 3e368edc0..814149c06 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -133,6 +133,7 @@ class BootWindow : public Fl_Window } // Fl_Box* logo { m_IWADBrowser = new Fl_Hold_Browser(135, 35, 280, 155); + m_IWADBrowser->callback(BootWindow::doPlayCB, static_cast(this)); } // Fl_Browser* m_IWADBrowser m_tabIWAD->end(); } // Fl_Group* tabIWAD From 9ef2a307428e289dcc3c35bbc3f546dc9ebe11f1 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Thu, 15 Jun 2023 20:33:54 -0400 Subject: [PATCH 33/75] Fix doubleclicking on IWAD --- client/gui/gui_boot.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 814149c06..d50ce6dfc 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -134,6 +134,7 @@ class BootWindow : public Fl_Window { m_IWADBrowser = new Fl_Hold_Browser(135, 35, 280, 155); m_IWADBrowser->callback(BootWindow::doPlayCB, static_cast(this)); + m_IWADBrowser->when(FL_WHEN_ENTER_KEY); } // Fl_Browser* m_IWADBrowser m_tabIWAD->end(); } // Fl_Group* tabIWAD From 6e7429ac442d70c759e832e43f52cd86e8092cbe Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 17 Jun 2023 20:40:47 -0400 Subject: [PATCH 34/75] have dehacked check for the proper RIP MBF21 bit --- common/d_dehacked.cpp | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/common/d_dehacked.cpp b/common/d_dehacked.cpp index 178aac3f8..670dfbe9a 100644 --- a/common/d_dehacked.cpp +++ b/common/d_dehacked.cpp @@ -1244,19 +1244,14 @@ static int PatchThing(int thingy) info->flags3 |= MF3_E4M8BOSS; } - if (tempval & MF3_FULLVOLSOUNDS) - { - info->flags3 |= MF3_FULLVOLSOUNDS; - } - - if (tempval & MF2_NODMGTHRUST) + if (tempval & BIT(17)) // MBF21 RIP is 1 << 17 { - info->flags2 |= MF2_NODMGTHRUST; + info->flags2 |= MF2_RIP; } - if (tempval & MF2_RIP) + if (tempval & MF3_FULLVOLSOUNDS) { - info->flags2 |= MF2_RIP; + info->flags3 |= MF3_FULLVOLSOUNDS; } value[3] |= atoi(strval); From 2977b344f83128b0c367292a7bfe1e8c24fd6d51 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sat, 17 Jun 2023 21:40:05 -0400 Subject: [PATCH 35/75] Improve options tab message --- client/gui/gui_boot.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index d50ce6dfc..613d9ad52 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -174,7 +174,7 @@ class BootWindow : public Fl_Window { Fl_Box* o = new Fl_Box( 10, 35, 405, 20, - "Set options idk."); + "Set gameplay options to modify your experience."); o->align(Fl_Align(132 | FL_ALIGN_INSIDE)); } // Fl_Box* o { From 521f21a637abd7f4b08daf77d2f0f94218b451ec Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 17 Jun 2023 22:08:50 -0400 Subject: [PATCH 36/75] Revert "Only process multiple ticcmds from a client if expected ticcmds have been delayed." This reverts commit c2938807965d284be95974ed52290a07dff88224. --- common/d_player.h | 1 - common/p_user.cpp | 3 --- server/src/sv_main.cpp | 44 +++++++++++++++++------------------------- 3 files changed, 18 insertions(+), 30 deletions(-) diff --git a/common/d_player.h b/common/d_player.h index c16f1f904..7240e95cb 100644 --- a/common/d_player.h +++ b/common/d_player.h @@ -134,7 +134,6 @@ class player_s struct ticcmd_t cmd; // the ticcmd currently being processed std::queue cmdqueue; // all received ticcmds - int missingticcmdcount; // number of gametics without processing a ticcmd for this player // [RH] who is this? UserInfo userinfo; diff --git a/common/p_user.cpp b/common/p_user.cpp index 0296f7993..d9a4bb965 100644 --- a/common/p_user.cpp +++ b/common/p_user.cpp @@ -1321,7 +1321,6 @@ player_s::player_s() : ping(0), last_received(0), tic(0), - missingticcmdcount(0), snapshots(PlayerSnapshotManager()), spying(0), spectator(false), @@ -1441,8 +1440,6 @@ player_s &player_s::operator =(const player_s &other) last_received = other.last_received; tic = other.tic; - missingticcmdcount = other.missingticcmdcount; - spying = other.spying; spectator = other.spectator; // deadspectator = other.deadspectator; diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index c718dc010..0ecaf300d 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -3204,39 +3204,35 @@ int SV_CalculateNumTiccmds(player_t &player) static const size_t maximum_queue_size = TICRATE / 4; - if (!sv_ticbuffer || gamestate != GS_LEVEL || player.spectator || player.playerstate == PST_DEAD) + if (!sv_ticbuffer || player.spectator || player.playerstate == PST_DEAD) { // Process all queued ticcmds. return maximum_queue_size; } - if (player.missingticcmdcount > 0) + if (player.mo->momx == 0 && player.mo->momy == 0 && player.mo->momz == 0) { - if (player.mo->momx == 0 && player.mo->momy == 0 && player.mo->momz == 0) - { - // Player is not moving - return 2; - } - if (player.cmdqueue.size() > 2 && gametic % (2*TICRATE) == player.id % (2*TICRATE)) - { - // Process an extra ticcmd once every 2 seconds to reduce the - // queue size. Use player id to stagger the timing to prevent everyone - // from running an extra ticcmd at the same time. - return 2; - } - if (player.cmdqueue.size() > maximum_queue_size) - { - // The player experienced a large latency spike so try to catch up by - // processing more than one ticcmd at the expense of appearing perfectly - // smooth. - return 2; - } + // Player is not moving + return 2; + } + if (player.cmdqueue.size() > 2 && gametic % (2*TICRATE) == player.id % (2*TICRATE)) + { + // Process an extra ticcmd once every 2 seconds to reduce the + // queue size. Use player id to stagger the timing to prevent everyone + // from running an extra ticcmd at the same time. + return 2; + } + if (player.cmdqueue.size() > maximum_queue_size) + { + // The player experienced a large latency spike so try to catch up by + // processing more than one ticcmd at the expense of appearing perfectly + // smooth + return 2; } // always run at least 1 ticcmd if possible return 1; } - // // SV_ProcessPlayerCmd // @@ -3266,9 +3262,6 @@ void SV_ProcessPlayerCmd(player_t &player) player.userinfo.netname, player.cmdqueue.size()); #endif // _TICCMD_QUEUE_DEBUG_ - if (player.cmdqueue.empty()) - player.missingticcmdcount++; - int num_cmds = SV_CalculateNumTiccmds(player); for (int i = 0; i < num_cmds && !player.cmdqueue.empty(); i++) @@ -3310,7 +3303,6 @@ void SV_ProcessPlayerCmd(player_t &player) } player.cmdqueue.pop(); // remove this tic from the queue after being processed - player.missingticcmdcount--; } } From 2f234cacad86f0acfca53ebbd6781c6d7e676ad1 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 17 Jun 2023 22:09:00 -0400 Subject: [PATCH 37/75] Revert "Fix a bug in the logic around processing an extra ticcmd from a client once every 2 seconds to reduce the size of the buffer" This reverts commit c8c913136d35944fff94c1c147867b884074e662. --- server/src/sv_main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index 0ecaf300d..cdc5be5ea 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -3214,7 +3214,7 @@ int SV_CalculateNumTiccmds(player_t &player) // Player is not moving return 2; } - if (player.cmdqueue.size() > 2 && gametic % (2*TICRATE) == player.id % (2*TICRATE)) + if (player.cmdqueue.size() > 2 && gametic % 2*TICRATE == player.id % 2*TICRATE) { // Process an extra ticcmd once every 2 seconds to reduce the // queue size. Use player id to stagger the timing to prevent everyone From fe2661a6f93df2421e74e205c062c885ed9df0f0 Mon Sep 17 00:00:00 2001 From: Ralph Vickers Date: Sat, 17 Jun 2023 22:28:38 -0400 Subject: [PATCH 38/75] Change | to || --- client/src/st_new.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/st_new.cpp b/client/src/st_new.cpp index ac59c38bb..a79bf1c28 100644 --- a/client/src/st_new.cpp +++ b/client/src/st_new.cpp @@ -1368,7 +1368,7 @@ void LevelStateHUD() break; } case LevelState::ENDROUND_COUNTDOWN: { - if (G_IsCoopGame() | G_IsHordeMode()) + if (G_IsCoopGame() || G_IsHordeMode()) StrFormat(lines.title, "Attempt " TEXTCOLOR_YELLOW "%d " TEXTCOLOR_GREY "complete\n", ::levelstate.getRound()); @@ -1386,7 +1386,7 @@ void LevelStateHUD() else if (win.type == WinInfo::WIN_TEAM) StrFormat(lines.subtitle[0], "%s team wins the round", WinToColorString(win).c_str()); - else if (G_IsCoopGame() | G_IsHordeMode()) + else if (G_IsCoopGame() || G_IsHordeMode()) StrFormat(lines.subtitle[0], "Next attempt in " TEXTCOLOR_GREEN "%d", ::levelstate.getCountdown()); else From 36876415439a73a7df2cf14fb4b1b5c2548ad876 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sat, 17 Jun 2023 22:58:28 -0400 Subject: [PATCH 39/75] Don't use indices of options to determine which argument to append --- client/gui/gui_boot.cpp | 25 ++++++++++++++++++------- client/gui/gui_boot.h | 2 +- client/src/d_main.cpp | 20 +++++--------------- 3 files changed, 24 insertions(+), 23 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 613d9ad52..5e8a49f8b 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -56,6 +56,15 @@ typedef std::vector scannedIWADs_t; typedef std::vector scannedPWADs_t; typedef std::vector scannedPWADPtrs_t; +// display strings for options tab and their corresponding command line arguments +const std::vector> OPTIONS_LIST = +{ + {"No Monsters", "-nomonsters"}, + {"Fast Monsters", "-fast"}, + {"Respawn Monsters", "-respawn"}, + {"Pistol Start", "-pistolstart"} +}; + /** * @brief Find the PWAD pointer in the scanned WAD array. */ @@ -98,7 +107,7 @@ static void EraseSelected(scannedPWADPtrs_t& mut, scannedPWAD_t* pwad) const scannedIWAD_t* g_SelectedIWAD; scannedWADs_t g_SelectedWADs; -const int WINDOW_WIDTH = 320; +const int WINDOW_WIDTH = 425; const int WINDOW_HEIGHT = 240; class BootWindow : public Fl_Window @@ -179,10 +188,11 @@ class BootWindow : public Fl_Window } // Fl_Box* o { m_gameOptionsBrowser = new Fl_Check_Browser(10, 65, 405, 125); - m_gameOptionsBrowser->add("No Monsters"); - m_gameOptionsBrowser->add("Fast Monsters"); - m_gameOptionsBrowser->add("Respawn Monsters"); - m_gameOptionsBrowser->add("Pistol Start"); + for (auto it = OPTIONS_LIST.begin(); + it != OPTIONS_LIST.end(); ++it) + { + m_gameOptionsBrowser->add((*it).first.c_str()); + } } tabGameOptions->end(); @@ -523,7 +533,8 @@ class BootWindow : public Fl_Window void setOptions() { for (int i = 1; i <= m_gameOptionsBrowser->nitems(); i++) { - g_SelectedWADs.options.push_back(m_gameOptionsBrowser->checked(i)); + if (m_gameOptionsBrowser->checked(i)) + g_SelectedWADs.options.push_back(OPTIONS_LIST[i - 1].second); } } @@ -557,7 +568,7 @@ class BootWindow : public Fl_Window */ static BootWindow* MakeBootWindow() { - return new BootWindow(0, 0, 425, 240, "Odamex " DOTVERSIONSTR); + return new BootWindow(0, 0, WINDOW_WIDTH, WINDOW_HEIGHT, "Odamex " DOTVERSIONSTR); } /** diff --git a/client/gui/gui_boot.h b/client/gui/gui_boot.h index 084c707fd..069f6c93c 100644 --- a/client/gui/gui_boot.h +++ b/client/gui/gui_boot.h @@ -29,7 +29,7 @@ struct scannedWADs_t { std::string iwad; StringTokens pwads; - std::vector options; + StringTokens options; }; scannedWADs_t GUI_BootWindow(); diff --git a/client/src/d_main.cpp b/client/src/d_main.cpp index 87a2829ca..309553abf 100644 --- a/client/src/d_main.cpp +++ b/client/src/d_main.cpp @@ -802,21 +802,11 @@ void D_DoomMain() iwad = wads.iwad; pwads = wads.pwads; - // Nomonsters - if(wads.options[0]) - Args.AppendArg("-nomonsters"); - - // Fast - if(wads.options[1]) - Args.AppendArg("-fast"); - - // Respawn - if(wads.options[2]) - Args.AppendArg("-respawn"); - - //Pistol start - if(wads.options[3]) - Args.AppendArg("-pistolstart"); + for (StringTokens::iterator it = wads.options.begin(); + it != wads.options.end(); ++it) + { + Args.AppendArg((*it).c_str()); + } } } From 9c8fbadd3ea0021d7c7dea4d8b9eed56d968e809 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 18 Jun 2023 00:03:00 -0400 Subject: [PATCH 40/75] Remove use of auto --- client/gui/gui_boot.cpp | 2 +- client/gui/gui_boot.h | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 5e8a49f8b..71044399b 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -188,7 +188,7 @@ class BootWindow : public Fl_Window } // Fl_Box* o { m_gameOptionsBrowser = new Fl_Check_Browser(10, 65, 405, 125); - for (auto it = OPTIONS_LIST.begin(); + for (std::vector>::const_iterator it = OPTIONS_LIST.begin(); it != OPTIONS_LIST.end(); ++it) { m_gameOptionsBrowser->add((*it).first.c_str()); diff --git a/client/gui/gui_boot.h b/client/gui/gui_boot.h index 069f6c93c..0b39c2b3d 100644 --- a/client/gui/gui_boot.h +++ b/client/gui/gui_boot.h @@ -23,8 +23,6 @@ #pragma once -#include "m_argv.h" - struct scannedWADs_t { std::string iwad; From f800f1891d543ec7a6bed1a46982742965b5d9cb Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 18 Jun 2023 00:29:05 -0400 Subject: [PATCH 41/75] Use make_pair instead of aggregate initialization --- client/gui/gui_boot.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 71044399b..3f308a700 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -59,10 +59,10 @@ typedef std::vector scannedPWADPtrs_t; // display strings for options tab and their corresponding command line arguments const std::vector> OPTIONS_LIST = { - {"No Monsters", "-nomonsters"}, - {"Fast Monsters", "-fast"}, - {"Respawn Monsters", "-respawn"}, - {"Pistol Start", "-pistolstart"} + std::make_pair("No Monsters", "-nomonsters"), + std::make_pair("Fast Monsters", "-fast"), + std::make_pair("Respawn Monsters", "-respawn"), + std::make_pair("Pistol Start", "-pistolstart") }; /** From a3cc7cc71e723f12a24129fc5f7eda49d2c7b1d4 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 18 Jun 2023 01:28:13 -0400 Subject: [PATCH 42/75] Don't initialize OPTIONS_LIST with braces either --- client/gui/gui_boot.cpp | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 3f308a700..456a7e00b 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -56,15 +56,6 @@ typedef std::vector scannedIWADs_t; typedef std::vector scannedPWADs_t; typedef std::vector scannedPWADPtrs_t; -// display strings for options tab and their corresponding command line arguments -const std::vector> OPTIONS_LIST = -{ - std::make_pair("No Monsters", "-nomonsters"), - std::make_pair("Fast Monsters", "-fast"), - std::make_pair("Respawn Monsters", "-respawn"), - std::make_pair("Pistol Start", "-pistolstart") -}; - /** * @brief Find the PWAD pointer in the scanned WAD array. */ @@ -124,11 +115,17 @@ class BootWindow : public Fl_Window Fl_Check_Browser* m_gameOptionsBrowser; StringTokens m_WADDirs; Fl_Hold_Browser* m_WADDirList; + // display strings for options tab and their corresponding command line arguments + std::vector> OPTIONS_LIST; public: BootWindow(int X, int Y, int W, int H, const char* L) : Fl_Window(X, Y, W, H, L), m_IWADs() { + OPTIONS_LIST.emplace_back("No Monsters", "-nomonsters"); + OPTIONS_LIST.emplace_back("Fast Monsters", "-fast"); + OPTIONS_LIST.emplace_back("Respawn Monsters", "-respawn"); + OPTIONS_LIST.emplace_back("Pistol Start", "-pistolstart"); { Fl_Tabs* tabs = new Fl_Tabs(0, 0, 425, 200); { @@ -188,7 +185,7 @@ class BootWindow : public Fl_Window } // Fl_Box* o { m_gameOptionsBrowser = new Fl_Check_Browser(10, 65, 405, 125); - for (std::vector>::const_iterator it = OPTIONS_LIST.begin(); + for (std::vector >::const_iterator it = OPTIONS_LIST.begin(); it != OPTIONS_LIST.end(); ++it) { m_gameOptionsBrowser->add((*it).first.c_str()); From 885031d2d564cf33bed8dffee519b6f673b3c502 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 18 Jun 2023 01:39:38 -0400 Subject: [PATCH 43/75] Replace uses of emplace_back with push_back --- client/gui/gui_boot.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 456a7e00b..4fe22c998 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -122,10 +122,10 @@ class BootWindow : public Fl_Window BootWindow(int X, int Y, int W, int H, const char* L) : Fl_Window(X, Y, W, H, L), m_IWADs() { - OPTIONS_LIST.emplace_back("No Monsters", "-nomonsters"); - OPTIONS_LIST.emplace_back("Fast Monsters", "-fast"); - OPTIONS_LIST.emplace_back("Respawn Monsters", "-respawn"); - OPTIONS_LIST.emplace_back("Pistol Start", "-pistolstart"); + OPTIONS_LIST.push_back(std::make_pair("No Monsters", "-nomonsters")); + OPTIONS_LIST.push_back(std::make_pair("Fast Monsters", "-fast")); + OPTIONS_LIST.push_back(std::make_pair("Respawn Monsters", "-respawn")); + OPTIONS_LIST.push_back(std::make_pair("Pistol Start", "-pistolstart")); { Fl_Tabs* tabs = new Fl_Tabs(0, 0, 425, 200); { From 9db5c8c78fae7ed4c7c7148ef447560dd99f11b7 Mon Sep 17 00:00:00 2001 From: Mia McMahill <84749759+electricbrass@users.noreply.github.com> Date: Sun, 18 Jun 2023 01:47:44 -0400 Subject: [PATCH 44/75] Add space in OPTIONS_LIST type --- client/gui/gui_boot.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/gui/gui_boot.cpp b/client/gui/gui_boot.cpp index 4fe22c998..a50bc0857 100644 --- a/client/gui/gui_boot.cpp +++ b/client/gui/gui_boot.cpp @@ -116,7 +116,7 @@ class BootWindow : public Fl_Window StringTokens m_WADDirs; Fl_Hold_Browser* m_WADDirList; // display strings for options tab and their corresponding command line arguments - std::vector> OPTIONS_LIST; + std::vector > OPTIONS_LIST; public: BootWindow(int X, int Y, int W, int H, const char* L) From ae64b91b21abf7633a5a3b2972c6c38f501dcc99 Mon Sep 17 00:00:00 2001 From: bcahue Date: Fri, 30 Jun 2023 22:47:23 -0400 Subject: [PATCH 45/75] fix obits for mbf21 projectiles --- common/p_map.cpp | 10 +++++++++- common/p_mobj.cpp | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/common/p_map.cpp b/common/p_map.cpp index bde33b11f..edb283f08 100644 --- a/common/p_map.cpp +++ b/common/p_map.cpp @@ -680,8 +680,16 @@ static BOOL PIT_CheckThing (AActor *thing) mod = MOD_BFG_BOOM; break; // [AM] Monster fireballs get a special MOD. + // Unless they're from players default: - mod = MOD_FIREBALL; + if ((tmthing->target && tmthing->target->player) || !tmthing->target) + { + mod = MOD_UNKNOWN; + } + else + { + mod = MOD_FIREBALL; + } break; } P_DamageMobj (thing, tmthing, tmthing->target, damage, mod); diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index e9ad3efd6..87216041a 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -2630,9 +2630,9 @@ void P_ExplodeMissile (AActor* mo) case MT_BFG: mod = MOD_BFG_BOOM; break; - // [AM] Monster fireballs get a special MOD. + // Blair: Unknown player projectiles get an unknown mod default: - mod = MOD_FIREBALL; + mod = MOD_UNKNOWN; break; } From a55d379bc1766d43007eaf4cee62d7b3812a5bb2 Mon Sep 17 00:00:00 2001 From: bcahue Date: Fri, 30 Jun 2023 22:51:59 -0400 Subject: [PATCH 46/75] give rippers a generic mod --- common/p_map.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/p_map.cpp b/common/p_map.cpp index edb283f08..60e9fb7af 100644 --- a/common/p_map.cpp +++ b/common/p_map.cpp @@ -651,7 +651,7 @@ static BOOL PIT_CheckThing (AActor *thing) if (tmthing->info->ripsound) S_Sound(tmthing, CHAN_VOICE, tmthing->info->ripsound, 1, ATTN_NORM); - P_DamageMobj(thing, tmthing, tmthing->target, damage); + P_DamageMobj(thing, tmthing, tmthing->target, damage, MOD_UNKNOWN); if (thing->flags2 & MF2_PUSHABLE && !(tmthing->flags2 & MF2_CANNOTPUSH)) { // Push thing thing->momx += tmthing->momx >> 2; From 9ab90823856efd321445aefbc885cc33d556beb9 Mon Sep 17 00:00:00 2001 From: DeathEgg Date: Fri, 21 Jul 2023 10:25:00 -0700 Subject: [PATCH 47/75] add dummy MAPINFO slot for compat_invisibility --- common/g_mapinfo.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/common/g_mapinfo.cpp b/common/g_mapinfo.cpp index c452337cb..ff98c95e4 100644 --- a/common/g_mapinfo.cpp +++ b/common/g_mapinfo.cpp @@ -1555,6 +1555,7 @@ struct MapInfoDataSetter ENTRY3("compat_boomscroll", &MIType_CompatFlag, &ref.flags) // todo: not implemented ENTRY3("compat_sectorsounds", &MIType_CompatFlag, &ref.flags) // todo: not implemented ENTRY4("compat_nopassover", &MIType_CompatFlag, &ref.flags, LEVEL_COMPAT_NOPASSOVER) + ENTRY3("compat_invisibility", &MIType_CompatFlag, &ref.flags) // todo: not implemented } }; From 93442958e0320b23a3853d6f3cf0417827afc552 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 29 Jul 2023 14:08:18 -0400 Subject: [PATCH 48/75] implement review changes --- common/p_map.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/common/p_map.cpp b/common/p_map.cpp index b9053921e..a3b3ddf44 100644 --- a/common/p_map.cpp +++ b/common/p_map.cpp @@ -705,7 +705,13 @@ static BOOL PIT_CheckThing (AActor *thing) // [SL] Work-around the additional height added to players // in P_CheckPosition. Don't let players grab items above // their real height! - if (!P_AllowPassover() || thing->z < tmthing->z + tmthing->height - 24*FRACUNIT) + + fixed_t max_z = tmthing->z + tmthing->height; + + if (tmthing->player) + max_z -= 24 * FRACUNIT; + + if (!P_AllowPassover() || thing->z < max_z) P_TouchSpecialThing (thing, tmthing); // can remove thing return !solid; @@ -728,8 +734,6 @@ static BOOL PIT_CheckThing (AActor *thing) else return !((thing->flags & MF_SOLID && !(thing->flags & MF_NOCLIP)) && (tmthing->flags & MF_SOLID || (demoplayback || !co_boomphys))); - - // return !(thing->flags & MF_SOLID); // old code -- killough } // This routine checks for Lost Souls trying to be spawned // phares From 91ef7e47e60194851c8f5f850f1424ffab66ba73 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sat, 29 Jul 2023 17:52:27 -0400 Subject: [PATCH 49/75] don't target spectators for mbf21 tracer functions --- common/p_maputl.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/common/p_maputl.cpp b/common/p_maputl.cpp index 8278c557d..cc2b85671 100644 --- a/common/p_maputl.cpp +++ b/common/p_maputl.cpp @@ -1231,6 +1231,13 @@ static AActor* RoughBlockCheck(AActor* mo, int index, angle_t fov) continue; } + // [Blair] Don't target spectators + if (mo->target->player && mo->target->player->spectator) + { + link = link->snext; + continue; + } + // [Blair] Don't target teammates if (mo->target->player && link->player && P_AreTeammates((player_t&)mo->target->player, (player_t&)link->player)) From 8570f61af88ba0a5a32842a3540c9973e7a4a61c Mon Sep 17 00:00:00 2001 From: bcahue Date: Sun, 6 Aug 2023 22:04:03 -0400 Subject: [PATCH 50/75] check if a target is spectating, not if the projectile originator is. --- common/p_maputl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/p_maputl.cpp b/common/p_maputl.cpp index cc2b85671..6805465c3 100644 --- a/common/p_maputl.cpp +++ b/common/p_maputl.cpp @@ -1232,7 +1232,7 @@ static AActor* RoughBlockCheck(AActor* mo, int index, angle_t fov) } // [Blair] Don't target spectators - if (mo->target->player && mo->target->player->spectator) + if (link->player && link->player->spectator) { link = link->snext; continue; From 6a6ced5bd251105fb807552eb35c83788a411823 Mon Sep 17 00:00:00 2001 From: bcahue Date: Tue, 8 Aug 2023 23:32:29 -0400 Subject: [PATCH 51/75] treat orangetext as a label text like the other label text --- client/src/m_options.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/client/src/m_options.cpp b/client/src/m_options.cpp index 9f55798dc..30c720ef2 100644 --- a/client/src/m_options.cpp +++ b/client/src/m_options.cpp @@ -1468,7 +1468,7 @@ void M_SwitchMenu(menu_t* menu) for (i = 0; i < menu->numitems; i++) { item = menu->items + i; - if (item->type != whitetext && item->type != redtext) + if (item->type != whitetext && item->type != redtext && item->type != orangetext) { thiswidth = V_StringWidth (item->label); if (thiswidth > widest) @@ -1932,6 +1932,7 @@ void M_OptResponder (event_t *ev) } while (CurrentMenu->items[CurrentItem].type == redtext || CurrentMenu->items[CurrentItem].type == whitetext || CurrentMenu->items[CurrentItem].type == yellowtext || + CurrentMenu->items[CurrentItem].type == orangetext || (CurrentMenu->items[CurrentItem].type == screenres && !CurrentMenu->items[CurrentItem].b.res1)); @@ -1972,6 +1973,7 @@ void M_OptResponder (event_t *ev) } while (CurrentMenu->items[CurrentItem].type == redtext || CurrentMenu->items[CurrentItem].type == whitetext || CurrentMenu->items[CurrentItem].type == yellowtext || + CurrentMenu->items[CurrentItem].type == orangetext || (CurrentMenu->items[CurrentItem].type == screenres && !CurrentMenu->items[CurrentItem].b.res1)); @@ -1993,6 +1995,7 @@ void M_OptResponder (event_t *ev) while (CurrentMenu->items[CurrentItem].type == redtext || CurrentMenu->items[CurrentItem].type == whitetext || CurrentMenu->items[CurrentItem].type == yellowtext || + CurrentMenu->items[CurrentItem].type == orangetext || (CurrentMenu->items[CurrentItem].type == screenres && !CurrentMenu->items[CurrentItem].b.res1)) { @@ -2015,6 +2018,7 @@ void M_OptResponder (event_t *ev) while (CurrentMenu->items[CurrentItem].type == redtext || CurrentMenu->items[CurrentItem].type == whitetext || CurrentMenu->items[CurrentItem].type == yellowtext || + CurrentMenu->items[CurrentItem].type == orangetext || (CurrentMenu->items[CurrentItem].type == screenres && !CurrentMenu->items[CurrentItem].b.res1)) { From 32d7cadeb4e1cb1f811381e70413243de17d9e43 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 9 Aug 2023 00:04:54 -0400 Subject: [PATCH 52/75] bump version to 10.4 --- CMakeLists.txt | 6 +++--- README | 2 +- Xbox/README.Xbox | 2 +- ag-odalaunch/res/Info.plist | 10 +++++----- common/version.h | 10 +++++----- config-samples/coop-doom.cfg | 2 +- config-samples/coop-masterlevels.cfg | 2 +- config-samples/coop-modern.cfg | 2 +- config-samples/coop-zdoom.cfg | 2 +- config-samples/ctf-attackdefend.cfg | 2 +- config-samples/ctf-doom.cfg | 2 +- config-samples/ctf-pub.cfg | 2 +- config-samples/ctf-wdl.cfg | 2 +- config-samples/dm-doom.cfg | 2 +- config-samples/dm-modern.cfg | 2 +- config-samples/dm-zdoom.cfg | 2 +- config-samples/duel-altdeath.cfg | 2 +- config-samples/duel-ddl.cfg | 2 +- config-samples/duel-doom.cfg | 2 +- config-samples/duel-zddl.cfg | 2 +- config-samples/duel-zdoom.cfg | 2 +- config-samples/horde-doom.cfg | 2 +- config-samples/horde-modern.cfg | 2 +- config-samples/horde-zdoom.cfg | 2 +- config-samples/lms-2team.cfg | 2 +- config-samples/lms-3team.cfg | 2 +- config-samples/lms-ffa.cfg | 2 +- config-samples/survival-modern.cfg | 2 +- config-samples/tdm-doom.cfg | 2 +- config-samples/tdm-modern.cfg | 2 +- config-samples/tdm-zdoom.cfg | 2 +- installer/windows/build_release.ps1 | 2 +- odalaunch/res/Info.plist | 10 +++++----- odalpapi/net_packet.h | 2 +- switch.cmake | 2 +- tools/upversion/upversion.ini | 8 ++++---- 36 files changed, 53 insertions(+), 53 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c0a3c830d..147060cb1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,7 +14,7 @@ cmake_minimum_required(VERSION 3.13) -project(Odamex VERSION 10.3.0) +project(Odamex VERSION 10.4.0) include(CMakeDependentOption) @@ -49,8 +49,8 @@ cmake_dependent_option( ENABLE_PORTMIDI "Enable portmidi support" 1 BUILD_CLIENT cmake_dependent_option( USE_MINIUPNP "Build with UPnP support" 1 BUILD_SERVER 0 ) cmake_dependent_option( USE_INTERNAL_MINIUPNP "Use internal MiniUPnP" 1 USE_MINIUPNP 0 ) -set(PROJECT_COPYRIGHT "2006-2022") -set(PROJECT_RC_VERSION "10,3,0,0") +set(PROJECT_COPYRIGHT "2006-2023") +set(PROJECT_RC_VERSION "10,4,0,0") set(PROJECT_COMPANY "The Odamex Team") # Include early required commands for specific systems diff --git a/README b/README index 0b99eea5d..4337ca1b1 100644 --- a/README +++ b/README @@ -1,5 +1,5 @@ =============================================================================== - Odamex v10.3.0 README + Odamex v10.4.0 README https://odamex.net =============================================================================== diff --git a/Xbox/README.Xbox b/Xbox/README.Xbox index 1af24c332..4a6876fb3 100644 --- a/Xbox/README.Xbox +++ b/Xbox/README.Xbox @@ -1,5 +1,5 @@ =============================================================================== - Odamex v10.3.0 for Xbox + Odamex v10.4.0 for Xbox http://odamex.net/ Authored by: Michael "Hyper_Eye" Wood diff --git a/ag-odalaunch/res/Info.plist b/ag-odalaunch/res/Info.plist index 1ea0393ce..ec6e5146b 100644 --- a/ag-odalaunch/res/Info.plist +++ b/ag-odalaunch/res/Info.plist @@ -19,15 +19,15 @@ CFBundleSignature ???? CFBundleVersion - 10.3.0 + 10.4.0 CFBundleShortVersionString - 10.3.0 + 10.4.0 CFBundleGetInfoString - Copyright © 2006-2022 The Odamex Team + Copyright © 2006-2023 The Odamex Team CFBundleLongVersionString - 10.3.0 + 10.4.0 NSHumanReadableCopyright - Copyright © 2006-2022 The Odamex Team + Copyright © 2006-2023 The Odamex Team LSRequiresCarbon diff --git a/common/version.h b/common/version.h index 4ce823335..fa6514f76 100644 --- a/common/version.h +++ b/common/version.h @@ -72,12 +72,12 @@ // Used by configuration files. upversion.py will update thie field // deterministically and unambiguously so newer versions always compare // greater. -#define CONFIGVERSIONSTR "010030" +#define CONFIGVERSIONSTR "010040" -#define DOTVERSIONSTR "10.3.0" -#define GAMEVER (MAKEVER(10, 3, 0)) +#define DOTVERSIONSTR "10.4.0" +#define GAMEVER (MAKEVER(10, 4, 0)) -#define COPYRIGHTSTR "Copyright (C) 2006-2022 The Odamex Team" +#define COPYRIGHTSTR "Copyright (C) 2006-2023 The Odamex Team" #define SERVERMAJ (VERMAJ(gameversion)) #define SERVERMIN (VERMIN(gameversion)) @@ -91,7 +91,7 @@ // earlier than this version. Needs to be exactly 16 chars long. // // upversion.py will update thie field deterministically and unambiguously. -#define SAVESIG "ODAMEXSAVE010030" +#define SAVESIG "ODAMEXSAVE010040" #define NETDEMOVER 3 diff --git a/config-samples/coop-doom.cfg b/config-samples/coop-doom.cfg index 3c5ffb4ac..53ac06423 100644 --- a/config-samples/coop-doom.cfg +++ b/config-samples/coop-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Cooperative Ruleset (4 Players/Ultraviolence Skill) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/coop-masterlevels.cfg b/config-samples/coop-masterlevels.cfg index 20bda0703..c1cb35831 100644 --- a/config-samples/coop-masterlevels.cfg +++ b/config-samples/coop-masterlevels.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Cooperative Ruleset (4 Players/Ultraviolence Skill) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/coop-modern.cfg b/config-samples/coop-modern.cfg index 021c1c551..f2bcaa74c 100644 --- a/config-samples/coop-modern.cfg +++ b/config-samples/coop-modern.cfg @@ -1,5 +1,5 @@ // "Modern" Doom(2) Cooperative Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/coop-zdoom.cfg b/config-samples/coop-zdoom.cfg index ea843a50a..77fe01601 100644 --- a/config-samples/coop-zdoom.cfg +++ b/config-samples/coop-zdoom.cfg @@ -1,5 +1,5 @@ // "ZDOOM" Style Cooperative Ruleset (8 Players/Freelook/Jumping) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/ctf-attackdefend.cfg b/config-samples/ctf-attackdefend.cfg index c1ecb3766..b0e629c5d 100644 --- a/config-samples/ctf-attackdefend.cfg +++ b/config-samples/ctf-attackdefend.cfg @@ -1,5 +1,5 @@ // Attack & Defend CTF with World Doom League (doomleague.org) 3v3/4v4 CTF Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/ctf-doom.cfg b/config-samples/ctf-doom.cfg index eda8aae31..981f61aed 100644 --- a/config-samples/ctf-doom.cfg +++ b/config-samples/ctf-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Settings (8v8) CTF Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/ctf-pub.cfg b/config-samples/ctf-pub.cfg index 74fbda436..7fe9ec7f3 100644 --- a/config-samples/ctf-pub.cfg +++ b/config-samples/ctf-pub.cfg @@ -1,5 +1,5 @@ // Commonly Used 8v8 Public CTF Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/ctf-wdl.cfg b/config-samples/ctf-wdl.cfg index 934354a37..85f7893c1 100644 --- a/config-samples/ctf-wdl.cfg +++ b/config-samples/ctf-wdl.cfg @@ -1,5 +1,5 @@ // World Doom League (doomleague.org) 3v3/4v4 CTF Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/dm-doom.cfg b/config-samples/dm-doom.cfg index c91ed76b1..63c68eb10 100644 --- a/config-samples/dm-doom.cfg +++ b/config-samples/dm-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Style (4 Player) Deathmatch Ruleset (50 Fraglimit/10 Min Timelimit/No Exit) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/dm-modern.cfg b/config-samples/dm-modern.cfg index c5ccd2f6c..7e09c0732 100644 --- a/config-samples/dm-modern.cfg +++ b/config-samples/dm-modern.cfg @@ -1,5 +1,5 @@ // "Modern" Doom 2 Style (16 Player) Deathmatch Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/dm-zdoom.cfg b/config-samples/dm-zdoom.cfg index 21c546cbf..7aa205489 100644 --- a/config-samples/dm-zdoom.cfg +++ b/config-samples/dm-zdoom.cfg @@ -1,5 +1,5 @@ // "ZDOOM" Style (16 Player) Deathmatch Ruleset (Jump/Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/duel-altdeath.cfg b/config-samples/duel-altdeath.cfg index 1be06036c..8035cfe7c 100644 --- a/config-samples/duel-altdeath.cfg +++ b/config-samples/duel-altdeath.cfg @@ -1,5 +1,5 @@ // Vanilla Doom 2 Altdeath (Deathmatch 2.0) 1v1 Ruleset (No Fraglimit and Exiting Enabled) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/duel-ddl.cfg b/config-samples/duel-ddl.cfg index 624f67b36..10f468337 100644 --- a/config-samples/duel-ddl.cfg +++ b/config-samples/duel-ddl.cfg @@ -1,5 +1,5 @@ // Doom Duel League (doomleague.org) 1v1 Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/duel-doom.cfg b/config-samples/duel-doom.cfg index 8257f3f83..1b9a7581b 100644 --- a/config-samples/duel-doom.cfg +++ b/config-samples/duel-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) 1v1 Ruleset (With Standard U.S. Fraglimit & No Exiting) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/duel-zddl.cfg b/config-samples/duel-zddl.cfg index fe7408d93..af8262861 100644 --- a/config-samples/duel-zddl.cfg +++ b/config-samples/duel-zddl.cfg @@ -1,5 +1,5 @@ // ZDoom Duel League 2011 1v1 Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/duel-zdoom.cfg b/config-samples/duel-zdoom.cfg index 913dc21e1..e8a344140 100644 --- a/config-samples/duel-zdoom.cfg +++ b/config-samples/duel-zdoom.cfg @@ -1,5 +1,5 @@ // "ZDOOM" Style 1v1 Ruleset -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/horde-doom.cfg b/config-samples/horde-doom.cfg index a4a3ca8af..44b7f5503 100644 --- a/config-samples/horde-doom.cfg +++ b/config-samples/horde-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Horde Ruleset (4 Players/Ultraviolence Skill) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/horde-modern.cfg b/config-samples/horde-modern.cfg index d635ccc0d..45842aee7 100644 --- a/config-samples/horde-modern.cfg +++ b/config-samples/horde-modern.cfg @@ -1,5 +1,5 @@ // "Modern" Doom(2) Horde Ruleset (No Jump/No Freelook/Ultraviolence Skill) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/horde-zdoom.cfg b/config-samples/horde-zdoom.cfg index 437a5ca5d..774aaf75e 100644 --- a/config-samples/horde-zdoom.cfg +++ b/config-samples/horde-zdoom.cfg @@ -1,5 +1,5 @@ // "ZDOOM" Style Horde Ruleset (32 Players/Freelook/Jumping/Ultraviolence Skill) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/lms-2team.cfg b/config-samples/lms-2team.cfg index b1e19274d..4514db1c1 100644 --- a/config-samples/lms-2team.cfg +++ b/config-samples/lms-2team.cfg @@ -1,5 +1,5 @@ // 2-Team Last Man Standing with "Modern" Doom 2 Style (8v8) Team Deathmatch Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/lms-3team.cfg b/config-samples/lms-3team.cfg index a68a140ee..bd5ff0b01 100644 --- a/config-samples/lms-3team.cfg +++ b/config-samples/lms-3team.cfg @@ -1,5 +1,5 @@ // 3-Team Last Man Standing with "Modern" Doom 2 Style (8v8) Team Deathmatch Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/lms-ffa.cfg b/config-samples/lms-ffa.cfg index 2f269eb9e..b2f3fa074 100644 --- a/config-samples/lms-ffa.cfg +++ b/config-samples/lms-ffa.cfg @@ -1,5 +1,5 @@ // Last Man Standing with "Modern" Doom 2 Style (16 Player) Deathmatch Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/survival-modern.cfg b/config-samples/survival-modern.cfg index d0f65ce91..25b402574 100644 --- a/config-samples/survival-modern.cfg +++ b/config-samples/survival-modern.cfg @@ -1,5 +1,5 @@ // "Modern" Doom(2) Survival Cooperative Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/tdm-doom.cfg b/config-samples/tdm-doom.cfg index 30006241d..13afb42b4 100644 --- a/config-samples/tdm-doom.cfg +++ b/config-samples/tdm-doom.cfg @@ -1,5 +1,5 @@ // Vanilla Doom(2) Style (2v2) Team Deathmatch Ruleset (50 Fraglimit/10 Min Timelimit/No Exit) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/tdm-modern.cfg b/config-samples/tdm-modern.cfg index 03e77ae66..74b819a4b 100644 --- a/config-samples/tdm-modern.cfg +++ b/config-samples/tdm-modern.cfg @@ -1,5 +1,5 @@ // "Modern" Doom 2 Style (8v8) Team Deathmatch Ruleset (No Jump/No Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/config-samples/tdm-zdoom.cfg b/config-samples/tdm-zdoom.cfg index 7ecc85d93..2e5a1b721 100644 --- a/config-samples/tdm-zdoom.cfg +++ b/config-samples/tdm-zdoom.cfg @@ -1,5 +1,5 @@ // "ZDOOM" Style (8v8) Team Deathmatch Ruleset (Jump/Freelook) -// Odamex 10.3.0 +// Odamex 10.4.0 // For in-depth information on these variables, visit http://odamex.net/wiki/Category:Server_variables // Note that 1 = on, 0 = off diff --git a/installer/windows/build_release.ps1 b/installer/windows/build_release.ps1 index 677920b98..94b55f978 100644 --- a/installer/windows/build_release.ps1 +++ b/installer/windows/build_release.ps1 @@ -9,7 +9,7 @@ # These parameters can and should be changed for new versions. # -Set-Variable -Name "OdamexVersion" -Value "10.3.0" +Set-Variable -Name "OdamexVersion" -Value "10.4.0" Set-Variable -Name "OdamexTestSuffix" -Value "" # "-RC3" # diff --git a/odalaunch/res/Info.plist b/odalaunch/res/Info.plist index 8d3b6a49b..44e45fa40 100644 --- a/odalaunch/res/Info.plist +++ b/odalaunch/res/Info.plist @@ -19,15 +19,15 @@ CFBundleSignature ???? CFBundleVersion - 10.3.0 + 10.4.0 CFBundleShortVersionString - 10.3.0 + 10.4.0 CFBundleGetInfoString - Copyright © 2006-2022 The Odamex Team + Copyright © 2006-2023 The Odamex Team CFBundleLongVersionString - 10.3.0 + 10.4.0 NSHumanReadableCopyright - Copyright © 2006-2022 The Odamex Team + Copyright © 2006-2023 The Odamex Team LSRequiresCarbon diff --git a/odalpapi/net_packet.h b/odalpapi/net_packet.h index 8891293c7..450e9fffe 100644 --- a/odalpapi/net_packet.h +++ b/odalpapi/net_packet.h @@ -66,7 +66,7 @@ #define VERSIONMINOR(V) ((V % 256) / 10) #define VERSIONPATCH(V) ((V % 256) % 10) -#define VERSION (MAKEVER(10, 3, 0)) +#define VERSION (MAKEVER(10, 4, 0)) #define PROTOCOL_VERSION 8 #define TAG_ID 0xAD0 diff --git a/switch.cmake b/switch.cmake index d0226c52b..dd239d2cd 100644 --- a/switch.cmake +++ b/switch.cmake @@ -37,7 +37,7 @@ set (GCONSOLE 1) # NACP info set (APP_TITLE "Odamex for Nintendo Switch") set (APP_AUTHOR "The Odamex Team") -set (APP_VERSION "10.3.0") +set (APP_VERSION "10.4.0") # Compiler stuff set(NACP_TOOL "${DEVKITPRO}/tools/bin/nacptool" CACHE PATH "nacp-tool") diff --git a/tools/upversion/upversion.ini b/tools/upversion/upversion.ini index fa3bc0f73..a9ee0b8e3 100644 --- a/tools/upversion/upversion.ini +++ b/tools/upversion/upversion.ini @@ -5,15 +5,15 @@ ; Existing and new versions of Odamex, in dotted-number format. ; Middle number only goes up to 25, last number only goes up to 9. -old_version=10.2.0 -new_version=10.3.0 +old_version=10.3.0 +new_version=10.4.0 ; Existing and new year ranges. Note that if these are the same, year ; replacement will be skipped entirely. Year ranges will not be updated ; in code comments. -old_year=2006-2022 -new_year=2006-2022 +old_year=2006-2023 +new_year=2006-2023 [files] From 46e0e1d7e6fcb8f0326884ba3331af92a3399bbc Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 9 Aug 2023 00:31:59 -0400 Subject: [PATCH 53/75] update to 10.4.0 --- odalaunch/res/gui_project.fbp | 2 +- odalaunch/src/dlg_about.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/odalaunch/res/gui_project.fbp b/odalaunch/res/gui_project.fbp index 77c1130ea..2345bf017 100644 --- a/odalaunch/res/gui_project.fbp +++ b/odalaunch/res/gui_project.fbp @@ -10315,7 +10315,7 @@ 0 0 wxID_ANY - Copyright (C) 2006-2022 The Odamex Team + Copyright (C) 2006-2023 The Odamex Team 0 diff --git a/odalaunch/src/dlg_about.cpp b/odalaunch/src/dlg_about.cpp index 3f7da287d..2e0991890 100644 --- a/odalaunch/src/dlg_about.cpp +++ b/odalaunch/src/dlg_about.cpp @@ -30,7 +30,7 @@ #include #include -#define _ODA_COPYRIGHT_ "Copyright (C) 2006-2022 The Odamex Team" +#define _ODA_COPYRIGHT_ "Copyright (C) 2006-2023 The Odamex Team" BEGIN_EVENT_TABLE(dlgAbout, wxDialog) EVT_TEXT_URL(XRCID("Id_TxtCtrlDevelopers"), dlgAbout::OnTxtCtrlUrlClick) From 53065be0f2dc3bf3cced30e6323a73e2d9f6142d Mon Sep 17 00:00:00 2001 From: Sean Leonard Date: Sat, 12 Aug 2023 13:44:07 -0700 Subject: [PATCH 54/75] Display the number of kills & deaths when an active player becomes a spectator --- server/src/sv_main.cpp | 94 +++++++++++++++++++++++++----------------- 1 file changed, 57 insertions(+), 37 deletions(-) diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index ca757ad7c..b6987a9fb 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -127,6 +127,7 @@ void P_PlayerLeavesGame(player_s* player); bool P_LineSpecialMovesSector(short special); void SV_UpdateShareKeys(player_t& player); +std::string SV_BuildKillsDeathsStatusString(player_t& player); std::string V_GetTeamColor(UserInfo userinfo); CVAR_FUNC_IMPL (sv_maxclients) @@ -183,7 +184,10 @@ CVAR_FUNC_IMPL (sv_maxplayers) SVC_PlayerMembers(*it, SVC_PM_SPECTATOR)); } - SV_BroadcastPrintf ("%s became a spectator.\n", it->userinfo.netname.c_str()); + std::string status = SV_BuildKillsDeathsStatusString(*it); + SV_BroadcastPrintf(PRINT_HIGH, "%s became a spectator.(%s)\n", + it->userinfo.netname.c_str(), status.c_str()); + MSG_WriteSVC( &it->client.reliablebuf, SVC_Print(PRINT_CHAT, @@ -1939,6 +1943,50 @@ void SV_ConnectClient2(player_t& player) SV_MidPrint((char*)sv_motd.cstring(), &player, 6); } + +// +// SV_BuildKillsDeathsStatusString +// +std::string SV_BuildKillsDeathsStatusString(player_t& player) +{ + std::string status; + char temp_str[100]; + + if (player.playerstate == PST_DOWNLOAD) + status = "downloading"; + else if (player.playerstate == PST_DISCONNECT && player.spectator) + status = "SPECTATOR"; + else + { + if (G_IsTeamGame()) + { + sprintf(temp_str, "%s TEAM, ", GetTeamInfo(player.userinfo.team)->ColorStringUpper.c_str()); + status += temp_str; + } + + // Points (CTF). + if (sv_gametype == GM_CTF) + { + sprintf(temp_str, "%d POINTS, ", player.points); + status += temp_str; + } + + // Frags (DM/TDM/CTF) or Kills (Coop). + if (G_IsCoopGame()) + sprintf(temp_str, "%d KILLS, ", player.killcount); + else + sprintf(temp_str, "%d FRAGS, ", player.fragcount); + + status += temp_str; + + // Deaths. + sprintf(temp_str, "%d DEATHS", player.deathcount); + status += temp_str; + } + return status; +} + + // // SV_DisconnectClient // @@ -1961,43 +2009,12 @@ void SV_DisconnectClient(player_t &who) Maplist_Disconnect(who); Vote_Disconnect(who); + who.playerstate = PST_DISCONNECT; + if (who.client.displaydisconnect) { // print some final stats for the disconnected player - std::string status; - if (who.playerstate == PST_DOWNLOAD) - status = "downloading"; - else if (who.spectator) - status = "SPECTATOR"; - else - { - if (G_IsTeamGame()) - { - sprintf(str, "%s TEAM, ", GetTeamInfo(who.userinfo.team)->ColorStringUpper.c_str()); - status += str; - } - - // Points (CTF). - if (sv_gametype == GM_CTF) - { - sprintf(str, "%d POINTS, ", who.points); - status += str; - } - - // Frags (DM/TDM/CTF) or Kills (Coop). - if (G_IsCoopGame()) - sprintf(str, "%d KILLS, ", who.killcount); - else - sprintf(str, "%d FRAGS, ", who.fragcount); - - status += str; - - // Deaths. - sprintf(str, "%d DEATHS", who.deathcount); - status += str; - } - - // Name and reason for disconnect. + std::string status = SV_BuildKillsDeathsStatusString(who); if (gametic - who.client.last_received == CLIENT_TIMEOUT*35) SV_BroadcastPrintf("%s timed out. (%s)\n", who.userinfo.netname.c_str(), status.c_str()); @@ -2006,7 +2023,6 @@ void SV_DisconnectClient(player_t &who) who.userinfo.netname.c_str(), status.c_str()); } - who.playerstate = PST_DISCONNECT; SV_UpdatePlayerQueuePositions(G_CanJoinGame, &who); } @@ -3580,7 +3596,11 @@ void SV_SpecPlayer(player_t &player, bool silent) P_SetSpectatorFlags(player); if (!silent) - SV_BroadcastPrintf(PRINT_HIGH, "%s became a spectator.\n", player.userinfo.netname.c_str()); + { + std::string status = SV_BuildKillsDeathsStatusString(player); + SV_BroadcastPrintf(PRINT_HIGH, "%s became a spectator.(%s)\n", + player.userinfo.netname.c_str(), status.c_str()); + } P_PlayerLeavesGame(&player); SV_UpdatePlayerQueuePositions(G_CanJoinGame, &player); From ea0319f1ccd06fe15bb306361ef493fc768ff175 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 16 Aug 2023 19:40:15 -0400 Subject: [PATCH 55/75] do demotests in different folder than archives, move demotest urls to envvar --- .github/workflows/windows.yml | 7 ++++++- ci/win-get-demotester.ps1 | 28 +++++++++++++++++++--------- ci/win-prepare-demotest.ps1 | 22 ++++++++++++++++++++++ 3 files changed, 47 insertions(+), 10 deletions(-) create mode 100644 ci/win-prepare-demotest.ps1 diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index da46ce5e3..daee52dbd 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -38,8 +38,13 @@ jobs: run: cmake --build .\build\ --config RelWithDebInfo --parallel - name: Prepare artifact run: .\ci\win-artifact.ps1 + - name: Stage artifacts for testing + run: .\ci\win-prepare-demotest.ps1 - name: Download DemoTester run: .\ci\win-get-demotester.ps1 + env: + DEMOTESTER_URL: ${{ env.DEMOTESTER_DOWNLOAD_URL }} + DEMORESOURCES_URL: ${{ env.DEMORESOURCES_DOWNLOAD_URL }} continue-on-error: true - name: Decrypt IWADs run: | @@ -56,7 +61,7 @@ jobs: - name: Run DemoTester run: python .\odatestcases.py env: - ODAMEX_BIN: ..\artifact\odamex.exe + ODAMEX_BIN: ..\demotest\odamex.exe working-directory: .\build\demotester continue-on-error: true - name: Upload artifact to B2 diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index a2c1aa159..b720045c2 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -1,15 +1,25 @@ Set-PSDebug -Trace 1 -$DemoTesterPath = "https://github.com/bcahue/odatests/releases/download/1.0.1/OdaTests-v1.0.1.zip" -$DemoResourcePath = "https://github.com/bcahue/odatests-resources/releases/download/1.0.0/odatests-resources-v1.0.0.zip" +if (($env:DEMOTESTER_URL -ne null) -and ($env:DEMORESOURCES_URL -ne null)) +{ + Write-Output "OdaTests Download URL: $env:DEMOTESTER_URL" + Write-Output "OdaTests WAD Resources Download URL: $env:DEMORESOURCES_URL" -Set-Location "build" -New-Item -Name "demotester" -ItemType "directory" | Out-Null + $DemoTesterPath = $env:DEMOTESTER_URL + $DemoResourcePath = $env:DEMORESOURCES_URL -Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip -Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip + Set-Location "build" + New-Item -Name "demotester" -ItemType "directory" | Out-Null -7z.exe x odatests.zip -odemotester -y -7z.exe x odatests-resources.zip -odemotester -y + Invoke-WebRequest -Uri $DemoTesterPath -OutFile .\odatests.zip + Invoke-WebRequest -Uri $DemoResourcePath -OutFile .\odatests-resources.zip -Set-Location .. + 7z.exe x odatests.zip -odemotester -y + 7z.exe x odatests-resources.zip -odemotester -y + + Set-Location .. +} +else +{ + Write-Output "OdaTests URL or OdaTests Resources URL missing, skipping..." +} diff --git a/ci/win-prepare-demotest.ps1 b/ci/win-prepare-demotest.ps1 new file mode 100644 index 000000000..a1f6d6c78 --- /dev/null +++ b/ci/win-prepare-demotest.ps1 @@ -0,0 +1,22 @@ +Set-PSDebug -Trace 1 + +Set-Location "build" +New-Item -Name "demotest" -ItemType "directory" | Out-Null + +# Copy all built files into artifact directory +Copy-Item -Path ` + ".\client\RelWithDebInfo\odamex.exe", ` + ".\client\RelWithDebInfo\odamex.pdb", ` + ".\client\RelWithDebInfo\*.dll", ` + ".\server\RelWithDebInfo\odasrv.exe", ` + ".\server\RelWithDebInfo\odasrv.pdb", ` + ".\odalaunch\RelWithDebInfo\odalaunch.exe", ` + ".\odalaunch\RelWithDebInfo\odalaunch.pdb", ` + ".\odalaunch\RelWithDebInfo\*.dll", ` + ".\wad\odamex.wad", ` + "C:\Windows\System32\msvcp140.dll", ` + "C:\Windows\System32\vcruntime140.dll", ` + "C:\Windows\System32\vcruntime140_1.dll" ` + -Destination "demotest" + +Set-Location .. From b4b4eff7c2e62496c67b155fef9a5b2a80e932e5 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 16 Aug 2023 20:00:37 -0400 Subject: [PATCH 56/75] forgot how to do powershell --- .github/workflows/windows.yml | 4 ++-- ci/win-get-demotester.ps1 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index daee52dbd..ebe96e041 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -40,7 +40,7 @@ jobs: run: .\ci\win-artifact.ps1 - name: Stage artifacts for testing run: .\ci\win-prepare-demotest.ps1 - - name: Download DemoTester + - name: Download OdaTests and Testing Resources run: .\ci\win-get-demotester.ps1 env: DEMOTESTER_URL: ${{ env.DEMOTESTER_DOWNLOAD_URL }} @@ -58,7 +58,7 @@ jobs: SECRET_KEY: ${{ secrets.DEMOTESTER_IWAD_KEY }} working-directory: .\build\demotester continue-on-error: true - - name: Run DemoTester + - name: Run OdaTests run: python .\odatestcases.py env: ODAMEX_BIN: ..\demotest\odamex.exe diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index b720045c2..59bf275f6 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -1,6 +1,6 @@ Set-PSDebug -Trace 1 -if (($env:DEMOTESTER_URL -ne null) -and ($env:DEMORESOURCES_URL -ne null)) +if (($env:DEMOTESTER_URL -ne $null) -and ($env:DEMORESOURCES_URL -ne $null)) { Write-Output "OdaTests Download URL: $env:DEMOTESTER_URL" Write-Output "OdaTests WAD Resources Download URL: $env:DEMORESOURCES_URL" From 465fdb460f90c6c3868411b19a681118190ae8d5 Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 16 Aug 2023 20:28:40 -0400 Subject: [PATCH 57/75] fix script and yaml --- .github/workflows/windows.yml | 4 ++-- ci/win-get-demotester.ps1 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index ebe96e041..a8e67a7f2 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -43,8 +43,8 @@ jobs: - name: Download OdaTests and Testing Resources run: .\ci\win-get-demotester.ps1 env: - DEMOTESTER_URL: ${{ env.DEMOTESTER_DOWNLOAD_URL }} - DEMORESOURCES_URL: ${{ env.DEMORESOURCES_DOWNLOAD_URL }} + DEMOTESTER_URL: ${{ vars.DEMOTESTER_DOWNLOAD_URL }} + DEMORESOURCES_URL: ${{ vars.DEMORESOURCES_DOWNLOAD_URL }} continue-on-error: true - name: Decrypt IWADs run: | diff --git a/ci/win-get-demotester.ps1 b/ci/win-get-demotester.ps1 index 59bf275f6..ed21c6e9d 100644 --- a/ci/win-get-demotester.ps1 +++ b/ci/win-get-demotester.ps1 @@ -1,6 +1,6 @@ Set-PSDebug -Trace 1 -if (($env:DEMOTESTER_URL -ne $null) -and ($env:DEMORESOURCES_URL -ne $null)) +if (!([String]::IsNullOrWhiteSpace($env:DEMOTESTER_URL)) -and !([String]::IsNullOrWhiteSpace($env:DEMORESOURCES_URL))) { Write-Output "OdaTests Download URL: $env:DEMOTESTER_URL" Write-Output "OdaTests WAD Resources Download URL: $env:DEMORESOURCES_URL" From 099d7e1da0443cd09ed32fa1e65126cf07b05adf Mon Sep 17 00:00:00 2001 From: bcahue Date: Wed, 16 Aug 2023 21:08:31 -0400 Subject: [PATCH 58/75] update readme to include info on how to get demo testing working on a fork --- README.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/README.md b/README.md index 5fcaecfad..915689568 100644 --- a/README.md +++ b/README.md @@ -77,6 +77,23 @@ Before submitting a pull request, please make sure it follows [our coding standa [3]: https://odamex.net/wiki/Coding_standard +**Note**: This project contains a demo testing utility that ensures vanilla compatibility by +running a specific set of demos after each commit. When forking this project to prepare a pull request, +this functionality will be unavailable by default to protect sensitive files. +You can restore this functionality by: + +1. Forking [OdaTest-Resources](https://github.com/odamex/odatests-resources) to get the PWADs. +2. Downloading [OdaTests](https://github.com/odamex/odatests) to get the encryption module. +3. Replacing the encrypted IWADs with your own set of encrypted IWADs. +Encrypt using `python .\secret.py encrypt doom2` with the environment variable +`SECRET_KEY` defined to encrypt the IWADs with. The following IWADs (latest version) are needed to run all tests: +`doom, doom1, doom2, tnt, plutonia, hacx` +4. Create a release for your forked OdaTest-Resources repo. +5. Enter the following Secrets / Repository Variables in GitHub: + - `secrets.DEMOTESTER_IWAD_KEY` - Encryption key for the IWADs + - `vars.DEMOTESTER_DOWNLOAD_URL` - Full URL to download the latest OdaTests release. + - `vars.DEMORESOURCES_DOWNLOAD_URL` - Full URL to download your personal demo resources + External Links -------------- From 04b1927ebf2baa2a41e6990023723879576cfc01 Mon Sep 17 00:00:00 2001 From: loopfz Date: Sun, 3 Sep 2023 21:26:36 +0000 Subject: [PATCH 59/75] Change g_coopthingfilter to g_thingfilter, and allow the value "3" to remove all pickupable things. --- common/c_cvarlist.cpp | 9 +++++---- common/doomdata.h | 2 +- common/p_mobj.cpp | 14 ++++++++++++++ common/p_setup.cpp | 6 +++--- 4 files changed, 23 insertions(+), 8 deletions(-) diff --git a/common/c_cvarlist.cpp b/common/c_cvarlist.cpp index 1e4f22145..312c042dc 100644 --- a/common/c_cvarlist.cpp +++ b/common/c_cvarlist.cpp @@ -245,12 +245,13 @@ CVAR(g_preroundreset, "0", "After preround is over, reset the map one last time. CVAR(g_postroundtime, "3", "Amount of time after a round before the next round/endgame", CVARTYPE_INT, CVAR_SERVERARCHIVE | CVAR_NOENABLEDISABLE) -CVAR_RANGE(g_coopthingfilter, "0", "Removes cooperative things of the map. Values are:\n" \ - "// 0 - All Coop things are retained (default).\n" \ +CVAR_RANGE(g_thingfilter, "0", "Removes some things from the map. Values are:\n" \ + "// 0 - All things are retained (default).\n" \ "// 1 - Only Coop weapons are removed.\n" \ - "// 2 - All Coop things are removed.", + "// 2 - All Coop things are removed.\n" \ + "// 3 - All pickupable things are removed.", CVARTYPE_BYTE, CVAR_SERVERARCHIVE | CVAR_SERVERINFO | CVAR_NOENABLEDISABLE | CVAR_LATCH, - 0.0f, 2.0f) + 0.0f, 3.0f) CVAR(g_resetinvonexit, "0", "Always reset players to their starting inventory on level exit", CVARTYPE_BOOL, diff --git a/common/doomdata.h b/common/doomdata.h index 367616ef5..2bbe997eb 100644 --- a/common/doomdata.h +++ b/common/doomdata.h @@ -269,7 +269,7 @@ typedef struct MapThing #define MTF_DEATHMATCH 0x0400 // Thing appears in deathmatch games // Custom MapThing Flags -#define MTF_FILTER_COOPWPN 0x0800 // Weapon thing is filtered with g_coopthingfilter 1. +#define MTF_FILTER_COOPWPN 0x0800 // Weapon thing is filtered with g_thingfilter 1. // (Hate this method but it works...) diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index ecd62b199..63c475421 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -85,6 +85,7 @@ EXTERN_CVAR(co_fixweaponimpacts) EXTERN_CVAR(co_fineautoaim) EXTERN_CVAR(sv_allowshowspawns) EXTERN_CVAR(sv_teamsinplay) +EXTERN_CVAR(g_thingfilter) mapthing2_t itemrespawnque[ITEMQUESIZE]; int itemrespawntime[ITEMQUESIZE]; @@ -2745,6 +2746,16 @@ size_t P_GetMapThingPlayerNumber(mapthing2_t *mthing) (mthing->type - 4001 + 4) % MAXPLAYERSTARTS; } +int P_IsPickupableThing(short type) +{ + return (type == 82 // SSG + || (type >= 2000 && type <= 2050) // weapons, ammo, health, armor, special items + || type == 17 // cell pack + || type == 83 // megasphere + || type == 8 // backpack + ); +} + // // P_SpawnMapThing // The fields of the mapthing should @@ -2886,6 +2897,9 @@ void P_SpawnMapThing (mapthing2_t *mthing, int position) return; } + if (g_thingfilter == 3 && P_IsPickupableThing(mthing->type)) + return; + // check for appropriate skill level if (!(mthing->flags & G_GetCurrentSkill().spawn_filter)) return; diff --git a/common/p_setup.cpp b/common/p_setup.cpp index 0c639b680..cb76b8e6a 100644 --- a/common/p_setup.cpp +++ b/common/p_setup.cpp @@ -70,7 +70,7 @@ int P_TranslateSectorSpecial(int special); extern dyncolormap_t NormalLight; extern AActor* shootthing; -EXTERN_CVAR(g_coopthingfilter) +EXTERN_CVAR(g_thingfilter) bool g_ValidLevel = false; @@ -629,9 +629,9 @@ void P_LoadThings (int lump) #ifdef SERVER_APP if (G_IsCoopGame()) { - if (g_coopthingfilter == 1) + if (g_thingfilter == 1) mt2.flags |= MTF_FILTER_COOPWPN; - else if (g_coopthingfilter == 2) + else if (g_thingfilter == 2) mt2.flags &= ~MTF_COOPERATIVE; } else From eee26dddbb91046c021915f213da7c247d5f54ac Mon Sep 17 00:00:00 2001 From: loopfz Date: Tue, 3 Oct 2023 16:49:30 +0000 Subject: [PATCH 60/75] Do not uppercase maplist items to fix download of mixed case wad files --- common/m_resfile.cpp | 14 +++++++------- server/src/sv_maplist.cpp | 6 +----- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git a/common/m_resfile.cpp b/common/m_resfile.cpp index cf77547bc..a278c769a 100644 --- a/common/m_resfile.cpp +++ b/common/m_resfile.cpp @@ -71,7 +71,7 @@ bool OResFile::make(OResFile& out, const std::string& file) out.m_fullpath = fullpath; out.m_md5 = hash; - out.m_basename = StdStringToUpper(basename); + out.m_basename = basename; return true; } @@ -111,7 +111,7 @@ bool OResFile::makeWithHash(OResFile& out, const std::string& file, const OMD5Ha out.m_fullpath = fullpath; out.m_md5 = hash; - out.m_basename = StdStringToUpper(basename); + out.m_basename = basename; return true; } @@ -136,8 +136,8 @@ bool OWantFile::make(OWantFile& out, const std::string& file, const ofile_t type out.m_wantedpath = file; out.m_wantedtype = type; - out.m_basename = StdStringToUpper(basename); - out.m_extension = std::string(".") + StdStringToUpper(extension); + out.m_basename = basename; + out.m_extension = std::string(".") + extension; return true; } @@ -165,8 +165,8 @@ bool OWantFile::makeWithHash(OWantFile& out, const std::string& file, const ofil out.m_wantedpath = file; out.m_wantedtype = type; out.m_wantedMD5 = hash; - out.m_basename = StdStringToUpper(basename); - out.m_extension = StdStringToUpper(extension); + out.m_basename = basename; + out.m_extension = extension; return true; } @@ -290,7 +290,7 @@ bool M_ResolveWantedFile(OResFile& out, const OWantFile& wanted) M_ExtractFileBase(path, basename); if (M_ExtractFileExtension(path, strext)) { - exts.push_back("." + StdStringToUpper(strext)); + exts.push_back("." + strext); } else { diff --git a/server/src/sv_maplist.cpp b/server/src/sv_maplist.cpp index 06b63a5cc..e1baa2180 100644 --- a/server/src/sv_maplist.cpp +++ b/server/src/sv_maplist.cpp @@ -129,13 +129,9 @@ bool Maplist::insert(const size_t &position, maplist_entry_t &maplist_entry) { } } - // capitalize the map name and WAD file names + // capitalize the map names maplist_entry.map = StdStringToUpper(maplist_entry.map); - for (std::vector::iterator it = maplist_entry.wads.begin(); - it != maplist_entry.wads.end(); ++it) - *it = StdStringToUpper(*it); - // Puts the map into its proper place this->maplist.insert(this->maplist.begin() + position, maplist_entry); From fa5bea9b1994257e9ceed3742092f79290152560 Mon Sep 17 00:00:00 2001 From: Sbzro12345 Date: Tue, 21 Nov 2023 06:07:55 +0700 Subject: [PATCH 61/75] Fix MBF21 instakill sector to not kill IDDQD players --- common/p_boomfspec.cpp | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/common/p_boomfspec.cpp b/common/p_boomfspec.cpp index 2307217ee..d78565d98 100644 --- a/common/p_boomfspec.cpp +++ b/common/p_boomfspec.cpp @@ -1304,17 +1304,20 @@ void P_PlayerInCompatibleSector(player_t* player) { switch ((sector->special & DAMAGE_MASK) >> DAMAGE_SHIFT) { - case 0: // Kill player unless invuln or rad suit - if (!player->powers[pw_invulnerability] && !player->powers[pw_ironfeet]) + case 0: // Kill player unless invuln or rad suit or IDDQD + if (!player->powers[pw_invulnerability] && !player->powers[pw_ironfeet] && !(player->cheats & CF_GODMODE)) { - P_DamageMobj(player->mo, NULL, NULL, 10000, MOD_UNKNOWN); + P_DamageMobj(player->mo, NULL, NULL, 999, MOD_UNKNOWN); // 999 so BUDDHA can survive } break; - case 1: // Kill player with no scruples - P_DamageMobj(player->mo, NULL, NULL, 10000, MOD_UNKNOWN); - break; + case 1: // Kill player with no scruples unless IDDQD + if(!(player->cheats & CF_GODMODE)) + { + P_DamageMobj(player->mo, NULL, NULL, 10000, MOD_UNKNOWN); + break; + } case 2: // Kill all players and exit. There's no delay here so it may confuse - // some players. + // some players. Do NOT kill players with IDDQD. if (serverside) { if (sv_allowexit) @@ -1322,14 +1325,14 @@ void P_PlayerInCompatibleSector(player_t* player) for (Players::iterator it = ::players.begin(); it != ::players.end(); ++it) { - if (player->ingame() && player->health > 0) + if (player->ingame() && player->health > 0 && !(player->cheats & CF_GODMODE)) { P_DamageMobj((*it).mo, NULL, NULL, 10000, MOD_EXIT); } } G_ExitLevel(0, 1); } - else + else if (!(player->cheats & CF_GODMODE)) // Do NOT kill players with IDDQD. { P_DamageMobj( player->mo, NULL, NULL, 10000, @@ -1339,7 +1342,7 @@ void P_PlayerInCompatibleSector(player_t* player) } break; case 3: // Kill all players and secret exit. There's no delay here so it may - // confuse some players. + // confuse some players. Do NOT kill players with IDDQD. if (serverside) { if (sv_allowexit) @@ -1347,14 +1350,14 @@ void P_PlayerInCompatibleSector(player_t* player) for (Players::iterator it = ::players.begin(); it != ::players.end(); ++it) { - if (player->ingame() && player->health > 0) + if (player->ingame() && player->health > 0 && !(player->cheats & CF_GODMODE)) { P_DamageMobj((*it).mo, NULL, NULL, 10000, MOD_EXIT); } } G_SecretExitLevel(0, 1); } - else + else if (!(player->cheats & CF_GODMODE)) // Do NOT kill players with IDDQD. { P_DamageMobj( player->mo, NULL, NULL, 10000, @@ -1365,7 +1368,7 @@ void P_PlayerInCompatibleSector(player_t* player) break; } } - else + else if (!(player->cheats & CF_GODMODE)) // Do NOT damage players with IDDQD. { P_ApplyGeneralizedSectorDamage(player, (sector->special & DAMAGE_MASK) >> DAMAGE_SHIFT); From b63967f531e71e87a3582ca5c9d5c269ecd4a62d Mon Sep 17 00:00:00 2001 From: Sbzro12345 Date: Tue, 21 Nov 2023 06:10:19 +0700 Subject: [PATCH 62/75] Wrongly placed break --- common/p_boomfspec.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/p_boomfspec.cpp b/common/p_boomfspec.cpp index d78565d98..bed8da9f5 100644 --- a/common/p_boomfspec.cpp +++ b/common/p_boomfspec.cpp @@ -1314,8 +1314,8 @@ void P_PlayerInCompatibleSector(player_t* player) if(!(player->cheats & CF_GODMODE)) { P_DamageMobj(player->mo, NULL, NULL, 10000, MOD_UNKNOWN); - break; } + break; case 2: // Kill all players and exit. There's no delay here so it may confuse // some players. Do NOT kill players with IDDQD. if (serverside) From b952137ac487a6558e1796c86d8fd55b8b3c9025 Mon Sep 17 00:00:00 2001 From: matoro Date: Wed, 6 Dec 2023 01:01:29 -0500 Subject: [PATCH 63/75] Fix auto-SIMD for i386+sse2, ppc+altivec Only Darwin ever used -faltivec, gcc uses -maltivec since at least 2007: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=30254#c1 Similarly, recent versions of gcc define __APPLE_ALTIVEC__ for compatibility, so just unconditionally include altivec.h. Canonical way to enable specific extensions is e.g. -msse2, use that instead of optimizing for a specific CPU. Finally, cmake uses target_compile_options to add arbitrary flags. target_compile_definitions assumes you want a preprocessor definition, which was adding "-D-faltivec" to the command line which gcc doesn't like; this is what originally prompted this change. --- client/CMakeLists.txt | 11 +++++++---- client/src/r_drawt_altivec.cpp | 2 -- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index 646164916..56caf04f8 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -169,14 +169,17 @@ if(TARGET SDL2::SDL2 OR TARGET SDL::SDL) message(STATUS "Default SIMD flags not touched for AMD64") elseif(ODAMEX_TARGET_ARCH STREQUAL "i386") if(NOT MSVC) - # Pentium M has SSE2. - target_compile_definitions(odamex PRIVATE -march=pentium-m) + target_compile_options(odamex PRIVATE -msse2) else() - target_compile_definitions(odamex PRIVATE /arch:SSE2) + target_compile_options(odamex PRIVATE /arch:SSE2) endif() message(STATUS "Default SIMD flags set to SSE2") elseif(ODAMEX_TARGET_ARCH MATCHES "ppc") - target_compile_definitions(odamex PRIVATE -faltivec) + if(APPLE) + target_compile_options(odamex PRIVATE -faltivec) + else() + target_compile_options(odamex PRIVATE -maltivec) + endif() message(STATUS "Default SIMD flags set to AltiVec") endif() else() diff --git a/client/src/r_drawt_altivec.cpp b/client/src/r_drawt_altivec.cpp index eea758733..5a0cdf95e 100644 --- a/client/src/r_drawt_altivec.cpp +++ b/client/src/r_drawt_altivec.cpp @@ -36,9 +36,7 @@ #include "r_main.h" #include "i_video.h" -#if !defined(__APPLE_ALTIVEC__) #include -#endif #define ALTIVEC_ALIGNED(x) x __attribute__((aligned(16))) From 2c03a5605bfac19cec66d2aa0fc71110d3c36bd0 Mon Sep 17 00:00:00 2001 From: bcahue Date: Sun, 11 Feb 2024 00:56:07 -0500 Subject: [PATCH 64/75] backout conveyer changes --- common/actor.h | 1 - common/p_mobj.cpp | 56 +++--------------------------------------- common/p_spec.cpp | 1 - server/src/sv_main.cpp | 8 ------ 4 files changed, 3 insertions(+), 63 deletions(-) diff --git a/common/actor.h b/common/actor.h index 13ea46063..c8fcaa724 100644 --- a/common/actor.h +++ b/common/actor.h @@ -521,7 +521,6 @@ class AActor : public DThinker SWORD gear; // killough 11/98: used in torque simulation bool onground; // NES - Fixes infinite jumping bug like a charm. - bool on_conveyor; // Blair - Update items on conveyors more often // a linked list of sectors where this object appears struct msecnode_s *touching_sectorlist; // phares 3/14/98 diff --git a/common/p_mobj.cpp b/common/p_mobj.cpp index 63c475421..aee30e6ba 100644 --- a/common/p_mobj.cpp +++ b/common/p_mobj.cpp @@ -128,7 +128,7 @@ AActor::AActor() prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyor(false),state(NULL), damage(0), flags(0), flags2(0), + info(NULL), tics(0), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -149,7 +149,7 @@ AActor::AActor(const AActor& other) dropoffz(other.dropoffz), floorsector(other.floorsector), radius(other.radius), height(other.height), momx(other.momx), momy(other.momy), momz(other.momz), validcount(other.validcount), type(other.type), info(other.info), tics(other.tics), - state(other.state), on_conveyor(other.on_conveyor), damage(other.damage), + state(other.state), damage(other.damage), flags(other.flags), flags2(other.flags2), flags3(other.flags3), oflags(other.oflags), special1(other.special1), special2(other.special2), health(other.health), movedir(other.movedir), movecount(other.movecount), @@ -198,7 +198,6 @@ AActor &AActor::operator= (const AActor &other) info = other.info; tics = other.tics; state = other.state; - on_conveyor = other.on_conveyor; damage = other.damage; flags = other.flags; flags2 = other.flags2; @@ -247,7 +246,7 @@ AActor::AActor(fixed_t ix, fixed_t iy, fixed_t iz, mobjtype_t itype) prevangle(0), sprite(SPR_UNKN), frame(0), pitch(0), prevpitch(0), effects(0), subsector(NULL), floorz(0), ceilingz(0), dropoffz(0), floorsector(NULL), radius(0), height(0), momx(0), momy(0), momz(0), validcount(0), type(MT_UNKNOWNTHING), - info(NULL), tics(0), on_conveyor(false), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), + info(NULL), tics(0), state(NULL), damage(0), flags(0), flags2(0), flags3(0), oflags(0), special1(0), special2(0), health(0), movedir(0), movecount(0), visdir(0), reactiontime(0), threshold(0), player(NULL), lastlook(0), special(0), inext(NULL), iprev(NULL), translation(translationref_t()), translucency(0), waterlevel(0), @@ -685,55 +684,6 @@ void AActor::RunThink () prevpitch = pitch; } - // Check to see if this actor is still on a conveyor. - if (on_conveyor) - { - bool still_on = false; - - TThinkerIterator scrollIter; - DScroller* scroller; - - while ((scroller = scrollIter.Next())) - { - if (scroller->GetType() != DScroller::sc_carry) - { - continue; - } - - sector_t* sec = sectors + scroller->GetAffectee(); - fixed_t height = P_HighestHeightOfFloor(sec); - fixed_t waterheight = - sec->heightsec && P_HighestHeightOfFloor(sec->heightsec) > height - ? P_HighestHeightOfFloor(sec->heightsec) - : MININT; - - if ((subsector->sector - sectors) == scroller->GetAffectee()) - { - msecnode_t* node; - AActor* thing; - - for (node = sec->touching_thinglist; node; node = node->m_snext) - { - if (!((thing = node->m_thing)->flags & MF_NOCLIP) && - (!(thing->flags & MF_NOGRAVITY || thing->z > height) || - thing->z < waterheight) && - thing == this) - { - still_on = true; - break; - } - } - } - - if (still_on) - { - break; - } - } - - on_conveyor = still_on; - } - // server removal of corpses only if (!clientside && serverside) { diff --git a/common/p_spec.cpp b/common/p_spec.cpp index df1a42a6a..4fdcf4407 100644 --- a/common/p_spec.cpp +++ b/common/p_spec.cpp @@ -2556,7 +2556,6 @@ void DScroller::RunThink () { // Move objects only if on floor or underwater, // non-floating, and clipped. - thing->on_conveyor = true; thing->momx += dx; thing->momy += dy; } diff --git a/server/src/sv_main.cpp b/server/src/sv_main.cpp index b6987a9fb..ffa61a676 100644 --- a/server/src/sv_main.cpp +++ b/server/src/sv_main.cpp @@ -1169,14 +1169,6 @@ bool SV_AwarenessUpdate(player_t &player, AActor *mo) return true; } - else if (previously_ok && ok - && player.mo && !mo->player && mo->type != MT_AVATAR && mo->type != MT_PLAYER - && mo->on_conveyor - && (gametic + mo->netid) % 120) // Update items on conveyers every 120 tics - { - SV_SendMobjToClient(mo, cl); - return true; - } return false; From bc5d134c161b38c30d63fc2c7e0fa1271cd2c89a Mon Sep 17 00:00:00 2001 From: ceski <56656010+ceski-1@users.noreply.github.com> Date: Sun, 11 Feb 2024 20:16:47 -0800 Subject: [PATCH 65/75] Improve game controller deadzones --- client/sdl/i_input_sdl20.cpp | 42 ++++++++++++++++++++++++++++++------ client/sdl/i_input_sdl20.h | 2 ++ client/src/cl_cvarlist.cpp | 2 +- 3 files changed, 39 insertions(+), 7 deletions(-) diff --git a/client/sdl/i_input_sdl20.cpp b/client/sdl/i_input_sdl20.cpp index e7283b165..90121cbde 100644 --- a/client/sdl/i_input_sdl20.cpp +++ b/client/sdl/i_input_sdl20.cpp @@ -726,15 +726,10 @@ void ISDL20JoystickInputDevice::gatherEvents() } else { - float deadzone = (joy_deadzone * 32767); event_t motion_event(ev_joystick); motion_event.type = ev_joystick; motion_event.data2 = sdl_ev.caxis.axis; - if ((sdl_ev.caxis.value >= deadzone) || - (sdl_ev.caxis.value <= -deadzone)){ - motion_event.data3 = sdl_ev.caxis.value; - } - + motion_event.data3 = calcAxisValue(sdl_ev.caxis.value); mEvents.push(motion_event); } @@ -743,6 +738,41 @@ void ISDL20JoystickInputDevice::gatherEvents() } } +int ISDL20JoystickInputDevice::calcAxisValue(int raw_value) +{ + float value; + + // Normalize. + if (raw_value > 0) + { + value = (float)raw_value / (float)SDL_JOYSTICK_AXIS_MAX; + } + else if (raw_value < 0) + { + value = (float)raw_value / (float)abs(SDL_JOYSTICK_AXIS_MIN); + } + else + { + value = 0.0f; + } + + // Apply deadzone. + if (value > joy_deadzone) + { + value = (value - joy_deadzone) / (1.0f - joy_deadzone); + } + else if (value < -joy_deadzone) + { + value = (value + joy_deadzone) / (1.0f - joy_deadzone); + } + else + { + value = 0.0f; + } + + // Scale value to the range used for calculations in G_BuildTiccmd(). + return lroundf(value * 32767.0f); +} // // ISDL20JoystickInputDevice::getEvent diff --git a/client/sdl/i_input_sdl20.h b/client/sdl/i_input_sdl20.h index b3cdcf855..0d3d9012a 100644 --- a/client/sdl/i_input_sdl20.h +++ b/client/sdl/i_input_sdl20.h @@ -139,6 +139,8 @@ class ISDL20JoystickInputDevice : public IInputDevice virtual void flushEvents(); private: + int calcAxisValue(int raw_value); + static const int JOY_DEADZONE = 6000; bool mActive; diff --git a/client/src/cl_cvarlist.cpp b/client/src/cl_cvarlist.cpp index d7013c302..531cbc3dc 100644 --- a/client/src/cl_cvarlist.cpp +++ b/client/src/cl_cvarlist.cpp @@ -309,7 +309,7 @@ CVAR (joy_fastsensitivity, "15.0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR CVAR (joy_freelook, "0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE) CVAR (joy_invert, "0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE) -CVAR_RANGE (joy_deadzone, "0.34", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.0f, 1.0f) +CVAR_RANGE (joy_deadzone, "0.20", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.0f, 1.0f) CVAR_RANGE(joy_lefttrigger_deadzone, "0.2", "Sets the required pressure to trigger a press on the left trigger (Analog controllers only)", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.01f, 1.0f) From 09ab2c8b3ed933440aa92e14933318f52069c46f Mon Sep 17 00:00:00 2001 From: ceski <56656010+ceski-1@users.noreply.github.com> Date: Sun, 11 Feb 2024 19:36:20 -0800 Subject: [PATCH 66/75] Flush/ignore unused game controller events --- client/sdl/i_input_sdl20.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/client/sdl/i_input_sdl20.cpp b/client/sdl/i_input_sdl20.cpp index e7283b165..fb1bdf8a2 100644 --- a/client/sdl/i_input_sdl20.cpp +++ b/client/sdl/i_input_sdl20.cpp @@ -741,6 +741,9 @@ void ISDL20JoystickInputDevice::gatherEvents() } } } + + // Flush all remaining joystick and game controller events. + SDL_FlushEvents(SDL_JOYAXISMOTION, SDL_CONTROLLERDEVICEREMAPPED); } @@ -788,6 +791,14 @@ ISDL20InputSubsystem::ISDL20InputSubsystem() : SDL_EventState(SDL_CONTROLLERBUTTONDOWN, SDL_IGNORE); SDL_EventState(SDL_CONTROLLERBUTTONUP, SDL_IGNORE); + // Ignore unsupported game controller events. +#if (SDL_MINOR_VERSION > 0 || SDL_PATCHLEVEL >= 14) + SDL_EventState(SDL_CONTROLLERTOUCHPADDOWN, SDL_IGNORE); + SDL_EventState(SDL_CONTROLLERTOUCHPADMOTION, SDL_IGNORE); + SDL_EventState(SDL_CONTROLLERTOUCHPADUP, SDL_IGNORE); + SDL_EventState(SDL_CONTROLLERSENSORUPDATE, SDL_IGNORE); +#endif + grabInput(); } From 704dd27a6c5338ddb45b7c954caf4d020f3009b7 Mon Sep 17 00:00:00 2001 From: ceski <56656010+ceski-1@users.noreply.github.com> Date: Sun, 11 Feb 2024 21:36:13 -0800 Subject: [PATCH 67/75] Use consistent `joy_deadzone` range for menu/CVAR --- client/src/cl_cvarlist.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/cl_cvarlist.cpp b/client/src/cl_cvarlist.cpp index 531cbc3dc..8ba00d710 100644 --- a/client/src/cl_cvarlist.cpp +++ b/client/src/cl_cvarlist.cpp @@ -309,7 +309,7 @@ CVAR (joy_fastsensitivity, "15.0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR CVAR (joy_freelook, "0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE) CVAR (joy_invert, "0", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE) -CVAR_RANGE (joy_deadzone, "0.20", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.0f, 1.0f) +CVAR_RANGE (joy_deadzone, "0.20", "", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.0f, 0.75f) CVAR_RANGE(joy_lefttrigger_deadzone, "0.2", "Sets the required pressure to trigger a press on the left trigger (Analog controllers only)", CVARTYPE_FLOAT, CVAR_CLIENTARCHIVE | CVAR_NOENABLEDISABLE, 0.01f, 1.0f) From 555bd1b93fa28368938d548bb975b353c208aa76 Mon Sep 17 00:00:00 2001 From: James Le Cuirot Date: Sun, 17 Mar 2024 23:29:59 +0000 Subject: [PATCH 68/75] Fix aliasing error in client concerning sector gravity Both the LHS and RHS of this assignment are floats, so you shouldn't cast to an int. They weren't floats at the time the cast was added. --- client/src/cl_parse.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/cl_parse.cpp b/client/src/cl_parse.cpp index cdadbbdf2..e15c45edc 100644 --- a/client/src/cl_parse.cpp +++ b/client/src/cl_parse.cpp @@ -2354,7 +2354,7 @@ static void CL_SectorProperties(const odaproto::svc::SectorProperties* msg) break; } case SPC_Gravity: - *(int*)§or->gravity = msg->sector().gravity(); + *§or->gravity = msg->sector().gravity(); break; case SPC_Panning: sector->ceiling_xoffs = msg->sector().ceiling_offs().x(); From 38116da6a371c298d6489dc719aef6d3f88500c4 Mon Sep 17 00:00:00 2001 From: James Le Cuirot Date: Sun, 17 Mar 2024 23:30:38 +0000 Subject: [PATCH 69/75] Fix aliasing error in pusher serialization m_Source is an AActorPtr aka an szp. AActor is a subclass of DObject so casting should work cleanly here, but it needs to be done against the underlying pointer, not the self zeroing wrapper. --- common/p_spec.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/p_spec.cpp b/common/p_spec.cpp index df1a42a6a..d0a5af419 100644 --- a/common/p_spec.cpp +++ b/common/p_spec.cpp @@ -465,7 +465,7 @@ void DPusher::Serialize (FArchive &arc) else { arc >> m_Type; - arc.ReadObject((DObject*&)m_Source, DPusher::StaticType()); + arc.ReadObject((DObject*&)*m_Source, DPusher::StaticType()); arc >> m_Xmag >> m_Ymag >> m_Magnitude >> m_Radius >> m_X >> m_Y >> m_Affectee; } } From 30a206aefe80216c74e3d5bc7a6d4405c3ca2ca6 Mon Sep 17 00:00:00 2001 From: James Le Cuirot Date: Mon, 18 Mar 2024 21:57:48 +0000 Subject: [PATCH 70/75] Fix aliasing error in net code that sets remote address The code currently assigns an in_addr (sin_addr) to an in_addr_t (sin_addr.s_addr) for no apparent reason. Even looking back at commit 28febc73ef5e877f does not make this clearer. I can only assume that the value was supposed to be assigned to sin_addr. It presumably worked anyway because an in_addr only contains an in_addr_t. --- odalpapi/net_io.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/odalpapi/net_io.cpp b/odalpapi/net_io.cpp index d6dd666fe..16f136374 100644 --- a/odalpapi/net_io.cpp +++ b/odalpapi/net_io.cpp @@ -194,7 +194,7 @@ void BufferedSocket::SetRemoteAddress(const string& Address, const uint16_t& Por m_RemoteAddress.sin_family = PF_INET; m_RemoteAddress.sin_port = htons(Port); - m_RemoteAddress.sin_addr.s_addr = *((unsigned long*)&(((sockaddr_in*)result->ai_addr)->sin_addr)); + m_RemoteAddress.sin_addr = ((sockaddr_in*)result->ai_addr)->sin_addr; memset(m_RemoteAddress.sin_zero, '\0', sizeof m_RemoteAddress.sin_zero); freeaddrinfo(result); From 3631f4395a22710ff0a2dde1d0ece54059ac4b9e Mon Sep 17 00:00:00 2001 From: Ralph Vickers Date: Sun, 24 Mar 2024 13:19:45 -0400 Subject: [PATCH 71/75] Update network connection error graphic Update network connection error graphic to include text so that it's more clear what's going on. --- wad/graphics/net.gif | Bin 1264 -> 1085 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/wad/graphics/net.gif b/wad/graphics/net.gif index a89b51ac0f5d85af2c28bdde91fce18ae1c85f29..e2ffc12f775970ddd5fe8e528fad85171c0bb75a 100644 GIT binary patch literal 1085 zcmZ?wbh9u|RAta(C}&_${K>+}#lXOz1H=p(h9-f?>oSmJWpPye|Uf#{X zFq?s4IRnFH28R7Wwz2VIYwP9q_NN&bt}`$^W?=XaMDp_g?d@kr3$J%~-|X+dJ3M@U zboBA$GS8$-@m+n`SRtfSFhf@dGq$|+xPF^ z|GdBd`|8#Iw{Jgw{P^k9r!QZ=eEat8=g*(NfBzohogqZB|8HPuVrgk@Ywzf6YwBS! z?C&?4WHe#wq=}QK8Va-YG|!qmW!B=EQ|HWM=reR#vv%G34eME#&tsXg&UWK27rS+v z=Wgv^Yon&Od%c?4P8a9>D^|H!TFNM^>0G*T^M>jjRWnP+a|c&jns7@gUNe9F=B=u- zk}SWerNg7%Lr)pmBwuRjGcs`TeDGsoXJO2{vip0dOfLhY&==#4N(VT*#hiOM4nAaX zY5kV*u$ZIpzKf_TbHF>nQx|Wb#0vfa_2q@9C8957#8k>b<&A+eS}n+o>X6 zlT?`>Qrk|$Bw=)hkdvF|zn{D>(RWrlSjm@t}z(s^MS*tBc0N7LhOyMb>M*ixM@ZW?d3vG-%Oy z)S)shBdJ4PYtf^w?gft?bsHQz!NJ*d!Q)V`*`tidJq#~yJnl99r=h~hC=e;c;5yAE zWmd1Jn&*>A{!T|k!x?>Ec5*OsG%e*|$eHWomim8sKWCv~PyPo378I#V`9 zGM&Ao?10CdrX!sZ45jBZ)#ukMX?jf4G;CV7z(c4?Wmb!t*5kz!PQ6g>GiCazJYkAk zmWoT@w;4;8`_*x+oSGSAxpaEYysC_z{5s9l*(<6d)t1yUH7uXM?Ng-sf}L(r8jCx$ NxB@rmu`w}N0|1n~dxro3 literal 1264 zcmW-gacmQH6vrQvSwaIv>Nsb`A}1E?*cnbZNYN8+;~3Q(aN7=YBQ4Zfq*@(<)RLa0Wd~;^D z$V4bK=Jyx8-n`qLb2u`xoR*}N#gY`ogdoH?F3PfDnhqHZ0h06+gjcWk;J8bxb!s$r z43pJrNu{zXl_rHkR490bf&*Xy7yvYuMih>|;9LKUO!!QPefubmaAapt%j^lP@vyEG=d6Q{K5R)7qWsO0a@lmvkpkzH^ z!F9Yw%U~F(QsYV`rbvdp@t`~EcZR+8pxYL3NEM!Si&@}$V>IRnm+8i&(jlLf29i58X@3@k^|te&EE2+3nPA)8<>28gIb z8xYlQMj`8==rzjaP$Gc>0pxHXlL^r@(rOXFIKT)%79b6f1c(8I0RjLX04IP9UugQKdC#GL)ipM1yIa^LL%}S zkW(`uV`DZ|-m1!)lxab6k%Kr3QRd;FD2q@GAumD_LM%c!LJ+1QNP&+4H(m^x8#L*C7g*heF>*ayRSxePC4B=w(gPEjc!%uP<8sK zr?(~3)-$;5ZtmQkDHXf^ed26>Kq3a)2ntK6tSwlSbA|! zL;L*gc=hn5%9&MQMa)s#1u)i-P?E8Eo6|E=Hr z!J^Sm8q9S^=9u?y_^zX=_x5O@vHh7fbxoJwEF6Dl^jM+X_txcuRqxkNolWkYv*WkU S51(7NaP|IWJJ!DfhW`Qo+$(Va From 6565ca64e83207a8c3721df83874436b5107e699 Mon Sep 17 00:00:00 2001 From: Ralph Vickers Date: Sun, 24 Mar 2024 13:51:36 -0400 Subject: [PATCH 72/75] Fix attempt on net icon --- wad/graphics/net.gif | Bin 1085 -> 1498 bytes 1 file changed, 0 insertions(+), 0 deletions(-) diff --git a/wad/graphics/net.gif b/wad/graphics/net.gif index e2ffc12f775970ddd5fe8e528fad85171c0bb75a..834705dbf303dc1761e456f9877e0593bc872289 100644 GIT binary patch literal 1498 zcmY+De@qj17{3~M#r>Ity%B@f|lB5gAt7S5WL}JG<8;V*H#4Hk- zghGQrpy%^x9#6~VsyQ5r!%=cL3IIp|2ms)41P%mYH~@pKu-6R(F6ei_)=KC$k1)n~ zwLa>gBbAzvmFhJsS(CzVl)LpLqa&(m+@X=#)KZH|Vp3uT1xk}*HGwE`kz6XoF@Xf- zqX;h^k4K}?NF)*thl9Z&%d&w$!0-3_d_K3^%`lA1<#IZmcDuc@veIg`n$2dD$z(7X zbUGbP(;AJ2q9~P0rBEnHk|YR1CX-2}QVheyVljds2B_1;wc3bU-K(Pf3S}cHcj82) z6gOj1J&I`%u~H}^1Of?D00RJo0AK;|1KR`@^>7tgi{X-o+_J)mv74Hmc*PYI9 zN@`ljuHSz?&%Jq1*WWX%Qa}BnrebIxJ9VR{ZhJoKjiLGO;vf5upF4QB3U%+wDC<`> zc!ZhrlXGTW4d;7H=ikj8`7?0EINJ2jaQ39~Tssy#zJ~3?em)etGl%;Shs6 z_A`BTany^!z>JM!ddgG$WXk;4{|4{$wuM^uF@4O8-hkh*iF#eH{^qxbQ@6J@le0}V zqtQRGmZV=Y_MSOLZlFYGM*LHoox2b6TgVKhA#r^B^)?9YVMVl_qHDB6UHbJTU zZrA5>Pu_u!&qlXhEl=}aIg^pH;`O2wdFG>XZrbA2m%8+uRuA^1`EHeD9POSE$W4ho zeVCr|N#X5xsdXiz?P+4Lq+vY_@&TndTaB<$*IrUC%yQ3d3#dl(6i3ufvI(M{NBU|$z1Exiyf=jko!hvPRtw0 sVq@O^Y_y~~)?jR6r*y8u+Ft!N7VrKrqQS0pP3gYS{;}X*aXOIw2Nd?eF8}}l literal 1085 zcmZ?wbh9u|RAta(C}&_${K>+}#lXOz1H=p(h9-f?>oSmJWpPye|Uf#{X zFq?s4IRnFH28R7Wwz2VIYwP9q_NN&bt}`$^W?=XaMDp_g?d@kr3$J%~-|X+dJ3M@U zboBA$GS8$-@m+n`SRtfSFhf@dGq$|+xPF^ z|GdBd`|8#Iw{Jgw{P^k9r!QZ=eEat8=g*(NfBzohogqZB|8HPuVrgk@Ywzf6YwBS! z?C&?4WHe#wq=}QK8Va-YG|!qmW!B=EQ|HWM=reR#vv%G34eME#&tsXg&UWK27rS+v z=Wgv^Yon&Od%c?4P8a9>D^|H!TFNM^>0G*T^M>jjRWnP+a|c&jns7@gUNe9F=B=u- zk}SWerNg7%Lr)pmBwuRjGcs`TeDGsoXJO2{vip0dOfLhY&==#4N(VT*#hiOM4nAaX zY5kV*u$ZIpzKf_TbHF>nQx|Wb#0vfa_2q@9C8957#8k>b<&A+eS}n+o>X6 zlT?`>Qrk|$Bw=)hkdvF|zn{D>(RWrlSjm@t}z(s^MS*tBc0N7LhOyMb>M*ixM@ZW?d3vG-%Oy z)S)shBdJ4PYtf^w?gft?bsHQz!NJ*d!Q)V`*`tidJq#~yJnl99r=h~hC=e;c;5yAE zWmd1Jn&*>A{!T|k!x?>Ec5*OsG%e*|$eHWomim8sKWCv~PyPo378I#V`9 zGM&Ao?10CdrX!sZ45jBZ)#ukMX?jf4G;CV7z(c4?Wmb!t*5kz!PQ6g>GiCazJYkAk zmWoT@w;4;8`_*x+oSGSAxpaEYysC_z{5s9l*(<6d)t1yUH7uXM?Ng-sf}L(r8jCx$ NxB@rmu`w}N0|1n~dxro3 From f9a7a1f3b5ef0f2612e512c810d06073d843754d Mon Sep 17 00:00:00 2001 From: James Le Cuirot Date: Mon, 18 Mar 2024 22:54:16 +0000 Subject: [PATCH 73/75] Always define INSTALL_PREFIX to fix paths for odalaunch Without INSTALL_PREFIX, it was falling back to the current directory and failing to launch the game. --- CMakeLists.txt | 5 +++++ client/CMakeLists.txt | 5 ----- server/CMakeLists.txt | 5 ----- 3 files changed, 5 insertions(+), 10 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 147060cb1..97c447424 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -26,6 +26,11 @@ include(GNUInstallDirs OPTIONAL) add_definitions(-DINSTALL_BINDIR="${CMAKE_INSTALL_BINDIR}") add_definitions(-DINSTALL_DATADIR="${CMAKE_INSTALL_DATADIR}") +# Set up FHS installation path +if(NOT APPLE AND NOT WIN32) + add_definitions(-DINSTALL_PREFIX="${CMAKE_INSTALL_PREFIX}") +endif() + if(WIN32) set(USE_INTERNAL_LIBS 1) else() diff --git a/client/CMakeLists.txt b/client/CMakeLists.txt index 56caf04f8..0559564c7 100644 --- a/client/CMakeLists.txt +++ b/client/CMakeLists.txt @@ -128,11 +128,6 @@ if(APPLE) ${AUDIOUNIT_LIBRARY}) endif() -# Set up FHS installation path -if(NOT APPLE AND NOT WIN32) - add_definitions(-DINSTALL_PREFIX="${CMAKE_INSTALL_PREFIX}") -endif() - # Client target if(TARGET SDL2::SDL2 OR TARGET SDL::SDL) diff --git a/server/CMakeLists.txt b/server/CMakeLists.txt index e5b54d8de..9afc6c2c6 100644 --- a/server/CMakeLists.txt +++ b/server/CMakeLists.txt @@ -37,11 +37,6 @@ if(WIN32 AND NOT MSVC) add_definitions(-DWINVER=0x0500) endif() -# Set up FHS installation path -if(NOT APPLE AND NOT WIN32) - add_definitions(-DINSTALL_PREFIX="${CMAKE_INSTALL_PREFIX}") -endif() - add_executable(odasrv ${COMMON_SOURCES} ${SERVER_SOURCES} ${SERVER_WIN32_SOURCES}) odamex_target_settings(odasrv) From deb113e672588879697ae3343c5d3f1616d13503 Mon Sep 17 00:00:00 2001 From: James Le Cuirot Date: Sat, 30 Mar 2024 22:39:14 +0000 Subject: [PATCH 74/75] Include wherever time_t is used to fix musl --- client/src/m_menu.cpp | 2 ++ client/src/v_screenshot.cpp | 2 ++ common/c_dispatch.cpp | 1 + common/cmdlib.h | 1 + common/p_user.cpp | 2 ++ server/src/c_console.cpp | 2 ++ server/src/sv_banlist.cpp | 1 + server/src/sv_banlist.h | 1 + 8 files changed, 12 insertions(+) diff --git a/client/src/m_menu.cpp b/client/src/m_menu.cpp index 6268e1819..f82cbf40d 100644 --- a/client/src/m_menu.cpp +++ b/client/src/m_menu.cpp @@ -25,6 +25,8 @@ #include "odamex.h" +#include + #include "gstrings.h" #include "c_console.h" #include "c_dispatch.h" diff --git a/client/src/v_screenshot.cpp b/client/src/v_screenshot.cpp index 2f24cb184..375de5b9d 100644 --- a/client/src/v_screenshot.cpp +++ b/client/src/v_screenshot.cpp @@ -24,6 +24,8 @@ #include "odamex.h" +#include + #include #include diff --git a/common/c_dispatch.cpp b/common/c_dispatch.cpp index 504379aad..d30dd4e24 100644 --- a/common/c_dispatch.cpp +++ b/common/c_dispatch.cpp @@ -26,6 +26,7 @@ #include #include +#include #include "cmdlib.h" #include "c_console.h" diff --git a/common/cmdlib.h b/common/cmdlib.h index c7041837b..a20be7c4c 100644 --- a/common/cmdlib.h +++ b/common/cmdlib.h @@ -24,6 +24,7 @@ #pragma once #include +#include #ifdef _MSC_VER #pragma warning(disable : 4244) // MIPS diff --git a/common/p_user.cpp b/common/p_user.cpp index d9a4bb965..461a3ef03 100644 --- a/common/p_user.cpp +++ b/common/p_user.cpp @@ -26,6 +26,8 @@ #include "odamex.h" +#include + #include #include "cmdlib.h" diff --git a/server/src/c_console.cpp b/server/src/c_console.cpp index 34fcd19d9..57d7e71e2 100644 --- a/server/src/c_console.cpp +++ b/server/src/c_console.cpp @@ -24,6 +24,8 @@ #include "odamex.h" +#include + #include #include "m_memio.h" diff --git a/server/src/sv_banlist.cpp b/server/src/sv_banlist.cpp index c271fe68c..36cdf9b63 100644 --- a/server/src/sv_banlist.cpp +++ b/server/src/sv_banlist.cpp @@ -24,6 +24,7 @@ #include "odamex.h" +#include #include #include "win32inc.h" diff --git a/server/src/sv_banlist.h b/server/src/sv_banlist.h index 6096f73fc..f4d686071 100644 --- a/server/src/sv_banlist.h +++ b/server/src/sv_banlist.h @@ -23,6 +23,7 @@ #pragma once +#include #include #include "json/json.h" From a77db80116810b12c93d60ac143e120b389f45ed Mon Sep 17 00:00:00 2001 From: Acts 19 quiz Date: Thu, 4 Apr 2024 11:08:21 -0500 Subject: [PATCH 75/75] Add Chex Quest MAPINFO par times. --- wad/lumps/_chexnfo.lmp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/wad/lumps/_chexnfo.lmp b/wad/lumps/_chexnfo.lmp index 3817fc76a..e5e58109c 100644 --- a/wad/lumps/_chexnfo.lmp +++ b/wad/lumps/_chexnfo.lmp @@ -21,7 +21,7 @@ map E1M1 lookup "CHUSTR_E1M1" secretnext = "E1M9" sky1 = "SKY1" cluster = 1 - par = 30 + par = 120 music = "$MUSIC_E1M1" } @@ -33,7 +33,7 @@ map E1M2 lookup "CHUSTR_E1M2" secretnext = "E1M9" sky1 = "SKY1" cluster = 1 - par = 75 + par = 360 music = "$MUSIC_E1M2" } @@ -45,7 +45,7 @@ map E1M3 lookup "CHUSTR_E1M3" secretnext = "E1M9" sky1 = "SKY1" cluster = 1 - par = 120 + par = 480 music = "$MUSIC_E1M3" } @@ -57,7 +57,7 @@ map E1M4 lookup "CHUSTR_E1M4" secretnext = "E1M9" sky1 = "SKY1" cluster = 1 - par = 90 + par = 200 music = "$MUSIC_E1M4" } @@ -69,7 +69,7 @@ map E1M5 lookup "CHUSTR_E1M5" secretnext = "E1M9" sky1 = "SKY1" cluster = 1 - par = 165 + par = 360 music = "$MUSIC_E1M5" nointermission }