PyBreakNoid 1.16

A new version of ArkaPygame that changes name to PyBreakNoid, fusion of Pygame / Python Arkanoid and Breakout.

New Feature:

  • Big screen
  • new sounds
  • gun

Changes in the code

I put the display surface as the main surface

# The main surface where the display surface is blitted
display = pygame.display.set_mode((850, 850))
# A second surface where the sprite are blitted
screen = pygame.Surface((500, 500))

So, all the sprites are blitted on the small surface screen and then it is blitted scaled in display

display.blit(pygame.transform.scale(screen, (850, 850)), (0, 0))

Sound of gun

            if event.type == pygame.MOUSEBUTTONDOWN:
                if bullet.canfire:
                    print("fire")      
                    pygame.mixer.Sound.play(sounds["bang"])
                    bullet.x = bar.x + bar.w // 2
                    bullet.y = bar.y
                    bullet.fire = 1
                    bullet.canfire = 0

The sound of the brick broken or hit is now different

pygame.mixer.Sound.play(sounds["brick"])

All the sounds are mp3 now.

Where is the code?

Find the code in the github repository of ArkaPyGame aka PyBreakNoid.

1.1 – Pong the father of Arkanoid

Pong v. 1.0 – Pygame example

1.2 – Starting arkanoid… from pong

Arkanoid… let’s make it better…

1.3 – Adding background

ArkaPyGame 1.3 – Adding a background

1.4 – Collision detection

ArkaPygame 1.4 – Collision detected

1.5 – Bricks collisions

Arkanoid in pygame part 5

1.6 – Still on Collisions

Arkanoid part 6 – Still on bricks collision

1.7 – Fixed strange bouncing

Arkanoid 1.7 – Fixed strange bouncing

1.8 – How to destroy the bricks

Arkanoid 1.8 – First stage almost complete: destroy bricks

1.9 – More levels

Arkanoid 1.9 – more stages

2.1 – Infinite level generator

Arkanoid 2.0 – infinite levels

2.3 – Sounds and faster frame rate tecnique

ArkaPyGame 2.1 – Arkanoid like game made with Pygame

2.5 – New nicer levels simmetric and in color and menus

Arkanoid-Pygame 2.5 – New levels and menu

2.6 – Keyboard control

ArkaGame 2.6 – Adding keyboard commands

2.7 – Mouse exclusive control

Arkanoid 2.7 with Pygame – Mouse control

2.xxx – Tiny version

TinyArka – “Mini” version of Arkanoid with pygame

5.0 – Arkagame: 5 different versions

Breakout / Arkanoid – 5 versions in one (pygame)

Github repository
https://github.com/formazione/arkapygame


Subscribe to the newsletter for updates
Tkinter templates
Avatar My youtube channel

Twitter: @pythonprogrammi - python_pygame

Videos

Speech recognition game

Pygame's Platform Game

Other Pygame's posts

Published by pythonprogramming

Started with basic on the spectrum, loved javascript in the 90ies and python in the 2000, now I am back with python, still making some javascript stuff when needed.