Skip to content

Commit

Permalink
Merge pull request #41 from shanemadden/patch-1
Browse files Browse the repository at this point in the history
Add support for output onto loader-type entities
  • Loading branch information
judos authored Jun 27, 2019
2 parents 3fc7519 + 06781ce commit 4458e63
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion source/libs/classes/BeltFactory.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ require "libs.classes.BeltAccess"
require "libs.classes.SplitterAccess"

BeltFactory={}
BeltFactory.supportedTypes = {"transport-belt","splitter","underground-belt"}
BeltFactory.supportedTypes = {"transport-belt","splitter","underground-belt","loader"}

BeltFactory.accessFor = function(entity,accessTarget,accessFrom)
if entity.type == "transport-belt" then
Expand All @@ -11,6 +11,8 @@ BeltFactory.accessFor = function(entity,accessTarget,accessFrom)
return SplitterAccess(entity,accessTarget,accessFrom)
elseif entity.type == "underground-belt" then
return BeltAccess(entity,accessFrom)
elseif entity.type == "loader" then
return BeltAccess(entity,accessFrom)
else
warn("Invalid entity type: "..entity.type.." to create an access object.")
end
Expand Down

0 comments on commit 4458e63

Please sign in to comment.