I try to take the positions from each line from a txt file and then give them to a tree that has been spawned.I help out in this area: Loads the Coordinates from the save file.
I would like to have it listed in such a way that the 3 digits in each line are all numbers in a multiple ints z.b int1 = first number, int2 = second number, int3 = three nummber.
My txt file looks like this:
-32,68481 1,5 -24,33997;
11,65891 1,5 29,67229;
33,34601 1,5 26,94939;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using System.IO;
public class SaveSystem : MonoBehaviour
{
                        //Loads the Coordinates from the save file
    public void LoadSaveData()
    {
        string[] data = SaveBaumText.text.Split(new char[] { '\n' });
        for(int i = 0;i < data.Length - 1;i++)
        {
        string[] row = data[i].Split(new char[] { ';' });
        Bäume = GameObject.FindGameObjectsWithTag(BaumTag);
        Debug.Log(row[0]);
        }
    }
  }
 
     
    