Merge branch 'master' into asmjit

This commit is contained in:
Christoph Oelckers 2018-11-27 19:53:22 +01:00
commit 5e4e9e2c2b
28 changed files with 51 additions and 36 deletions

View file

@ -182,7 +182,7 @@ void GLFlat::SetupLights(HWDrawInfo *di, FLightNode * node, FDynLightData &light
void GLFlat::DrawSubsectors(HWDrawInfo *di, FRenderState &state)
{
if (level.HasDynamicLights && screen->BuffersArePersistent())
if (level.HasDynamicLights && screen->BuffersArePersistent() && !di->isFullbrightScene())
{
SetupLights(di, section->lighthead, lightdata, sector->PortalGroup);
}
@ -375,7 +375,7 @@ inline void GLFlat::PutFlat(HWDrawInfo *di, bool fog)
}
else if (!screen->BuffersArePersistent())
{
if (level.HasDynamicLights && gltexture != nullptr && !(hacktype & (SSRF_PLANEHACK|SSRF_FLOODHACK)) )
if (level.HasDynamicLights && gltexture != nullptr && !di->isFullbrightScene() && !(hacktype & (SSRF_PLANEHACK|SSRF_FLOODHACK)) )
{
SetupLights(di, section->lighthead, lightdata, sector->PortalGroup);
}

View file

@ -94,7 +94,7 @@ void GLSprite::DrawSprite(HWDrawInfo *di, FRenderState &state, bool translucent)
gl_usecolorblending && !di->isFullbrightScene() && actor &&
fullbright && gltexture && !gltexture->tex->GetTranslucency())
{
RenderStyle = LegacyRenderStyles[STYLE_ColorBlend];
RenderStyle = LegacyRenderStyles[STYLE_ColorAdd];
}
state.SetRenderStyle(RenderStyle);

View file

@ -46,6 +46,9 @@ xx(Shadow)
xx(Subtract)
xx(Subtractive)
xx(FillColor)
xx(ColorBlend)
xx(ColorAdd)
xx(Multiply)
// Healingradius types
xx(Mana)

View file

@ -8587,7 +8587,7 @@ void PrintMiscActorInfo(AActor *query)
/*for (flagi = 0; flagi < 31; flagi++)
if (query->BounceFlags & 1<<flagi) Printf(" %s", flagnamesb[flagi]);*/
Printf("\nRender style = %i:%s, alpha %f\nRender flags: %x",
querystyle, (querystyle < STYLE_Count ? renderstyles[querystyle] : "Unknown"),
querystyle, (querystyle < countof(renderstyles) ? renderstyles[querystyle] : "Custom"),
query->Alpha, query->renderflags.GetValue());
/*for (flagi = 0; flagi < 31; flagi++)
if (query->renderflags & 1<<flagi) Printf(" %s", flagnamesr[flagi]);*/

View file

@ -739,6 +739,15 @@ public:
case NAME_Subtractive:
th->RenderStyle = STYLE_Subtract;
break;
case NAME_ColorBlend:
th->RenderStyle = STYLE_ColorBlend;
break;
case NAME_ColorAdd:
th->RenderStyle = STYLE_ColorAdd;
break;
case NAME_Multiply:
th->RenderStyle = STYLE_Multiply;
break;
default:
break;
}

View file

@ -62,6 +62,7 @@ FRenderStyle LegacyRenderStyles[STYLE_Count] =
{ { STYLEOP_Add, STYLEALPHA_InvDstCol, STYLEALPHA_Zero, 0 } }, /* STYLE_InverseMultiply */
{ { STYLEOP_Add, STYLEALPHA_SrcCol, STYLEALPHA_InvSrcCol, 0 } }, /* STYLE_ColorBlend */
{ { STYLEOP_Add, STYLEALPHA_One, STYLEALPHA_Zero, 0 } }, /* STYLE_Source */
{ { STYLEOP_Add, STYLEALPHA_SrcCol, STYLEALPHA_One, 0 } }, /* STYLE_ColorAdd */
};
double GetAlpha(int type, double alpha)

View file

@ -78,6 +78,7 @@ enum ERenderStyle
STYLE_InverseMultiply, // Multiply source with inverse of destination (HW renderer only.)
STYLE_ColorBlend, // Use color intensity as transparency factor
STYLE_Source, // No blending (only used internally)
STYLE_ColorAdd, // Use color intensity as transparency factor and blend additively.
STYLE_Count
};

View file

@ -700,12 +700,14 @@ DEFINE_PROPERTY(renderstyle, S, Actor)
PROP_STRING_PARM(str, 0);
static const char * renderstyles[]={
"NONE", "NORMAL", "FUZZY", "SOULTRANS", "OPTFUZZY", "STENCIL",
"TRANSLUCENT", "ADD", "SHADED", "SHADOW", "SUBTRACT", "ADDSTENCIL", "ADDSHADED", NULL };
"TRANSLUCENT", "ADD", "SHADED", "SHADOW", "SUBTRACT", "ADDSTENCIL",
"ADDSHADED", "COLORBLEND", "COLORADD", "MULTIPLY", NULL };
static const int renderstyle_values[]={
STYLE_None, STYLE_Normal, STYLE_Fuzzy, STYLE_SoulTrans, STYLE_OptFuzzy,
STYLE_TranslucentStencil, STYLE_Translucent, STYLE_Add, STYLE_Shaded,
STYLE_Shadow, STYLE_Subtract, STYLE_AddStencil, STYLE_AddShaded};
STYLE_Shadow, STYLE_Subtract, STYLE_AddStencil, STYLE_AddShaded,
STYLE_ColorBlend, STYLE_ColorAdd, STYLE_Multiply};
// make this work for old style decorations, too.
if (!strnicmp(str, "style_", 6)) str+=6;

View file

@ -660,7 +660,7 @@ SPREE15 = "%k is dominating!";
SPREE20 = "%k is unstoppable!";
SPREE25 = "%k is Godlike!";
// Mulitkill messages
// Multikill messages
MULTI2 = "Double kill!";
MULTI3 = "Multi kill!";
MULTI4 = "Ultra kill!";
@ -824,12 +824,12 @@ OB_MPCWEAPFLAME = "%o was lit up by %k's flames.";
OB_MPCWEAPWRAITHVERGE = "%o was cleansed by %k's Wraithverge.";
OB_MPMWEAPWAND = "%o took one too many sapphire beams from %k.";
OB_MPMWEAPFROST = "%o was turned into a frosty fellow by %k.";
OB_MPMWEAPLIGHTNING = "%o recieved a shocking revelation from %k.";
OB_MPMWEAPLIGHTNING = "%o received a shocking revelation from %k.";
OB_MPMWEAPBLOODSCOURGE = "%o was wiped off the face of the universe by %k's Bloodscourge.";
OB_MPPUNCHDAGGER = "%o was unwittingly backstabbed by %k.";
OB_MPELECTRICBOLT = "%o got bolted to the wall by %k.";
OB_MPPOISONBOLT = "%o recieved a lethal dose of %k's wrath.";
OB_MPPOISONBOLT = "%o received a lethal dose of %k's wrath.";
OB_MPASSAULTGUN = "%o was drilled full of holes by %k's assault gun.";
OB_MPMINIMISSILELAUNCHER = "%o gulped down %k's missile.";
OB_MPSTRIFEGRENADE = "%o was inverted by %k's H-E grenade.";
@ -950,7 +950,7 @@ TAG_ARTIPUZZGEMGREEN2 = "Emerald Planet (2)";
TAG_ARTIPUZZGEMBLUE1 = "Sapphire Planet (1)";
TAG_ARTIPUZZGEMBLUE2 = "Sapphire Planet (2)";
TAG_ARTIPUZZBOOK1 = "Daemon Codex";
TAG_ARTIPUZZBOOK2 = "Liber Obscura";
TAG_ARTIPUZZBOOK2 = "Liber Oscura";
TAG_ARTIPUZZSKULL2 = "Flame Mask";
TAG_ARTIPUZZFWEAPON = "Glaive Seal";
TAG_ARTIPUZZCWEAPON = "Holy Relic";
@ -1003,7 +1003,7 @@ TAG_TELEPORTERBEACON = "Teleporter Beacon";
TAG_METALARMOR = "Metal Armor";
TAG_LEATHER = "Leather Armor";
TAG_HEGRENADES = "HE-Grenade Rounds";
TAG_PHGRENADES = "Phoshorus-Grenade Rounds"; // "Fire-Grenade_Rounds" in the Teaser
TAG_PHGRENADES = "Phosphorus-Grenade Rounds"; // "Fire-Grenade_Rounds" in the Teaser
TAG_CLIPOFBULLETS = "Clip of Bullets"; // "bullets" in the Teaser
TAG_BOXOFBULLETS = "Ammo";
TAG_MINIMISSILES = "Mini Missiles"; //"rocket" in the Teaser
@ -2692,7 +2692,7 @@ OB_CYCLOPTIS = "%o was slimed by a cycloptis.";
OB_FLEMBRANE = "%o was defeated by the Flembrane.";
OB_MPSPOON = "%o was spoon fed by %k.";
OB_MPBOOTSPORK = "%o was thouroughly mixed with %k's bootspork.";
OB_MPBOOTSPORK = "%o was thoroughly mixed with %k's bootspork.";
OB_MPZORCH = "%o was zorched by %k.";
OB_MPMEGAZORCH = "%o was hit by %k's mega-zorcher.";
OB_MPRAPIDZORCH = "%o was rapid zorched by %k.";

View file

@ -1016,7 +1016,7 @@ TAG_ARTIPUZZGEMGREEN2 = "Planète en émeraude (2)";
TAG_ARTIPUZZGEMBLUE1 = "Planète en saphir (1)";
TAG_ARTIPUZZGEMBLUE2 = "Planète en saphir (2)";
TAG_ARTIPUZZBOOK1 = "Codex Démoniaque";
TAG_ARTIPUZZBOOK2 = "Liber Obscura";
TAG_ARTIPUZZBOOK2 = "Liber Oscura";
TAG_ARTIPUZZSKULL2 = "Masque de Flammes";
TAG_ARTIPUZZFWEAPON = "Sceau du Glaive";
TAG_ARTIPUZZCWEAPON = "Relique Sacrée";
@ -1459,7 +1459,7 @@ TXT_ARTIPUZZGEMGREEN2 = "PLANETE D'EMERAUDE";
TXT_ARTIPUZZGEMBLUE1 = "PLANETE DE SAPHIR";
TXT_ARTIPUZZGEMBLUE2 = "PLANETE DE SAPHIR";
TXT_ARTIPUZZBOOK1 = "CODEX DEMONIAQUE";
TXT_ARTIPUZZBOOK2 = "LIBER OBSCURA";
TXT_ARTIPUZZBOOK2 = "LIBER OSCURA";
TXT_ARTIPUZZSKULL2 = "MASQUE DE FLAMMES";
TXT_ARTIPUZZFWEAPON = "SCEAU DU GLAIVE";
TXT_ARTIPUZZCWEAPON = "RELIQUE SACREE";

View file

@ -882,7 +882,7 @@ TAG_ARTIPUZZGEMGREEN2 = "Emerald Planet (2)";
TAG_ARTIPUZZGEMBLUE1 = "Sapphire Planet (1)";
TAG_ARTIPUZZGEMBLUE2 = "Sapphire Planet (2)";
TAG_ARTIPUZZBOOK1 = "Daemon Codex";
TAG_ARTIPUZZBOOK2 = "Liber Obscura";
TAG_ARTIPUZZBOOK2 = "Liber Oscura";
TAG_ARTIPUZZSKULL2 = "Flame Mask";
TAG_ARTIPUZZFWEAPON = "Glaive Seal";
TAG_ARTIPUZZCWEAPON = "Holy Relic";

View file

@ -1175,7 +1175,7 @@ class Actor : Thinker native
native void A_SetMugshotState(String name);
native void A_RearrangePointers(int newtarget, int newmaster = AAPTR_DEFAULT, int newtracer = AAPTR_DEFAULT, int flags=0);
native void A_TransferPointer(int ptr_source, int ptr_recepient, int sourcefield, int recepientfield=AAPTR_DEFAULT, int flags=0);
native void A_TransferPointer(int ptr_source, int ptr_recipient, int sourcefield, int recipientfield=AAPTR_DEFAULT, int flags=0);
native void A_CopyFriendliness(int ptr_source = AAPTR_MASTER);
action native bool A_Overlay(int layer, statelabel start = null, bool nooverride = false);

View file

@ -428,7 +428,7 @@ const ATTN_NORM = 1;
const ATTN_IDLE = 1.001;
const ATTN_STATIC = 3;
// For SetPlayerProprty action special
// For SetPlayerProperty action special
enum EPlayerProperties
{
PROP_FROZEN = 0,

View file

@ -194,7 +194,7 @@ extend class Actor
Actor owner = (flags & MSF_DontHurt) ? target : self;
aimtarget.Height = Height;
bool shootmode = ((flags & MSF_Classic) || // Flag explicitely set, or no flags and compat options
bool shootmode = ((flags & MSF_Classic) || // Flag explicitly set, or no flags and compat options
(flags == 0 && CurState.bDehacked && compat_mushroom));
for (i = -numspawns; i <= numspawns; i += 8)

View file

@ -224,7 +224,7 @@ class HornRodFX2 : Actor
RainTracker tracker;
if (target == null || target.health <= 0)
{ // Shooter is dead or nonexistant
{ // Shooter is dead or nonexistent
return;
}

View file

@ -347,7 +347,6 @@ class ArtiPoisonBag3 : ArtiPoisonBag
// is as set by the projectile. To accommodate self with a proper trajectory, we
// aim the projectile ~20 degrees higher than we're looking at and increase the
// speed we fire at accordingly.
double orgpitch = -Owner.Pitch;
double modpitch = clamp(-Owner.Pitch + 20, -89., 89.);
double ang = mo.angle;
double speed = (mo.Speed, 4.).Length();

View file

@ -1038,7 +1038,7 @@ class SorcFX3 : Actor
mo.Destroy ();
}
else if (target != null)
{ // [RH] Make the new bishops inherit the Heriarch's target
{ // [RH] Make the new bishops inherit the Heresiarch's target
mo.CopyFriendliness (target, true);
mo.master = target;
}

View file

@ -4,7 +4,7 @@
**
**---------------------------------------------------------------------------
** Copyright 2000-2016 Randy Heit
** Copyright 2006-2017 Cheistoph Oelckers
** Copyright 2006-2017 Christoph Oelckers
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without

View file

@ -827,7 +827,7 @@ class Inventory : Actor native
}
/*
else if ((ItemFlags & IF_FANCYPICKUPSOUND) &&
(toucher == NULL || toucher->CheckLocalView(consoeplayer)))
(toucher == NULL || toucher->CheckLocalView(consoleplayer)))
{
atten = ATTN_NONE;
}

View file

@ -3,7 +3,7 @@
** Implements generic weapon pieces
**
**---------------------------------------------------------------------------
** Copyright 2006-2016 Cheistoph Oelckers
** Copyright 2006-2016 Christoph Oelckers
** Copyright 2006-2016 Randy Heit
** All rights reserved.
**

View file

@ -1109,7 +1109,7 @@ class LevelCompatibility play
break;
}
case 'D67CECE3F60083383DF992B8C824E4AC': // Icarus: Alien Vanuguard MAP13
case 'D67CECE3F60083383DF992B8C824E4AC': // Icarus: Alien Vanguard MAP13
{
// Moves sector special to platform with Berserk powerup. The
// map's only secret can now be scored.
@ -1118,7 +1118,7 @@ class LevelCompatibility play
break;
}
case '61373587339A768854E2912CC99A4781': // Icarus: Alien Vanuguard MAP15
case '61373587339A768854E2912CC99A4781': // Icarus: Alien Vanguard MAP15
{
// Can press use on the lift to reveal the secret Shotgun,
// making 100% secrets possible.
@ -1128,7 +1128,7 @@ class LevelCompatibility play
break;
}
case '9F66B0797925A09D4DC0725540F8EEF7': // Icarus: Alien Vanuguard MAP16
case '9F66B0797925A09D4DC0725540F8EEF7': // Icarus: Alien Vanguard MAP16
{
// Can press use on the walls at the secret Rocket Launcher in
// case of getting stuck.

View file

@ -157,7 +157,7 @@ struct Line native play
native uint activation; // activation type
native int special;
native int args[5]; // <--- hexen-style arguments (expanded to ZDoom's full width)
native double alpha; // <--- translucency (0=invisibile, FRACUNIT=opaque)
native double alpha; // <--- translucency (0=invisible, FRACUNIT=opaque)
native readonly Side sidedef[2];
native readonly double bbox[4]; // bounding box, for the extent of the LineDef.
native readonly Sector frontsector, backsector;

View file

@ -1,6 +1,6 @@
/*
** messagebox.cpp
** Confirmation, notification screns
** Confirmation, notification screens
**
**---------------------------------------------------------------------------
** Copyright 2010-2017 Christoph Oelckers

View file

@ -46,7 +46,7 @@ class BridgeBall : Actor
{
if (target == NULL)
{ // Don't crash if somebody spawned this into the world
// independantly of a Bridge actor.
// independently of a Bridge actor.
return;
}
// Set default values

View file

@ -1,6 +1,6 @@
/*
** a_soundsequence.cpp
** Actors for independantly playing sound sequences in a map.
** Actors for independently playing sound sequences in a map.
**
**---------------------------------------------------------------------------
** Copyright 1998-2006 Randy Heit

View file

@ -205,7 +205,7 @@ class BaseStatusBar native ui
DI_ITEM_VMASK = 0x180000,
DI_ITEM_LEFT = 0x200000,
DI_ITEM_HCENTER = 0, // this is the deafault horizontal alignment
DI_ITEM_HCENTER = 0, // this is the default horizontal alignment
DI_ITEM_RIGHT = 0x400000,
DI_ITEM_HOFFSET = 0x600000,
DI_ITEM_HMASK = 0x600000,
@ -1140,7 +1140,7 @@ class LinearValueInterpolator : Object
mCurrentValue = value;
}
// This must be called peroiodically in the status bar's Tick function.
// This must be called periodically in the status bar's Tick function.
// Do not call this in the Draw function because that may skip some frames!
void Update(int destvalue)
{
@ -1184,7 +1184,7 @@ class DynamicValueInterpolator : Object
mCurrentValue = value;
}
// This must be called peroiodically in the status bar's Tick function.
// This must be called periodically in the status bar's Tick function.
// Do not call this in the Draw function because that may skip some frames!
void Update(int destvalue)
{

View file

@ -38,7 +38,7 @@ extend class Actor
}
// A Cloud used for varius explosions ---------------------------------------
// A Cloud used for various explosions --------------------------------------
// This actor has no direct equivalent in strife. To create this, Strife
// spawned a spark and then changed its state to that of this explosion
// cloud. Weird.

View file

@ -204,7 +204,7 @@ class PhosphorousGrenade : Actor
}
}
// Fire from the Phoshorous Grenade -----------------------------------------
// Fire from the Phosphorous Grenade ----------------------------------------
class PhosphorousFire : Actor
{