Skip to main content

interface IObjectBuilder

(Niantic.Lightship.Maps.Builders.IObjectBuilder)

Overview

The base type for maptile feature builders that instantiate Unity Objects attached to an IMapTileObject.

    interface IObjectBuilder: Niantic.Lightship.Maps.Builders.IFeatureBuilder {
// methods

GameObject CreateParent(IMapTileObject mapTileObject);
void Release(GameObject parent);
};

// direct descendants

class ObjectBuilderBase;
interface IObjectBuilderAsync;
interface IObjectBuilderStandard;

Inherited Members

public:
// properties

Guid Id;
int MinLOD;
int MaxLOD;

Detailed Documentation

The base type for maptile feature builders that instantiate Unity Objects attached to an IMapTileObject.

Methods

CreateParent

GameObject CreateParent(IMapTileObject mapTileObject)

Creates a GameObject that all Objects instantiated by this builder will be parented to.

    Parameters:

    mapTileObject - The IMapTileObject that the parent GameObject will be attached to.

    Returns:

    A new parent GameObject

Release

void Release(GameObject parent)

Called when a maptile is removed from the scene. This method cleans up objects or other resources created when the maptile is built by this builder.

    Parameters:

    parent - The GameObject created by the call to CreateParent.