From b7cab48776b36d162e45304296e4ec7e99bcd4f6 Mon Sep 17 00:00:00 2001 From: Marko Lindqvist Date: Fri, 31 May 2024 01:54:45 +0300 Subject: [PATCH] Update to Freeciv server freeciv/freeciv@95e975300e Signed-off-by: Marko Lindqvist --- freeciv/apply_patches.sh | 8 ---- ...ystem-when-client-requests-activity-.patch | 44 ------------------- ...loading-invalid-resources-on-FoW-map.patch | 33 -------------- freeciv/version.txt | 2 +- 4 files changed, 1 insertion(+), 86 deletions(-) delete mode 100644 freeciv/patches/backports/0049-Trigger-action-system-when-client-requests-activity-.patch delete mode 100644 freeciv/patches/backports/0050-savegame-Fix-loading-invalid-resources-on-FoW-map.patch diff --git a/freeciv/apply_patches.sh b/freeciv/apply_patches.sh index 93f3286bc..5195c022b 100755 --- a/freeciv/apply_patches.sh +++ b/freeciv/apply_patches.sh @@ -6,12 +6,6 @@ # https://osdn.net/projects/freeciv/ticket/????? # https://redmine.freeciv.org/issues/??? # -# 0050-savegame-Fix-loading-invalid-resources-on-FoW-map.patch -# Savegame resources loading fix -# RM #463 -# 0049-Trigger-action-system-when-client-requests-activity-.patch -# Activity action fix (esp. Pillage) -# osdn #57670 # 0048-Handle-CoastStrict-units-correctly-on-city-removal.patch # Fix to unit placement after city destruction # RM #525 @@ -59,8 +53,6 @@ declare -a GIT_PATCHLIST=( ) declare -a PATCHLIST=( - "backports/0050-savegame-Fix-loading-invalid-resources-on-FoW-map" - "backports/0049-Trigger-action-system-when-client-requests-activity-" "backports/0048-Handle-CoastStrict-units-correctly-on-city-removal" "backports/0061-savegame-Correct-loading-last-turn-change-time" "backports/0073-savecompat-Fix-adding-ACTION_NONE-actions-for-units-" diff --git a/freeciv/patches/backports/0049-Trigger-action-system-when-client-requests-activity-.patch b/freeciv/patches/backports/0049-Trigger-action-system-when-client-requests-activity-.patch deleted file mode 100644 index 85f80bd09..000000000 --- a/freeciv/patches/backports/0049-Trigger-action-system-when-client-requests-activity-.patch +++ /dev/null @@ -1,44 +0,0 @@ -From 4d901b9a1c506b634b4085ad0e150ef4bf199786 Mon Sep 17 00:00:00 2001 -From: Marko Lindqvist -Date: Tue, 16 Apr 2024 00:18:51 +0300 -Subject: [PATCH 49/50] Trigger action system when client requests activity - change - -Lacking action handling for some activities reported by bard - -See osdn #57670 - -Signed-off-by: Marko Lindqvist ---- - server/unithand.c | 14 ++++++++++++-- - 1 file changed, 12 insertions(+), 2 deletions(-) - -diff --git a/server/unithand.c b/server/unithand.c -index 63f644aebf..e821b929a9 100644 ---- a/server/unithand.c -+++ b/server/unithand.c -@@ -6681,9 +6681,19 @@ bool unit_activity_handling_targeted(struct unit *punit, - unit_activity_handling(punit, new_activity, trigger_action); - } else if (can_unit_do_activity_targeted(&(wld.map), punit, - new_activity, *new_target)) { -+ struct action_list *list = action_list_by_activity(new_activity); -+ - free_unit_orders(punit); -- unit_activity_targeted_internal(punit, new_activity, new_target, -- trigger_action); -+ -+ if (list != NULL && action_list_size(list) > 0) { -+ /* Trigger action system */ -+ unit_do_action(unit_owner(punit), punit->id, punit->tile->index, -+ (*new_target) != NULL ? (*new_target)->id : NO_TARGET, -+ "", action_number(action_list_get(list, 0))); -+ } else { -+ unit_activity_targeted_internal(punit, new_activity, new_target, -+ trigger_action); -+ } - } - - return TRUE; --- -2.43.0 - diff --git a/freeciv/patches/backports/0050-savegame-Fix-loading-invalid-resources-on-FoW-map.patch b/freeciv/patches/backports/0050-savegame-Fix-loading-invalid-resources-on-FoW-map.patch deleted file mode 100644 index c4c2ee015..000000000 --- a/freeciv/patches/backports/0050-savegame-Fix-loading-invalid-resources-on-FoW-map.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 8d719e330a4c48024f50026f3053d15c828b2dd3 Mon Sep 17 00:00:00 2001 -From: Marko Lindqvist -Date: Wed, 17 Apr 2024 20:51:26 +0300 -Subject: [PATCH 50/50] savegame: Fix loading invalid resources on FoW map - -See RM #463 - -Signed-off-by: Marko Lindqvist ---- - server/savegame/savegame3.c | 6 ++++-- - 1 file changed, 4 insertions(+), 2 deletions(-) - -diff --git a/server/savegame/savegame3.c b/server/savegame/savegame3.c -index de2fa885a3..875839dec0 100644 ---- a/server/savegame/savegame3.c -+++ b/server/savegame/savegame3.c -@@ -7160,9 +7160,11 @@ static void sg_load_player_vision(struct loaddata *loading, - struct player_tile *plrtile = map_get_player_tile(ptile, plr); - - extra_type_by_cause_iterate(EC_RESOURCE, pres) { -- if (BV_ISSET(plrtile->extras, extra_number(pres)) -- && terrain_has_resource(plrtile->terrain, pres)) { -+ if (BV_ISSET(plrtile->extras, extra_number(pres))) { - plrtile->resource = pres; -+ if (!terrain_has_resource(plrtile->terrain, pres)) { -+ BV_CLR(plrtile->extras, extra_number(pres)); -+ } - } - } extra_type_by_cause_iterate_end; - } whole_map_iterate_end; --- -2.43.0 - diff --git a/freeciv/version.txt b/freeciv/version.txt index 1d2520d5f..2f621b7e3 100644 --- a/freeciv/version.txt +++ b/freeciv/version.txt @@ -1,7 +1,7 @@ # The Git SHA hash for the commit to checkout from # https://github.com/freeciv/freeciv -FCREV=3c41f4e1ac25fe1ff8b383740ebabfe044907c0b +FCREV=95e975300e39ba90c8a561d6cfef5f64f8e490f2 ORIGCAPSTR="+Freeciv.Devel-\${MAIN_VERSION}-2024.Apr.30"