Changes in new-game.cpp [8d5e67b:cf2d1e5] in opengl-game


Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • new-game.cpp

    r8d5e67b rcf2d1e5  
    748748   obj.selected_colors = { 0.0f };
    749749
    750    T_model = translate(mat4(), vec3(0.0f, -1.2f, 1.8f));
     750   T_model = translate(mat4(), vec3(0.0f, -1.2f, 0.0f));
    751751   R_model = rotate(mat4(), 20.0f * (float)ONE_DEG_IN_RAD, vec3(1.0f, 0.0f, 0.0f));
    752752   R_model = mat4();
    753    obj.model_base = T_model * R_model * scale(mat4(), vec3(0.1f, 0.1f, 0.1f));
     753   obj.model_base = T_model * R_model * scale(mat4(), vec3(0.3f, 0.3f, 0.3f));
    754754
    755755   addObjectToScene(obj);
    756756
    757    spawnAsteroid(vec3(0.0f, -1.2f, -21.5f), color_sp);
    758    spawnAsteroid(vec3(1.0f, -1.2f, -21.5f), color_sp);
    759    spawnAsteroid(vec3(-0.5f, -1.2f, -20.8f), color_sp);
     757   spawnAsteroid(vec3(0.0f, -1.2f, -11.5f), color_sp);
     758   spawnAsteroid(vec3(1.0f, -1.2f, -11.5f), color_sp);
     759   spawnAsteroid(vec3(-0.5f, -0.7f, -10.8f), color_sp);
    760760
    761761   vector<SceneObject>::iterator obj_it;
     
    827827   //cam_pos = vec3(-2.1f, -1.5f, -1.5f); // Good position for checking ship faces
    828828   float cam_yaw = 0.0f * 2.0f * 3.14159f / 360.0f;
    829    float cam_pitch = -50.0f * 2.0f * 3.14159f / 360.0f;
     829   float cam_pitch = 0.0f * 2.0f * 3.14159f / 360.0f;
    830830
    831831   mat4 T = translate(mat4(), vec3(-cam_pos.x, -cam_pos.y, -cam_pos.z));
    832    mat4 yaw_mat = rotate(mat4(), -cam_yaw, vec3(0.0f, 1.0f, 0.0f));
    833    mat4 pitch_mat = rotate(mat4(), -cam_pitch, vec3(1.0f, 0.0f, 0.0f));
    834    mat4 R = pitch_mat * yaw_mat;
     832   mat4 R = mat4();
    835833   view_mat = R*T;
    836834
     
    966964
    967965         if (key_pressed[GLFW_KEY_DOWN]) {
    968             transformObject(objects[1], translate(mat4(), vec3(0.0f, 0.0f, 0.03f)), ubo);
     966            transformObject(objects[1], translate(mat4(), vec3(0.0f, 0.0f, 0.17f)), ubo);
    969967            transformObject(objects[2], translate(mat4(), vec3(0.0f, 0.0f, 0.06f)), ubo);
    970             transformObject(objects[3], translate(mat4(), vec3(0.0f, 0.0f, 0.04f)), ubo);
     968            transformObject(objects[3], translate(mat4(), vec3(0.0f, 0.0f, 0.11f)), ubo);
    971969         }
    972970      }
     
    16631661   mat4 T = translate(mat4(), pos);
    16641662   mat4 R = rotate(mat4(), 60.0f * (float)ONE_DEG_IN_RAD, vec3(1.0f, 1.0f, -1.0f));
    1665    obj.model_base = T * R * scale(mat4(), vec3(0.1f, 0.1f, 0.1f));
     1663   obj.model_base = T * R * scale(mat4(), vec3(0.2f, 0.2f, 0.2f));
    16661664
    16671665   addObjectToScene(obj);
Note: See TracChangeset for help on using the changeset viewer.