Adding code x2

This commit is contained in:
2023-12-26 21:29:05 -06:00
parent d9bd070fd1
commit f90f1cf40b
25 changed files with 188 additions and 88 deletions

View File

@@ -1,11 +1,11 @@
#include <J3ML/LinearAlgebra/Vector2.h>
#include <cassert>
#include <algorithm>
#include <valarray>
namespace LinearAlgebra {
#pragma region vector2
Vector2::Vector2(): x(0), y(0)
{}
@@ -158,6 +158,7 @@ const Vector2 Vector2::Up = {0, -1};
const Vector2 Vector2::Down = {0, 1};
const Vector2 Vector2::Left = {-1, 0};
const Vector2 Vector2::Right = {1, 0};
const Vector2 Vector2::NaN = {NAN, NAN};
float Vector2::GetX() const { return x; }
@@ -171,5 +172,5 @@ const Vector2 Vector2::Right = {1, 0};
float Vector2::Length(const Vector2 &of) { return of.Length(); }
#pragma endregion
}