diff --git a/src/g_shared/a_randomspawner.cpp b/src/g_shared/a_randomspawner.cpp index 5633c7b7..549c957a 100644 --- a/src/g_shared/a_randomspawner.cpp +++ b/src/g_shared/a_randomspawner.cpp @@ -31,6 +31,7 @@ class ARandomSpawner : public AActor FDropItem *di; // di will be our drop item list iterator FDropItem *drop; // while drop stays as the reference point. int n=0; + bool nomonsters = (dmflags & DF_NO_MONSTERS) || (level.flags2 & LEVEL2_NOMONSTERS); Super::BeginPlay(); drop = di = GetDropItems(); @@ -40,11 +41,19 @@ class ARandomSpawner : public AActor { if (di->Name != NAME_None) { - if (di->amount < 0) di->amount = 1; // default value is -1, we need a positive value. - n += di->amount; // this is how we can weight the list. + if (!nomonsters || !(GetDefaultByType(PClass::FindClass(di->Name))->flags3 & MF3_ISMONSTER)) + { + if (di->amount < 0) di->amount = 1; // default value is -1, we need a positive value. + n += di->amount; // this is how we can weight the list. + } di = di->Next; } } + if (n == 0) + { // Nothing left to spawn. They must have all been monsters, and monsters are disabled. + Destroy(); + return; + } // Then we reset the iterator to the start position... di = drop; // Take a random number... @@ -54,15 +63,22 @@ class ARandomSpawner : public AActor { if (di->Name != NAME_None) { - n -= di->amount; - if ((di->Next != NULL) && (n > -1)) di = di->Next; else n = -1; + if (!nomonsters || !(GetDefaultByType(PClass::FindClass(di->Name))->flags3 & MF3_ISMONSTER)) + { + n -= di->amount; + if ((di->Next != NULL) && (n > -1)) + di = di->Next; + else + n = -1; + } } } // So now we can spawn the dropped item. if (bouncecount >= MAX_RANDOMSPAWNERS_RECURSION) // Prevents infinite recursions { Spawn("Unknown", x, y, z, NO_REPLACE); // Show that there's a problem. - Destroy(); return; + Destroy(); + return; } else if (pr_randomspawn() <= di->probability) // prob 255 = always spawn, prob 0 = never spawn. { @@ -167,8 +183,10 @@ class ARandomSpawner : public AActor if (rep && ((rep->flags4 & MF4_BOSSDEATH) || (rep->flags2 & MF2_BOSS))) boss = true; } - if (boss) this->tracer = newmobj; - else Destroy(); // "else" because a boss-replacing spawner must wait until it can call A_BossDeath. + if (boss) + this->tracer = newmobj; + else // "else" because a boss-replacing spawner must wait until it can call A_BossDeath. + Destroy(); } void Tick() // This function is needed for handling boss replacers diff --git a/src/p_enemy.cpp b/src/p_enemy.cpp index 0961e867..dd5ab581 100644 --- a/src/p_enemy.cpp +++ b/src/p_enemy.cpp @@ -550,9 +550,14 @@ bool P_Move (AActor *actor) { actor->z = savedz; } - else if (actor->floorsector->SecActTarget != NULL) + else { // The monster just hit the floor, so trigger any actions. - actor->floorsector->SecActTarget->TriggerAction(actor, SECSPAC_HitFloor); + if (actor->floorsector->SecActTarget != NULL && + actor->floorz == actor->floorsector->floorplane.ZatPoint(actor->x, actor->y)) + { + actor->floorsector->SecActTarget->TriggerAction(actor, SECSPAC_HitFloor); + } + P_CheckFor3DFloorHit(actor); } } } diff --git a/src/svnrevision.h b/src/svnrevision.h index a7f67d42..8c7dce3f 100644 --- a/src/svnrevision.h +++ b/src/svnrevision.h @@ -3,5 +3,5 @@ // This file was automatically generated by the // updaterevision tool. Do not edit by hand. -#define ZD_SVN_REVISION_STRING "4150" -#define ZD_SVN_REVISION_NUMBER 4150 +#define ZD_SVN_REVISION_STRING "4154" +#define ZD_SVN_REVISION_NUMBER 4154 diff --git a/src/textures/multipatchtexture.cpp b/src/textures/multipatchtexture.cpp index 5d5f6106..3083735a 100644 --- a/src/textures/multipatchtexture.cpp +++ b/src/textures/multipatchtexture.cpp @@ -558,7 +558,7 @@ int FMultiPatchTexture::CopyTrueColorPixels(FBitmap *bmp, int x, int y, int rota return Parts[0].Texture->CopyTrueColorPixels(bmp, x, y, rotate, inf); } - if (rotate != 0 || (inf != NULL && inf->op != OP_OVERWRITE && inf->op != OP_COPY)) + if (rotate != 0 || (inf != NULL && ((inf->op != OP_OVERWRITE && inf->op != OP_COPY) || inf->blend != BLEND_NONE))) { // We are doing some sort of fancy stuff to the destination bitmap, so composite to // a temporary bitmap, and copy that. FBitmap tbmp; diff --git a/wadsrc/static/menudef.txt b/wadsrc/static/menudef.txt index 915d0840..f50f21a6 100644 --- a/wadsrc/static/menudef.txt +++ b/wadsrc/static/menudef.txt @@ -465,6 +465,16 @@ OptionMenu "CustomizeControls" StaticText "Weapons", 1 Control "Next weapon", "weapnext" Control "Previous weapon", "weapprev" + Control "Weapon Slot 1", "slot 1" + Control "Weapon Slot 2", "slot 2" + Control "Weapon Slot 3", "slot 3" + Control "Weapon Slot 4", "slot 4" + Control "Weapon Slot 5", "slot 5" + Control "Weapon Slot 6", "slot 6" + Control "Weapon Slot 7", "slot 7" + Control "Weapon Slot 8", "slot 8" + Control "Weapon Slot 9", "slot 9" + Control "Weapon Slot 0", "slot 0" StaticText "" StaticText "Inventory", 1 Control "Activate item", "invuse"