Beispiel #1
0
        public static bool PlaceTile(this Tilemap tilemap, Vector3Int position, ItemTile item)
        {
            if (!tilemap.HasTile(position) && item != null)
            {
                TileBasic tile = ScriptableObject.CreateInstance <TileBasic>().Initialise(item);
                tilemap.SetTile(position, tile);
                return(true);
            }

            return(false);
        }
Beispiel #2
0
 public TileBasic Initialise(ItemTile item)
 {
     Item = item;
     return(this);
 }