Unfocus more UI Elements

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
mac
Posts: 81
Joined: Sat Aug 22, 2020 7:54 pm

Unfocus more UI Elements

Post by mac »

So I have a frame for the character portraits (as you can see in the attachment), and I also want to apply the unfocus to those frames, how can I achieve that?
Attachments
Screenshot_1.png
Screenshot_1.png (252.59 KiB) Viewed 245 times
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Unfocus more UI Elements

Post by Tony Li »

Hi,

You can just add those frames to the focus and/or unfocus animations. For example, if you're basing your UI off the VN template, edit the Show Color and Focus Color animations, and add animation for your frames. Better yet, duplicate the animator controller and animation clips, assign them to your dialogue UI, and edit the duplicates. This way you won't lose your changes when you update the Dialogue System.
mac
Posts: 81
Joined: Sat Aug 22, 2020 7:54 pm

Re: Unfocus more UI Elements

Post by mac »

Thank you Tony, it works.
However for some reason, my custom sequencer is not getting recognized, heres it's code:
(I already tried deleting and making it from scratch, same result, check goes red)

Code: Select all

using UnityEngine;
using System.Collections;
using PixelCrushers.DialogueSystem;

namespace PixelCrushers.DialogueSystem.SequencerCommands
{

    public class SequencerCommandAudreyMove : SequencerCommand
    { // Rename to SequencerCommand<YourCommand>

        public void Awake()
        {
            // Add your initialization code here. You can use the GetParameter***() and GetSubject()
            // functions to get information from the command's parameters. You can also use the
            // Sequencer property to access the SequencerCamera, CameraAngle, Speaker, Listener,
            // SubtitleEndTime, and other properties on the sequencer. If IsAudioMuted() is true, 
            // the player has muted audio.

            GameObject directressObj = GameObject.Find("Audrey");
            DirectressMovement dirMove = directressObj.GetComponent<DirectressMovement>();
            dirMove.Move();
            //DiaTrigger trigger = FindObjectOfType<DiaTrigger>();
            //trigger.directressStage = 1;
            print("MOVING EVENT PLAYED");

            // If your sequencer command only does something immediately and then finishes,
            // you can call Stop() here and remove the Update() method:
            //
            Stop();
            //
            // If you want to use a coroutine, use a Start() method in place of or in addition to
            // this method.
        }

    }

}
Attachments
Screenshot_2.png
Screenshot_2.png (22 KiB) Viewed 241 times
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Unfocus more UI Elements

Post by Tony Li »

Hi,

Try adding () at the end:

Code: Select all

AudreyMove()
mac
Posts: 81
Joined: Sat Aug 22, 2020 7:54 pm

Re: Unfocus more UI Elements

Post by mac »

It worked, thank you again.
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Unfocus more UI Elements

Post by Tony Li »

Happy to help!
Post Reply