user193464
user193464

Reputation: 400

Display a sprite with no image - PyGame

I am working on a game project meant for learning and I was thinking if I create a sprite without a set image. I need this because I have an ideea to keep the value of the rect tiles that need collision in a sprite group. Is it possible?

Upvotes: 1

Views: 901

Answers (1)

Octo
Octo

Reputation: 727

Create a list of sprites excluding the invisible sprite(s):

all_sprites_list.draw(screen)

Then for collision just make a barrier list and put your invisible sprites that need collision in it.

Upvotes: 1

Related Questions