void Awake() { LoadCSV.Load(); float startx = LoadCSV.rowList[0].longitudem; float startz = LoadCSV.rowList[0].latitudem; int lastline = LoadCSV.rowList.Count - 1; float endy = LoadCSV.rowList[lastline].height1; Vector3 scale = Vector3.one * 10f; Vector3 position; foreach (Row r in LoadCSV.rowList) { Transform point = Instantiate(pointprefab); position.x = r.longitudem - startx; position.z = r.latitudem - startz; position.y = r.height1 - endy; point.localPosition = position; point.localScale = scale; //Debug.Log(r.longitudem - startx); } }
private void LoadCsvIntoBD(object sender, RoutedEventArgs e) { //check if it is empty FC_Carrier c = new FC_Carrier(); if (c.ObjToTable(SQL.Select(c)).Count == 0) { LoadCSV.Load(); } Carrier_DataLoadClick(null, null); }
private void ChangeCSVLocation(object sender, RoutedEventArgs e) { // View Save As File Dialog OpenFileDialog openFileDialog = new OpenFileDialog(); openFileDialog.Filter = "csv Files (*.csv)|*.csv"; if (openFileDialog.ShowDialog() == true) { LoadCSV.SetNewCSVLocation(openFileDialog.FileName); LoadCSV.Load(); } }
/// <summary> /// Will connect to Photon server and load the deck the player chose /// </summary> private void loadDeckFromServer() { // Grab Deck from the server - Currently only grabs from local CSV _playerDeck = LoadCSV.Load(Resources.Load <TextAsset>("Data/testdeck")); }