now she stays on the ground i think
This commit is contained in:
parent
6fd0fc5868
commit
527315e976
@ -27,11 +27,11 @@ void GameObjectManager::initialize() {
|
||||
testObjMeshMutable.data = testObjMesh;
|
||||
testObjMeshMutable.RefreshVBO();
|
||||
|
||||
textMesh = ZL::LoadFromTextFile("./mesh_first_room.txt"); // Add ZL:: namespace
|
||||
textMesh.Scale(17);
|
||||
textMesh = ZL::LoadFromTextFile("./textures/mesh_first_room.txt"); // Add ZL:: namespace
|
||||
textMesh.Scale(10);
|
||||
textMesh.SwapZandY();
|
||||
textMesh.RotateByMatrix(QuatToMatrix(QuatFromRotateAroundX(M_PI * 0.5)));
|
||||
|
||||
textMesh.Move(Vector3f{0, 70, 0});
|
||||
|
||||
coneMesh = ZL::LoadFromTextFile("./cone001.txt"); // Add ZL:: namespace
|
||||
coneMesh.Scale(200);
|
||||
|
||||
@ -286,6 +286,13 @@ namespace ZL {
|
||||
PositionData[i] = PositionData[i] * scale;
|
||||
}
|
||||
}
|
||||
void VertexDataStruct::Move(Vector3f diff)
|
||||
{
|
||||
for (int i = 0; i < PositionData.size(); i++)
|
||||
{
|
||||
PositionData[i] = PositionData[i] + diff;
|
||||
}
|
||||
}
|
||||
|
||||
void VertexDataStruct::SwapZandY()
|
||||
{
|
||||
|
||||
@ -52,6 +52,7 @@ namespace ZL {
|
||||
void RotateByMatrix(Matrix3f m);
|
||||
|
||||
void Scale(float scale);
|
||||
void Move(Vector3f diff);
|
||||
void SwapZandY();
|
||||
};
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user