コード例 #1
0
    public override Node Create(Vector2 pos)
    {
        DialogMultiOptionsNode node = CreateInstance <DialogMultiOptionsNode>();

        node.rect = new Rect(pos.x, pos.y, 300, 350);
        node.name = "Dailog with Options Node";

        //Previous Node Connections
        node.CreateInput("Previous Node", "DialogForward", NodeSide.Left, 30);
        node.CreateOutput("Back Node", "DialogBack", NodeSide.Left, 50);

        ////Next Node to go to
        //node.CreateOutput("Next Node", "DialogForward", NodeSide.Right, 30);

        node.SayingCharacterName    = "Morgen Freeman";
        node.WhatTheCharacterSays   = "I'm GOD";
        node.SayingBackground       = null;
        node.SayingCharacterPotrait = null;

        node._options = new List <DataHolderForOption>();

        node.AddNewOption();

        return(node);
    }
コード例 #2
0
    public override Node Create(Vector2 pos)
    {
        DialogMultiOptionsNode node = CreateInstance <DialogMultiOptionsNode>();

        //node.rect = new Rect(pos.x, pos.y, 300, 275);
        node.rect.position = pos;
        node.name          = "Dialog with Options Node";

        //Previous Node Connections
        node.CreateInput("Previous Node", "DialogForward", NodeSide.Left, 30);
        node.CreateOutput("Back Node", "DialogBack", NodeSide.Left, 50);

        ////Next Node to go to
        //node.CreateOutput("Next Node", "DialogForward", NodeSide.Right, 30);

        node.CharacterName    = "Character Name";
        node.DialogLine       = "Dialog Line Here";
        node.CharacterPotrait = null;

        node._options = new List <DataHolderForOption>();

        node.AddNewOption();

        return(node);
    }