protected virtual void ServiceButton_OnMouseClick(BaseScreenComponent sender, Vector2 position) { DaggerfallUI.Instance.PlayOneShot(SoundClips.ButtonClick); CloseWindow(); // Use a registered custom service method Guilds.Services.CustomMerchantService customMerchantService; if (Guilds.Services.GetCustomMerchantService(merchantNPC.Data.factionID, out customMerchantService)) { customMerchantService(this); } else { switch (currentService) { default: case Services.Sell: uiManager.PushWindow(UIWindowFactory.GetInstanceWithArgs(UIWindowType.Trade, new object[] { uiManager, this, DaggerfallTradeWindow.WindowModes.Sell, null })); break; case Services.Banking: uiManager.PushWindow(UIWindowFactory.GetInstance(UIWindowType.Banking, uiManager, this)); break; } } }
protected override void Setup() { // Load all the textures used by spell maker window LoadTextures(); // Always dim background ParentPanel.BackgroundColor = ScreenDimColor; // Setup native panel background NativePanel.BackgroundColor = new Color(0, 0, 0, 0.75f); NativePanel.BackgroundTexture = baseTexture; // Setup controls SetupLabels(); SetupButtons(); SetupPickers(); SetIcon(selectedIcon); SetStatusLabels(); // Setup effect editor window effectEditor = (DaggerfallEffectSettingsEditorWindow)UIWindowFactory.GetInstanceWithArgs(UIWindowType.EffectSettingsEditor, new object[] { uiManager, this }); effectEditor.OnSettingsChanged += EffectEditor_OnSettingsChanged; effectEditor.OnClose += EffectEditor_OnClose; // Setup icon picker iconPicker = (SpellIconPickerWindow)UIWindowFactory.GetInstance(UIWindowType.SpellIconPicker, uiManager, this); iconPicker.OnClose += IconPicker_OnClose; }
void StartNewGame() { uiManager.PushWindow(UIWindowFactory.GetInstance(UIWindowType.StartNewGameWizard, uiManager)); }
private void SwitchClassicButton_OnMouseClick(BaseScreenComponent sender, Vector2 position) { uiManager.PushWindow(UIWindowFactory.GetInstance(UIWindowType.LoadClassicGame, uiManager, null)); }