- Joined
- Nov 1, 2023
- Messages
- 1
- Reaction score
- 0
File "/home/runner/Python/main.py", line 9
pizza_img = image.load('pizza.img') = image.load('images/vampire.png')
^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: cannot assign to function call,
and this is what my code looks like:
import pygame
from pygame import *
pygame.init()
GAME_WINDOW = pygame.display.set_mode((900, 400))
pygame.display.set_caption('Attack of the Vampire Pizzas!')
pizza_img = image.load('pizza.img') = image.load('images/vampire.png')
surf = Surface.convert_alpha(pizza_img)
game_running = True
while game_running:
for event in pygame.event.get():
if event.type == pygame.QUIT:
game_running = False
GAME_WINDOW.fill((255, 255, 255))
pygame.display.update()
pygame.quit().
I don't know what is going on, but the top message is my error message, and i don't know what it means
pizza_img = image.load('pizza.img') = image.load('images/vampire.png')
^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: cannot assign to function call,
and this is what my code looks like:
import pygame
from pygame import *
pygame.init()
GAME_WINDOW = pygame.display.set_mode((900, 400))
pygame.display.set_caption('Attack of the Vampire Pizzas!')
pizza_img = image.load('pizza.img') = image.load('images/vampire.png')
surf = Surface.convert_alpha(pizza_img)
game_running = True
while game_running:
for event in pygame.event.get():
if event.type == pygame.QUIT:
game_running = False
GAME_WINDOW.fill((255, 255, 255))
pygame.display.update()
pygame.quit().
I don't know what is going on, but the top message is my error message, and i don't know what it means