Ejemplo n.º 1
0
 /// <summary>
 /// ScenarioManagerのRequestNextLineよりBroadcastMessage経由で呼ばれるコールバック。
 /// 新しいテキストを呼ぶ直前に呼ばれる
 /// </summary>
 public void OnRequestNextLine()
 {
     if (m_rawImage.texture != null)
     {
         TextureresourceManager.Mark(m_rawImage.texture.name);
     }
 }
Ejemplo n.º 2
0
        public void Command(Dictionary <string, string> command)
        {
            var fileName   = command["image"];
            var objectName = command["name"];

            var obj = Array.Find <GameObject>(GameObject.FindGameObjectsWithTag("Layer"), item => item.name == objectName);

            obj.GetComponent <Layer>().UpdateTexture(TextureresourceManager.Load(fileName));
        }
Ejemplo n.º 3
0
 /// <summary>
 ///  テキストコマンド実行時に呼ばれるコールバック
 /// UITextManagerより呼ばれる
 /// </summary>
 public void UpdateTexture(Texture texture)
 {
     if (texture == null)
     {
         m_rawImage.enabled = false;
         m_rawImage.texture = null;
     }
     else
     {
         m_rawImage.texture = texture;
         m_rawImage.enabled = true;
         m_rawImage.SetNativeSize();
         TextureresourceManager.Mark(texture.name);
     }
 }
Ejemplo n.º 4
0
        public void PreCommand(Dictionary <string, string> command)
        {
            var fileName = command["image"];

            TextureresourceManager.Load(fileName);
        }