3 #include "vehicletype.h"
9 Bogie3D::Bogie3D(const Vehicle3D &v, unsigned b):
10 VehiclePart3D(v, *v.get_type().get_bogie_object(b)),
11 bogie(vehicle.get_vehicle().get_bogie(b))
14 void Bogie3D::update_matrix()
16 matrix = vehicle.Object3D::get_matrix();
18 matrix.translate(bogie.type->position, 0, 0);
19 Angle dir = bogie.direction;
20 if(bogie.type->rotate_object)
21 dir += Angle::half_turn();
22 matrix.rotate(dir, 0, 0, 1);