Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tileset changing for big base plates #4177

Merged
merged 8 commits into from
Jan 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions data/base/script/rules.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,14 +244,10 @@ function setupGame()
{
setCampaignNumber(2);
replaceTexture("page-7-barbarians-arizona.png", "page-7-barbarians-urban.png");
replaceTexture("page-8-player-buildings-bases.png", "page-8-player-buildings-bases-urban.png");
replaceTexture("page-9-player-buildings-bases.png", "page-9-player-buildings-bases-urban.png");
}
else if (tilesetType === "ROCKIES")
{
setCampaignNumber(3);
replaceTexture("page-8-player-buildings-bases.png", "page-8-player-buildings-bases-rockies.png");
replaceTexture("page-9-player-buildings-bases.png", "page-9-player-buildings-bases-rockies.png");
replaceTexture("page-7-barbarians-arizona.png", "page-7-barbarians-kevlar.png");
}

Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbcfact.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-9-player-buildings-bases.png 0 0
TEXTURE 0 page-9-player-buildings-bases.png
TEXTURE 1 page-9-player-buildings-bases-urban.png
TEXTURE 2 page-9-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbdrdcm.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-8-player-buildings-bases.png 0 0
TEXTURE 0 page-8-player-buildings-bases.png
TEXTURE 1 page-8-player-buildings-bases-urban.png
TEXTURE 2 page-8-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbfact.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-9-player-buildings-bases.png 0 0
TEXTURE 0 page-9-player-buildings-bases.png
TEXTURE 1 page-9-player-buildings-bases-urban.png
TEXTURE 2 page-9-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbhq.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-8-player-buildings-bases.png 0 0
TEXTURE 0 page-8-player-buildings-bases.png
TEXTURE 1 page-8-player-buildings-bases-urban.png
TEXTURE 2 page-8-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbpower.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-8-player-buildings-bases.png 0 0
TEXTURE 0 page-8-player-buildings-bases.png
TEXTURE 1 page-8-player-buildings-bases-urban.png
TEXTURE 2 page-8-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
6 changes: 4 additions & 2 deletions data/base/structs/blbresch.pie
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
PIE 3
PIE 4
TYPE 200
TEXTURE 0 page-8-player-buildings-bases.png 0 0
TEXTURE 0 page-8-player-buildings-bases.png
TEXTURE 1 page-8-player-buildings-bases-urban.png
TEXTURE 2 page-8-player-buildings-bases-rockies.png
LEVELS 1
LEVEL 1
POINTS 4
Expand Down
3 changes: 0 additions & 3 deletions data/base/wrf/cam2/cam2change.wrf
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ directory "texpages"
file TERTILES "tertilesc2hw"
file TEXPAGE "page-31-features-urban.png"
file TEXPAGE "page-7-barbarians-urban.png"
file TEXPAGE "page-8-player-buildings-bases-urban.png"
file TEXPAGE "page-9-player-buildings-bases-urban.png"
/* These come from ../vidmem2.wrf */
file TEXPAGE "page-25-sky-urban.png"
file TEXPAGE "page-80-water-1.png"
Expand All @@ -26,4 +24,3 @@ file TEXPAGE "page-95-brown-rocks-urban.png"
file TEXPAGE "page-96-burned-ground-urban.png"
file TEXPAGE "page-97-burned-tiles-urban.png"
file TEXPAGE "page-98-bottom-urban.png"

3 changes: 0 additions & 3 deletions data/base/wrf/cam3/cam3change.wrf
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ directory "texpages"
file TERTILES "tertilesc3hw"
file TEXPAGE "page-30-features-rockies.png"
file TEXPAGE "page-7-barbarians-kevlar.png"
file TEXPAGE "page-8-player-buildings-bases-rockies.png"
file TEXPAGE "page-9-player-buildings-bases-rockies.png"
/* These come from ../vidmem3.wrf */
file TEXPAGE "page-25-sky-urban.png"
file TEXPAGE "page-80-water-1.png"
Expand All @@ -26,4 +24,3 @@ file TEXPAGE "page-105-snow-rockies.png"
file TEXPAGE "page-106-snowrock-rockies.png"
file TEXPAGE "page-107-brown-earth-rockies.png"
file TEXPAGE "page-108-snowcliff-rockies.png"

4 changes: 0 additions & 4 deletions data/mp/multiplay/script/rules/setupgame.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,11 @@ function setupGame()
else if (tilesetType === "URBAN")
{
setCampaignNumber(2);
replaceTexture("page-8-player-buildings-bases.png", "page-8-player-buildings-bases-urban.png");
replaceTexture("page-9-player-buildings-bases.png", "page-9-player-buildings-bases-urban.png");
replaceTexture("page-7-barbarians-arizona.png", "page-7-barbarians-urban.png");
}
else if (tilesetType === "ROCKIES")
{
setCampaignNumber(3);
replaceTexture("page-8-player-buildings-bases.png", "page-8-player-buildings-bases-rockies.png");
replaceTexture("page-9-player-buildings-bases.png", "page-9-player-buildings-bases-rockies.png");
replaceTexture("page-7-barbarians-arizona.png", "page-7-barbarians-kevlar.png");
// for some reason rockies will use arizona babas
}
Expand Down
7 changes: 7 additions & 0 deletions lib/wzmaplib/src/map_script.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wcast-function-type"
#endif
#if defined(__clang__) && defined(__clang_major__) && __clang_major__ >= 19
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wcast-function-type-mismatch"
#endif
#if defined(_MSC_VER)
__pragma(warning( push ))
__pragma(warning( disable : 4191 )) // disable "warning C4191: 'type cast': unsafe conversion from 'JSCFunctionMagic (__cdecl *)' to 'JSCFunction (__cdecl *)'"
Expand All @@ -44,6 +48,9 @@ __pragma(warning( disable : 4191 )) // disable "warning C4191: 'type cast': unsa
#if defined(_MSC_VER)
__pragma(warning( pop ))
#endif
#if defined(__clang__) && defined(__clang_major__) && __clang_major__ >= 19
#pragma clang diagnostic pop
#endif
#if !defined(__clang__) && defined(__GNUC__) && __GNUC__ >= 8
#pragma GCC diagnostic pop
#endif
Expand Down
7 changes: 7 additions & 0 deletions src/quickjs_backend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,19 @@
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wcast-function-type"
#endif
#if defined(__clang__) && defined(__clang_major__) && __clang_major__ >= 19
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wcast-function-type-mismatch"
#endif
MSVC_PRAGMA(warning( push ))
MSVC_PRAGMA(warning( disable : 4191 )) // disable "warning C4191: 'type cast': unsafe conversion from 'JSCFunctionMagic (__cdecl *)' to 'JSCFunction (__cdecl *)'"
#include "quickjs.h"
#include "quickjs-debugger.h"
#include "quickjs-limitedcontext.h"
MSVC_PRAGMA(warning( pop ))
#if defined(__clang__) && defined(__clang_major__) && __clang_major__ >= 19
#pragma clang diagnostic pop
#endif
#if !defined(__clang__) && defined(__GNUC__) && __GNUC__ >= 8
#pragma GCC diagnostic pop
#endif
Expand Down
Loading