Tanoda
LoadAndPlayScene.cs
Go to the documentation of this file.
1using UnityEngine;
2using System.Collections;
3using GILES.Interface;
4
5namespace GILES.Example
6{
10 public class LoadAndPlayScene : MonoBehaviour
11 {
13
17 public void OpenLoadPanel()
18 {
19 pb_FileDialog dlog = GameObject.Instantiate(dialogPrefab);
20 dlog.SetDirectory(System.IO.Directory.GetCurrentDirectory());
21 dlog.isFileBrowser = true;
22 dlog.filePattern = "*.json";
23 dlog.AddOnSaveListener(OnOpen);
24
25 pb_ModalWindow.SetContent(dlog.gameObject);
26 pb_ModalWindow.SetTitle("Open Scene");
28 }
29
30 private void OnOpen(string path)
31 {
33 }
34 }
35}
static void LoadScene(string path)
string filePattern
If isFileBrowser is true, this string my be used to filter file results (see https://msdn....
void AddOnSaveListener(Callback< string > listener)
void SetDirectory(string directory)
static void SetTitle(string title)
static void SetContent(GameObject prefab)