peripheral_detach event

From ComputerCraft
Jump to: navigation, search
peripheral_detach
Event
Returns

Source CC:Tweaked

Occurs every time a peripheral is detached.

ExampleExampleAlert on peripheral detachment
Waits for a peripheral to be detached and alerts the user when it occured.
Code
local event, peripheral_name = os.pullEvent("peripheral_detach")
print("Peripheral", peripheral_name, "has been detached.")