mirror of
				https://github.com/raysan5/raylib.git
				synced 2025-10-26 12:27:01 +00:00 
			
		
		
		
	Remove unneeded comment
This commit is contained in:
		| @@ -57,7 +57,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);                  // Update camera |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -45,7 +45,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         if (IsKeyDown('Z')) camera.target = (Vector3){ 0.0f, 0.0f, 0.0f }; |         if (IsKeyDown('Z')) camera.target = (Vector3){ 0.0f, 0.0f, 0.0f }; | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|   | |||||||
| @@ -50,7 +50,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) |         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) | ||||||
|         { |         { | ||||||
|   | |||||||
| @@ -109,7 +109,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update camera (simulator mode) |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -46,7 +46,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Calculate cube screen space position (with a little offset to be in top) |         // Calculate cube screen space position (with a little offset to be in top) | ||||||
|         cubeScreenPosition = GetWorldToScreen((Vector3){cubePosition.x, cubePosition.y + 2.5f, cubePosition.z}, camera); |         cubeScreenPosition = GetWorldToScreen((Vector3){cubePosition.x, cubePosition.y + 2.5f, cubePosition.z}, camera); | ||||||
|   | |||||||
| @@ -46,7 +46,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -52,7 +52,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -57,7 +57,7 @@ int main(void) | |||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         Vector3 oldCamPos = camera.position;    // Store old camera position |         Vector3 oldCamPos = camera.position;    // Store old camera position | ||||||
|  |  | ||||||
|         UpdateCamera(&camera);      // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Check player collision (we simplify to 2D collision detection) |         // Check player collision (we simplify to 2D collision detection) | ||||||
|         Vector2 playerPos = { camera.position.x, camera.position.z }; |         Vector2 playerPos = { camera.position.x, camera.position.z }; | ||||||
|   | |||||||
| @@ -49,7 +49,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -48,7 +48,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update our camera with inputs |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -79,7 +79,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);      // Update our camera to orbit |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Cycle between models on mouse click |         // Cycle between models on mouse click | ||||||
|         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) currentModel = (currentModel + 1)%MAX_VOX_FILES; |         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) currentModel = (currentModel + 1)%MAX_VOX_FILES; | ||||||
|   | |||||||
| @@ -78,7 +78,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);      // Update internal camera and our camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) |         if (IsMouseButtonPressed(MOUSE_BUTTON_LEFT)) | ||||||
|         { |         { | ||||||
|   | |||||||
| @@ -73,7 +73,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);          // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Display information about closest hit |         // Display information about closest hit | ||||||
|         RayCollision collision = { 0 }; |         RayCollision collision = { 0 }; | ||||||
|   | |||||||
| @@ -97,7 +97,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Load new cubemap texture on drag&drop |         // Load new cubemap texture on drag&drop | ||||||
|         if (IsFileDropped()) |         if (IsFileDropped()) | ||||||
|   | |||||||
| @@ -90,7 +90,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         // Update the shader with the camera view vector (points towards { 0.0f, 0.0f, 0.0f }) |         // Update the shader with the camera view vector (points towards { 0.0f, 0.0f, 0.0f }) | ||||||
|         float cameraPos[3] = { camera.position.x, camera.position.y, camera.position.z }; |         float cameraPos[3] = { camera.position.x, camera.position.y, camera.position.z }; | ||||||
|   | |||||||
| @@ -78,6 +78,8 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |         UpdateCamera(&camera); | ||||||
|  |          | ||||||
|         Vector2 mousePosition = GetMousePosition(); |         Vector2 mousePosition = GetMousePosition(); | ||||||
|  |  | ||||||
|         swirlCenter[0] = mousePosition.x; |         swirlCenter[0] = mousePosition.x; | ||||||
| @@ -85,8 +87,6 @@ int main(void) | |||||||
|  |  | ||||||
|         // Send new value to the shader to be used on drawing |         // Send new value to the shader to be used on drawing | ||||||
|         SetShaderValue(shader, swirlCenterLoc, swirlCenter, SHADER_UNIFORM_VEC2); |         SetShaderValue(shader, swirlCenterLoc, swirlCenter, SHADER_UNIFORM_VEC2); | ||||||
|  |  | ||||||
|         UpdateCamera(&camera);          // Update camera |  | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -94,7 +94,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         if (IsKeyDown(KEY_UP)) |         if (IsKeyDown(KEY_UP)) | ||||||
|         { |         { | ||||||
|   | |||||||
| @@ -70,7 +70,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);                  // Update camera |         UpdateCamera(&camera); | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -118,7 +118,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         if (IsKeyPressed(KEY_RIGHT)) currentShader++; |         if (IsKeyPressed(KEY_RIGHT)) currentShader++; | ||||||
|         else if (IsKeyPressed(KEY_LEFT)) currentShader--; |         else if (IsKeyPressed(KEY_LEFT)) currentShader--; | ||||||
|   | |||||||
| @@ -66,7 +66,7 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|         UpdateCamera(&camera);              // Update camera |         UpdateCamera(&camera); | ||||||
|  |  | ||||||
|         float cameraPos[3] = { camera.position.x, camera.position.y, camera.position.z }; |         float cameraPos[3] = { camera.position.x, camera.position.y, camera.position.z }; | ||||||
|         float cameraTarget[3] = { camera.target.x, camera.target.y, camera.target.z }; |         float cameraTarget[3] = { camera.target.x, camera.target.y, camera.target.z }; | ||||||
|   | |||||||
| @@ -93,6 +93,8 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |         UpdateCamera(&camera); | ||||||
|  |          | ||||||
|         framesCounter++; |         framesCounter++; | ||||||
|         rotation.x += 0.01f; |         rotation.x += 0.01f; | ||||||
|         rotation.y += 0.005f; |         rotation.y += 0.005f; | ||||||
| @@ -103,8 +105,6 @@ int main(void) | |||||||
|  |  | ||||||
|         // Rotate one of the models |         // Rotate one of the models | ||||||
|         model1.transform = MatrixRotateXYZ(rotation); |         model1.transform = MatrixRotateXYZ(rotation); | ||||||
|  |  | ||||||
|         UpdateCamera(&camera); |  | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |  | ||||||
|         // Draw |         // Draw | ||||||
|   | |||||||
| @@ -141,6 +141,8 @@ int main(void) | |||||||
|     { |     { | ||||||
|         // Update |         // Update | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|  |         UpdateCamera(&camera); | ||||||
|  |          | ||||||
|         // Handle font files dropped |         // Handle font files dropped | ||||||
|         if (IsFileDropped()) |         if (IsFileDropped()) | ||||||
|         { |         { | ||||||
| @@ -265,7 +267,6 @@ int main(void) | |||||||
|         // Measure 3D text so we can center it |         // Measure 3D text so we can center it | ||||||
|         tbox = MeasureTextWave3D(font, text, fontSize, fontSpacing, lineSpacing); |         tbox = MeasureTextWave3D(font, text, fontSize, fontSpacing, lineSpacing); | ||||||
|  |  | ||||||
|         UpdateCamera(&camera);          // Update camera |  | ||||||
|         quads = 0;                      // Reset quad counter |         quads = 0;                      // Reset quad counter | ||||||
|         time += GetFrameTime();         // Update timer needed by `DrawTextWave3D()` |         time += GetFrameTime();         // Update timer needed by `DrawTextWave3D()` | ||||||
|         //---------------------------------------------------------------------------------- |         //---------------------------------------------------------------------------------- | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Ray
					Ray