Difference between revisions of "Computer.shutdown"

From ComputerCraft Wiki
Jump to: navigation, search
(Created page with "{{lowercase}} {{Function |name=peripheral.wrap |args= (string) side |returns=A handle to the peripheral on ''side''. |api=peripheral |addon=ComputerCraft |de...")
 
Line 1: Line 1:
 
{{lowercase}}
 
{{lowercase}}
 
{{Function
 
{{Function
|name=peripheral.wrap
+
|name=computer.wrap
 
|args= [[string (type)|(string)]] side
 
|args= [[string (type)|(string)]] side
|returns=A handle to the peripheral on ''side''.
 
 
|api=peripheral
 
|api=peripheral
 
|addon=ComputerCraft
 
|addon=ComputerCraft
|desc=Returns a handle to a peripheral that can then be used to call methods, as if using peripheral.call(side, method)
+
|desc=Shuts down a computer wrapped to the "computer" variable
 
|examples=
 
|examples=
 
{{Example
 
{{Example

Revision as of 13:56, 11 February 2013


Grid Redstone.png  Function computer.wrap
Shuts down a computer wrapped to the "computer" variable
Syntax computer.wrap((string) side)
Returns nil
Part of ComputerCraft
API peripheral

Examples

Grid paper.png  Example
Shuts down the computer or turtle on the right side of the calling machine.
Code
local handle = peripheral.wrap("right")
Output Shuts down any computer to the right of the computer/turtle.