Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using System.IO;
- using System;
- public class PhotoPoserAuto : MonoBehaviour
- {
- public PhotoPoser PP;
- public bool activ;
- public GameObject leftUpPoint;
- public GameObject rightUpPoint;
- public static string foldeR;
- public static string[] directoryName;
- //0. Глобальный метод
- //1. Метод получения информации о стриминг ассетс
- //2. Метод расчета ширины поля и остатка ширины
- //3. Метод изменения размера фотографий
- //4. Метод распределяющий метод постановки объекта
- //5. Метод распределяющий метод равнения объекта
- //
- public void AutoPosing()
- {
- GetInfo();
- }
- public void GetInfo()
- {
- foldeR = System.IO.Path.GetDirectoryName(Application.streamingAssetsPath);
- foldeR = foldeR + "/Streaming Assets";
- Mass(foldeR);
- }
- public static void Mass(string fold)
- {
- try
- {
- string[] dirs = Directory.GetFiles(fold);
- foreach (string dir in dirs)
- {
- Debug.Log(dir);// Вывел только .metы, а папки не вывел
- }
- directoryName = dirs;
- }
- catch (Exception e)
- {
- //Debug.Log("The process failed: {0}", e.ToString());
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement