Modem.isWireless
From ComputerCraft Wiki
Function modem.isWireless | |
Returns true if a modem is wireless, false if it's wired. | |
Syntax | modem.isWireless() |
Returns | boolean is modem wireless? |
Part of | ComputerCraft |
API | Modem |
Examples
Example | |
Prints whether the modem on top of the computer is wireless or wired. | |
Code |
local modem = peripheral.wrap("top") if modem.isWireless() then print("The modem on top of the computer is wireless.") else print("The modem on top of the computer is wired.") end |