title: pygame.QUIT() - TypeError: 'int' object is not callable
body: <p>I'm fairly new to python. I'm writing a code for a simple alien invasion game but I'm getting this error.</p>
  <pre><code>import sys
  import pygame
  from settings import Settings
  from ship import Ship
  import game_functions as gf
  
  def run_game():
      pygame.init()
      ai_settings = Settings()
      screen = pygame.display.set_mode((ai_settings.screen_width, ai_settings.screen_height))
      pygame.display.set_caption(&quot;Game&quot;)
      ship = Ship(screen)
      bg_color = (230, 230, 230)
  
      while True:
          gf.check_events(ship)
          ship.update()
          gf.update_screen(ai_settings, screen, ship)
          for event in pygame.event.get():
              if event.type==pygame.QUIT():
                  sys.exit()
          screen.fill(ai_settings.bg_color)
          ship.blitme()
          pygame.display.flip()
  run_game()
  </code></pre>
  <p>I'm aware that I'm accidentally calling some integer value but I have no clue where I'm going wrong.</p>
  <p>I have also checked these lines</p>
  <blockquote>
  <p>File &quot;C:/Users/Areeb Irfan/.PyCharmCE2018.3/config/scratches/AlienGame.py&quot;, line 25, in 
  run_game()<br />
  File &quot;C:/Users/Areeb Irfan/.PyCharmCE2018.3/config/scratches/AlienGame.py&quot;, line 16, in run_game
  gf.check_events(ship)<br />
  File &quot;C:\Users\Areeb Irfan.PyCharmCE2018.3\config\scratches\game_functions.py&quot;, line 5, in check_events
  if event.type==pygame.QUIT():<br />
  TypeError: 'int' object is not callable</p>
  </blockquote>