summaryrefslogtreecommitdiff
path: root/Runtime/Math/Vector2.h
blob: 5fb230c99901bd1851b46e75666e57d57252b2b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#pragma once

struct Vector2
{
	Vector2(float x=0, float y = 0)
	{
		this->x = x; 
		this->y = y;
	}
	inline void Set(float x, float y)
	{
		this->x = x;
		this->y = y;
	}

	bool operator == (const Vector2& v) const
	{
		return v.x == x && v.y == y;
	}

	bool operator != (const Vector2& v) const
	{
		return v.x != x || v.y != y;
	}

	float x, y;

	static Vector2 zero;
	static Vector2 one;
};