Exemplo n.º 1
0
        public virtual GameObject Build(ISceneContext context)
        {
            var obj = StructureBuilderUtils.Build(prefabPath, structure.Transform);

            obj.layer = LayerMaskForCollisionLayer(collisionLayer, context);
            return(obj);
        }
Exemplo n.º 2
0
 public GameObject Build(ISceneContext context)
 {
     var spawner = StructureBuilderUtils.AddGameObjectWithBehaviour<RollingObstacleSpawnerBehaviour>(structure.Transform);
     spawner.SpawnInterval = structure.SpawnInterval;
     spawner.ObstacleLifetime = structure.ObstacleLifetime;
     spawner.ForceMultiplier = structure.ForceMultiplier;
     spawner.Context = context;
     return spawner.gameObject;
 }