From 95985a8894a2c94aecf7dfcb3625b01d0306cf12 Mon Sep 17 00:00:00 2001 From: MaxED Date: Mon, 13 Jun 2016 23:37:55 +0000 Subject: [PATCH] Added, Visual mode: added "Toggle Alpha-based Texture Highlighting" action. When enabled, 3d floor textures and middle textures on double-sided lines will be highlighted only when the crosshair points at a non-transparent pixel. Changed: multi-part sectors are now better preserved after drawing new lines. Changed, TEXTURES parser: patch loading errors are now ignored for textures with "NullTexture" option. Changed, Game configurations: changed default door action arguments to better match vanilla ones. Fixed, Actions: in some cases keyboard shortcuts involving Ctrl/Alt/Shift modifier keys were displayed incorrectly. Fixed(?): probably fixed inability to save map wad in Slade 3. Updated ZDoom_ACS.cfg. Updated ZDoom_DECORATE.cfg. Updated ZDoom ACC. --- .gitignore | 1 + Build/Compilers/ZDoom/zdefs.acs | 14 +++++++ Build/Compilers/ZDoom/zspecial.acs | 3 +- .../Includes/Hexen_linedefs.cfg | 12 +++--- .../Includes/ZDoom_linedefs.cfg | 4 +- Build/Configurations/Includes/ZDoom_misc.cfg | 1 + Build/Scripting/ZDoom_ACS.cfg | 14 +++++++ Build/Scripting/ZDoom_DECORATE.cfg | 5 ++- Source/Core/Actions/Action.cs | 12 ++++-- Source/Core/Builder.csproj | 2 +- Source/Core/General/MapManager.cs | 12 ++++-- Source/Core/Geometry/Tools.cs | 37 +++++++++++++++---- Source/Core/IO/WAD.cs | 5 ++- Source/Core/Map/Sidedef.cs | 8 ++-- .../Core/Windows/PreferencesForm.Designer.cs | 32 +++++----------- Source/Core/Windows/PreferencesForm.resx | 3 -- .../BuilderModes/General/BuilderPlug.cs | 10 +++-- .../BuilderModes/Resources/Actions.cfg | 11 ++++++ .../VisualModes/BaseVisualMode.cs | 9 +++++ .../BuilderModes/VisualModes/VisualCeiling.cs | 10 ++--- .../BuilderModes/VisualModes/VisualFloor.cs | 10 ++--- .../VisualModes/VisualMiddle3D.cs | 8 ++-- .../VisualModes/VisualMiddleDouble.cs | 2 +- 23 files changed, 150 insertions(+), 75 deletions(-) diff --git a/.gitignore b/.gitignore index ac69764..903ceea 100644 --- a/.gitignore +++ b/.gitignore @@ -463,3 +463,4 @@ /Build/D3D9.dll /Build/D3D8.dll /UpgradeLog.htm +/UpgradeLog2.htm diff --git a/Build/Compilers/ZDoom/zdefs.acs b/Build/Compilers/ZDoom/zdefs.acs index e8926ae..10b9b89 100644 --- a/Build/Compilers/ZDoom/zdefs.acs +++ b/Build/Compilers/ZDoom/zdefs.acs @@ -1086,3 +1086,17 @@ #define WARPF_USEPTR 0x2000 #define WARPF_COPYVELOCITY 0x4000 #define WARPF_COPYPITCH 0x8000 + +#define CPXF_ANCESTOR (1 << 0) +#define CPXF_LESSOREQUAL (1 << 1) +#define CPXF_NOZ (1 << 2) +#define CPXF_COUNTDEAD (1 << 3) +#define CPXF_DEADONLY (1 << 4) +#define CPXF_EXACT (1 << 5) +#define CPXF_SETTARGET (1 << 6) +#define CPXF_SETMASTER (1 << 7) +#define CPXF_SETTRACER (1 << 8) +#define CPXF_FARTHEST (1 << 9) +#define CPXF_CLOSEST (1 << 10) +#define CPXF_SETONPTR (1 << 11) +#define CPXF_CHECKSIGHT (1 << 12) diff --git a/Build/Compilers/ZDoom/zspecial.acs b/Build/Compilers/ZDoom/zspecial.acs index bf084c1..f989fb2 100644 --- a/Build/Compilers/ZDoom/zspecial.acs +++ b/Build/Compilers/ZDoom/zspecial.acs @@ -363,8 +363,9 @@ special -93:GetMaxInventory(2), -94:SetSectorDamage(2,5), -95:SetSectorTerrain(3), - -96:SpawnParticle(1,15), + -96:SpawnParticle(1,16), -97:SetMusicVolume(1), + -98:CheckProximity(3, 6), // Zandronum's -100:ResetMap(0), diff --git a/Build/Configurations/Includes/Hexen_linedefs.cfg b/Build/Configurations/Includes/Hexen_linedefs.cfg index 6efb068..28fc868 100644 --- a/Build/Configurations/Includes/Hexen_linedefs.cfg +++ b/Build/Configurations/Includes/Hexen_linedefs.cfg @@ -400,7 +400,7 @@ door title = "Movement Speed"; type = 11; enum = "door_speeds"; - default = 32; + default = 16; } arg2 @@ -426,7 +426,7 @@ door title = "Movement Speed"; type = 11; enum = "door_speeds"; - default = 32; + default = 16; } arg2 @@ -452,7 +452,7 @@ door title = "Movement Speed"; type = 11; enum = "door_speeds"; - default = 32; + default = 16; } arg2 @@ -460,7 +460,7 @@ door title = "Close Delay"; type = 11; enum = "reset_tics"; - default = 105; + default = 150; } arg3 @@ -486,7 +486,7 @@ door title = "Movement Speed"; type = 11; enum = "door_speeds"; - default = 32; + default = 16; } arg2 @@ -494,7 +494,7 @@ door title = "Close Delay"; type = 11; enum = "reset_tics"; - default = 105; + default = 150; } arg3 diff --git a/Build/Configurations/Includes/ZDoom_linedefs.cfg b/Build/Configurations/Includes/ZDoom_linedefs.cfg index 599ec46..1dcdebc 100644 --- a/Build/Configurations/Includes/ZDoom_linedefs.cfg +++ b/Build/Configurations/Includes/ZDoom_linedefs.cfg @@ -675,14 +675,14 @@ zdoom title = "Animation Speed"; type = 11; enum = "door_speeds"; - default = 32; + default = 16; } arg2 { title = "Close Delay"; type = 11; enum = "reset_tics"; - default = 140; + default = 150; } arg3 { diff --git a/Build/Configurations/Includes/ZDoom_misc.cfg b/Build/Configurations/Includes/ZDoom_misc.cfg index a650e09..8deac69 100644 --- a/Build/Configurations/Includes/ZDoom_misc.cfg +++ b/Build/Configurations/Includes/ZDoom_misc.cfg @@ -854,6 +854,7 @@ enums 70 = "70: 2 Seconds"; 105 = "105: 3 Seconds"; 140 = "140: 4 Seconds"; + 150 = "150: Doom default"; 175 = "175: 5 Seconds"; 210 = "210: 6 Seconds"; 245 = "245: 7 Seconds"; diff --git a/Build/Scripting/ZDoom_ACS.cfg b/Build/Scripting/ZDoom_ACS.cfg index ca70b8e..f339a31 100644 --- a/Build/Scripting/ZDoom_ACS.cfg +++ b/Build/Scripting/ZDoom_ACS.cfg @@ -110,6 +110,7 @@ keywords CheckFont = "bool CheckFont(str fontname)"; CheckInventory = "int CheckInventory(str inventory_item)\nChecks the inventory of the actor who activated the script for the item specified by inventory_item"; CheckPlayerCamera = "int CheckPlayerCamera(int player)"; + CheckProximity = "bool CheckProximity(int tid, str classname, float distance[, int count = 1[, int flags = 0[, int pointer = AAPTR_DEFAULT]]])"; CheckSight = "bool CheckSight(int source, int dest, int flags)"; CheckWeapon = "bool CheckWeapon(str weapon)\nChecks if player's active weapon is the weapon with specified class name."; ClassifyActor = "int ClassifyActor(int tid)"; @@ -658,6 +659,19 @@ constants CLASS_CLERIC; CLASS_FIGHTER; CLASS_MAGE; + CPXF_ANCESTOR; + CPXF_LESSOREQUAL; + CPXF_NOZ; + CPXF_COUNTDEAD; + CPXF_DEADONLY; + CPXF_EXACT; + CPXF_SETTARGET; + CPXF_SETMASTER; + CPXF_SETTRACER; + CPXF_FARTHEST; + CPXF_CLOSEST; + CPXF_SETONPTR; + CPXF_CHECKSIGHT; CR_BLACK; CR_BLUE; CR_BRICK; diff --git a/Build/Scripting/ZDoom_DECORATE.cfg b/Build/Scripting/ZDoom_DECORATE.cfg index 1af50b8..44a5b60 100644 --- a/Build/Scripting/ZDoom_DECORATE.cfg +++ b/Build/Scripting/ZDoom_DECORATE.cfg @@ -85,7 +85,7 @@ keywords A_FaceTarget = "A_FaceTarget[(float angle = 0.0[, float pitch = 270.0])]\nA_FaceTarget([float max_turn = 0.0[, float max_pitch = 270.0[, float ang_offset = 0.0[, float pitch_offset = 0.0[, int flags = 0[, float z_add = 0.0]]]]]])"; A_FaceMaster = "A_FaceMaster[(float angle = 0.0[, float pitch = 270.0])]\nA_FaceMaster([float max_turn = 0.0[, float max_pitch = 270.0[, float ang_offset = 0.0[, float pitch_offset = 0.0[, int flags = 0[, float z_add = 0.0]]]]]])"; A_FastChase = "A_FastChase"; - A_KillChildren = "A_KillChildren[(str damagetype = \"None\"[, int flags = 0[, str filter = \"None\[, str species = \"None\"[, int src = AAPTR_DEFAULT[, int inflictor = AAPTR_DEFAULT]]]]])]\ndamagetype: if the actor dies, the actor will enter a death state based on damagetype if present (or pain state if using NODAMAGE).\nflags: KILS flags.\nfilter: the actor class to damage.\nspecies: the actor species to damage."; + A_KillChildren = "A_KillChildren[(str damagetype = \"None\"[, int flags = 0[, str filter = \"None\"[, str species = \"None\"[, int src = AAPTR_DEFAULT[, int inflictor = AAPTR_DEFAULT]]]]])]\ndamagetype: if the actor dies, the actor will enter a death state based on damagetype if present (or pain state if using NODAMAGE).\nflags: KILS flags.\nfilter: the actor class to damage.\nspecies: the actor species to damage."; A_KillMaster = "A_KillMaster[(str damagetype = \"None\"[, int flags = 0[, str filter = \"None\"[, str species = \"None\"[, int src = AAPTR_DEFAULT[, int inflictor = AAPTR_DEFAULT]]]]])]\ndamagetype: if the actor dies, the actor will enter a death state based on damagetype if present (or pain state if using NODAMAGE).\nflags: KILS flags.\nfilter: the actor class to damage.\nspecies: the actor species to damage."; A_KillSiblings = "A_KillSiblings[(str damagetype = \"None\"[, int flags = 0[, str filter = \"None\"[, str species = \"None\"[, int src = AAPTR_DEFAULT[, int inflictor = AAPTR_DEFAULT]]]]])]\ndamagetype: if the actor dies, the actor will enter a death state based on damagetype if present (or pain state if using NODAMAGE).\nflags: KILS flags.\nfilter: the actor class to damage.\nspecies: the actor species to damage."; A_KillTarget = "A_KillTarget[(str damagetype = \"None\"[, int flags = 0[, str filter = \"None\"[, str species = \"None\"[, int src = AAPTR_DEFAULT[, int inflictor = AAPTR_DEFAULT]]]]])]\ndamagetype: if the actor dies, the actor will enter a death state based on damagetype if present (or pain state if using NODAMAGE).\nflags: KILS flags.\nfilter: the actor class to damage.\nspecies: the actor species to damage."; @@ -427,6 +427,8 @@ keywords GetZAt = "float GetZAt([float x = 0.0[, float y = 0.0[, float angle = 0.0[, int flags = 0[, int pick_pointer = AAPTR_TARGET]]]]])"; GetGibHealth = "int GetGibHealth()"; GetCrouchFactor = "float GetCrouchFactor(int ptr = AAPTR_PLAYER1)"; + GetCVar = "int GetCVar(str name)"; + GetUserCVar = "int GetUserCVar(int playernum, str name)"; } properties @@ -1245,6 +1247,7 @@ constants SMF_PRECISE; SPF_FORCECLAMP; SPF_INTERPOLATE; + SPF_NOTIMEFREEZE; TF_TELEFRAG; TF_RANDOMDECIDE; TF_FORCED; diff --git a/Source/Core/Actions/Action.cs b/Source/Core/Actions/Action.cs index 0037f23..59304b3 100644 --- a/Source/Core/Actions/Action.cs +++ b/Source/Core/Actions/Action.cs @@ -133,15 +133,19 @@ namespace CodeImp.DoomBuilder.Actions int button = key & ~((int)Keys.Control | (int)Keys.Shift | (int)Keys.Alt); // When the button is a control key, then remove the control itsself - if((button == (int)Keys.ControlKey) || - (button == (int)Keys.ShiftKey)) + if((button == (int)Keys.ControlKey) || (button == (int)Keys.ShiftKey) || (button == (int)Keys.Alt)) { ctrl = 0; key = key & ~((int)Keys.Control | (int)Keys.Shift | (int)Keys.Alt); } - // Determine control prefix - if(ctrl != 0) ctrlprefix = conv.ConvertToString(key); + //mxd. Determine control prefix + if(ctrl != 0) + { + if((key & (int)Keys.Control) != 0) ctrlprefix += "Ctrl+"; + if((key & (int)Keys.Alt) != 0) ctrlprefix += "Alt+"; + if((key & (int)Keys.Shift) != 0) ctrlprefix += "Shift+"; + } // Check if button is special switch(button) diff --git a/Source/Core/Builder.csproj b/Source/Core/Builder.csproj index 8b48f67..f6a3d91 100644 --- a/Source/Core/Builder.csproj +++ b/Source/Core/Builder.csproj @@ -73,7 +73,7 @@ x86 false prompt - TRACE + TRACE;PROFILE