vector.new

From ComputerCraft Wiki
Jump to: navigation, search


Grid Redstone.png  Function vector.new
Creates a vector.
Syntax vector.new(number x, number y, number z)
Returns vector
Part of ComputerCraft
API vector

Examples

Grid paper.png  Example
Creates a vector and prints the components
Code
local a = vector.new(1, 2, 3)

print(a.x)
print(a.y)
print(a.z)
--1
--2
--3
Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox