update:ui修改
@ -19,7 +19,7 @@ namespace Dto
|
||||
public List<double> UserScoreList { get; private set; }
|
||||
public List<SportBase> Sports { get; private set; }
|
||||
public List<string> UseNameList { get; private set; } = new() { "蓝方选手", "红方选手" };
|
||||
public List<int> UserBeatSyncList = new List<int>();
|
||||
public static List<int> UserBeatSyncList = new List<int>();
|
||||
|
||||
public Dictionary<string, List<double>> MusicBeats { get; private set; } = new()
|
||||
{
|
||||
|
||||
|
Before Width: | Height: | Size: 3.8 MiB After Width: | Height: | Size: 2.9 MiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/Album/11.gif
Normal file
|
After Width: | Height: | Size: 3.8 MiB |
|
Before Width: | Height: | Size: 6.2 MiB After Width: | Height: | Size: 1.4 MiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/Album/22.gif
Normal file
|
After Width: | Height: | Size: 6.2 MiB |
|
Before Width: | Height: | Size: 3.8 MiB After Width: | Height: | Size: 2.9 MiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/Album/33.gif
Normal file
|
After Width: | Height: | Size: 3.8 MiB |
|
Before Width: | Height: | Size: 793 B After Width: | Height: | Size: 2.1 KiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/Album/change_bg2.png
Normal file
|
After Width: | Height: | Size: 793 B |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 2.9 MiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/gif/22.gif
Normal file
|
After Width: | Height: | Size: 1.9 MiB |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 2.9 MiB |
BIN
Wpf_AiSportsMicrospace/Resources/Img/gif/33.gif
Normal file
|
After Width: | Height: | Size: 1.9 MiB |
@ -30,23 +30,29 @@
|
||||
Padding="0,100"
|
||||
/>
|
||||
<Grid Margin="314,833,214,0" VerticalAlignment="Top" Height="182">
|
||||
<Image
|
||||
<!--<Image
|
||||
Source="/Resources/Img/Album/change_back.png"
|
||||
MouseDown="GoNew"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="330"
|
||||
Margin="0,100,0,0"
|
||||
/>
|
||||
/>-->
|
||||
<Grid Margin="0,0,0,0" VerticalAlignment="Top" HorizontalAlignment="Left" Height="182" Width="340" MouseDown="GoPro">
|
||||
<Image Source="/Resources/Img/Album/change_bg.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="330" Margin="0,106,0,0" />
|
||||
<TextBlock Text="右手挥手" FontSize="28" FontWeight="Bold" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="85,127,0,0" />
|
||||
<TextBlock Text="切换菜单" FontSize="28" FontWeight="Bold" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="202,127,0,0" Foreground="red"/>
|
||||
</Grid>
|
||||
<Image
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/2.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="Forever"
|
||||
gif:ImageBehavior.AnimationSpeedRatio="0.8"
|
||||
gif:ImageBehavior.AnimateInDesignMode="True"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Margin="-20,10,30,20"
|
||||
VerticalAlignment="Top" Margin="-9,-10,0,0"
|
||||
/>
|
||||
|
||||
<Image
|
||||
<!--<Image
|
||||
Source="/Resources/Img/Album/change_right.png"
|
||||
HorizontalAlignment="right"
|
||||
VerticalAlignment="Top"
|
||||
@ -54,13 +60,18 @@
|
||||
Height="400"
|
||||
Margin="0,100,0,0"
|
||||
MouseDown="GoPro"
|
||||
/>
|
||||
/>-->
|
||||
<Grid Margin="1052,0,0,0" VerticalAlignment="Center" Height="182" Width="340" MouseDown="GoPro">
|
||||
<Image Source="/Resources/Img/Album/change_bg.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="330" Margin="0,106,0,0" />
|
||||
<TextBlock Text="举右手" FontSize="28" FontWeight="Bold" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="90,127,0,0" />
|
||||
<TextBlock Text="进入菜单" FontSize="28" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="130,127,0,0" Foreground="red"/>
|
||||
</Grid>
|
||||
<Image
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/1.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="Forever"
|
||||
HorizontalAlignment="right"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Margin="50,10,200,20"
|
||||
Margin="1027,-20,0,0"
|
||||
/>
|
||||
|
||||
|
||||
@ -135,7 +146,7 @@
|
||||
<RadioButton Style="{DynamicResource RadioGroupItemSingle}" Content="取消" x:Name="SetCancelButton" Click="SetCancelButton_Click" />
|
||||
<RadioButton Margin="10,0,20,0" Style="{StaticResource RadioButtonSameAsButtonPrimary}" Content="保存" Foreground="#fff" x:Name="SetOkButton1" Click="SetOkButton_Click"/>
|
||||
</StackPanel>
|
||||
|
||||
|
||||
<TextBlock Text="基础配置" FontSize="18" Margin="12,30,0,0" FontWeight="Bold" Grid.Row="7"/>
|
||||
<hc:TextBox hc:InfoElement.TitlePlacement="Left" hc:InfoElement.Title="多人跳绳点位数量:" Width="400" Text="5" Grid.Row="8" x:Name="homeWidth" />
|
||||
|
||||
|
||||
@ -174,15 +174,23 @@ namespace Wpf_AiSportsMicrospace
|
||||
mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
}
|
||||
else if (coverFlow.SelectedIndex == 1)
|
||||
{
|
||||
var newPage = new StandingLeap();
|
||||
mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
}
|
||||
else if (coverFlow.SelectedIndex == 2)
|
||||
{
|
||||
var newPage = new MusicJumpRope();
|
||||
mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
}
|
||||
else if (coverFlow.SelectedIndex == 3)
|
||||
{
|
||||
var newPage = new WhackAMole();
|
||||
mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
//var newPage = new TrainingRecords();
|
||||
//var newPage = new WhackAMole();
|
||||
var newPage = new StandingLeap();
|
||||
var newPage = new TrainingRecords();
|
||||
mainWin?.SwitchPageWithMaskAnimation(newPage, true);
|
||||
}
|
||||
}
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
<Grid Height="1080" Width="1920" x:Name="userBox" >
|
||||
<Image x:Name="videoImage" Stretch="Uniform" />
|
||||
<Image x:Name="centerImg1" Source="/Resources/Img/new/long/title.png" HorizontalAlignment="Center" VerticalAlignment="Top" Width="315" Margin="0,25,0,0"/>
|
||||
<Image x:Name="centerImg2" Source="/Resources/Img/new/long/mat.png" HorizontalAlignment="Center" VerticalAlignment="Top" Width="1337" Margin="0,556,0,0" Height="210"/>
|
||||
<Image x:Name="centerImg2" Source="/Resources/Img/new/long/mat.png" HorizontalAlignment="Center" VerticalAlignment="Top" Width="1336" Margin="0,727,0,0" Height="210"/>
|
||||
<!--<Image
|
||||
x:Name="centerImg3"
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/new/long/right_hand.gif"
|
||||
@ -26,16 +26,16 @@
|
||||
Visibility="Visible"
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/new/long/jumping.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="1x"
|
||||
gif:ImageBehavior.AutoStart="True"
|
||||
gif:ImageBehavior.AutoStart="False"
|
||||
gif:ImageBehavior.AnimationSpeedRatio="1.5"
|
||||
gif:ImageBehavior.AnimateInDesignMode="True"
|
||||
HorizontalAlignment="Left" VerticalAlignment="Top" Margin="488,95,0,0" Width="1072" Height="750"/>
|
||||
HorizontalAlignment="Left" VerticalAlignment="Top" Margin="482,260,0,0" Width="1072" Height="750"/>
|
||||
<Grid Width="1920" Height="1080" Background="#80000000" x:Name="TipBox" Opacity="0">
|
||||
<Image Source="/Resources/Img/test_img/jump_long/tip.png" HorizontalAlignment="Center" VerticalAlignment="Center" Width="1416" Margin="0,0,0,-700"/>
|
||||
</Grid>
|
||||
|
||||
<!--成绩-->
|
||||
<Grid x:Name="RankingGrid" Margin="0,0,0,0" Height="1080" Width="1920" Opacity="0">
|
||||
<Grid x:Name="RankingGrid" Margin="0,0,0,0" Height="1080" Width="1920" Opacity="1">
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/finish_bg.png"
|
||||
HorizontalAlignment="Center"
|
||||
@ -107,7 +107,7 @@
|
||||
<Image gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/3.gif" gif:ImageBehavior.RepeatBehavior="Forever" gif:ImageBehavior.AnimateInDesignMode="True" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="-20,10,30,20" />
|
||||
</Grid>
|
||||
<Grid Margin="700,0,0,50" VerticalAlignment="Bottom" Height="182" Width="340" >
|
||||
<Image Source="/Resources/Img/Album/change_bg.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="330" Margin="0,103,0,0" />
|
||||
<Image Source="/Resources/Img/Album/change_bg2.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="330" Margin="0,103,0,0" />
|
||||
<TextBlock Text="10s" x:Name="countDown" FontSize="28" FontWeight="Bold" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="65,127,0,0" Foreground="red"/>
|
||||
<TextBlock Text="后继续挑战" FontSize="28" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="30,127,0,0" />
|
||||
</Grid>
|
||||
|
||||
@ -388,8 +388,8 @@ namespace Wpf_AiSportsMicrospace.Views.JumpRope
|
||||
|
||||
public void showRank()
|
||||
{
|
||||
double left = _musicJumpRopeContext.UserBeatSyncList[0];
|
||||
double right = _musicJumpRopeContext.UserBeatSyncList[1];
|
||||
double left = MusicJumpRopeContext.UserBeatSyncList[0];
|
||||
double right = MusicJumpRopeContext.UserBeatSyncList[1];
|
||||
score4.Text = (left * 10).ToString();
|
||||
score3.Text = (right * 10).ToString();
|
||||
if (left > right)
|
||||
@ -436,7 +436,7 @@ namespace Wpf_AiSportsMicrospace.Views.JumpRope
|
||||
_musicJumpRopeContext.Sports.Clear();
|
||||
_musicJumpRopeContext.UserList.Clear();
|
||||
_musicJumpRopeContext.UserNumberList.Clear();
|
||||
_musicJumpRopeContext.UserBeatSyncList.Clear();
|
||||
MusicJumpRopeContext.UserBeatSyncList.Clear();
|
||||
|
||||
double imgWidth = userBox.ActualWidth;
|
||||
double imgHeight = userBox.ActualHeight;
|
||||
@ -479,9 +479,9 @@ namespace Wpf_AiSportsMicrospace.Views.JumpRope
|
||||
bool hit = beats.Any(b => Math.Abs(b - currentTime) <= _beatTolerance);
|
||||
if (hit)
|
||||
{
|
||||
_musicJumpRopeContext.UserBeatSyncList[indexCopy] += 1;
|
||||
double left = _musicJumpRopeContext.UserBeatSyncList[0];
|
||||
double right = _musicJumpRopeContext.UserBeatSyncList[1];
|
||||
MusicJumpRopeContext.UserBeatSyncList[indexCopy] += 1;
|
||||
double left = MusicJumpRopeContext.UserBeatSyncList[0];
|
||||
double right = MusicJumpRopeContext.UserBeatSyncList[1];
|
||||
double total = left + right;
|
||||
|
||||
|
||||
@ -599,7 +599,7 @@ namespace Wpf_AiSportsMicrospace.Views.JumpRope
|
||||
userBox.Children.Add(userItem);
|
||||
_musicJumpRopeContext.UserList.Add(userItem);
|
||||
_musicJumpRopeContext.UserNumberList.Add("0");
|
||||
_musicJumpRopeContext.UserBeatSyncList.Add(0);
|
||||
MusicJumpRopeContext.UserBeatSyncList.Add(0);
|
||||
return userItem; //
|
||||
}
|
||||
|
||||
|
||||
@ -6,130 +6,185 @@
|
||||
xmlns:local="clr-namespace:Views.JumpRope"
|
||||
mc:Ignorable="d"
|
||||
xmlns:gif="http://wpfanimatedgif.codeplex.com"
|
||||
xmlns:hc="https://handyorg.github.io/handycontrol"
|
||||
Height="1080" Width="1920" Loaded="UserControl_Loaded">
|
||||
<Grid>
|
||||
<!--排行榜-->
|
||||
<Grid x:Name="RankingGrid" Margin="0,0,0,0" Height="1080" Width="1920" Visibility="Visible">
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/finish_bg.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="1920"
|
||||
Height="1080"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/1.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="0,85"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/2.png"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="451,134,0,0"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/3.png"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="0,149,451,0"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/top.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="1346"
|
||||
Height="163"
|
||||
Margin="0,168"
|
||||
/>
|
||||
|
||||
<Grid Width="1346" Height="520" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,331,0,0" x:Name="ScoreGrid">
|
||||
<Border Background="#FEDE50" CornerRadius="0,0,20,20"/>
|
||||
<Grid HorizontalAlignment="Center" VerticalAlignment="Top" Width="1344" Height="71">
|
||||
<Border Background="#f7f7f7"/>
|
||||
<TextBlock Text="排名" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="150 , 0" HorizontalAlignment="Left" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
<TextBlock Text="位置" FontSize="24" FontWeight="Bold" Foreground="#999999" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
<TextBlock Text="成绩" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="0 ,0,150, 0" HorizontalAlignment="Right" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
</Grid>
|
||||
|
||||
<!--<Grid HorizontalAlignment="Center" Margin="0,57" VerticalAlignment="Top" Width="1344" Height="71">
|
||||
<Border Background="#fff"/>
|
||||
<TextBlock Text="1" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="150 , 0" HorizontalAlignment="Left" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
<TextBlock Text="一号位" FontSize="24" FontWeight="Bold" Foreground="#999999" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
<TextBlock Text="100" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="0 ,0,150, 0" HorizontalAlignment="Right" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
</Grid>-->
|
||||
|
||||
</Grid>
|
||||
<Grid Width="368" Height="100" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,200,0,0">
|
||||
<TextBlock x:Name="name1" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number1" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Grid Width="369" Height="100" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="1225,231,0,0">
|
||||
<TextBlock x:Name="name3" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number3" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Grid Width="368" Height="100" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="310,226,0,0">
|
||||
<TextBlock x:Name="name2" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number2" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
|
||||
<Grid Margin="0,0,0,50" VerticalAlignment="Bottom" Height="182" Width="340" >
|
||||
<hc:Carousel IsCenter="True" AutoRun="True" Width="1920" Height="1080" VerticalAlignment="Center" Interval="3000">
|
||||
<!--多人跳绳排行榜-->
|
||||
<Grid x:Name="RankingGrid" Margin="0,0,0,0" Height="1080" Width="1920" Visibility="Visible">
|
||||
|
||||
<Image
|
||||
Source="/Resources/Img/Album/change_left.png"
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/finish_bg.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="1920"
|
||||
Height="1080"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/new/group/test_title.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="215"
|
||||
Margin="0,15,0,0"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/1.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="0,85"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/2.png"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="451,134,0,0"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/3.png"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Top"
|
||||
Width="120"
|
||||
Height="92"
|
||||
Margin="0,149,451,0"
|
||||
/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/top.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Top"
|
||||
Width="1346"
|
||||
Height="163"
|
||||
Margin="0,168"
|
||||
/>
|
||||
|
||||
<Grid Width="1346" Height="620" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,331,0,0" x:Name="ScoreGrid">
|
||||
<Border Background="#FEDE50" CornerRadius="0,0,20,20"/>
|
||||
<Grid HorizontalAlignment="Center" VerticalAlignment="Top" Width="1344" Height="71">
|
||||
<Border Background="#f7f7f7"/>
|
||||
<TextBlock Text="排名" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="150 , 0" HorizontalAlignment="Left" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
<TextBlock Text="位置" FontSize="24" FontWeight="Bold" Foreground="#999999" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
<TextBlock Text="成绩" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="0 ,0,150, 0" HorizontalAlignment="Right" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
</Grid>
|
||||
|
||||
<!--<Grid HorizontalAlignment="Center" Margin="0,57" VerticalAlignment="Top" Width="1344" Height="71">
|
||||
<Border Background="#fff"/>
|
||||
<TextBlock Text="1" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="150 , 0" HorizontalAlignment="Left" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
<TextBlock Text="一号位" FontSize="24" FontWeight="Bold" Foreground="#999999" HorizontalAlignment="Center" VerticalAlignment="Center"/>
|
||||
<TextBlock Text="100" FontSize="24" FontWeight="Bold" Foreground="#999999" Margin="0 ,0,150, 0" HorizontalAlignment="Right" VerticalAlignment="Center" TextAlignment="Center" Width="200"/>
|
||||
</Grid>-->
|
||||
|
||||
</Grid>
|
||||
<Grid Width="368" Height="100" HorizontalAlignment="Center" VerticalAlignment="Top" Margin="0,200,0,0">
|
||||
<TextBlock x:Name="name1" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number1" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Grid Width="369" Height="100" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="1225,231,0,0">
|
||||
<TextBlock x:Name="name3" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number3" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Grid Width="368" Height="100" HorizontalAlignment="Left" VerticalAlignment="Top" Margin="310,226,0,0">
|
||||
<TextBlock x:Name="name2" Text="??" FontSize="32" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" />
|
||||
<Grid HorizontalAlignment="Right">
|
||||
<Border Background="#e54229" CornerRadius="20" Width="110" Height="40"/>
|
||||
<Image
|
||||
Source="/Resources/Img/test_img/one_rope/finish_img/star.png"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
Width="22"
|
||||
Height="30"
|
||||
Margin="0,0,50,2"
|
||||
/>
|
||||
<TextBlock x:Name="number2" Text="999" FontSize="24" FontWeight="Bold" Foreground="#fff" HorizontalAlignment="Left" Margin="50,0,0,0" VerticalAlignment="Center" />
|
||||
</Grid>
|
||||
</Grid>
|
||||
|
||||
<Grid Margin="0,0,0,50" VerticalAlignment="Bottom" Height="182" Width="340" >
|
||||
<Image
|
||||
Source="/Resources/Img/Album/change_left.png"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="330"
|
||||
Margin="0,103,0,0"
|
||||
/>
|
||||
<Image
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/3.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="Forever"
|
||||
gif:ImageBehavior.AnimateInDesignMode="True"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="330"
|
||||
Margin="0,103,0,0"
|
||||
/>
|
||||
<Image
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/3.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="Forever"
|
||||
gif:ImageBehavior.AnimateInDesignMode="True"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Margin="-20,10,30,20"
|
||||
/>
|
||||
Margin="-20,10,30,20"
|
||||
/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</Grid>
|
||||
|
||||
<!--音乐跳绳排行榜-->
|
||||
<Grid x:Name="RankingGrid1" Margin="0,0,0,0" Height="1080" Width="1920" Visibility="Visible">
|
||||
<Grid.Background>
|
||||
<ImageBrush ImageSource="/Resources/Img/play_img/music_rope/play_bg.jpg" Stretch="UniformToFill"/>
|
||||
</Grid.Background>
|
||||
<!-- <Border Background="#1e1e1e" Opacity="0.8"></Border> -->
|
||||
|
||||
<Image x:Name="lose1" Visibility="Visible" Source="/Resources/Img/play_img/music_rope/lose.png" HorizontalAlignment="Left" VerticalAlignment="Center" Width="861" Height="662" Margin="982,0,0,0"/>
|
||||
<Image x:Name="lose2" Visibility="Visible" Source="/Resources/Img/play_img/music_rope/lose.png" HorizontalAlignment="Left" VerticalAlignment="Center" Width="861" Height="662" Margin="982,0,0,0"/>
|
||||
<Image x:Name="lose3" Visibility="Visible" Source="/Resources/Img/play_img/music_rope/lose.png" HorizontalAlignment="Left" VerticalAlignment="Center" Width="861" Height="662" Margin="982,0,0,0"/>
|
||||
|
||||
<Image x:Name="win1" Source="/Resources/Img/play_img/music_rope/win.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="861" Margin="60,-123,0,0"/>
|
||||
<Image x:Name="win2" Source="/Resources/Img/play_img/music_rope/win.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="861" Margin="60,-123,0,0"/>
|
||||
<Image x:Name="win3" Visibility="Hidden" Source="/Resources/Img/play_img/music_rope/win.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="861" Margin="982,-123,0,0"/>
|
||||
<Image x:Name="win4" Visibility="Hidden" Source="/Resources/Img/play_img/music_rope/win.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="861" Margin="982,-123,0,0"/>
|
||||
|
||||
<TextBlock x:Name="text1" Text="WIN" FontSize="100" FontWeight="UltraBold" FontStyle="Italic" Foreground="#fdcb50" Margin="206,433,0,0" TextAlignment="Center" HorizontalAlignment="Left" Width="230" />
|
||||
<TextBlock x:Name="text2" Text="LOSE" FontSize="100" FontWeight="UltraBold" FontStyle="Italic" Foreground="#7987a2" Margin="1114,427,0,0" TextAlignment="Center" HorizontalAlignment="Left" Width="254" />
|
||||
|
||||
<TextBlock x:Name="score3" Text="1000" FontSize="100" FontWeight="UltraBold" FontStyle="Italic" Foreground="#fff" Margin="206,558,0,0" TextAlignment="Center" HorizontalAlignment="Left" Width="246" />
|
||||
<TextBlock x:Name="score4" Text="1000" FontSize="100" FontWeight="UltraBold" FontStyle="Italic" Foreground="#fff" Margin="0,540,552,0" TextAlignment="Center" HorizontalAlignment="Right" Width="250" />
|
||||
<Image Source="/Resources/Img/play_img/music_rope/back.png" HorizontalAlignment="Left" VerticalAlignment="Top" Width="860" Margin="552,125,0,0" />
|
||||
|
||||
|
||||
<Grid Margin="0,0,0,60" VerticalAlignment="Bottom" Height="182" Width="340" >
|
||||
<Image
|
||||
Source="/Resources/Img/Album/change_left.png"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Width="330"
|
||||
Margin="0,103,0,0"
|
||||
/>
|
||||
<Image
|
||||
gif:ImageBehavior.AnimatedSource="/Resources/Img/Album/3.gif"
|
||||
gif:ImageBehavior.RepeatBehavior="Forever"
|
||||
gif:ImageBehavior.AnimateInDesignMode="True"
|
||||
HorizontalAlignment="Left"
|
||||
VerticalAlignment="Top"
|
||||
Margin="-20,10,30,20"
|
||||
/>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</hc:Carousel>
|
||||
|
||||
</Grid>
|
||||
</UserControl>
|
||||
|
||||
@ -28,7 +28,10 @@ namespace Views.JumpRope
|
||||
public partial class TrainingRecords : UserControl
|
||||
{
|
||||
private Main _mainWin => Application.Current.MainWindow as Main;
|
||||
private GroupJumpRopeContext _groupJumpRopeContext;
|
||||
//private GroupJumpRopeContext _groupJumpRopeContext;
|
||||
//private MusicJumpRopeContext _musicJumpRopeContext;
|
||||
|
||||
|
||||
UserControl newPage = null;
|
||||
public TrainingRecords()
|
||||
{
|
||||
@ -96,6 +99,7 @@ namespace Views.JumpRope
|
||||
public void LoadData()
|
||||
{
|
||||
ShowRankingBoard(GroupJumpRopeContext.RankList);
|
||||
showRank();
|
||||
}
|
||||
public void ShowRankingBoard(List<RankItem> list)
|
||||
{
|
||||
@ -163,6 +167,37 @@ namespace Views.JumpRope
|
||||
}
|
||||
}
|
||||
|
||||
public void showRank()
|
||||
{
|
||||
double left = MusicJumpRopeContext.UserBeatSyncList[0];
|
||||
double right = MusicJumpRopeContext.UserBeatSyncList[1];
|
||||
score4.Text = (left * 10).ToString();
|
||||
score3.Text = (right * 10).ToString();
|
||||
if (left > right)
|
||||
{
|
||||
lose1.Margin = new Thickness(60, 0, 0, 0);
|
||||
lose2.Margin = new Thickness(60, 0, 0, 0);
|
||||
lose3.Margin = new Thickness(60, 0, 0, 0);
|
||||
win1.Margin = new Thickness(980, -123, 0, 0);
|
||||
win2.Margin = new Thickness(980, -123, 0, 0);
|
||||
|
||||
text1.Text = "LOSE";
|
||||
text2.Text = "WIN";
|
||||
text1.Foreground = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#7987a2"));
|
||||
text2.Foreground = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#fdcb50"));
|
||||
}
|
||||
else if (right == left)
|
||||
{
|
||||
text2.Text = "WIN";
|
||||
text2.Foreground = new SolidColorBrush((Color)ColorConverter.ConvertFromString("#fdcb50"));
|
||||
lose1.Visibility = Visibility.Hidden;
|
||||
lose2.Visibility = Visibility.Hidden;
|
||||
lose3.Visibility = Visibility.Hidden;
|
||||
|
||||
win3.Visibility = Visibility.Visible;
|
||||
win4.Visibility = Visibility.Visible;
|
||||
}
|
||||
}
|
||||
public int DetectLeftHandRaise(Human human)
|
||||
{
|
||||
var calculator = PostureCalculate.CreateCalculator();
|
||||
|
||||