mirror of
https://git.do.srb2.org/STJr/ZoneBuilder.git
synced 2025-03-12 12:12:04 +00:00
Added, Visual mode: added support for ROLLCENTER sprite rendering flag, updated ROLLSPRITE implementation.
Fixed, DECORATE support: the editor was unable to determine actor sprite when the actor itself had no sprites defined and the actor it inherited from was only defined in the game configuration. Fixed, Drag geometry modes: linedefs without both sides were removed after dragging them when "Replace with Dragged Geometry" mode was active. Updated ZDoom_DECORATE.cfg.
This commit is contained in:
parent
dc054f767b
commit
5a6e62aa4f
2 changed files with 26 additions and 26 deletions
|
@ -733,6 +733,12 @@ properties
|
||||||
|
|
||||||
constants
|
constants
|
||||||
{
|
{
|
||||||
|
//rendering
|
||||||
|
FLATSPRITE;
|
||||||
|
ROLLSPRITE;
|
||||||
|
WALLSPRITE;
|
||||||
|
DONTFLIP;
|
||||||
|
ROLLCENTER;
|
||||||
//pointers
|
//pointers
|
||||||
AAPTR_DEFAULT;
|
AAPTR_DEFAULT;
|
||||||
AAPTR_NULL;
|
AAPTR_NULL;
|
||||||
|
|
|
@ -3078,40 +3078,34 @@ namespace CodeImp.DoomBuilder.Map
|
||||||
foreach(Linedef l in alllines)
|
foreach(Linedef l in alllines)
|
||||||
{
|
{
|
||||||
// Remove line when it's start, center and end are inside a changed sector and neither side references it
|
// Remove line when it's start, center and end are inside a changed sector and neither side references it
|
||||||
if(l.Start != null && l.End != null)
|
if(l.Start != null && l.End != null
|
||||||
|
&& (l.Front == null || !changedsectors.Contains(l.Front.Sector))
|
||||||
|
&& (l.Back == null || !changedsectors.Contains(l.Back.Sector)))
|
||||||
{
|
{
|
||||||
if(l.Front == null && l.Back == null)
|
foreach(Sector s in changedsectors)
|
||||||
{
|
{
|
||||||
l.Dispose();
|
if(s.Intersect(l.Start.Position) && s.Intersect(l.End.Position) && s.Intersect(l.GetCenterPoint()))
|
||||||
}
|
|
||||||
else if((l.Front == null || !changedsectors.Contains(l.Front.Sector)) &&
|
|
||||||
(l.Back == null || !changedsectors.Contains(l.Back.Sector)))
|
|
||||||
{
|
|
||||||
foreach(Sector s in changedsectors)
|
|
||||||
{
|
{
|
||||||
if(s.Intersect(l.Start.Position) && s.Intersect(l.End.Position) && s.Intersect(l.GetCenterPoint()))
|
Vertex[] tocheck = { l.Start, l.End };
|
||||||
|
l.Dispose();
|
||||||
|
|
||||||
|
foreach(Vertex v in tocheck)
|
||||||
{
|
{
|
||||||
Vertex[] tocheck = { l.Start, l.End };
|
// If the newly created vertex only has 2 linedefs attached, then merge the linedefs
|
||||||
l.Dispose();
|
if(!v.IsDisposed && v.Linedefs.Count == 2 && splitverts.Contains(v))
|
||||||
|
|
||||||
foreach(Vertex v in tocheck)
|
|
||||||
{
|
{
|
||||||
// If the newly created vertex only has 2 linedefs attached, then merge the linedefs
|
Linedef ld1 = General.GetByIndex(v.Linedefs, 0);
|
||||||
if(!v.IsDisposed && v.Linedefs.Count == 2 && splitverts.Contains(v))
|
Linedef ld2 = General.GetByIndex(v.Linedefs, 1);
|
||||||
{
|
Vertex v2 = (ld2.Start == v) ? ld2.End : ld2.Start;
|
||||||
Linedef ld1 = General.GetByIndex(v.Linedefs, 0);
|
if(ld1.Start == v) ld1.SetStartVertex(v2); else ld1.SetEndVertex(v2);
|
||||||
Linedef ld2 = General.GetByIndex(v.Linedefs, 1);
|
ld2.Dispose();
|
||||||
Vertex v2 = (ld2.Start == v) ? ld2.End : ld2.Start;
|
|
||||||
if(ld1.Start == v) ld1.SetStartVertex(v2); else ld1.SetEndVertex(v2);
|
|
||||||
ld2.Dispose();
|
|
||||||
|
|
||||||
// Trash vertex
|
// Trash vertex
|
||||||
v.Dispose();
|
v.Dispose();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue