Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local reader = peripheral.find("blockReader")
- local nbtBuffer = peripheral.find("nbtStorage")
- local taskID = "Task"
- local regex = "[0-9]+"
- local function getValue()
- local data = textutils.serialiseJSON(reader.getBlockData()[taskID])
- local value = data:match(regex)
- return tonumber(value)
- end
- print(getValue())
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement