Optimize UI more and fix some layout weirdness
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
|
||||||
[assembly: AssemblyVersion("1.0.195.514")]
|
[assembly: AssemblyVersion("1.0.198.562")]
|
||||||
[assembly: AssemblyFileVersion("1.0.195.514")]
|
[assembly: AssemblyFileVersion("1.0.198.562")]
|
@@ -1,4 +1,4 @@
|
|||||||
using System.Reflection;
|
using System.Reflection;
|
||||||
|
|
||||||
[assembly: AssemblyVersion("1.0.195.514")]
|
[assembly: AssemblyVersion("1.1.198.562")]
|
||||||
[assembly: AssemblyFileVersion("1.0.195.514")]
|
[assembly: AssemblyFileVersion("1.1.198.562")]
|
@@ -8,7 +8,7 @@ using System.Reflection;
|
|||||||
|
|
||||||
<# var dt = DateTime.Now;
|
<# var dt = DateTime.Now;
|
||||||
int major = 1;
|
int major = 1;
|
||||||
int minor = 0;
|
int minor = 1;
|
||||||
int build = dt.DayOfYear;
|
int build = dt.DayOfYear;
|
||||||
int rev = (int)dt.TimeOfDay.TotalMinutes / 2;
|
int rev = (int)dt.TimeOfDay.TotalMinutes / 2;
|
||||||
#>
|
#>
|
||||||
|
@@ -1,9 +1,6 @@
|
|||||||
using System;
|
using System;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using NLog;
|
|
||||||
using Sandbox.Game.Entities;
|
using Sandbox.Game.Entities;
|
||||||
using Sandbox.Game.Multiplayer;
|
|
||||||
using Sandbox.Game.World;
|
|
||||||
using Sandbox.ModAPI;
|
using Sandbox.ModAPI;
|
||||||
using Torch.Server.ViewModels.Blocks;
|
using Torch.Server.ViewModels.Blocks;
|
||||||
|
|
||||||
|
@@ -5,12 +5,12 @@
|
|||||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||||
xmlns:local="clr-namespace:Torch.Server"
|
xmlns:local="clr-namespace:Torch.Server"
|
||||||
mc:Ignorable="d">
|
mc:Ignorable="d">
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<DockPanel DockPanel.Dock="Bottom">
|
<Grid.RowDefinitions>
|
||||||
<Button x:Name="Send" Content="Send" DockPanel.Dock="Right" Width="50" Margin="5,5,5,5" Click="SendButton_Click"></Button>
|
<RowDefinition/>
|
||||||
<TextBox x:Name="Message" DockPanel.Dock="Left" Margin="5,5,5,5" KeyDown="Message_OnKeyDown"></TextBox>
|
<RowDefinition Height="Auto"/>
|
||||||
</DockPanel>
|
</Grid.RowDefinitions>
|
||||||
<ListView x:Name="ChatItems" ItemsSource="{Binding ChatHistory}" Margin="5,5,5,5">
|
<ListView Grid.Row="0" x:Name="ChatItems" ItemsSource="{Binding ChatHistory}" Margin="5,5,5,5">
|
||||||
<ScrollViewer HorizontalScrollBarVisibility="Disabled"/>
|
<ScrollViewer HorizontalScrollBarVisibility="Disabled"/>
|
||||||
<ListView.ItemTemplate>
|
<ListView.ItemTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
@@ -24,5 +24,13 @@
|
|||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</ListView.ItemTemplate>
|
</ListView.ItemTemplate>
|
||||||
</ListView>
|
</ListView>
|
||||||
</DockPanel>
|
<Grid Grid.Row="1">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Button Grid.Column="1" x:Name="Send" Content="Send" DockPanel.Dock="Right" Width="50" Margin="5,5,5,5" Click="SendButton_Click"></Button>
|
||||||
|
<TextBox Grid.Column="0" x:Name="Message" DockPanel.Dock="Left" Margin="5,5,5,5" KeyDown="Message_OnKeyDown"></TextBox>
|
||||||
|
</Grid>
|
||||||
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
@@ -10,15 +10,27 @@
|
|||||||
<UserControl.DataContext>
|
<UserControl.DataContext>
|
||||||
<viewModels:ConfigDedicatedViewModel />
|
<viewModels:ConfigDedicatedViewModel />
|
||||||
</UserControl.DataContext>
|
</UserControl.DataContext>
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<DockPanel DockPanel.Dock="Top">
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
<RowDefinition/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<DockPanel Grid.Row="0">
|
||||||
<Label Content="World:" DockPanel.Dock="Left" />
|
<Label Content="World:" DockPanel.Dock="Left" />
|
||||||
<Button Content="New World" Margin="3" DockPanel.Dock="Right" Click="NewWorld_OnClick"/>
|
<Button Content="New World" Margin="3" DockPanel.Dock="Right" Click="NewWorld_OnClick"/>
|
||||||
<ComboBox Text="{Binding LoadWorld}" ItemsSource="{Binding WorldPaths}" IsEditable="True" Margin="3" SelectionChanged="Selector_OnSelectionChanged"/>
|
<ComboBox Text="{Binding LoadWorld}" ItemsSource="{Binding WorldPaths}" IsEditable="True" Margin="3" SelectionChanged="Selector_OnSelectionChanged"/>
|
||||||
</DockPanel>
|
</DockPanel>
|
||||||
<DockPanel DockPanel.Dock="Bottom">
|
<Grid Grid.Row="1">
|
||||||
<StackPanel DockPanel.Dock="Left">
|
<Grid.ColumnDefinitions>
|
||||||
<ScrollViewer IsEnabled="True">
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Grid Grid.Column="0">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition/>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<ScrollViewer Grid.Row="0" Margin="3">
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<StackPanel Margin="3" DockPanel.Dock="Left">
|
<StackPanel Margin="3" DockPanel.Dock="Left">
|
||||||
<Label Content="Server Name" />
|
<Label Content="Server Name" />
|
||||||
@@ -37,24 +49,6 @@
|
|||||||
<CheckBox IsChecked="{Binding PauseGameWhenEmpty}" Content="Pause When Empty" Margin="3" />
|
<CheckBox IsChecked="{Binding PauseGameWhenEmpty}" Content="Pause When Empty" Margin="3" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
<StackPanel Margin="3">
|
<StackPanel Margin="3">
|
||||||
<!--
|
|
||||||
<ListBox ItemsSource="{Binding Banned}" Width="130" Margin="3,0,3,3" Height="100"
|
|
||||||
MouseDoubleClick="Banned_OnMouseDoubleClick" /> -->
|
|
||||||
<!--
|
|
||||||
<ListBox ItemsSource="{Binding Administrators}" Width="130" Margin="3,0,3,3" Height="100"
|
|
||||||
MouseDoubleClick="Administrators_OnMouseDoubleClick">
|
|
||||||
<ListBox.ItemTemplate>
|
|
||||||
<DataTemplate>
|
|
||||||
<StackPanel Orientation="Horizontal">
|
|
||||||
<TextBox Text="{Binding SteamId}" Width="100"/>
|
|
||||||
<Label Content="{Binding Name}"/>
|
|
||||||
</StackPanel>
|
|
||||||
</DataTemplate>
|
|
||||||
</ListBox.ItemTemplate>
|
|
||||||
</ListBox> -->
|
|
||||||
<!--
|
|
||||||
<ListBox ItemsSource="{Binding Mods}" Width="130" Margin="3,0,3,3" Height="100"
|
|
||||||
MouseDoubleClick="Mods_OnMouseDoubleClick" /> -->
|
|
||||||
<Label Content="Mods" />
|
<Label Content="Mods" />
|
||||||
<TextBox Text="{Binding Mods}" Margin="3" Height="100" AcceptsReturn="true" VerticalScrollBarVisibility="Auto"/>
|
<TextBox Text="{Binding Mods}" Margin="3" Height="100" AcceptsReturn="true" VerticalScrollBarVisibility="Auto"/>
|
||||||
<Label Content="Administrators" />
|
<Label Content="Administrators" />
|
||||||
@@ -64,20 +58,20 @@
|
|||||||
</StackPanel>
|
</StackPanel>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
<Button Content="Save Config" Margin="3" Click="Save_OnClick" />
|
<Button Grid.Row="1" Content="Save Config" Margin="3" Click="Save_OnClick" />
|
||||||
</StackPanel>
|
</Grid>
|
||||||
<ScrollViewer Margin="3" DockPanel.Dock="Right" IsEnabled="True">
|
<ScrollViewer Grid.Column="1" Margin="3">
|
||||||
<StackPanel DataContext="{Binding SessionSettings}">
|
<StackPanel DataContext="{Binding SessionSettings}">
|
||||||
<Expander Header="Block Limits">
|
<Expander Header="Block Limits">
|
||||||
<StackPanel Margin="10,0,0,0">
|
<StackPanel Margin="10,0,0,0">
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding MaxBlocksPerPlayer}" Margin="3" Width="70" />
|
<TextBox Text="{Binding MaxBlocksPerPlayer}" Margin="3" Width="70" />
|
||||||
<Label Content="Max Blocks Per Player" />
|
<Label Content="Max Blocks Per Player" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding MaxGridSize}" Margin="3" Width="70" />
|
<TextBox Text="{Binding MaxGridSize}" Margin="3" Width="70" />
|
||||||
<Label Content="Max Grid Size" />
|
<Label Content="Max Grid Size" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<Button Content="Add" Margin="3" Click="AddLimit_OnClick" />
|
<Button Content="Add" Margin="3" Click="AddLimit_OnClick" />
|
||||||
<ListView ItemsSource="{Binding BlockLimits}" Margin="3">
|
<ListView ItemsSource="{Binding BlockLimits}" Margin="3">
|
||||||
<ListView.ItemTemplate>
|
<ListView.ItemTemplate>
|
||||||
@@ -94,30 +88,30 @@
|
|||||||
</Expander>
|
</Expander>
|
||||||
<Expander Header="Multipliers">
|
<Expander Header="Multipliers">
|
||||||
<StackPanel Margin="10,0,0,0">
|
<StackPanel Margin="10,0,0,0">
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding InventorySizeMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding InventorySizeMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Inventory Size" />
|
<Label Content="Inventory Size" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding RefinerySpeedMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding RefinerySpeedMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Refinery Speed" />
|
<Label Content="Refinery Speed" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding AssemblerEfficiencyMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding AssemblerEfficiencyMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Assembler Efficiency" />
|
<Label Content="Assembler Efficiency" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding AssemblerSpeedMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding AssemblerSpeedMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Assembler Speed" />
|
<Label Content="Assembler Speed" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding GrinderSpeedMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding GrinderSpeedMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Grinder Speed" />
|
<Label Content="Grinder Speed" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding HackSpeedMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding HackSpeedMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Hacking Speed" />
|
<Label Content="Hacking Speed" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Expander>
|
</Expander>
|
||||||
<Expander Header="NPCs">
|
<Expander Header="NPCs">
|
||||||
@@ -131,14 +125,14 @@
|
|||||||
</Expander>
|
</Expander>
|
||||||
<Expander Header="Environment">
|
<Expander Header="Environment">
|
||||||
<StackPanel Margin="10,0,0,0">
|
<StackPanel Margin="10,0,0,0">
|
||||||
<DockPanel ToolTip="Increases physics precision at the cost of performance.">
|
<StackPanel Orientation="Horizontal" ToolTip="Increases physics precision at the cost of performance.">
|
||||||
<TextBox Text="{Binding PhysicsIterations}" Margin="3" Width="70" />
|
<TextBox Text="{Binding PhysicsIterations}" Margin="3" Width="70" />
|
||||||
<Label Content="Physics Iterations" />
|
<Label Content="Physics Iterations" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding MaxFloatingObjects}" Margin="3" Width="70" />
|
<TextBox Text="{Binding MaxFloatingObjects}" Margin="3" Width="70" />
|
||||||
<Label Content="Max Floating Objects" />
|
<Label Content="Max Floating Objects" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<CheckBox IsChecked="{Binding EnableRealisticSound}" Content="Enable Realistic Sound"
|
<CheckBox IsChecked="{Binding EnableRealisticSound}" Content="Enable Realistic Sound"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding EnableAirtightness}" Content="Enable Airtightness" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableAirtightness}" Content="Enable Airtightness" Margin="3" />
|
||||||
@@ -149,41 +143,41 @@
|
|||||||
<CheckBox IsChecked="{Binding EnableVoxelDestruction}" Content="Enable Voxel Destruction"
|
<CheckBox IsChecked="{Binding EnableVoxelDestruction}" Content="Enable Voxel Destruction"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding EnableSunRotation}" Content="Enable Sun Rotation" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableSunRotation}" Content="Enable Sun Rotation" Margin="3" />
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding SunRotationInterval}" Margin="3" Width="70" />
|
<TextBox Text="{Binding SunRotationInterval}" Margin="3" Width="70" />
|
||||||
<Label Content="Sun Rotation Interval (mins)" />
|
<Label Content="Sun Rotation Interval (mins)" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<CheckBox IsChecked="{Binding EnableFlora}" Content="Enable Flora" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableFlora}" Content="Enable Flora" Margin="3" />
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding FloraDensity}" Margin="3" Width="70" />
|
<TextBox Text="{Binding FloraDensity}" Margin="3" Width="70" />
|
||||||
<Label Content="Flora Density" />
|
<Label Content="Flora Density" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding FloraDensityMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding FloraDensityMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Flora Density Multiplier" />
|
<Label Content="Flora Density Multiplier" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding ViewDistance}" Margin="3" Width="70" />
|
<TextBox Text="{Binding ViewDistance}" Margin="3" Width="70" />
|
||||||
<Label Content="View Distance (meters)" />
|
<Label Content="View Distance (meters)" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding WorldSize}" Margin="3" Width="70" />
|
<TextBox Text="{Binding WorldSize}" Margin="3" Width="70" />
|
||||||
<Label Content="World Size (km)" />
|
<Label Content="World Size (km)" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<ComboBox SelectedItem="{Binding EnvironmentHostility}"
|
<ComboBox SelectedItem="{Binding EnvironmentHostility}"
|
||||||
ItemsSource="{Binding EnvironmentHostilityValues}" Margin="3" Width="100"
|
ItemsSource="{Binding EnvironmentHostilityValues}" Margin="3" Width="100"
|
||||||
DockPanel.Dock="Left" />
|
DockPanel.Dock="Left" />
|
||||||
<Label Content="Environment Hostility" />
|
<Label Content="Environment Hostility" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Expander>
|
</Expander>
|
||||||
<Expander Header="Players">
|
<Expander Header="Players">
|
||||||
<StackPanel Margin="10,0,0,0">
|
<StackPanel Margin="10,0,0,0">
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding MaxPlayers}" Margin="3" Width="70" />
|
<TextBox Text="{Binding MaxPlayers}" Margin="3" Width="70" />
|
||||||
<Label Content="Max Players" />
|
<Label Content="Max Players" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<CheckBox IsChecked="{Binding EnableThirdPerson}" Content="Enable 3rd Person Camera"
|
<CheckBox IsChecked="{Binding EnableThirdPerson}" Content="Enable 3rd Person Camera"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding EnableJetpack}" Content="Enable Jetpack" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableJetpack}" Content="Enable Jetpack" Margin="3" />
|
||||||
@@ -191,20 +185,20 @@
|
|||||||
<CheckBox IsChecked="{Binding EnableCopyPaste}" Content="Enable Copy/Paste" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableCopyPaste}" Content="Enable Copy/Paste" Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding ShowPlayerNamesOnHud}" Content="Show Player Names on HUD"
|
<CheckBox IsChecked="{Binding ShowPlayerNamesOnHud}" Content="Show Player Names on HUD"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding SpawnTimeMultiplier}" Margin="3" Width="70" />
|
<TextBox Text="{Binding SpawnTimeMultiplier}" Margin="3" Width="70" />
|
||||||
<Label Content="Respawn Time Multiplier" />
|
<Label Content="Respawn Time Multiplier" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<CheckBox IsChecked="{Binding ResetOwnership}" Content="Reset Ownership" Margin="3" />
|
<CheckBox IsChecked="{Binding ResetOwnership}" Content="Reset Ownership" Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding SpawnWithTools}" Content="Spawn With Tools" Margin="3" />
|
<CheckBox IsChecked="{Binding SpawnWithTools}" Content="Spawn With Tools" Margin="3" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Expander>
|
</Expander>
|
||||||
<Expander Header="Miscellaneous">
|
<Expander Header="Miscellaneous">
|
||||||
<StackPanel Margin="10,0,0,0">
|
<StackPanel Margin="10,0,0,0">
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding AutosaveInterval}" Margin="3" Width="70" />
|
<TextBox Text="{Binding AutosaveInterval}" Margin="3" Width="70" />
|
||||||
<Label Content="Autosave Interval (minutes)" />
|
<Label Content="Autosave Interval (minutes)" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<CheckBox IsChecked="{Binding EnableConvertToStation}" Content="Enable Convert to Station"
|
<CheckBox IsChecked="{Binding EnableConvertToStation}" Content="Enable Convert to Station"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
|
|
||||||
@@ -223,19 +217,19 @@
|
|||||||
<CheckBox IsChecked="{Binding EnableWeapons}" Content="Enable Weapons" Margin="3" />
|
<CheckBox IsChecked="{Binding EnableWeapons}" Content="Enable Weapons" Margin="3" />
|
||||||
<CheckBox IsChecked="{Binding EnableIngameScripts}" Content="Enable Ingame Scripts"
|
<CheckBox IsChecked="{Binding EnableIngameScripts}" Content="Enable Ingame Scripts"
|
||||||
Margin="3" />
|
Margin="3" />
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<ComboBox SelectedItem="{Binding GameMode}" ItemsSource="{Binding GameModeValues}"
|
<ComboBox SelectedItem="{Binding GameMode}" ItemsSource="{Binding GameModeValues}"
|
||||||
Margin="3" Width="100" DockPanel.Dock="Left" />
|
Margin="3" Width="100" DockPanel.Dock="Left" />
|
||||||
<Label Content="Game Mode" />
|
<Label Content="Game Mode" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
<DockPanel>
|
<StackPanel Orientation="Horizontal">
|
||||||
<TextBox Text="{Binding MaxBackupSaves}" Margin="3" Width="70" />
|
<TextBox Text="{Binding MaxBackupSaves}" Margin="3" Width="70" />
|
||||||
<Label Content="Max Backup Saves" />
|
<Label Content="Max Backup Saves" />
|
||||||
</DockPanel>
|
</StackPanel>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Expander>
|
</Expander>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</ScrollViewer>
|
</ScrollViewer>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
@@ -9,8 +9,12 @@
|
|||||||
<UserControl.DataContext>
|
<UserControl.DataContext>
|
||||||
<blocks:BlockViewModel />
|
<blocks:BlockViewModel />
|
||||||
</UserControl.DataContext>
|
</UserControl.DataContext>
|
||||||
<DockPanel x:Name="Stack" Margin="3">
|
<Grid Margin="3">
|
||||||
<StackPanel DockPanel.Dock="Top">
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
<RowDefinition/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<StackPanel Grid.Row="0">
|
||||||
<Label Content="{Binding FullName}" FontSize="16" />
|
<Label Content="{Binding FullName}" FontSize="16" />
|
||||||
<StackPanel Orientation="Horizontal">
|
<StackPanel Orientation="Horizontal">
|
||||||
<Label Content="Built By: "/>
|
<Label Content="Built By: "/>
|
||||||
@@ -18,7 +22,7 @@
|
|||||||
</StackPanel>
|
</StackPanel>
|
||||||
<Label Content="Properties"/>
|
<Label Content="Properties"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
<ListView ItemsSource="{Binding Properties}" Margin="3" IsEnabled="True" DockPanel.Dock="Bottom">
|
<ListView Grid.Row="1" ItemsSource="{Binding Properties}" Margin="3" IsEnabled="True">
|
||||||
<ListView.ItemTemplate>
|
<ListView.ItemTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<local:PropertyView />
|
<local:PropertyView />
|
||||||
@@ -35,5 +39,5 @@
|
|||||||
</Style>
|
</Style>
|
||||||
</ListView.ItemContainerStyle>
|
</ListView.ItemContainerStyle>
|
||||||
</ListView>
|
</ListView>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
@@ -10,13 +10,17 @@
|
|||||||
<UserControl.Resources>
|
<UserControl.Resources>
|
||||||
<converters:StringIdConverter x:Key="StringIdConverter"/>
|
<converters:StringIdConverter x:Key="StringIdConverter"/>
|
||||||
</UserControl.Resources>
|
</UserControl.Resources>
|
||||||
<DockPanel x:Name="Dock">
|
<Grid>
|
||||||
<Label x:Name="Label" Width="150" VerticalAlignment="Center" DockPanel.Dock="Left">
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Label Grid.Column="0" x:Name="Label" Width="150" VerticalAlignment="Center">
|
||||||
<Label.Content>
|
<Label.Content>
|
||||||
<TextBlock Text="{Binding Name, StringFormat={}{0}: }" />
|
<TextBlock Text="{Binding Name, StringFormat={}{0}: }" />
|
||||||
</Label.Content>
|
</Label.Content>
|
||||||
</Label>
|
</Label>
|
||||||
<Frame x:Name="Frame" DockPanel.Dock="Right" NavigationUIVisibility="Hidden"/>
|
<Frame Grid.Column="1" x:Name="Frame" NavigationUIVisibility="Hidden"/>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|
||||||
|
@@ -32,10 +32,10 @@ namespace Torch.Server.Views.Blocks
|
|||||||
{
|
{
|
||||||
switch (args.NewValue)
|
switch (args.NewValue)
|
||||||
{
|
{
|
||||||
case PropertyViewModel<bool> vmBool:
|
case PropertyViewModel<bool> _:
|
||||||
InitBool();
|
InitBool();
|
||||||
break;
|
break;
|
||||||
case PropertyViewModel<StringBuilder> vmSb:
|
case PropertyViewModel<StringBuilder> _:
|
||||||
InitStringBuilder();
|
InitStringBuilder();
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@@ -8,14 +8,17 @@
|
|||||||
xmlns:entities="clr-namespace:Torch.Server.ViewModels.Entities"
|
xmlns:entities="clr-namespace:Torch.Server.ViewModels.Entities"
|
||||||
xmlns:blocks="clr-namespace:Torch.Server.ViewModels.Blocks"
|
xmlns:blocks="clr-namespace:Torch.Server.ViewModels.Blocks"
|
||||||
mc:Ignorable="d">
|
mc:Ignorable="d">
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<DockPanel DockPanel.Dock="Left">
|
<Grid.ColumnDefinitions>
|
||||||
<StackPanel DockPanel.Dock="Bottom">
|
<ColumnDefinition/>
|
||||||
<Button Content="Delete" Click="Delete_OnClick" IsEnabled="{Binding CurrentEntity.CanDelete}"
|
<ColumnDefinition MinWidth="300" Width="Auto"/>
|
||||||
Margin="3" />
|
</Grid.ColumnDefinitions>
|
||||||
<Button Content="Stop" Click="Stop_OnClick" IsEnabled="{Binding CurrentEntity.CanStop}" Margin="3" />
|
<Grid Grid.Column="0">
|
||||||
</StackPanel>
|
<Grid.RowDefinitions>
|
||||||
<TreeView Width="300" Margin="3" DockPanel.Dock="Top" SelectedItemChanged="TreeView_OnSelectedItemChanged" TreeViewItem.Expanded="TreeViewItem_OnExpanded">
|
<RowDefinition/>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<TreeView Grid.Row="0" Margin="3" DockPanel.Dock="Top" SelectedItemChanged="TreeView_OnSelectedItemChanged" TreeViewItem.Expanded="TreeViewItem_OnExpanded">
|
||||||
<TreeView.Resources>
|
<TreeView.Resources>
|
||||||
<HierarchicalDataTemplate DataType="{x:Type entities:GridViewModel}" ItemsSource="{Binding Blocks}">
|
<HierarchicalDataTemplate DataType="{x:Type entities:GridViewModel}" ItemsSource="{Binding Blocks}">
|
||||||
<TextBlock Text="{Binding DescriptiveName}" />
|
<TextBlock Text="{Binding DescriptiveName}" />
|
||||||
@@ -63,7 +66,12 @@
|
|||||||
</TreeViewItem.ItemTemplate>
|
</TreeViewItem.ItemTemplate>
|
||||||
</TreeViewItem>
|
</TreeViewItem>
|
||||||
</TreeView>
|
</TreeView>
|
||||||
</DockPanel>
|
<StackPanel Grid.Row="1" DockPanel.Dock="Bottom">
|
||||||
<Frame x:Name="EditorFrame" Margin="3" NavigationUIVisibility="Hidden" />
|
<Button Content="Delete" Click="Delete_OnClick" IsEnabled="{Binding CurrentEntity.CanDelete}"
|
||||||
</DockPanel>
|
Margin="3" />
|
||||||
|
<Button Content="Stop" Click="Stop_OnClick" IsEnabled="{Binding CurrentEntity.CanStop}" Margin="3" />
|
||||||
|
</StackPanel>
|
||||||
|
</Grid>
|
||||||
|
<Frame Grid.Column="1" x:Name="EditorFrame" Margin="3" NavigationUIVisibility="Hidden" />
|
||||||
|
</Grid>
|
||||||
</UserControl>
|
</UserControl>
|
@@ -10,21 +10,26 @@
|
|||||||
<UserControl.DataContext>
|
<UserControl.DataContext>
|
||||||
<viewModels:PluginManagerViewModel/>
|
<viewModels:PluginManagerViewModel/>
|
||||||
</UserControl.DataContext>
|
</UserControl.DataContext>
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<DockPanel>
|
<Grid.ColumnDefinitions>
|
||||||
<Button Content="Open Folder" Margin="3" DockPanel.Dock="Bottom" IsEnabled="false"></Button>
|
<ColumnDefinition Width="150"/>
|
||||||
<ListView Width="150" ItemsSource="{Binding Plugins}" SelectedItem="{Binding SelectedPlugin}" Margin="3">
|
<ColumnDefinition/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Grid Grid.Column="0">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition/>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<ListView Grid.Row="0" ItemsSource="{Binding Plugins}" SelectedItem="{Binding SelectedPlugin}" Margin="3">
|
||||||
<ListView.ItemTemplate>
|
<ListView.ItemTemplate>
|
||||||
<DataTemplate>
|
<DataTemplate>
|
||||||
<TextBlock Text="{Binding Name}"/>
|
<TextBlock Text="{Binding Name}"/>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</ListView.ItemTemplate>
|
</ListView.ItemTemplate>
|
||||||
</ListView>
|
</ListView>
|
||||||
</DockPanel>
|
<Button Grid.Row="1" Content="Open Folder" Margin="3" DockPanel.Dock="Bottom" IsEnabled="false"/>
|
||||||
<StackPanel Margin="3">
|
</Grid>
|
||||||
<Label Content="{Binding SelectedPlugin.Name}" FontSize="16"/>
|
<Frame Grid.Column="1" NavigationUIVisibility="Hidden" Content="{Binding SelectedPlugin.Control}"/>
|
||||||
<Frame NavigationUIVisibility="Hidden" Content="{Binding SelectedPlugin.Control}"/>
|
</Grid>
|
||||||
</StackPanel>
|
|
||||||
</DockPanel>
|
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|
||||||
|
@@ -9,12 +9,16 @@
|
|||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
Title="Torch">
|
Title="Torch">
|
||||||
<Window.Resources>
|
<Window.Resources>
|
||||||
<converters:InverseBooleanConverter x:Key="inverseBool"/>
|
<converters:InverseBooleanConverter x:Key="InverseBool"/>
|
||||||
</Window.Resources>
|
</Window.Resources>
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<StackPanel DockPanel.Dock="Top" Margin="5,5,5,5" Orientation="Horizontal">
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="Auto"/>
|
||||||
|
<RowDefinition/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<StackPanel Grid.Row="0" Margin="5,5,5,5" Orientation="Horizontal">
|
||||||
<Button x:Name="BtnStart" Content="Start" Height="24" Width="75" Margin="5,0,5,0"
|
<Button x:Name="BtnStart" Content="Start" Height="24" Width="75" Margin="5,0,5,0"
|
||||||
HorizontalAlignment="Left" Click="BtnStart_Click" IsDefault="True" IsEnabled="{Binding IsRunning, Converter={StaticResource inverseBool}}"/>
|
HorizontalAlignment="Left" Click="BtnStart_Click" IsDefault="True" IsEnabled="{Binding IsRunning, Converter={StaticResource InverseBool}}"/>
|
||||||
<Button x:Name="BtnStop" Content="Stop" Height="24" Width="75" Margin="5,0,5,0" HorizontalAlignment="Left"
|
<Button x:Name="BtnStop" Content="Stop" Height="24" Width="75" Margin="5,0,5,0" HorizontalAlignment="Left"
|
||||||
Click="BtnStop_Click" IsEnabled="{Binding IsRunning}" />
|
Click="BtnStop_Click" IsEnabled="{Binding IsRunning}" />
|
||||||
<Label>
|
<Label>
|
||||||
@@ -33,22 +37,34 @@
|
|||||||
</Label.Content>
|
</Label.Content>
|
||||||
</Label>
|
</Label>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
<TabControl x:Name="TabControl" DockPanel.Dock="Bottom" Margin="5,0,5,5">
|
<TabControl Grid.Row="1" Height="Auto" x:Name="TabControl" Margin="5,0,5,5">
|
||||||
<TabItem Header="Configuration">
|
<TabItem Header="Configuration">
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<DockPanel DockPanel.Dock="Top">
|
<Grid.RowDefinitions>
|
||||||
<Label Content="Instance Path: " Margin="3" />
|
<RowDefinition Height="Auto"/>
|
||||||
<TextBox x:Name="InstancePathBox" Margin="3" Height="20"
|
<RowDefinition/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
<Grid Grid.Row="0">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="Auto"/>
|
||||||
|
<ColumnDefinition/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Label Grid.Column="0" Content="Instance Path: " Margin="3" />
|
||||||
|
<TextBox Grid.Column="1" x:Name="InstancePathBox" Margin="3" Height="20"
|
||||||
TextChanged="InstancePathBox_OnTextChanged" IsEnabled="False" />
|
TextChanged="InstancePathBox_OnTextChanged" IsEnabled="False" />
|
||||||
</DockPanel>
|
</Grid>
|
||||||
<views:ConfigControl x:Name="ConfigControl" Margin="3" DockPanel.Dock="Bottom" IsEnabled="{Binding IsRunning, Converter={StaticResource inverseBool}}"/>
|
<views:ConfigControl Grid.Row="1" x:Name="ConfigControl" Margin="3" DockPanel.Dock="Bottom" IsEnabled="{Binding IsRunning, Converter={StaticResource InverseBool}}"/>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</TabItem>
|
</TabItem>
|
||||||
<TabItem Header="Chat/Players">
|
<TabItem Header="Chat/Players">
|
||||||
<DockPanel>
|
<Grid>
|
||||||
<local:PlayerListControl x:Name="PlayerList" DockPanel.Dock="Right" Width="250" />
|
<Grid.ColumnDefinitions>
|
||||||
<local:ChatControl x:Name="Chat" IsEnabled="{Binding IsRunning}"/>
|
<ColumnDefinition/>
|
||||||
</DockPanel>
|
<ColumnDefinition Width="250"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<local:ChatControl Grid.Column="0" x:Name="Chat" IsEnabled="{Binding IsRunning}"/>
|
||||||
|
<local:PlayerListControl Grid.Column="1" x:Name="PlayerList" DockPanel.Dock="Right"/>
|
||||||
|
</Grid>
|
||||||
</TabItem>
|
</TabItem>
|
||||||
<TabItem Header="Entity Manager">
|
<TabItem Header="Entity Manager">
|
||||||
<views:EntitiesControl />
|
<views:EntitiesControl />
|
||||||
@@ -57,5 +73,5 @@
|
|||||||
<views:PluginsControl x:Name="Plugins" />
|
<views:PluginsControl x:Name="Plugins" />
|
||||||
</TabItem>
|
</TabItem>
|
||||||
</TabControl>
|
</TabControl>
|
||||||
</DockPanel>
|
</Grid>
|
||||||
</Window>
|
</Window>
|
Reference in New Issue
Block a user