-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
120 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<UserControl x:Class="ALE_ShipFixer.Control" | ||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
mc:Ignorable="d" | ||
d:DesignHeight="450" d:DesignWidth="800"> | ||
<Grid> | ||
|
||
<Grid.ColumnDefinitions> | ||
<ColumnDefinition Width="Auto" SharedSizeGroup="Labels"/> | ||
<ColumnDefinition Width="*"/> | ||
<ColumnDefinition Width="Auto" SharedSizeGroup="Buttons"/> | ||
</Grid.ColumnDefinitions> | ||
<Grid.RowDefinitions> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="Auto"/> | ||
</Grid.RowDefinitions> | ||
|
||
<TextBlock Grid.Column="0" Grid.Row ="0" VerticalAlignment="Center" Text="ALE Shipfixer" FontWeight="Bold" FontSize="16" Grid.ColumnSpan="2" Margin="5"/> | ||
|
||
<TextBlock Grid.Column="0" Grid.Row ="1" VerticalAlignment="Center" Text="Command cooldown for player (seconds)" Margin="5"/> | ||
<TextBox Name="CommandCooldown" Grid.Column="1" Grid.Row ="1" Grid.ColumnSpan="2" Margin="5" Text="{Binding CooldownInSeconds}"/> | ||
|
||
<TextBlock Grid.Column="0" Grid.Row ="2" VerticalAlignment="Center" Text="Confirmaton cooldown (seconds)" Margin="5"/> | ||
<TextBox Name="ConfirmationCooldown" Grid.Column="1" Grid.Row ="2" Grid.ColumnSpan="2" Margin="5" Text="{Binding ConfirmationInSeconds}"/> | ||
|
||
<Button Grid.Column="2" Grid.Row="3" Content="Save Config" Margin="5" Click="SaveButton_OnClick"></Button> | ||
|
||
<TextBlock Grid.Column="0" Grid.Row ="4" VerticalAlignment="Center" Grid.ColumnSpan="2" Text="Commands" Margin="5" FontWeight="Bold" /> | ||
<TextBlock Grid.Column="0" Grid.Row ="5" VerticalAlignment="Center" Text="!fixship" Margin="5" /> | ||
<TextBlock Grid.Column="1" Grid.Row ="5" VerticalAlignment="Center" Grid.ColumnSpan="2" TextWrapping="Wrap" Text="Cuts and pastes ship you are looking at (accessible to all)" Margin="5"/> | ||
<TextBlock Grid.Column="0" Grid.Row ="6" VerticalAlignment="Center" Text="!fixship <shipname>" Margin="5"/> | ||
<TextBlock Grid.Column="1" Grid.Row ="6" VerticalAlignment="Center" Grid.ColumnSpan="2" TextWrapping="Wrap" Text="Cuts and pastes ship you are looking at by given name (accessible to all)" Margin="5"/> | ||
<TextBlock Grid.Column="0" Grid.Row ="7" VerticalAlignment="Center" Text="!fixshipmod" Margin="5"/> | ||
<TextBlock Grid.Column="1" Grid.Row ="7" VerticalAlignment="Center" Grid.ColumnSpan="2" TextWrapping="Wrap" Text="Cuts and pastes ship you are looking at while ignoring coolodnws (accessible to moderator and above)" Margin="5"/> | ||
<TextBlock Grid.Column="0" Grid.Row ="8" VerticalAlignment="Center" Text="!fixshipmod <shipname>" Margin="5"/> | ||
<TextBlock Grid.Column="1" Grid.Row ="8" VerticalAlignment="Center" Grid.ColumnSpan="2" TextWrapping="Wrap" Text="Cuts and pastes ship by given name while ignoring coolodnws (accessible to moderator and above)" Margin="5"/> | ||
</Grid> | ||
</UserControl> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Text; | ||
using System.Threading.Tasks; | ||
using System.Windows; | ||
using System.Windows.Controls; | ||
using System.Windows.Data; | ||
using System.Windows.Documents; | ||
using System.Windows.Input; | ||
using System.Windows.Media; | ||
using System.Windows.Media.Imaging; | ||
using System.Windows.Navigation; | ||
using System.Windows.Shapes; | ||
|
||
namespace ALE_ShipFixer { | ||
|
||
public partial class Control : UserControl { | ||
|
||
private ShipFixerPlugin Plugin { get; } | ||
|
||
public Control() { | ||
InitializeComponent(); | ||
} | ||
|
||
public Control(ShipFixerPlugin plugin) : this() { | ||
Plugin = plugin; | ||
DataContext = plugin.Config; | ||
} | ||
|
||
private void SaveButton_OnClick(object sender, RoutedEventArgs e) { | ||
Plugin.Save(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters