diff --git a/src/p_floor.c b/src/p_floor.c
index b8d3f7b5e0098605bb44dd37e4e25dfca6d4d81b..cacaadf8101406b47f10a75969ea7783cbca4edf 100644
--- a/src/p_floor.c
+++ b/src/p_floor.c
@@ -1973,71 +1973,51 @@ void T_NoEnemiesSector(levelspecthink_t *nobaddies)
 {
 	size_t i;
 	fixed_t upperbound, lowerbound;
-	sector_t *sec = NULL;
-	sector_t *targetsec = NULL;
-	INT32 secnum = -1;
+	INT32 s;
+	sector_t *checksector;
 	msecnode_t *node;
 	mobj_t *thing;
-	boolean FOFsector = false;
+	boolean exists = false;
 
-	while ((secnum = P_FindSectorFromLineTag(nobaddies->sourceline, secnum)) >= 0)
+	for (i = 0; i < nobaddies->sector->linecount; i++)
 	{
-		sec = &sectors[secnum];
-
-		FOFsector = false;
-
-		// Check the lines of this sector, to see if it is a FOF control sector.
-		for (i = 0; i < sec->linecount; i++)
+		if (nobaddies->sector->lines[i]->special == 223)
 		{
-			INT32 targetsecnum = -1;
-
-			if (sec->lines[i]->special < 100 || sec->lines[i]->special >= 300)
-				continue;
 
-			FOFsector = true;
+			upperbound = nobaddies->sector->ceilingheight;
+			lowerbound = nobaddies->sector->floorheight;
 
-			while ((targetsecnum = P_FindSectorFromLineTag(sec->lines[i], targetsecnum)) >= 0)
+			for (s = -1; (s = P_FindSectorFromLineTag(nobaddies->sector->lines[i], s)) >= 0 ;)
 			{
-				targetsec = &sectors[targetsecnum];
+				checksector = &sectors[s];
 
-				upperbound = targetsec->ceilingheight;
-				lowerbound = targetsec->floorheight;
-				node = targetsec->touching_thinglist; // things touching this sector
+				node = checksector->touching_thinglist; // things touching this sector
 				while (node)
 				{
 					thing = node->m_thing;
 
 					if ((thing->flags & (MF_ENEMY|MF_BOSS)) && thing->health > 0
-					&& thing->z < upperbound && thing->z+thing->height > lowerbound)
-						return;
+						&& thing->z < upperbound && thing->z+thing->height > lowerbound)
+					{
+						exists = true;
+						goto foundenemy;
+					}
 
 					node = node->m_snext;
 				}
 			}
 		}
-
-		if (!FOFsector)
-		{
-			upperbound = sec->ceilingheight;
-			lowerbound = sec->floorheight;
-			node = sec->touching_thinglist; // things touching this sector
-			while (node)
-			{
-				thing = node->m_thing;
-
-				if ((thing->flags & (MF_ENEMY|MF_BOSS)) && thing->health > 0
-				&& thing->z < upperbound && thing->z+thing->height > lowerbound)
-					return;
-
-				node = node->m_snext;
-			}
-		}
 	}
+foundenemy:
+	if (exists)
+		return;
+
+	s = P_AproxDistance(nobaddies->sourceline->dx, nobaddies->sourceline->dy)>>FRACBITS;
 
-	CONS_Debug(DBG_GAMELOGIC, "Running no-more-enemies exec with tag of %d\n", nobaddies->sourceline->tag);
+	CONS_Debug(DBG_GAMELOGIC, "Running no-more-enemies exec with tag of %d\n", s);
 
-	// No enemies found, run the linedef exec and terminate this thinker
-	P_RunTriggerLinedef(nobaddies->sourceline, NULL, NULL);
+	// Otherwise, run the linedef exec and terminate this thinker
+	P_LinedefExecute((INT16)s, NULL, NULL);
 	P_RemoveThinker(&nobaddies->thinker);
 }
 
diff --git a/src/p_spec.c b/src/p_spec.c
index 34b779068e83666201d9fb24789ac1c31ce8ddea..285da0e7f3610d88d982fc3b566c34371ce6199c 100644
--- a/src/p_spec.c
+++ b/src/p_spec.c
@@ -1891,7 +1891,6 @@ boolean P_RunTriggerLinedef(line_t *triggerline, mobj_t *actor, sector_t *caller
 	 || specialtype == 304  // Ring count - Once
 	 || specialtype == 307  // Character ability - Once
 	 || specialtype == 308  // Race only - Once
-	 || specialtype == 313  // No More Enemies - Once
 	 || specialtype == 315  // No of pushables - Once
 	 || specialtype == 318  // Unlockable trigger - Once
 	 || specialtype == 320  // Unlockable - Once