mirror of
https://github.com/MaddyThorson/StrawberryBF.git
synced 2025-07-19 20:11:55 +08:00
Sample game. Easing methods. Colors.
This commit is contained in:
@ -13,6 +13,9 @@ namespace Strawberry
|
||||
static public readonly Color Cyan = 0xFF00FFFF;
|
||||
static public readonly Color Magenta = 0xFFFF00FF;
|
||||
static public readonly Color Yellow = 0x00FFFFFF;
|
||||
static public readonly Color DarkGray = 0x3F3F3FFF;
|
||||
static public readonly Color Gray = 0x7F7F7FFF;
|
||||
static public readonly Color LightGray = 0xBFBFBFFF;
|
||||
|
||||
public uint8 R;
|
||||
public uint8 G;
|
||||
|
@ -51,6 +51,16 @@ namespace Strawberry
|
||||
return Point((int)Math.Round(X), (int)Math.Round(Y));
|
||||
}
|
||||
|
||||
static public Vector Lerp(Vector a, Vector b, float t)
|
||||
{
|
||||
if (t == 0)
|
||||
return a;
|
||||
else if (t == 1)
|
||||
return b;
|
||||
else
|
||||
return a + (b - a) * t;
|
||||
}
|
||||
|
||||
public override void ToString(String strBuffer)
|
||||
{
|
||||
strBuffer.Set("Vector [ ");
|
||||
|
Reference in New Issue
Block a user