-
-
Notifications
You must be signed in to change notification settings - Fork 193
Open
Labels
Description
Issue №3409 opened by ncassetta at 2022-08-20 08:15:03
The documentation of pygame.sprite.spritecollide() says:
spritecollide(sprite, group, dokill, collided = None) -> Sprite_list
. . .
The dokill argument is a bool. If set to True, all Sprites that collide will be removed from the Group.
The name dokill suggests that they are removed from all Groups, and in fact I see in pygame.sprite:1685 that kill() is called on the colliding sprites. This difference is relevant if the sprites in group belong to more than one Group, as they should be killed "manually" with other instructions (which are unneeded)
The same problem arises for pygame.sprite.groupcollide()
Comments
# # illume commented at 2022-09-18 10:45:35
Thanks for the issue report. I agree some clarity can be added to the documentation about what happens when a sprite is in all groups.