Skip to content

Commit

Permalink
Fix shipyard store not selling class 2 Military Drive
Browse files Browse the repository at this point in the history
Class 2 military drives require "MILITARY" tech level, which under the hood is
interpreted as tech-level 11 (because that's how Frontier implemented it).
Higher military drives are available at higher tech levels. Code had a bug
where in stations of higher tech level than "MILITARY", you could only buy
military drive of class 1, 3, and 4, but not military drive class 2.
  • Loading branch information
impaktor committed Jul 8, 2024
1 parent d5e3147 commit 771aed4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion data/pigui/libs/ship-equipment.lua
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ local hasTech = function (station, e)

if type(equip_tech_level) == "string" then
if equip_tech_level == "MILITARY" then
return station.techLevel == 11
equip_tech_level = 11
else
error("Unknown tech level:\t"..equip_tech_level)
end
Expand Down

0 comments on commit 771aed4

Please sign in to comment.