Difference between revisions of "Disk (API)"
From ComputerCraft Wiki
Line 1: | Line 1: | ||
The Disk API allows you to mess around with disk drives. | The Disk API allows you to mess around with disk drives. | ||
− | + | {| border="1" cellpadding="2" cellspacing="0" | |
− | * disk.isPresent( side ) | + | !style="background:#EEE" width="200px"|Method name |
− | + | !style="background:#EEE" width="*"|Description | |
− | + | |- | |
− | + | |disk.isPresent( side ) | |
− | + | |Checks the given side for a disk | |
− | + | |- | |
− | + | |disk.hasData( side ) | |
− | + | |Checks the disk for data | |
− | + | |- | |
+ | |disk.getMountPath( side ) | ||
+ | |<no description given> | ||
+ | |- | ||
+ | |disk.setLabel( side ) | ||
+ | |Sets the label | ||
+ | |- | ||
+ | |disk.getLabel( side ) | ||
+ | |Finds label | ||
+ | |- | ||
+ | |disk.hasAudio( side ) | ||
+ | |Checks if the disk is a music disk | ||
+ | |- | ||
+ | |disk.playAudio( side ) | ||
+ | |Plays the audio | ||
+ | |- | ||
+ | |disk.stopAudio( side ) | ||
+ | |Stops the audio | ||
+ | |- | ||
+ | |disk.eject( side ) | ||
+ | |Ejects the disk. | ||
+ | |} | ||
[[Category:APIs]] | [[Category:APIs]] |
Revision as of 05:36, 31 January 2012
The Disk API allows you to mess around with disk drives.
Method name | Description |
---|---|
disk.isPresent( side ) | Checks the given side for a disk |
disk.hasData( side ) | Checks the disk for data |
disk.getMountPath( side ) | <no description given> |
disk.setLabel( side ) | Sets the label |
disk.getLabel( side ) | Finds label |
disk.hasAudio( side ) | Checks if the disk is a music disk |
disk.playAudio( side ) | Plays the audio |
disk.stopAudio( side ) | Stops the audio |
disk.eject( side ) | Ejects the disk. |