Fix TechTree prerequisite bug for buildings with a build limit.

Fixes where a building/unit whose prereq is a build limited structure
was always available to be built even when the prereq was not satisfied.
Rewrite for better efficiency

uses a single, more concise statement rather than an if statement, and
checks buildLimit before attempting to check if the buildables cache
contains the key.
Fix sold tech bug on build limited structures

Fixes where if a structure with a build limit was sold, it was not
properly removed from the buildables prerequisite list until next
update.
Merge pull request #5233 from Squiggles211/BuildLimitTech

Fix TechTree prerequisite bug for buildings with a build limit.