Merge pull request #504 from Martinfx/master

Fix potential bugs from static analysis
This commit is contained in:
Ray 2018-04-02 18:10:38 +02:00 committed by GitHub
commit 3e0de31424
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 110 additions and 126 deletions

View file

@ -39,8 +39,8 @@ int main()
SetPhysicsGravity(0, 0);
// Create random polygon physics body to shatter
PhysicsBody body = CreatePhysicsBodyPolygon((Vector2){ screenWidth/2, screenHeight/2 }, GetRandomValue(80, 200), GetRandomValue(3, 8), 10);
CreatePhysicsBodyPolygon((Vector2){ screenWidth/2, screenHeight/2 }, GetRandomValue(80, 200), GetRandomValue(3, 8), 10);
SetTargetFPS(60);
//--------------------------------------------------------------------------------------
@ -53,7 +53,7 @@ int main()
if (needsReset)
{
// Create random polygon physics body to shatter
body = CreatePhysicsBodyPolygon((Vector2){ screenWidth/2, screenHeight/2 }, GetRandomValue(80, 200), GetRandomValue(3, 8), 10);
CreatePhysicsBodyPolygon((Vector2){ screenWidth/2, screenHeight/2 }, GetRandomValue(80, 200), GetRandomValue(3, 8), 10);
}
if (IsKeyPressed('R')) // Reset physics input