IdleAreaObj : GeometryClass

IdleAreaObj - superclass: GeometryClass; super-superclass:node - 15:1 - classID: #(685327, 452283)

Value > MAXWrapper > Node > GeometryClass > IdleAreaObj

 

   

Geometry Objects - Quick Navigation

Exposes the Idle Area object to MAXScript. It is part of the Populate toolset.

Available in 3ds Max 2014 and higher.

   

Constructors:

IdleAreaObj...

   

Properties:

People group of controls

<IdleAreaObj>.density     Float    default: 0.5   --  float

Get/set the value of the "Density" slider controlling the amount of people in the idle area.

A value of 0.0 will not create an empty idle area, but either one character or one group with two or three characters depending on the grouping and pairing properties documented below.

Note that the User Interface control only allows values between 0.0 and 1.0, but the property can be set to higher values using MAXScript.

   

<IdleAreaObj>.groups     Float    default: 0.5   --  float

Get/set the value of the "Singles or Groups" slider controlling the creation of groups vs. individual characters.

A value of 0.0 will produce only singles.

A value of 0.5 will produce approximately equal proportions of singles and groups.

A value of 1.0 will cause the whole population to be spread in groups of twos or threes.

   

<IdleAreaObj>.pair     Float    default: 0.5   --  float

Get/set the value of the "Group 3s or Group 2s" slider controlling the number of people in groups.

A value of 0.0 will produce only groups of threes.

A value of 0.5 will produce approximately equal proportions of threes and twos.

A value of 1.0 will produce only pairs.

   

<IdleAreaObj>.gender     Float    default: 0.5   --  float

Get/set the value of the "Males or Females" slider controlling the gender balance of the idle area.

A value of 0.0 produces only male population.

A value of 0.5 produces equal parts male and female population.

A value of 1.0 produces only female population.

   

Singles Orientation group of controls

<IdleAreaObj>.orient     Float    default: 0.0   --  float

Get/set the value of the "Orientation" slider which controls the orientation offset of all single characters.

Characters in groups will always be oriented according to the group's center.

   

<IdleAreaObj>.orientspread     Float    default: 360.0   --  float

Get/set the value of the "Spread" slider which controls the randomization range of the orientation angle.

When the value is 0.0, all characters will be oriented in the same direction and the .orient property can be used to specify the angle relative to the local X axis.

When the value is 360.0, each character will have a different random orientation.

   

<IdleAreaObj>.baseobject.lookat     BooleanClass    default: false   --  boolean

Get/set the state of the "Face" checkbox.

When set to True, the population will look at the object specified by the .lookatobj property.

When set to False, the population will not look at anything specific.

NOTE:The property .lookat already exists as a general node property. It expects a node target for a LookAt controller. Thus it is necessary to explicitly specify the .baseobject of the IdleAreaObj.

   

<IdleAreaObj>.lookatobj     UndefinedClass    default: undefined   --  node

Get/set the scene object to population will look at when the .lookat property is set to True.

   

Samples group of controls

<IdleAreaObj>.randseedIndiv     Integer    default: 1   --  integer

Get/set the value of the "Positions" spinner controlling the random seed for the characters' positioning.

   

<IdleAreaObj>.randseedGroup     Integer    default: 1   --  integer

Get/set the value of the "Singles" spinner controlling the random seed for grouping generation.

   

<IdleAreaObj>.randseedRot     Integer    default: 1   --  integer

Get/set the value of the "Orientation" spinner controlling the random seed for orientation generation.

   

<IdleAreaObj>.randseedGen     Integer    default: 1   --  integer

Get/set the value of the "Gender" spinner controlling the random seed for gender generation.

   

<IdleAreaObj>.randseedMtn     Integer    default: 1   --  integer

Get/set the value of the "Motion" spinner controlling the random seed for motion generation.

   

Other Properties

<IdleAreaObj>.id     Integer    default: 1   --  integer

Get/set the ID of the Idle Area.

   

<IdleAreaObj>.Editable_Poly     Editable_Poly    default: Editable Poly   --  SubAnim

Get the Editable_Poly mesh of the Idle Area object.

The Editable_Poly mesh can be modified in place, for example you can change the vertex positions as needed using polyOp.setVert() , create new vertices and polygons to produce complex shapes, and so on. See the Editable_Poly Methods topic for details.

   

EXAMPLE:
theIdleArea = IdleAreaObj() --Create a new empty Idle Area object
ep = theIdleArea.Editable_Poly --Assign the Editable_Poly property to a shorter user variable --Create a custom-shaped Idle Area by setting a few vertices:
polyOp.createVert ep [-300,-300,0]
polyOp.createVert ep [300,-300,0]
polyOp.createVert ep [200,300,0]
polyOp.createVert ep [-200,300,0]
polyOp.createVert ep [-400,0,0]
polyOp.createPolygon ep #(1,2,3,4,5) --Create a polygon from the 5 vertices
select theIdleArea --Select the new Idle Area object

theIdleArea.density = 1.0 --Increase the density
theIdleArea.groups = 0.3 --Reduce the number of groups
theIdleArea.pair = 0.8 --When grouped, prefer threes
theIdleArea.gender = 0.7 --Create more women than men

p = point pos:[600,600,0] --Create a look at target
theIdleArea.lookatobj = p --Assign the look at target
theIdleArea.baseobject.lookat = true --And enable the "Face" option by accessing the .lookat property in the base object
theIdleArea.orientspread = 0.0 --Make sure everybody is looking in the general direction of the reference point

pop.addIdleArea theIdleArea --Add the Idle Area to the Populate simulator
pop.Simulate() --Trigger the simulation to populate the Idle Area

IdleAreaObj interfaces:

Interface: IMtlRender_Compability_MtlBase

Properties:

Methods:

Actions:

See Also