aboutsummaryrefslogtreecommitdiff
path: root/src/engine
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/bounds.cpp5
-rw-r--r--src/engine/bounds.hpp4
-rw-r--r--src/engine/vector2.cpp2
-rw-r--r--src/engine/vector2.hpp4
4 files changed, 9 insertions, 6 deletions
diff --git a/src/engine/bounds.cpp b/src/engine/bounds.cpp
index 782fd02..aa54439 100644
--- a/src/engine/bounds.cpp
+++ b/src/engine/bounds.cpp
@@ -1,6 +1,9 @@
#include "bounds.hpp"
-Bounds::Bounds(BoundsOpts opts) : _width(opts.width), _height(opts.height) {}
+Bounds::Bounds(const BoundsOptions &options)
+ : _width(options.width), _height(options.height)
+{
+}
unsigned int Bounds::width() const
{
diff --git a/src/engine/bounds.hpp b/src/engine/bounds.hpp
index 964e73a..0cadb9d 100644
--- a/src/engine/bounds.hpp
+++ b/src/engine/bounds.hpp
@@ -2,7 +2,7 @@
#include "engine/vector2.hpp"
-struct BoundsOpts
+struct BoundsOptions
{
unsigned int width;
unsigned int height;
@@ -11,7 +11,7 @@ struct BoundsOpts
class Bounds
{
public:
- explicit Bounds(BoundsOpts opts);
+ explicit Bounds(const BoundsOptions &options);
[[nodiscard]] unsigned int width() const;
diff --git a/src/engine/vector2.cpp b/src/engine/vector2.cpp
index 2d2283b..8a5a3c1 100644
--- a/src/engine/vector2.cpp
+++ b/src/engine/vector2.cpp
@@ -2,7 +2,7 @@
#include <memory>
-Vector2::Vector2(Vector2Opts opts) : _x(opts.x), _y(opts.y) {}
+Vector2::Vector2(const Vector2Options &options) : _x(options.x), _y(options.y) {}
unsigned int Vector2::x() const
{
diff --git a/src/engine/vector2.hpp b/src/engine/vector2.hpp
index f69008f..e0c0d6b 100644
--- a/src/engine/vector2.hpp
+++ b/src/engine/vector2.hpp
@@ -2,7 +2,7 @@
#include <memory>
-struct Vector2Opts
+struct Vector2Options
{
unsigned int x;
unsigned int y;
@@ -17,7 +17,7 @@ public:
/**
* Creates a 2D vector.
*/
- explicit Vector2(Vector2Opts opts);
+ explicit Vector2(const Vector2Options &options);
/**
* Returns the X coordinate.