mirror of
https://github.com/krgamestudios/Toy.git
synced 2026-04-15 14:54:07 +10:00
Added partial cos and sine implementations
This commit is contained in:
@@ -157,6 +157,7 @@ import standard;
|
||||
assert typeof lerp(0, 10, 0) == float, "typeof lerp result failed";
|
||||
}
|
||||
|
||||
|
||||
// test toRad
|
||||
{
|
||||
assert toRad(0) == 0, "toRad 0° failed";
|
||||
@@ -164,6 +165,7 @@ import standard;
|
||||
assert toRad(360) == 2 * PI, "toRad 360° failed";
|
||||
}
|
||||
|
||||
|
||||
// test toDeg
|
||||
{
|
||||
assert toDeg(0) == 0, "toDeg 0 failed";
|
||||
@@ -171,6 +173,16 @@ import standard;
|
||||
assert toDeg(2 * PI) == 360, "toDeg 2π failed";
|
||||
}
|
||||
|
||||
// test sin
|
||||
{
|
||||
assert sin(PI) == 0, "sin π failed";
|
||||
}
|
||||
|
||||
|
||||
// test cos
|
||||
{
|
||||
assert cos(PI) == -1, "cos π failed";
|
||||
}
|
||||
|
||||
//test concat
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user