Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 17 additions & 1 deletion examples/03-conditions.sfm
Original file line number Diff line number Diff line change
Expand Up @@ -61,4 +61,20 @@ every 20 ticks do
end

output to b
end
end

--------------------

-- Complex conditionals, AND and OR

every 20 ticks do
if a has >= 10 iron_ingot and a has >= 5 coal then
input 1 redstone_block from a
output to b
end

if a has >= 1 sand or a has >1 red_sand then
input 1 glass from a
output to b
end
end