improved initialization

This commit is contained in:
Pascal Serrarens 2023-12-28 09:38:26 +01:00
parent 30c74c44a4
commit e0230a7684

View File

@ -5,17 +5,14 @@ Placement::Placement() {
this->thing = nullptr;
}
Placement::Placement(Thing* thing,
Vector3 position,
float horizontalDirection,
float verticalDirection) {
Placement::Placement(Thing *thing, Vector3 position, float horizontalDirection,
float verticalDirection)
: horizontalDirection(horizontalDirection),
verticalDirection(verticalDirection) {
this->thing = thing;
this->position = position;
this->horizontalDirection = horizontalDirection;
this->verticalDirection = verticalDirection;
}
Placement::Placement(Thing* thing,
float horizontalDirection,
Placement::Placement(Thing *thing, float horizontalDirection,
float verticalDirection)
: Placement(thing, Vector3::zero, horizontalDirection, verticalDirection) {}