| 744 | |
| 745 | template<typename T> |
| 746 | struct Object_Lifetime_Vector2 |
| 747 | { |
| 748 | Object_Lifetime_Vector2() : x(0), y(0) {} |
| 749 | Object_Lifetime_Vector2(T px, T py) : x(px), y(py) {} |
| 750 | Object_Lifetime_Vector2(const Object_Lifetime_Vector2& cp) : x(cp.x), y(cp.y) {} |
| 751 | |
| 752 | Object_Lifetime_Vector2& operator+=(const Object_Lifetime_Vector2& vec_r) |
| 753 | { |
| 754 | x += vec_r.x; |
| 755 | y += vec_r.y; |
| 756 | return *this; |
| 757 | } |
| 758 | |
| 759 | Object_Lifetime_Vector2 operator+(const Object_Lifetime_Vector2& vec_r) |
| 760 | { |
| 761 | return Object_Lifetime_Vector2(*this += vec_r); |
| 762 | } |
| 763 | |
| 764 | Object_Lifetime_Vector2 &operator=(const Object_Lifetime_Vector2& ver_r) |
| 765 | { |
| 766 | x = ver_r.x; |
| 767 | y = ver_r.y; |
| 768 | return *this; |
| 769 | } |
| 770 | |
| 771 | |
| 772 | T x; |
| 773 | T y; |
| 774 | }; |
| 775 | |
| 776 | Object_Lifetime_Vector2<float> Object_Lifetime_Vector2_GetValue() |
| 777 | { |