mirror of
https://github.com/alexandria121/new.git
synced 2026-07-01 09:24:24 -04:00
Refactor GameView and update related resources
- Updated GameView.xaml to modify event handling and bindings for equipment slots. - Changed references in GameView.g.cs to reflect updated XAML structure. - Updated sourcelink and assembly info files for consistency. - Modified binary files related to the UI project, including DLLs and caches. - Added a temporary backup of the old GameView.xaml for reference.
This commit is contained in:
@@ -81,9 +81,19 @@ public class OpponentAI
|
||||
}
|
||||
}
|
||||
|
||||
// Return proper decision type for equipment
|
||||
var decisionType = randomCard.Type switch
|
||||
{
|
||||
CardType.Weapon => AIDecisionType.PlayWeapon,
|
||||
CardType.Armor => AIDecisionType.PlayArtifact,
|
||||
CardType.Artifact => AIDecisionType.PlayArtifact,
|
||||
CardType.Event => AIDecisionType.PlaySpell,
|
||||
_ => AIDecisionType.PlaySpell
|
||||
};
|
||||
|
||||
return new AIDecision
|
||||
{
|
||||
Type = AIDecisionType.PlaySpell,
|
||||
Type = decisionType,
|
||||
CardId = randomCard.Id
|
||||
};
|
||||
}
|
||||
@@ -126,9 +136,19 @@ public class OpponentAI
|
||||
};
|
||||
}
|
||||
|
||||
// Return proper decision type for equipment
|
||||
var journeymanDecisionType = bestCard.Type switch
|
||||
{
|
||||
CardType.Weapon => AIDecisionType.PlayWeapon,
|
||||
CardType.Armor => AIDecisionType.PlayArtifact,
|
||||
CardType.Artifact => AIDecisionType.PlayArtifact,
|
||||
CardType.Event => AIDecisionType.PlaySpell,
|
||||
_ => AIDecisionType.PlaySpell
|
||||
};
|
||||
|
||||
return new AIDecision
|
||||
{
|
||||
Type = AIDecisionType.PlaySpell,
|
||||
Type = journeymanDecisionType,
|
||||
CardId = bestCard.Id
|
||||
};
|
||||
}
|
||||
@@ -171,9 +191,18 @@ public class OpponentAI
|
||||
};
|
||||
}
|
||||
|
||||
var decisionType = bestCard.Type switch
|
||||
{
|
||||
CardType.Weapon => AIDecisionType.PlayWeapon,
|
||||
CardType.Armor => AIDecisionType.PlayArtifact,
|
||||
CardType.Artifact => AIDecisionType.PlayArtifact,
|
||||
CardType.Event => AIDecisionType.PlaySpell,
|
||||
_ => AIDecisionType.PlaySpell
|
||||
};
|
||||
|
||||
return new AIDecision
|
||||
{
|
||||
Type = bestCard.Type == CardType.Weapon ? AIDecisionType.PlayWeapon : AIDecisionType.PlaySpell,
|
||||
Type = decisionType,
|
||||
CardId = bestCard.Id
|
||||
};
|
||||
}
|
||||
|
||||
Binary file not shown.
Binary file not shown.
+1
-1
@@ -13,7 +13,7 @@ using System.Reflection;
|
||||
[assembly: System.Reflection.AssemblyCompanyAttribute("MagicalDeckbuilder.Shared")]
|
||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+e36147670d0b5d9de9af88c354d731309a75bbcb")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+b964d2efdff64eea1fe8e481b408f2839d79781e")]
|
||||
[assembly: System.Reflection.AssemblyProductAttribute("MagicalDeckbuilder.Shared")]
|
||||
[assembly: System.Reflection.AssemblyTitleAttribute("MagicalDeckbuilder.Shared")]
|
||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||
|
||||
+1
-1
@@ -1 +1 @@
|
||||
f3cd84ef00a45e933b8d1d8cbbf0acd01412fe59bc0e36926555e87bbcd6af3e
|
||||
ff25f90c39331fbb5aa6538efbb0f6352bcfa29099126552fa54f8fe361006c8
|
||||
|
||||
Binary file not shown.
Binary file not shown.
+1
-1
@@ -1 +1 @@
|
||||
{"documents":{"C:\\Users\\atw61\\OneDrive\\Desktop\\new\\*":"https://raw.githubusercontent.com/alexandria121/new/e36147670d0b5d9de9af88c354d731309a75bbcb/*"}}
|
||||
{"documents":{"C:\\Users\\atw61\\OneDrive\\Desktop\\new\\*":"https://raw.githubusercontent.com/alexandria121/new/b964d2efdff64eea1fe8e481b408f2839d79781e/*"}}
|
||||
Binary file not shown.
BIN
Binary file not shown.
@@ -10,6 +10,7 @@
|
||||
<Color x:Key="AccentColor">#FF6B35</Color>
|
||||
<Color x:Key="TextPrimaryColor">#FFFFFF</Color>
|
||||
<Color x:Key="TextSecondaryColor">#B0B0B0</Color>
|
||||
<Color x:Key="TextTertiaryColor">#707070</Color>
|
||||
<Color x:Key="SuccessColor">#4CAF50</Color>
|
||||
<Color x:Key="WarningColor">#FF9800</Color>
|
||||
<Color x:Key="DangerColor">#F44336</Color>
|
||||
@@ -24,6 +25,7 @@
|
||||
<SolidColorBrush x:Key="AccentBrush" Color="{StaticResource AccentColor}"/>
|
||||
<SolidColorBrush x:Key="TextPrimaryBrush" Color="{StaticResource TextPrimaryColor}"/>
|
||||
<SolidColorBrush x:Key="TextSecondaryBrush" Color="{StaticResource TextSecondaryColor}"/>
|
||||
<SolidColorBrush x:Key="TextTertiaryBrush" Color="{StaticResource TextTertiaryColor}"/>
|
||||
<SolidColorBrush x:Key="SuccessBrush" Color="{StaticResource SuccessColor}"/>
|
||||
<SolidColorBrush x:Key="WarningBrush" Color="{StaticResource WarningColor}"/>
|
||||
<SolidColorBrush x:Key="DangerBrush" Color="{StaticResource DangerColor}"/>
|
||||
|
||||
@@ -303,6 +303,55 @@ public class MainViewModel : ViewModelBase
|
||||
public System.Collections.ObjectModel.ObservableCollection<CardViewModel?> PlayerArtifactSlotsObs { get; } = new();
|
||||
public System.Collections.ObjectModel.ObservableCollection<CardViewModel?> OpponentArtifactSlotsObs { get; } = new();
|
||||
|
||||
// Battle log for game events
|
||||
public ObservableCollection<BattleLogEntry> BattleLog { get; } = new();
|
||||
|
||||
/// <summary>
|
||||
/// Represents a single entry in the battle log
|
||||
/// </summary>
|
||||
public class BattleLogEntry
|
||||
{
|
||||
public int Turn { get; set; }
|
||||
public string Message { get; set; } = "";
|
||||
public BattleLogEntryType Type { get; set; }
|
||||
public DateTime Timestamp { get; set; }
|
||||
|
||||
public string FormattedEntry => $"[Turn {Turn}] {Message}";
|
||||
}
|
||||
|
||||
public enum BattleLogEntryType
|
||||
{
|
||||
Info,
|
||||
PlayerAction,
|
||||
OpponentAction,
|
||||
Damage,
|
||||
CreatureDeath,
|
||||
Spell,
|
||||
Combat
|
||||
}
|
||||
|
||||
private void AddBattleLog(string message, BattleLogEntryType type = BattleLogEntryType.Info)
|
||||
{
|
||||
var entry = new BattleLogEntry
|
||||
{
|
||||
Turn = TurnCount,
|
||||
Message = message,
|
||||
Type = type,
|
||||
Timestamp = DateTime.Now
|
||||
};
|
||||
BattleLog.Add(entry);
|
||||
LogToFile($"[BattleLog] Turn {TurnCount}: {message}");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Clear the battle log at the start of a new game
|
||||
/// </summary>
|
||||
public void ClearBattleLog()
|
||||
{
|
||||
BattleLog.Clear();
|
||||
AddBattleLog("Game started!", BattleLogEntryType.Info);
|
||||
}
|
||||
|
||||
// Debug file logging
|
||||
private static readonly string DebugLogPath = System.IO.Path.Combine(
|
||||
Environment.GetFolderPath(Environment.SpecialFolder.Desktop),
|
||||
@@ -563,6 +612,38 @@ public class MainViewModel : ViewModelBase
|
||||
FieldSlots[i] = null;
|
||||
}
|
||||
|
||||
// Clear artifact slots
|
||||
for (int i = 0; i < _opponentArtifactSlots.Length; i++)
|
||||
{
|
||||
_opponentArtifactSlots[i] = null;
|
||||
}
|
||||
for (int i = 0; i < _playerArtifactSlots.Length; i++)
|
||||
{
|
||||
_playerArtifactSlots[i] = null;
|
||||
}
|
||||
OpponentArtifactSlotsObs.Clear();
|
||||
PlayerArtifactSlotsObs.Clear();
|
||||
|
||||
// Clear equipment slots
|
||||
OpponentWeapon = null;
|
||||
OpponentArmor = null;
|
||||
OpponentEventSlot = null;
|
||||
PlayerWeapon = null;
|
||||
PlayerArmor = null;
|
||||
PlayerEventSlot = null;
|
||||
|
||||
// Notify UI of artifact slot changes
|
||||
OnPropertyChanged(nameof(OpponentArtifactSlots));
|
||||
OnPropertyChanged(nameof(PlayerArtifactSlots));
|
||||
OnPropertyChanged(nameof(OpponentArtifactSlotsObs));
|
||||
OnPropertyChanged(nameof(PlayerArtifactSlotsObs));
|
||||
OnPropertyChanged(nameof(OpponentWeapon));
|
||||
OnPropertyChanged(nameof(OpponentArmor));
|
||||
OnPropertyChanged(nameof(OpponentEventSlot));
|
||||
OnPropertyChanged(nameof(PlayerWeapon));
|
||||
OnPropertyChanged(nameof(PlayerArmor));
|
||||
OnPropertyChanged(nameof(PlayerEventSlot));
|
||||
|
||||
// Refresh cached slot arrays
|
||||
RefreshCreatureSlotCaches();
|
||||
LogToFile("[InitializeGame] Calling OnPropertyChanged for slots");
|
||||
@@ -620,6 +701,9 @@ public class MainViewModel : ViewModelBase
|
||||
TurnCount = 1;
|
||||
IsPlayerTurn = true;
|
||||
StatusMessage = "";
|
||||
|
||||
// Clear and initialize battle log
|
||||
ClearBattleLog();
|
||||
|
||||
// Refresh UI bindings
|
||||
RefreshHand();
|
||||
@@ -755,6 +839,10 @@ public class MainViewModel : ViewModelBase
|
||||
// Update status message
|
||||
StatusMessage = $"Opponent summons {card.Name}!";
|
||||
|
||||
// Add to battle log
|
||||
int displaySlot = decision.SlotIndex.Value + 1;
|
||||
AddBattleLog($"Opponent summons {card.Name} to slot {displaySlot}", BattleLogEntryType.OpponentAction);
|
||||
|
||||
RefreshCreatureSlotCaches();
|
||||
OnPropertyChanged(nameof(FieldSlots));
|
||||
OnPropertyChanged(nameof(OpponentCreatureSlots));
|
||||
@@ -773,22 +861,136 @@ public class MainViewModel : ViewModelBase
|
||||
break;
|
||||
|
||||
case OpponentAI.AIDecisionType.PlaySpell:
|
||||
if (decision.CardId != null)
|
||||
{
|
||||
var card = OpponentDeck.Hand.FirstOrDefault(c => c.Id == decision.CardId);
|
||||
if (card != null && card.ManaCost <= opponentMana)
|
||||
{
|
||||
// Check if this is an Event card that should go to the event slot
|
||||
if (card.Type == CardType.Event)
|
||||
{
|
||||
var cardVm = new CardViewModel(card);
|
||||
OpponentDeck.PlayCard(card.Id);
|
||||
opponentMana -= cardVm.ManaCost;
|
||||
OpponentEventSlot = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Plays event: {cardVm.Name}");
|
||||
StatusMessage = $"Opponent plays {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent plays {cardVm.Name}", BattleLogEntryType.Spell);
|
||||
OnPropertyChanged(nameof(OpponentEventSlot));
|
||||
}
|
||||
else
|
||||
{
|
||||
// Regular spell/enchantment - apply effects
|
||||
OpponentDeck.PlayCard(card.Id);
|
||||
opponentMana -= card.ManaCost;
|
||||
LogToFile($"[ExecuteOpponentTurn] Playing {card.Name} (type={card.Type})");
|
||||
|
||||
// Update status message to show opponent action
|
||||
string cardTypeStr = card.Type.ToString();
|
||||
StatusMessage = $"Opponent plays {card.Name}!";
|
||||
|
||||
// Add to battle log
|
||||
AddBattleLog($"Opponent plays {card.Name} ({cardTypeStr})", BattleLogEntryType.Spell);
|
||||
|
||||
ApplyOpponentCardEffects(card);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
keepPlaying = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
keepPlaying = false;
|
||||
}
|
||||
break;
|
||||
|
||||
case OpponentAI.AIDecisionType.PlayWeapon:
|
||||
if (decision.CardId != null)
|
||||
{
|
||||
var card = OpponentDeck.Hand.FirstOrDefault(c => c.Id == decision.CardId);
|
||||
if (card != null && card.ManaCost <= opponentMana)
|
||||
{
|
||||
var cardVm = new CardViewModel(card);
|
||||
OpponentDeck.PlayCard(cardVm.Id);
|
||||
opponentMana -= cardVm.ManaCost;
|
||||
OpponentWeapon = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Equipped weapon: {cardVm.Name}");
|
||||
|
||||
StatusMessage = $"Opponent equips {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent equips {cardVm.Name}", BattleLogEntryType.OpponentAction);
|
||||
OnPropertyChanged(nameof(OpponentWeapon));
|
||||
}
|
||||
else
|
||||
{
|
||||
keepPlaying = false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
keepPlaying = false;
|
||||
}
|
||||
break;
|
||||
|
||||
case OpponentAI.AIDecisionType.PlayArtifact:
|
||||
if (decision.CardId != null)
|
||||
{
|
||||
var card = OpponentDeck.Hand.FirstOrDefault(c => c.Id == decision.CardId);
|
||||
if (card != null && card.ManaCost <= opponentMana)
|
||||
{
|
||||
OpponentDeck.PlayCard(card.Id);
|
||||
opponentMana -= card.ManaCost;
|
||||
LogToFile($"[ExecuteOpponentTurn] Playing {card.Name} (type={card.Type})");
|
||||
var cardVm = new CardViewModel(card);
|
||||
OpponentDeck.PlayCard(cardVm.Id);
|
||||
opponentMana -= cardVm.ManaCost;
|
||||
|
||||
// Update status message to show opponent action
|
||||
string cardTypeStr = card.Type.ToString();
|
||||
StatusMessage = $"Opponent plays {card.Name}!";
|
||||
|
||||
ApplyOpponentCardEffects(card);
|
||||
// Handle based on card type
|
||||
if (cardVm.Type == CardType.Weapon)
|
||||
{
|
||||
OpponentWeapon = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Equipped weapon: {cardVm.Name}");
|
||||
StatusMessage = $"Opponent equips {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent equips {cardVm.Name}", BattleLogEntryType.OpponentAction);
|
||||
OnPropertyChanged(nameof(OpponentWeapon));
|
||||
}
|
||||
else if (cardVm.Type == CardType.Armor)
|
||||
{
|
||||
OpponentArmor = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Equipped armor: {cardVm.Name}");
|
||||
StatusMessage = $"Opponent equips {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent equips {cardVm.Name}", BattleLogEntryType.OpponentAction);
|
||||
OnPropertyChanged(nameof(OpponentArmor));
|
||||
}
|
||||
else if (cardVm.Type == CardType.Event)
|
||||
{
|
||||
OpponentEventSlot = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Plays event: {cardVm.Name}");
|
||||
StatusMessage = $"Opponent plays {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent plays {cardVm.Name}", BattleLogEntryType.Spell);
|
||||
OnPropertyChanged(nameof(OpponentEventSlot));
|
||||
}
|
||||
else if (cardVm.Type == CardType.Artifact)
|
||||
{
|
||||
// Place artifact in first available artifact slot
|
||||
for (int i = 0; i < _opponentArtifactSlots.Length; i++)
|
||||
{
|
||||
if (_opponentArtifactSlots[i] == null)
|
||||
{
|
||||
_opponentArtifactSlots[i] = cardVm;
|
||||
LogToFile($"[ExecuteOpponentTurn] Plays artifact: {cardVm.Name} to slot {i}");
|
||||
StatusMessage = $"Opponent plays {cardVm.Name}!";
|
||||
AddBattleLog($"Opponent plays {cardVm.Name}", BattleLogEntryType.Spell);
|
||||
break;
|
||||
}
|
||||
}
|
||||
// Update observable collection
|
||||
OpponentArtifactSlotsObs.Clear();
|
||||
for (int i = 0; i < _opponentArtifactSlots.Length; i++)
|
||||
{
|
||||
OpponentArtifactSlotsObs.Add(_opponentArtifactSlots[i]);
|
||||
}
|
||||
OnPropertyChanged(nameof(OpponentArtifactSlots));
|
||||
OnPropertyChanged(nameof(OpponentArtifactSlotsObs));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -907,16 +1109,19 @@ public class MainViewModel : ViewModelBase
|
||||
RefreshCreatureSlotCaches();
|
||||
PlayerHealth -= opponentCreature.Power;
|
||||
StatusMessage = $"Your {playerCreature.Name} was destroyed by {opponentCreature.Name}!";
|
||||
AddBattleLog($"Your {playerCreature.Name} was destroyed by {opponentCreature.Name}!", BattleLogEntryType.CreatureDeath);
|
||||
}
|
||||
else
|
||||
{
|
||||
StatusMessage = $"{opponentCreature.Name} attacks your {playerCreature.Name} for {opponentCreature.Power} damage!";
|
||||
AddBattleLog($"{opponentCreature.Name} attacks your {playerCreature.Name} for {opponentCreature.Power} damage", BattleLogEntryType.Damage);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
PlayerHealth -= opponentCreature.Power;
|
||||
StatusMessage = $"{opponentCreature.Name} deals {opponentCreature.Power} damage to you!";
|
||||
AddBattleLog($"{opponentCreature.Name} deals {opponentCreature.Power} damage to you", BattleLogEntryType.Damage);
|
||||
}
|
||||
OnPropertyChanged(nameof(FieldSlots));
|
||||
}
|
||||
@@ -943,6 +1148,7 @@ public class MainViewModel : ViewModelBase
|
||||
int damage = weapon.Power;
|
||||
PlayerHealth -= damage;
|
||||
StatusMessage = $"Opponent's {weapon.Name} deals {damage} damage to you!";
|
||||
AddBattleLog($"Opponent's {weapon.Name} deals {damage} damage to you", BattleLogEntryType.Damage);
|
||||
LogToFile($"[ResolveOpponentWeaponDamage] {weapon.Name} deals {damage} direct damage to player");
|
||||
}
|
||||
else if (weapon.TargetType == WeaponTargetType.DamageToCreatures)
|
||||
@@ -969,10 +1175,12 @@ public class MainViewModel : ViewModelBase
|
||||
}
|
||||
RefreshCreatureSlotCaches();
|
||||
StatusMessage = $"Your {target.Name} was destroyed by {weapon.Name}!";
|
||||
AddBattleLog($"Your {target.Name} was destroyed by {weapon.Name}!", BattleLogEntryType.CreatureDeath);
|
||||
}
|
||||
else
|
||||
{
|
||||
StatusMessage = $"Opponent's {weapon.Name} attacks your {target.Name} for {damage} damage!";
|
||||
AddBattleLog($"Opponent's {weapon.Name} attacks your {target.Name} for {damage} damage", BattleLogEntryType.Damage);
|
||||
}
|
||||
|
||||
LogToFile($"[ResolveOpponentWeaponDamage] {weapon.Name} attacks {target.Name} for {damage} damage, remaining HP: {target.Health}");
|
||||
@@ -1241,6 +1449,10 @@ public class MainViewModel : ViewModelBase
|
||||
|
||||
LogToFile($"[PlayCardToSlot] SUCCESS: FieldSlots[{slotIndex}]={card.Name}");
|
||||
|
||||
// Add to battle log
|
||||
int displaySlot = slotIndex - 5; // Convert 6-11 to 1-6
|
||||
AddBattleLog($"You summon {card.Name} to slot {displaySlot}", BattleLogEntryType.PlayerAction);
|
||||
|
||||
// Force refresh by creating new array instances to trigger UI update
|
||||
OnPropertyChanged(nameof(FieldSlots));
|
||||
OnPropertyChanged(nameof(OpponentCreatureSlots));
|
||||
|
||||
@@ -37,7 +37,7 @@
|
||||
<Grid Margin="10">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="200"/>
|
||||
<RowDefinition Height="160"/>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
@@ -181,14 +181,18 @@
|
||||
<!-- MIDDLE ROW: Playing Field (Row 2) -->
|
||||
<Border Grid.Row="2" Background="#2A3232" CornerRadius="6" Padding="12" Margin="0,5">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="3*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="*"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<!-- Opponent Creatures and Artifacts -->
|
||||
<StackPanel Grid.Row="0" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<!-- Opponent Creatures and Artifacts at top -->
|
||||
<StackPanel Grid.Column="0" Grid.Row="0" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<ItemsControl ItemsSource="{Binding OpponentCreatureSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
@@ -215,7 +219,7 @@
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<ItemsControl ItemsSource="{Binding OpponentArtifactSlots}">
|
||||
<ItemsControl ItemsSource="{Binding OpponentArtifactSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
@@ -241,10 +245,10 @@
|
||||
</StackPanel>
|
||||
|
||||
<!-- Divider -->
|
||||
<Border Grid.Row="1" Height="3" Background="#3A4040" Margin="30,5"/>
|
||||
<Border Grid.Column="0" Grid.Row="1" Height="3" Background="#3A4040" Margin="30,5"/>
|
||||
|
||||
<!-- Player Creatures and Artifacts -->
|
||||
<StackPanel Grid.Row="2" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<!-- Player Creatures and Artifacts at bottom -->
|
||||
<StackPanel Grid.Column="0" Grid.Row="2" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<ItemsControl ItemsSource="{Binding PlayerCreatureSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
@@ -272,7 +276,7 @@
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<ItemsControl ItemsSource="{Binding PlayerArtifactSlots}">
|
||||
<ItemsControl ItemsSource="{Binding PlayerArtifactSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
@@ -297,6 +301,26 @@
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Battle Log (right side) -->
|
||||
<Border Grid.Column="1" Grid.RowSpan="3" Background="{StaticResource SurfaceLightBrush}" CornerRadius="4" Padding="6" Margin="8,0,0,0">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="*"/>
|
||||
</Grid.RowDefinitions>
|
||||
<TextBlock Grid.Row="0" Text="Battle Log" Foreground="{StaticResource TextSecondaryBrush}" FontSize="10" FontWeight="Bold" Margin="0,0,0,5"/>
|
||||
<ScrollViewer Grid.Row="1" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled">
|
||||
<ItemsControl ItemsSource="{Binding BattleLog}">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding FormattedEntry}" Foreground="{StaticResource TextPrimaryBrush}" FontSize="9" TextWrapping="Wrap" Margin="0,1"/>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</ScrollViewer>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
@@ -304,13 +328,13 @@
|
||||
<Border Grid.Row="3" Background="{StaticResource SurfaceBrush}" CornerRadius="6" Padding="12" Margin="0,5,0,0">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="3*"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="200"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- Player Hand (50%) -->
|
||||
<!-- Player Hand (90%) -->
|
||||
<StackPanel Grid.Column="0">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,0,0,5">
|
||||
<TextBlock Text="HP: " Foreground="{StaticResource HealthBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
@@ -347,7 +371,7 @@
|
||||
<Border Grid.Row="1" Background="{Binding Element, Converter={StaticResource ElementToColorConverter}}" Margin="2,4" CornerRadius="2">
|
||||
<TextBlock Text="{Binding Type}" Foreground="#80FFFFFF" FontSize="8" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
</Border>
|
||||
<StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Center">
|
||||
<StackPanel Grid.Row="1" Orientation="Horizontal" HorizontalAlignment="Center">
|
||||
<TextBlock Text="P:" Foreground="{StaticResource DangerBrush}" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Power}" Foreground="{StaticResource DangerBrush}" FontSize="9" FontWeight="Bold" Margin="2,0,8,0"/>
|
||||
<TextBlock Text="H:" Foreground="{StaticResource HealthBrush}" FontSize="9" FontWeight="Bold"/>
|
||||
@@ -361,59 +385,71 @@
|
||||
</StackPanel>
|
||||
|
||||
<!-- Player Equipment (25%) -->
|
||||
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
|
||||
<!-- Player Event Slot -->
|
||||
<Border Background="{Binding PlayerEventSlot.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#C8A050}"
|
||||
BorderBrush="#D4B060" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding PlayerEventSlot}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnEventSlotDrop" DragEnter="OnEventSlotDragEnter" DragLeave="OnEventSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Name, FallbackValue=Event}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Player Weapon Slot -->
|
||||
<Border Background="{Binding PlayerWeapon.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
<Grid Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- Weapon Slot (top left) -->
|
||||
<Border Grid.Row="0" Grid.Column="0"
|
||||
Background="{Binding PlayerWeapon.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="2" CornerRadius="5" Width="55" Height="45"
|
||||
Tag="{Binding PlayerWeapon}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnWeaponSlotDrop" DragEnter="OnWeaponSlotDragEnter" DragLeave="OnWeaponSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerWeapon.Name, FallbackValue=Weapon}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,2,0,0">
|
||||
<TextBlock Text="{Binding PlayerWeapon.Name, FallbackValue=Weapon}" Foreground="White" HorizontalAlignment="Center" FontSize="6" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="48"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,2">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="7" FontWeight="Bold" Margin="1,0,2,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Player Armor Slot -->
|
||||
<Border Background="{Binding PlayerArmor.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
<!-- Armor Slot (top right) -->
|
||||
<Border Grid.Row="0" Grid.Column="1"
|
||||
Background="{Binding PlayerArmor.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="2" CornerRadius="5" Width="55" Height="45"
|
||||
Tag="{Binding PlayerArmor}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnArmorSlotDrop" DragEnter="OnArmorSlotDragEnter" DragLeave="OnArmorSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerArmor.Name, FallbackValue=Armor}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,2,0,0">
|
||||
<TextBlock Text="{Binding PlayerArmor.Name, FallbackValue=Armor}" Foreground="White" HorizontalAlignment="Center" FontSize="6" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="48"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,2">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="7" FontWeight="Bold" Margin="1,0,2,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</StackPanel>
|
||||
<!-- Event Slot (bottom, centered) -->
|
||||
<Border Grid.Row="1" Grid.ColumnSpan="2"
|
||||
Background="{Binding PlayerEventSlot.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#C8A050}"
|
||||
BorderBrush="#D4B060" BorderThickness="2" Margin="2,4,2,2" CornerRadius="5" Width="55" Height="40"
|
||||
Tag="{Binding PlayerEventSlot}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnEventSlotDrop" DragEnter="OnEventSlotDragEnter" DragLeave="OnEventSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,2,0,0">
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Name, FallbackValue=Event}" Foreground="White" HorizontalAlignment="Center" FontSize="6" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="48"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,2">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="7" FontWeight="Bold" Margin="1,0,2,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="7" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
|
||||
<!-- Player Combo Area (25%) -->
|
||||
<Border Grid.Column="2" Background="{StaticResource SurfaceLightBrush}" CornerRadius="5" Padding="8" Margin="8,0,0,0">
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -13,7 +13,7 @@ using System.Reflection;
|
||||
[assembly: System.Reflection.AssemblyCompanyAttribute("NewGame.UI")]
|
||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+e36147670d0b5d9de9af88c354d731309a75bbcb")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+b964d2efdff64eea1fe8e481b408f2839d79781e")]
|
||||
[assembly: System.Reflection.AssemblyProductAttribute("NewGame.UI")]
|
||||
[assembly: System.Reflection.AssemblyTitleAttribute("NewGame.UI")]
|
||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||
|
||||
@@ -1 +1 @@
|
||||
dcbebcf5e68b4fb5c118a4c89104f49c6c6f8b43f61a050b4470f8516d90a8f3
|
||||
09a172c93fdb78fe1cc993859098e28552c5e858f8636f01dbfca90197c017b8
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -1 +1 @@
|
||||
{"documents":{"C:\\Users\\atw61\\OneDrive\\Desktop\\new\\*":"https://raw.githubusercontent.com/alexandria121/new/e36147670d0b5d9de9af88c354d731309a75bbcb/*"}}
|
||||
{"documents":{"C:\\Users\\atw61\\OneDrive\\Desktop\\new\\*":"https://raw.githubusercontent.com/alexandria121/new/b964d2efdff64eea1fe8e481b408f2839d79781e/*"}}
|
||||
Binary file not shown.
Binary file not shown.
@@ -1,4 +1,4 @@
|
||||
#pragma checksum "..\..\..\..\Views\GameView.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "BA5924FB2C4218944DD6C4924C7E9DDDD8021D57"
|
||||
#pragma checksum "..\..\..\..\Views\GameView.xaml" "{ff1816ec-aa5e-4d10-87f7-6f4963833460}" "11332F2EAAD616EAB958079DABAE649F10A9F31C"
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// This code was generated by a tool.
|
||||
@@ -43,7 +43,7 @@ namespace NewGame.UI.Views {
|
||||
public partial class GameView : System.Windows.Controls.UserControl, System.Windows.Markup.IComponentConnector, System.Windows.Markup.IStyleConnector {
|
||||
|
||||
|
||||
#line 435 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 471 "..\..\..\..\Views\GameView.xaml"
|
||||
[System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
|
||||
internal NewGame.UI.Controls.CardZoomOverlay CardZoomPopup;
|
||||
|
||||
@@ -151,58 +151,6 @@ namespace NewGame.UI.Views {
|
||||
return;
|
||||
case 10:
|
||||
|
||||
#line 368 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnEquipmentRightClick);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 369 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnEventSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 369 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnEventSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 369 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnEventSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
return;
|
||||
case 11:
|
||||
|
||||
#line 385 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnEquipmentRightClick);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 386 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnWeaponSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 386 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnWeaponSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 386 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnWeaponSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
return;
|
||||
case 12:
|
||||
|
||||
#line 402 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnEquipmentRightClick);
|
||||
|
||||
@@ -210,20 +158,72 @@ namespace NewGame.UI.Views {
|
||||
#line hidden
|
||||
|
||||
#line 403 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnWeaponSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 403 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnWeaponSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 403 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnWeaponSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
return;
|
||||
case 11:
|
||||
|
||||
#line 420 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnEquipmentRightClick);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 421 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnArmorSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 403 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 421 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnArmorSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 403 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 421 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnArmorSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
return;
|
||||
case 12:
|
||||
|
||||
#line 438 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnEquipmentRightClick);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 439 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnEventSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 439 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnEventSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 439 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnEventSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
return;
|
||||
@@ -245,7 +245,7 @@ namespace NewGame.UI.Views {
|
||||
{
|
||||
case 5:
|
||||
|
||||
#line 202 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 206 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnFieldCardRightClick);
|
||||
|
||||
#line default
|
||||
@@ -253,7 +253,7 @@ namespace NewGame.UI.Views {
|
||||
break;
|
||||
case 6:
|
||||
|
||||
#line 228 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 232 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnFieldCardRightClick);
|
||||
|
||||
#line default
|
||||
@@ -261,31 +261,31 @@ namespace NewGame.UI.Views {
|
||||
break;
|
||||
case 7:
|
||||
|
||||
#line 258 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 262 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnPlayerSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 258 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 262 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnPlayerSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 258 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 262 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnPlayerSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 258 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 262 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseMove += new System.Windows.Input.MouseEventHandler(this.OnPlayerSlotMouseMove);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 259 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 263 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnFieldCardRightClick);
|
||||
|
||||
#line default
|
||||
@@ -293,37 +293,37 @@ namespace NewGame.UI.Views {
|
||||
break;
|
||||
case 8:
|
||||
|
||||
#line 285 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 289 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).Drop += new System.Windows.DragEventHandler(this.OnArtifactSlotDrop);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 285 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 289 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragEnter += new System.Windows.DragEventHandler(this.OnArtifactSlotDragEnter);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 285 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 289 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragOver += new System.Windows.DragEventHandler(this.OnArtifactSlotDragOver);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 285 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 289 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).DragLeave += new System.Windows.DragEventHandler(this.OnArtifactSlotDragLeave);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 285 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 289 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseMove += new System.Windows.Input.MouseEventHandler(this.OnArtifactSlotMouseMove);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 286 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 290 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnFieldCardRightClick);
|
||||
|
||||
#line default
|
||||
@@ -331,25 +331,25 @@ namespace NewGame.UI.Views {
|
||||
break;
|
||||
case 9:
|
||||
|
||||
#line 331 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 355 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnHandCardPreviewMouseLeftButtonDown);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 332 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 356 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.OnHandCardPreviewMouseLeftButtonUp);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 333 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 357 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseMove += new System.Windows.Input.MouseEventHandler(this.OnHandCardPreviewMouseMove);
|
||||
|
||||
#line default
|
||||
#line hidden
|
||||
|
||||
#line 334 "..\..\..\..\Views\GameView.xaml"
|
||||
#line 358 "..\..\..\..\Views\GameView.xaml"
|
||||
((System.Windows.Controls.Border)(target)).MouseRightButtonDown += new System.Windows.Input.MouseButtonEventHandler(this.OnHandCardRightClick);
|
||||
|
||||
#line default
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,437 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<UserControl x:Class="NewGame.UI.Views.GameView"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:vm="clr-namespace:NewGame.UI.ViewModels"
|
||||
xmlns:controls="clr-namespace:NewGame.UI.Controls"
|
||||
xmlns:Converters="clr-namespace:NewGame.UI.Converters"
|
||||
mc:Ignorable="d"
|
||||
Background="{StaticResource BackgroundBrush}"
|
||||
AllowDrop="True"
|
||||
Drop="OnSpellDrop"
|
||||
DragEnter="OnSpellDragEnter"
|
||||
DragLeave="OnSpellDragLeave">
|
||||
|
||||
<UserControl.Resources>
|
||||
<Converters:BoolToTurnTextConverter x:Key="BoolToTurnTextConverter"/>
|
||||
<Converters:BoolToTurnColorConverter x:Key="BoolToTurnColorConverter"/>
|
||||
<Converters:NullToVisibilityConverter x:Key="NullToVisibilityConverter"/>
|
||||
<Converters:CanAffordToOpacityConverter x:Key="CanAffordToOpacityConverter"/>
|
||||
<Converters:CanAffordToColorConverter x:Key="CanAffordToColorConverter"/>
|
||||
<Converters:ElementToColorConverter x:Key="ElementToColorConverter"/>
|
||||
<Converters:ElementToGradientConverter x:Key="ElementToGradientConverter"/>
|
||||
<Converters:ElementToGlowConverter x:Key="ElementToGlowConverter"/>
|
||||
<Converters:TypeToColorConverter x:Key="TypeToColorConverter"/>
|
||||
<Converters:EffectTypeToIconConverter x:Key="EffectTypeToIconConverter"/>
|
||||
<Converters:IntToVisibilityConverter x:Key="IntToVisibilityConverter"/>
|
||||
<Converters:BoolToVisibilityConverter x:Key="BoolToVisibilityConverter"/>
|
||||
<Converters:RarityToGradientConverter x:Key="RarityToGradientConverter"/>
|
||||
<Converters:RarityToGlowConverter x:Key="RarityToGlowConverter"/>
|
||||
<Converters:BoolToOpacityConverter x:Key="BoolToOpacityConverter"/>
|
||||
<Converters:BoolToTextConverter x:Key="BoolToTextConverter"/>
|
||||
<Converters:InverseBoolToVisibilityConverter x:Key="InverseBoolToVisibilityConverter"/>
|
||||
</UserControl.Resources>
|
||||
|
||||
<Grid Margin="10">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="200"/>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<!-- Turn Info Bar (Row 0) -->
|
||||
<Border Grid.Row="0" Background="{StaticResource SurfaceBrush}" CornerRadius="6" Padding="12" Margin="0,0,0,5">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<StackPanel Orientation="Horizontal" Grid.Column="0">
|
||||
<TextBlock Text="Turn " Foreground="{StaticResource TextPrimaryBrush}" FontSize="13"/>
|
||||
<TextBlock Text="{Binding TurnCount}" Foreground="{StaticResource TextPrimaryBrush}" FontSize="13" FontWeight="Bold"/>
|
||||
<TextBlock Text=" | " Foreground="{StaticResource TextSecondaryBrush}"/>
|
||||
<TextBlock Text="{Binding IsPlayerTurn, Converter={StaticResource BoolToTurnTextConverter}}" Foreground="{Binding IsPlayerTurn, Converter={StaticResource BoolToTurnColorConverter}}" FontSize="13" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
<TextBlock Grid.Column="1" Text="{Binding StatusMessage}" Foreground="{StaticResource AccentBrush}" FontSize="12" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
<StackPanel Grid.Column="2" Orientation="Horizontal" Margin="15,0">
|
||||
<TextBlock Text="You: " Foreground="{StaticResource HealthBrush}" FontSize="12"/>
|
||||
<TextBlock Text="{Binding PlayerHealth}" Foreground="{StaticResource HealthBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
<TextBlock Text=" | " Foreground="{StaticResource TextSecondaryBrush}"/>
|
||||
<TextBlock Text="Enemy: " Foreground="{StaticResource DangerBrush}" FontSize="12" Margin="10,0,0,0"/>
|
||||
<TextBlock Text="{Binding OpponentHealth}" Foreground="{StaticResource DangerBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
<StackPanel Grid.Column="3" Orientation="Horizontal" Margin="15,0">
|
||||
<TextBlock Text="Mana: " Foreground="{StaticResource ManaBrush}" FontSize="13"/>
|
||||
<TextBlock Text="{Binding PlayerMana}" Foreground="{StaticResource ManaBrush}" FontSize="13" FontWeight="Bold"/>
|
||||
<TextBlock Text="/" Foreground="{StaticResource TextSecondaryBrush}"/>
|
||||
<TextBlock Text="{Binding PlayerMaxMana}" Foreground="{StaticResource TextSecondaryBrush}" FontSize="13"/>
|
||||
</StackPanel>
|
||||
<Button Grid.Column="4" Content="End Turn" Style="{StaticResource AccentButtonStyle}" Command="{Binding EndTurnCommand}" Padding="15,6"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- TOP ROW: Opponent Area (Row 1) -->
|
||||
<Border Grid.Row="1" Background="{StaticResource SurfaceBrush}" CornerRadius="6" Padding="12" Margin="0,0,0,5">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="200"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- Opponent Hand (50%) -->
|
||||
<StackPanel Grid.Column="0">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,0,0,5">
|
||||
<TextBlock Text="HP: " Foreground="{StaticResource DangerBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentHealth}" Foreground="{StaticResource DangerBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
<TextBlock Text=" | Mana: " Foreground="{StaticResource ManaBrush}" FontSize="12" Margin="15,0,0,0"/>
|
||||
<TextBlock Text="{Binding PlayerMana}" Foreground="{StaticResource ManaBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Border Background="#2A1A1A" BorderBrush="#4A2A2A" BorderThickness="1" CornerRadius="3" Width="32" Height="44" Margin="2">
|
||||
<TextBlock Text="?" Foreground="#505050" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="16" FontWeight="Bold"/>
|
||||
</Border>
|
||||
<Border Background="#2A1A1A" BorderBrush="#4A2A2A" BorderThickness="1" CornerRadius="3" Width="32" Height="44" Margin="2">
|
||||
<TextBlock Text="?" Foreground="#505050" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="16" FontWeight="Bold"/>
|
||||
</Border>
|
||||
<Border Background="#2A1A1A" BorderBrush="#4A2A2A" BorderThickness="1" CornerRadius="3" Width="32" Height="44" Margin="2">
|
||||
<TextBlock Text="?" Foreground="#505050" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="16" FontWeight="Bold"/>
|
||||
</Border>
|
||||
<Border Background="#2A1A1A" BorderBrush="#4A2A2A" BorderThickness="1" CornerRadius="3" Width="32" Height="44" Margin="2">
|
||||
<TextBlock Text="?" Foreground="#505050" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="16" FontWeight="Bold"/>
|
||||
</Border>
|
||||
<Border Background="#2A1A1A" BorderBrush="#4A2A2A" BorderThickness="1" CornerRadius="3" Width="32" Height="44" Margin="2">
|
||||
<TextBlock Text="?" Foreground="#505050" HorizontalAlignment="Center" VerticalAlignment="Center" FontSize="16" FontWeight="Bold"/>
|
||||
</Border>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Opponent Equipment (25%) -->
|
||||
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
|
||||
<!-- Opponent Event Slot -->
|
||||
<Border Background="{Binding OpponentEventSlot.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#503232}"
|
||||
BorderBrush="#804040" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding OpponentEventSlot}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnOpponentEventSlotDrop" DragEnter="OnOpponentEventSlotDragEnter" DragLeave="OnOpponentEventSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding OpponentEventSlot.Name, FallbackValue=Event}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentEventSlot.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentEventSlot.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Opponent Weapon Slot -->
|
||||
<Border Background="{Binding OpponentWeapon.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#503232}"
|
||||
BorderBrush="#804040" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding OpponentWeapon}" MouseRightButtonDown="OnEquipmentRightClick">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding OpponentWeapon.Name, FallbackValue=Weapon}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentWeapon.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentWeapon.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Opponent Armor Slot -->
|
||||
<Border Background="{Binding OpponentArmor.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#503232}"
|
||||
BorderBrush="#804040" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding OpponentArmor}" MouseRightButtonDown="OnEquipmentRightClick">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding OpponentArmor.Name, FallbackValue=Armor}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentArmor.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding OpponentArmor.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Opponent Combo Area (25%) -->
|
||||
<Border Grid.Column="2" Background="{StaticResource SurfaceLightBrush}" CornerRadius="5" Padding="8" Margin="8,0,0,0">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions><RowDefinition Height="Auto"/><RowDefinition Height="*"/></Grid.RowDefinitions>
|
||||
<TextBlock Grid.Row="0" Text="Opponent Combo" Foreground="{StaticResource TextSecondaryBrush}" FontSize="11" FontWeight="Bold" HorizontalAlignment="Center"/>
|
||||
<Border Grid.Row="1" Background="#3A3A3A" CornerRadius="3" Height="45" Margin="0,5,0,0">
|
||||
<TextBlock Text="Drop cards here" Foreground="#505050" FontSize="10" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- MIDDLE ROW: Playing Field (Row 2) -->
|
||||
<Border Grid.Row="2" Background="#2A3232" CornerRadius="6" Padding="12" Margin="0,5">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="*"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<!-- Opponent Creatures and Artifacts -->
|
||||
<StackPanel Grid.Row="0" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<ItemsControl ItemsSource="{Binding OpponentCreatureSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Background="{Binding Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#503232}"
|
||||
BorderBrush="#604040" BorderThickness="2" Margin="3" CornerRadius="5" Width="80" Height="70"
|
||||
MouseRightButtonDown="OnFieldCardRightClick" Tag="{Binding}">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding Name, FallbackValue=?}" Foreground="White" HorizontalAlignment="Center" FontSize="8" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="72"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,4">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Power, FallbackValue=0}" Foreground="#FF6464" FontSize="9" FontWeight="Bold" Margin="2,0,5,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Health, FallbackValue=0}" Foreground="#64FF64" FontSize="9" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<ItemsControl ItemsSource="{Binding OpponentArtifactSlots}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Background="{Binding Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#C8C864}"
|
||||
BorderBrush="#D4D474" BorderThickness="2" Margin="3" CornerRadius="5" Width="80" Height="70"
|
||||
MouseRightButtonDown="OnFieldCardRightClick" Tag="{Binding}">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding Name, FallbackValue=Artifact}" Foreground="White" HorizontalAlignment="Center" FontSize="8" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="72"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,4">
|
||||
<TextBlock Text="{Binding Type, FallbackValue=Artifact}" Foreground="#80FFFFFF" FontSize="8"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Divider -->
|
||||
<Border Grid.Row="1" Height="3" Background="#3A4040" Margin="30,5"/>
|
||||
|
||||
<!-- Player Creatures and Artifacts -->
|
||||
<StackPanel Grid.Row="2" Orientation="Horizontal" VerticalAlignment="Center">
|
||||
<ItemsControl ItemsSource="{Binding PlayerCreatureSlotsObs}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Background="{Binding Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="3" CornerRadius="5" Width="80" Height="70"
|
||||
Tag="{Binding}" AllowDrop="True" Drop="OnPlayerSlotDrop" DragEnter="OnPlayerSlotDragEnter" DragLeave="OnPlayerSlotDragLeave" MouseMove="OnPlayerSlotMouseMove"
|
||||
MouseRightButtonDown="OnFieldCardRightClick">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding Name, FallbackValue=?}" Foreground="White" HorizontalAlignment="Center" FontSize="8" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="72"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,4">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Power, FallbackValue=0}" Foreground="#FF6464" FontSize="9" FontWeight="Bold" Margin="2,0,5,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Health, FallbackValue=0}" Foreground="#64FF64" FontSize="9" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<ItemsControl ItemsSource="{Binding PlayerArtifactSlots}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Background="{Binding Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#C8C864}"
|
||||
BorderBrush="#D4D474" BorderThickness="2" Margin="3" CornerRadius="5" Width="80" Height="70"
|
||||
Tag="{Binding}" AllowDrop="True" Drop="OnArtifactSlotDrop" DragEnter="OnArtifactSlotDragEnter" DragOver="OnArtifactSlotDragOver" DragLeave="OnArtifactSlotDragLeave" MouseMove="OnArtifactSlotMouseMove"
|
||||
MouseRightButtonDown="OnFieldCardRightClick">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding Name, FallbackValue=Artifact}" Foreground="White" HorizontalAlignment="Center" FontSize="8" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="72"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,4">
|
||||
<TextBlock Text="{Binding Type, FallbackValue=Artifact}" Foreground="#80FFFFFF" FontSize="8"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- BOTTOM ROW: Player Area (Row 3) -->
|
||||
<Border Grid.Row="3" Background="{StaticResource SurfaceBrush}" CornerRadius="6" Padding="12" Margin="0,5,0,0">
|
||||
<Grid>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="*"/>
|
||||
<ColumnDefinition Width="200"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<!-- Player Hand (50%) -->
|
||||
<StackPanel Grid.Column="0">
|
||||
<StackPanel Orientation="Horizontal" Margin="0,0,0,5">
|
||||
<TextBlock Text="HP: " Foreground="{StaticResource HealthBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerHealth}" Foreground="{StaticResource HealthBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
<TextBlock Text=" | Mana: " Foreground="{StaticResource ManaBrush}" FontSize="12" Margin="15,0,0,0"/>
|
||||
<TextBlock Text="{Binding PlayerMana}" Foreground="{StaticResource ManaBrush}" FontSize="12" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
<ItemsControl ItemsSource="{Binding PlayerHand}">
|
||||
<ItemsControl.ItemsPanel>
|
||||
<ItemsPanelTemplate>
|
||||
<StackPanel Orientation="Horizontal"/>
|
||||
</ItemsPanelTemplate>
|
||||
</ItemsControl.ItemsPanel>
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Border Background="#464636" BorderBrush="#506046" BorderThickness="2" CornerRadius="3" Width="80" Height="110" Margin="2" Cursor="Hand"
|
||||
Tag="{Binding}"
|
||||
MouseLeftButtonDown="OnHandCardPreviewMouseLeftButtonDown"
|
||||
MouseLeftButtonUp="OnHandCardPreviewMouseLeftButtonUp"
|
||||
MouseMove="OnHandCardPreviewMouseMove"
|
||||
MouseRightButtonDown="OnHandCardRightClick">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
<StackPanel Grid.Row="0" Orientation="Horizontal">
|
||||
<TextBlock Text="{Binding Name}" Foreground="White" FontSize="9" FontWeight="Bold" TextTrimming="CharacterEllipsis" MaxWidth="60"/>
|
||||
<Border Background="{StaticResource ManaBrush}" CornerRadius="3" Padding="3,1" Margin="4,0,0,0">
|
||||
<TextBlock Text="{Binding ManaCost}" Foreground="White" FontSize="8" FontWeight="Bold"/>
|
||||
</Border>
|
||||
</StackPanel>
|
||||
<Border Grid.Row="1" Background="{Binding Element, Converter={StaticResource ElementToColorConverter}}" Margin="2,4" CornerRadius="2">
|
||||
<TextBlock Text="{Binding Type}" Foreground="#80FFFFFF" FontSize="8" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
</Border>
|
||||
<StackPanel Grid.Row="2" Orientation="Horizontal" HorizontalAlignment="Center">
|
||||
<TextBlock Text="P:" Foreground="{StaticResource DangerBrush}" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Power}" Foreground="{StaticResource DangerBrush}" FontSize="9" FontWeight="Bold" Margin="2,0,8,0"/>
|
||||
<TextBlock Text="H:" Foreground="{StaticResource HealthBrush}" FontSize="9" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding Health}" Foreground="{StaticResource HealthBrush}" FontSize="9" FontWeight="Bold" Margin="2,0,0,0"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Player Equipment (25%) -->
|
||||
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Center" VerticalAlignment="Center">
|
||||
<!-- Player Event Slot -->
|
||||
<Border Background="{Binding PlayerEventSlot.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#C8A050}"
|
||||
BorderBrush="#D4B060" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding PlayerEventSlot}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnEventSlotDrop" DragEnter="OnEventSlotDragEnter" DragLeave="OnEventSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Name, FallbackValue=Event}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerEventSlot.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Player Weapon Slot -->
|
||||
<Border Background="{Binding PlayerWeapon.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding PlayerWeapon}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnWeaponSlotDrop" DragEnter="OnWeaponSlotDragEnter" DragLeave="OnWeaponSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerWeapon.Name, FallbackValue=Weapon}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerWeapon.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
<!-- Player Armor Slot -->
|
||||
<Border Background="{Binding PlayerArmor.Element, Converter={StaticResource ElementToColorConverter}, FallbackValue=#465046}"
|
||||
BorderBrush="#506050" BorderThickness="2" Margin="4" CornerRadius="5" Width="60" Height="50"
|
||||
Tag="{Binding PlayerArmor}" MouseRightButtonDown="OnEquipmentRightClick" AllowDrop="True"
|
||||
Drop="OnArmorSlotDrop" DragEnter="OnArmorSlotDragEnter" DragLeave="OnArmorSlotDragLeave">
|
||||
<Grid>
|
||||
<StackPanel VerticalAlignment="Top" HorizontalAlignment="Center" Margin="0,3,0,0">
|
||||
<TextBlock Text="{Binding PlayerArmor.Name, FallbackValue=Armor}" Foreground="White" HorizontalAlignment="Center" FontSize="7" FontWeight="Bold" TextWrapping="Wrap" TextAlignment="Center" MaxWidth="54"/>
|
||||
</StackPanel>
|
||||
<StackPanel Orientation="Horizontal" VerticalAlignment="Bottom" HorizontalAlignment="Center" Margin="0,0,0,3">
|
||||
<TextBlock Text="P:" Foreground="#FF6464" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Power, FallbackValue=0}" Foreground="#FF6464" FontSize="8" FontWeight="Bold" Margin="1,0,3,0"/>
|
||||
<TextBlock Text="H:" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
<TextBlock Text="{Binding PlayerArmor.Health, FallbackValue=0}" Foreground="#64FF64" FontSize="8" FontWeight="Bold"/>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</Border>
|
||||
</StackPanel>
|
||||
|
||||
<!-- Player Combo Area (25%) -->
|
||||
<Border Grid.Column="2" Background="{StaticResource SurfaceLightBrush}" CornerRadius="5" Padding="8" Margin="8,0,0,0">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions><RowDefinition Height="Auto"/><RowDefinition Height="*"/></Grid.RowDefinitions>
|
||||
<TextBlock Grid.Row="0" Text="Combine" Foreground="{StaticResource AccentBrush}" FontSize="11" FontWeight="Bold" HorizontalAlignment="Center"/>
|
||||
<Border Grid.Row="1" Background="#3A3A3A" CornerRadius="3" Height="45" Margin="0,5,0,0">
|
||||
<TextBlock Text="Drop cards here" Foreground="#505050" FontSize="10" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
</Border>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- End Turn Button -->
|
||||
<Button Grid.Column="3" Content="End Turn" Style="{StaticResource AccentButtonStyle}" Command="{Binding EndTurnCommand}" Padding="15,10" Margin="10,0,0,0" VerticalAlignment="Center"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
<!-- Card Zoom Overlay: Default collapsed, only shows when both conditions are met -->
|
||||
<controls:CardZoomOverlay x:Name="CardZoomPopup" DataContext="{Binding ZoomedCard}" Visibility="Collapsed"/>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
Reference in New Issue
Block a user