mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
clientobject, clouds, collision, clientsimpleobject: code modernization (#6260)
* clientobject, clouds, collision, clientsimpleobject: code modernization * use range-based for loops * simplify some tests * various code style fixes * use emplace_back instead of push_back when necessary * use auto on some iterators * use default operator when needed * unroll v3s16 creation on collisionMoveSimple
This commit is contained in:
parent
9bd18874a1
commit
c738d1eeab
6 changed files with 41 additions and 44 deletions
|
@ -36,7 +36,8 @@ enum CollisionType
|
|||
|
||||
struct CollisionInfo
|
||||
{
|
||||
CollisionInfo() {}
|
||||
CollisionInfo() = default;
|
||||
|
||||
CollisionType type = COLLISION_NODE;
|
||||
v3s16 node_p = v3s16(-32768,-32768,-32768); // COLLISION_NODE
|
||||
v3f old_speed;
|
||||
|
@ -45,7 +46,8 @@ struct CollisionInfo
|
|||
|
||||
struct collisionMoveResult
|
||||
{
|
||||
collisionMoveResult() {}
|
||||
collisionMoveResult() = default;
|
||||
|
||||
bool touching_ground = false;
|
||||
bool collides = false;
|
||||
bool standing_on_object = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue