Animating Replicated Objects

It is the common situation when you have a replicated object representing a set of objects and you want each object to be depicted on the presentation with an individual shape. In this case, instead of drawing a number of shapes individually one by one, use shape replication

 To animate a replicated object

  1. Open the diagram of the agent type that embeds your replicated object.
  2. Draw a shape that will depict an individual instance of your replicated object. 
  3. Go to the Advanced section of the shape's Properties.
  4. Define the number of shapes to be created. Suppose your replicated object is named object. In this case you should type object.size() in the Replication edit box. 
  5. You may set specific visual properties for the shapes. Assume, for instance, that the replicated object has a parameter x and you want each shape to have X-coordinate as defined by the parameter of the corresponding object instance. In this case, type object.get(index).x in the X dynamic property field. object here is the name of the replicated object and index is the keyword used to make correspondence between shapes and elements of the replicated object.

Related topics

 Replicated objects