Parcel Editor: Creating a Diner On the Fly

This introductory tutorial to Ürban PAD will help you get a basic understanding of how the software works. Knowing your way around the Editors and City Designer will allow you get to the most out of Ürban PAD.

Using the Ocean Isle tutorial parcels included with the Ocean Isle city project, you will:

  • Combine operators and policies to create complex parcels
  • Create variety and diversity in activity templates

A current version of the Ocean Isle city project is available for download from the following locations:

  • On the site at Evaluation upon filling out an evaluation request
  • As a link in the confirmation e-mail sent to you after you fill out the evaluation request
  • On the Forum upon account creation

Parcel Editor: Creating Variety & Constructing a Diner

Highlights of this tutorial include:

  • Using rectangular filler policies to fill spaces
  • Creating context to change the global appearance of parcel templates

To start using the tutorials in your trial version:

  • Load the Ocean Isle city project following the instructions in Loading the City Project.
  • Open the diner.gcf file in Parcel Editor. This will bring the diner to the workspace. You will see a 2D representation of the Diner activity template in the Parcel Editor workspace. To see it in 3D, switch to Camera Maya in the Cameras tab.
_images/ofd_1.png _images/ofd_2.png
  • Switch to View Mode. You should see a 3D representation of the diner on a flat heightmap (see Heightfield and Heightmaps). Use the hotkey R to regenerate this parcel several times. Note the variations in the appearance of the activity template.

Next, return to the workspace by clicking Edit Mode in the Modes window. Open the Layers window. This will bring up the semantic description of the parcel, or activity template.

Now, let’s look at some of the ways Parcel Editor operations create visual diversity in the Diner parcel.

Highlight: Filling Space with Objects

Fillers: Using objects to fill up parcel spaces

Using a Rectangular Filler Expanding Policy, one of the Expanding Policies, is an easy way to fill spaces in parcels with objects, textures, or other parcel links. This is useful when you want to quickly create a visually uniform area and save time in manual placement.

We can see how this works by clicking the Layers Window and right-clicking on the parking_lot line. Select Edit to bring up the properties of this sub parcel.

There is one child object under the sub parcel: parcel_link_cars:

_images/ofd_14.png

As discussed on the Expanding Policies page, the sub parcel is given a Rectangular Filler Expanding Policy. Child Index 1 is selected, since the sub parcel will be filled with parcel_link_cars:

_images/ofd_13.png

Highlight: Context and Tags

Changing the appearance of an activity parcel

Using context and tags is an easy way to perform a complicated task: changing the global appearance of an activity template with a touch of a button. This feature is useful when you want to globally change the appearance of an area. This could be necessary, for example, when you want to show the same city under daytime and nighttime conditions.

Let’s take a closer look at how this works in the Diner activity template.

_images/context_1.png _images/context_2.png

As you see in the images above, the cars and tables are absent from several of the screenshots. Notice that when they are present, they are present together. Likewise, when one of them is missing, the other is absent, too.

The explanation is simple: we have designed the Diner to change its appearance according to opening and closing times. When the diner is “open,” the cars and exterior tables are present. When the diner is “closed,” the tables and cars are absent.

Defining Tags

How does this simulator “know” when the Diner is open and when it is closed?

The explanation is simple: you can create context by adding a semantic tag to an object. When the activity template is regenerated, the simulator chooses between the tag values that you define and applies that tag to the template display.

We can see how this works by clicking the Layers Window and right-clicking on the parking_lot link. Select Edit to bring up the properties of this sub parcel.

You see here that a String Tag Value Policy has been defined as an Existence Policy for parcel_filler_parking.

This String Tag Value Policy has been defined through the ntextgen. The name of the tag used here is opening hours and has two values:

  • opening time
  • closing time

These values set context for the activity template. Object existence will vary with the application of these values.

Here, the opening time value means that the cars in parking_lot_filler will be present when the opening_time context is selected by the Context Generator and applied to the activity parcel.

We have set the same opening_time value for the tables, meaning that they will be present when this context value is applied to the parcel template.

By setting these tag values, we can create the appearance of an open Diner during opening time, and a closed diner during closing time by specifying that cars and tables will be present only during opening time.

These values can be applied globally through the City Project Settings option in the Properties window.

Highlight: Creating a Contextual String Tag

A short tutorial for creating a string tag, using opening_hours as an example:

  • Open the Properties window to access the City Project Settings.
  • Click Context Generator, then Add.
_images/ofd_6.png
  • Select String Range as Tag Type.
_images/ofd_7.png
  • Enter the name you want to give the tag in the Tag field (here opening_hours).
_images/ofd_8.png
  • Enter names for each tag value, separated by a comma (no space between comma and tag names).
_images/ofd_9.png
  • Click the green checkmark at the bottom of the window. We now see the context tag in the Context Generator window.
_images/ofd_10.png

Checking Context Function in Parcel Editor

You can check which context value(s) apply at a given regeneration of your parcel by clicking the sun-and-cloud context icon tab at the top of the screen:

_images/ofd_11.png

A small window will appear at the bottom of the screen showing the current context value.

You may also click the red Error triangle to get a full report of which objects were not placed in the current regeneration. This is useful when a parcel contains many context tags, or when you want a report of placement problems unrelated to context:

_images/ofd_12.png