Exemplo n.º 1
0
        public void BuildDefaultSettings()
        {
            Joypads.Clear();
            JoypadSettings joypadSettings = new JoypadSettings();

            joypadSettings.Port   = 1;
            joypadSettings.Start  = joypadSettings.EncodeKeyboardMapping(Keys.Enter);
            joypadSettings.Select = joypadSettings.EncodeKeyboardMapping(Keys.Tab);
            joypadSettings.A      = joypadSettings.EncodeKeyboardMapping(Keys.Z);
            joypadSettings.B      = joypadSettings.EncodeKeyboardMapping(Keys.X);
            joypadSettings.Up     = joypadSettings.EncodeKeyboardMapping(Keys.Up);
            joypadSettings.Down   = joypadSettings.EncodeKeyboardMapping(Keys.Down);
            joypadSettings.Left   = joypadSettings.EncodeKeyboardMapping(Keys.Left);
            joypadSettings.Right  = joypadSettings.EncodeKeyboardMapping(Keys.Right);

            Joypads.Add(joypadSettings);

            ZapperSettings zapperSettings = new ZapperSettings();

            zapperSettings.Port       = 2;
            zapperSettings.Trigger    = "mouse:left";
            zapperSettings.LightSense = "mouse:cursor";

            Zappers.Add(zapperSettings);
        }
Exemplo n.º 2
0
        public JoypadSettings Duplicate()
        {
            JoypadSettings copy = new JoypadSettings();

            copy.Port   = Port;
            copy.Start  = Start;
            copy.Select = Select;
            copy.A      = A;
            copy.B      = B;
            copy.Left   = Left;
            copy.Right  = Right;
            copy.Up     = Up;
            copy.Down   = Down;
            return(copy);
        }