Exemplo n.º 1
0
 public LayerObjects Map(Tiled.ObjectGroup src, LayerObjects dst = null)
 {
     if (dst == null)
     {
         dst = new LayerObjects();
     }
     dst.Name         = src.Name;
     dst.Visible      = src.Visible;
     dst.DefinitionId = GetPropertyValue(src.Properties, default(Guid), nameof(LayerTilemap.DefinitionId));
     dst.Objects      = src.Objects.Select(x => Map(x)).ToList();
     return(dst);
 }
Exemplo n.º 2
0
 public Tiled.ObjectGroup Map(LayerObjects src, Tiled.ObjectGroup dst = null)
 {
     if (dst == null)
     {
         dst = new Tiled.ObjectGroup();
     }
     dst.Name    = src.Name;
     dst.Visible = src.Visible;
     dst.Opacity = 1.0;
     dst.Properties[nameof(LayerTilemap.DefinitionId)] = src.DefinitionId;
     dst.Objects = src.Objects.Select(x => Map(x)).ToList();
     return(dst);
 }