- Two-timer architecture: game timer + 60fps render timer for smooth interpolation - Snake body: StreamGeometry path with teal gradient, rounded joins - Directional head with white eyes and dark pupils - Food: pulsating glow, highlight, green leaf animation - Modern dark theme (#0D1117), glassmorphism HUD - Speed indicator bar, score +N popup - High score persistence to JSON - All keyboard shortcuts: Arrows, WASD, Space/P pause, Enter start, R restart, Esc quit - Window resizable, 640x540 default New files: AnimationHelper.cs, HighScoreManager.cs, SnakeRenderer.cs
17 lines
660 B
XML
17 lines
660 B
XML
<Window xmlns="https://github.com/avaloniaui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:views="using:Snake.Avalonia.Views"
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="540"
|
|
x:Class="Snake.Avalonia.MainWindow"
|
|
Title="🐍 Snake"
|
|
MinWidth="540"
|
|
MinHeight="460"
|
|
Width="640"
|
|
Height="540"
|
|
Background="#0D1117"
|
|
ExtendClientAreaToDecorationsHint="False">
|
|
<views:GameView />
|
|
</Window>
|