Exemplo n.º 1
0
        private void Beacon(KeyAndState key)
        {
            var position = this.camera.Position;

            Observable
                .Return(0, this.Engine.InputScheduler).Delay(TimeSpan.FromSeconds(10))
                .Subscribe(
                    (x) => this.camera.Position = position
                );
        }
Exemplo n.º 2
0
        private void SelectPrevButton(KeyAndState kas)
        {
            var button = this.currentButton.First();

            var index = buttons.IndexOf(button);

            if(--index < 0)
            {
                index = buttons.Count - 1;
            }

            this.oldButton.OnNext(button);
            this.currentButton.OnNext(buttons[index]);
        }
Exemplo n.º 3
0
        private void SelectNextButton(KeyAndState kas)
        {
            var button = this.currentButton.First();

            var index = buttons.IndexOf(button);

            if (++index >= buttons.Count)
            {
                index = 0;
            }

            this.oldButton.OnNext(button);
            this.currentButton.OnNext(buttons[index]);
        }