[eureka] 02/03: Backport a patch from upstream GIT to fix a regression with sector merging

Fabian Greffrath fabian at moszumanska.debian.org
Sat Jun 24 12:32:26 UTC 2017


This is an automated email from the git hooks/post-receive script.

fabian pushed a commit to branch master
in repository eureka.

commit bdfa05d0ece603623acd7a3bd9d7c1596546e419
Author: Fabian Greffrath <fabian at debian.org>
Date:   Sat Jun 24 14:09:42 2017 +0200

    Backport a patch from upstream GIT to fix a regression with sector merging
---
 ...ssion-with-sector-merging-it-is-supposed-.patch | 63 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 2 files changed, 64 insertions(+)

diff --git a/debian/patches/0001-Fixed-regression-with-sector-merging-it-is-supposed-.patch b/debian/patches/0001-Fixed-regression-with-sector-merging-it-is-supposed-.patch
new file mode 100644
index 0000000..c99d7bf
--- /dev/null
+++ b/debian/patches/0001-Fixed-regression-with-sector-merging-it-is-supposed-.patch
@@ -0,0 +1,63 @@
+From dbc69819bb5891ab74461e42343f7fd590490afb Mon Sep 17 00:00:00 2001
+From: Andrew Apted <ajapted at users.sf.net>
+Date: Tue, 4 Apr 2017 12:52:56 +1000
+Subject: [PATCH 1/5] Fixed regression with sector merging, it is supposed to
+ keep the properties of the first selected sector, but this behavior broke
+ when another issue with sector merging was fixed.
+
+---
+ CHANGES.txt     |  3 +++
+ src/e_sector.cc | 19 ++++++++++++++++++-
+ 2 files changed, 21 insertions(+), 1 deletion(-)
+
+--- a/CHANGES.txt
++++ b/CHANGES.txt
+@@ -115,3 +115,6 @@ Bugs Fixed:
+ -  fixed bad sidedef fallback when loading a map with no sectors
+ -  fixed default pixel-aspect to be 0.83, matching original DOOM
+ 
++
++- fixed sector merge to keep properties of first selected sector
++
+--- a/src/e_sector.cc
++++ b/src/e_sector.cc
+@@ -4,7 +4,7 @@
+ //
+ //  Eureka DOOM Editor
+ //
+-//  Copyright (C) 2001-2016 Andrew Apted
++//  Copyright (C) 2001-2017 Andrew Apted
+ //  Copyright (C) 1997-2003 Andr� Majorel et al
+ //
+ //  This program is free software; you can redistribute it and/or
+@@ -264,6 +264,8 @@ void CMD_SEC_Merge(void)
+ 		return;
+ 	}
+ 
++	int first = edit.Selected->find_first();
++
+ 	bool keep_common_lines = Exec_HasFlag("/keep");
+ 
+ 	// we require the *lowest* numbered sector, otherwise we can
+@@ -284,6 +286,21 @@ void CMD_SEC_Merge(void)
+ 
+ 	BA_MessageForSel("merged", edit.Selected);
+ 
++	// keep the properties of the first selected sector
++	if (new_sec != first)
++	{
++		const Sector *ref = Sectors[first];
++
++		BA_ChangeSEC(new_sec, Sector::F_FLOORH,    ref->floorh);
++		BA_ChangeSEC(new_sec, Sector::F_FLOOR_TEX, ref->floor_tex);
++		BA_ChangeSEC(new_sec, Sector::F_CEILH,     ref->ceilh);
++		BA_ChangeSEC(new_sec, Sector::F_CEIL_TEX,  ref->ceil_tex);
++
++		BA_ChangeSEC(new_sec, Sector::F_LIGHT, ref->light);
++		BA_ChangeSEC(new_sec, Sector::F_TYPE,  ref->type);
++		BA_ChangeSEC(new_sec, Sector::F_TAG,   ref->tag);
++	}
++
+ 	for (edit.Selected->begin(&it) ; !it.at_end() ; ++it)
+ 	{
+ 		int old_sec = *it;
diff --git a/debian/patches/series b/debian/patches/series
index 265de1c..27c9d3a 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
 xdg-install.patch
 reproducible-build.patch
+0001-Fixed-regression-with-sector-merging-it-is-supposed-.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/eureka.git



More information about the Pkg-games-commits mailing list