예제 #1
0
        /// <summary>
        /// Constructs a new <see cref="Nwn2TriggerControl"/> instance.
        /// </summary>
        public Nwn2SlotTrigger(Fitter raiserFitter, string text1, string text2)
        {
            if (raiserFitter == null)
            {
                throw new ArgumentNullException("raiserFitter");
            }

            this.addressFactory = new Nwn2AddressFactory();

            raiserSlot = new BlockSlot("raiser", raiserFitter);
            raiserSlot.BorderThickness = new Thickness(1);
            raiserSlot.Padding         = new Thickness(4);
            raiserSlot.LayoutTransform = scaleTransform;

            InitializeComponent();

            this.text1.Text = text1;
            this.text2.Text = text2;

            raiserSlot.MoveableChanged += delegate
            {
                OnChanged(new EventArgs());
            };

            mainPanel.Children.Insert(1, raiserSlot);
        }
        /// <summary>
        /// Constructs a new <see cref="Nwn2ParameterlessTrigger"/> instance.
        /// </summary>
        public Nwn2ParameterlessTrigger(string text)
        {
            this.addressFactory = new Nwn2AddressFactory();

            InitializeComponent();

            this.text1.Text = text;
        }
예제 #3
0
        public ScriptHelper(Nwn2TriggerFactory triggerFactory)
        {
            if (triggerFactory == null)
            {
                throw new ArgumentNullException("triggerFactory");
            }

            this.triggerFactory = triggerFactory;
            this.addressFactory = new Nwn2AddressFactory();
            this.session        = new Nwn2Session();
            this.nt             = new NarrativeThreadsHelper();
        }