Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --[[
- Copyright 2015 Max Thor <thormax5@gmail.com>
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
- http://www.apache.org/licenses/LICENSE-2.0
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- --]]
- for k, v in pairs(rs.getSides()) do
- if peripheral.getType(v) == "modem" then
- rednet.open(v)
- end
- end
- while true do
- _, p1, p2, p3 = os.pullEvent("rednet_message")
- if p1 == 269 then
- turtle.select(tonumber(p2))
- if turtle.place() then
- rednet.send(269, "Success!")
- else
- rednet.send(269, "Error")
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement