Skip to content

Commit

Permalink
delete legacy firewalls
Browse files Browse the repository at this point in the history
  • Loading branch information
ennorehling committed Feb 22, 2025
1 parent a2a755c commit c5beb0c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/kernel/connection.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
#include "terrain.h"
#include "unit.h"

#include <spells/borders.h>
#include <kernel/attrib.h>
#include <kernel/gamedata.h>

Expand Down Expand Up @@ -487,6 +488,14 @@ int read_borders(gamedata *data)
if (type->read) {
connection *b = NULL;

if (data->version < WALL_DATA_VERSION) {
/* remove legacy firewalls */
if (type == &bt_firewall) {
log_info("removing legacy firewall in %s", regionname(from, NULL));
b = &dummy;
b->data.v = NULL;
}
}
if (data->version < FIX_SEAROADS_VERSION) {
/* bug 2694: eliminate roads in oceans */
if (type->terrain_flags != 0 && type->terrain_flags != fval(from->terrain, type->terrain_flags)) {
Expand Down

0 comments on commit c5beb0c

Please sign in to comment.