disk.getID
Returns the ID of the disk drive attached at the specified side or network name. Returns nil if there is no disk drive attached at the specified side or network name or there is no disk in the disk drive.
|
|||
Gets and prints the ID of the disk inserted in the disk drive on the top. | |||
Code | print(disk.getID("top"))
|
||
Output | If a disk drive is attached on the top, it would return the disk's ID. |
Functions | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Lua |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
CC:Tweaked |
|
disk.getID Function | |
---|---|
Syntax disk.getID(
| |
Returns | number ID |
API | disk |
Source | CC:Tweaked (source) |
This article is issued from Computercraft. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.