CreateObjectPlane

Family: 3D · 2 forms

What it does

CreateObjectPlane brings a 3D object into being: it is how the rest of the program comes to have one. It takes objectID (an integer), width (a float) and height (a float), and returns nothing. That is the first of 2 forms. objectID is the id you are giving a 3D object: every later call names it by that number.

Syntax

1
CreateObjectPlane(objectID integer, width float, height float)
2
CreateObjectPlane(width float, height float) → integer

Parameters

NameTypeIn forms
objectIDinteger1
widthfloatall
heightfloatall

What each form returns

1CreateObjectPlane(1, 64.0, 64.0)nothing
2objectPlane = CreateObjectPlane(64.0, 64.0)integer

Example · generated

Form 1, you choose the id yourself

CreateObjectPlane(1, 64.0, 64.0)DO  Sync()LOOP

Form 2, the command hands back the id

objectPlane = CreateObjectPlane(64.0, 64.0)DO  Sync()LOOP

CreateObjectPlane is called with values of the types its signature asks for. The DO … LOOP is not decoration: a classic BASIC program ends the moment it runs out of lines, and Sync() is what draws the frame.

286 commands in 3D