Hello. I am trying to read value from Ini file, but i can do this.
I using this code:
using UnityEngine;
using System.Collections;
using Ini;
public class ReadValue : MonoBehaviour {
public IniFile myini;
// Use this for initialization
void Start () {
myini = new IniFile("Settings.ini");
}
// Update is called once per frame
void read()
{
string time = myini.IniReadValue("Settings","gametime");
}
public float time1 = time;
void Update () {
Debug.Log(time1);
}
}
But i have error:
Assets/ReadValue.cs(18,22): error CS0103: The name `time’ does not exist in the current context.
How can I handle with this?