本文整理汇总了C#中System.Drawing.Rect.fade方法的典型用法代码示例。如果您正苦于以下问题:C# Rect.fade方法的具体用法?C# Rect.fade怎么用?C# Rect.fade使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Drawing.Rect
的用法示例。
在下文中一共展示了Rect.fade方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: update
public void update(FrameEventArgs e)
{
if (enabled)
{
b.OnUpdateFrame(e);
b2.OnUpdateFrame(e);
}
if (avatar == null && done)
{
avatar = new Rect(new Rectangle(back.Bounds.X + 2, back.Bounds.Y+2, 100, 100), Path.GetTempPath() + u.Name + "av.jpg", false, false);
avatar.Alpha = 0;
avatar.fade(1, .3);
u.avatarRect = avatar;
done = false;
}
if (Utils.contains(back.ModifiedBounds) && Game.MouseState.LeftButton && canpress)
{
enabled = !enabled;
if (enabled)
{
playCount.Alpha = 0;
}
else
{
playCount.Alpha = 1;
}
canpress = false;
Game.lClickFrame = true;
}
else
{
if (!Game.MouseState.LeftButton)
{
canpress = true;
}
}
if (Utils.contains(back.ModifiedBounds) && !set)
{
playCount.Line = "Accuracy: " + u.Accuracy.ToString("N2")+"%";//("Song: " + u.CurrentSong + "\n" + u.CurrentChart);
set = true;
set1 = true;
} else {
if (set1 && !Utils.contains(back.ModifiedBounds))
{
playCount.Line = ("PC: " + u.Playcount + "\nScore: " + u.TotalScore + "\nLevel: " + u.Level);
set1 = false;
set = false;
}
}
}
示例2: burstAcc
private void burstAcc(int acc)
{
Rect tempTexture;
tempTexture = new Rect(new Rectangle(frame.Location.X + (int)(frame.Width / 2) - 15, (int)frame.HitHeight - 250, 30, 10), accsID[acc]);
tempTexture.Colour = Skin.AccColours[acc];
tempTexture.Lifespan = 0.20;
tempTexture.Alpha = 0.0f;
tempTexture.fade(1.0f, 0.07);
tempTexture.scale(new Size((int)frame.Width - 20, 100), 0.07);
tempTexture.move(new Point(frame.Location.X + 10, (int)frame.HitHeight - 300), 0.07);
accBurst = tempTexture;
}