Added, Visual mode: "Raise/Lower Floor/Ceiling to adjacent Sector" actions now take surrounding 3d floors into account.

Added, Visual mode: highlight/selection based on texture alpha now works on 3d floors.
Changed, Game configurations, TranslucentLine:208 action: renamed the second argument from "Translucency Amount" to "Opacity".
Internal, documentation: updated udmf_zdoom.txt.
This commit is contained in:
MaxED 2016-01-26 22:29:12 +00:00
parent 5d47e331d8
commit f9a7c22e03
11 changed files with 181 additions and 34 deletions

View file

@ -53,8 +53,9 @@ namespace CodeImp.DoomBuilder.Data
protected string shortname; //mxd. Name in uppercase and clamped to DataManager.CLASIC_IMAGE_NAME_LENGTH
protected string virtualname; //mxd. Path of this name is used in TextureBrowserForm
protected string displayname; //mxd. Name to display in TextureBrowserForm
protected bool isFlat; //mxd. if false, it's a texture
protected bool istranslucent; //mxd
protected bool isFlat; //mxd. If false, it's a texture
protected bool istranslucent; //mxd. If true, has pixels with alpha > 0 && < 255
protected bool ismasked; //mxd. If true, has pixels with zero alpha
protected bool hasLongName; //mxd. Texture name is longer than DataManager.CLASIC_IMAGE_NAME_LENGTH
protected bool hasPatchWithSameName; //mxd
protected int level; //mxd. Folder depth of this item
@ -97,6 +98,7 @@ namespace CodeImp.DoomBuilder.Data
public string DisplayName { get { return displayname; } } //mxd
public bool IsFlat { get { return isFlat; } } //mxd
public bool IsTranslucent { get { return istranslucent; } } //mxd
public bool IsMasked { get { return ismasked; } } //mxd
public bool HasPatchWithSameName { get { return hasPatchWithSameName; } } //mxd
internal bool HasLongName { get { return hasLongName; } } //mxd
public bool UseColorCorrection { get { return usecolorcorrection; } set { usecolorcorrection = value; } }
@ -364,6 +366,7 @@ namespace CodeImp.DoomBuilder.Data
// Also check alpha
if(cp->a > 0 && cp->a < 255) istranslucent = true;
else if(cp->a == 0) ismasked = true;
}
// Update glow data
@ -396,7 +399,7 @@ namespace CodeImp.DoomBuilder.Data
}
}
//mxd. Check if the texture is translucent
else
else if(!loadfailed)
{
BitmapData bmpdata = null;
try { bmpdata = bitmap.LockBits(new Rectangle(0, 0, bitmap.Size.Width, bitmap.Size.Height), ImageLockMode.ReadWrite, PixelFormat.Format32bppArgb); }
@ -410,11 +413,8 @@ namespace CodeImp.DoomBuilder.Data
for(PixelColor* cp = pixels + numpixels - 1; cp >= pixels; cp--)
{
// Check alpha
if(cp->a > 0 && cp->a < 255)
{
istranslucent = true;
break;
}
if(cp->a > 0 && cp->a < 255) istranslucent = true;
else if(cp->a == 0) ismasked = true;
}
// Release the data