public Animat CreateAnimat(FrameworkElement target) { var ani = new Animat(target); Actions.Add(ani); return(ani); }
void MoveMerge(Animat ani) { ani.OnPlayOver = null; var si = ani.DataContext as SquareInfo; (ani.Target as Border).Visibility = Visibility.Collapsed; Animat a = si.Target; si = a.DataContext as SquareInfo; Border bor = a.Target as Border; bor.Background = color_buff[si.levevl]; TextBlock tb = bor.Child as TextBlock; tb.Text = si.Number.ToString(); if (si.Number > 1000) { tb.FontSize = 36; } tb.Foreground = color_buff[si.levevl + 1]; }
public void ReleaseAnimat(Animat ani) { Actions.Remove(ani); }