| 63 | } |
| 64 | |
| 65 | void Logic::Controller::importObject(const json& j) |
| 66 | { |
| 67 | Math::Matrix transform = Math::Matrix::CreateIdentity(); |
| 68 | |
| 69 | auto& jtrans = j["transform"]; |
| 70 | |
| 71 | // Parse transform from json |
| 72 | for (int i = 0; i < 16; i++) |
| 73 | if (!jtrans[i].is_null()) |
| 74 | transform.mv[i] = jtrans[i]; |
| 75 | |
| 76 | setEntityTransform(transform); |
| 77 | |
| 78 | Vob::VobInformation vob = Vob::asVob(m_World, m_Entity); |
| 79 | vob.object->m_EnableCollision = j["collision"]; |
| 80 | } |
no test coverage detected