├── .gitattributes ├── .gitignore ├── .pytest_cache └── v │ └── cache │ ├── lastfailed │ ├── nodeids │ └── stepwise ├── README.md ├── docs ├── .DS_Store ├── 10_games │ ├── breakout │ │ ├── app.py │ │ ├── asteroid.png │ │ ├── asteroids.py │ │ ├── ball.py │ │ ├── breakout.py │ │ ├── breakout.rst │ │ ├── pokemon-ball.png │ │ ├── space.png │ │ └── spaceship.png │ ├── games.rst │ ├── pong.py │ ├── pong1.png │ ├── pong1.py │ ├── pygamelib.py │ └── snake.py ├── 1_intro │ ├── AdditiveColorMixing.png │ ├── ball.gif │ ├── intro.rst │ ├── intro1.py │ ├── intro2.png │ ├── intro2.py │ ├── intro3.png │ ├── intro3.py │ ├── intro4.py │ ├── intro5.png │ ├── intro5.py │ ├── intro6.png │ └── intro6.py ├── 2_draw │ ├── draw.rst │ ├── draw1.png │ ├── draw1.py │ ├── draw2.png │ ├── draw2.py │ ├── mouse1.py │ ├── mouse2.png │ ├── mouse2.py │ ├── mouse3.png │ ├── mouse3.py │ ├── mouse4.png │ └── mouse4.py ├── 3_image │ ├── bird.png │ ├── image.rst │ ├── image0.png │ ├── image1.png │ ├── image1.py │ ├── image2.png │ ├── image2.py │ └── image3.png ├── 4_text │ ├── text.rst │ ├── text1.png │ ├── text1.py │ ├── text2.png │ ├── text2.py │ └── text3.py ├── 5_app │ ├── anim1.py │ ├── app.py │ ├── app.rst │ ├── app1.py │ ├── app2.png │ ├── app2.py │ ├── app3.py │ ├── app3a.png │ ├── app3b.png │ ├── app3c.png │ ├── app4.py │ ├── app4a.png │ ├── app4b.png │ ├── app4c.png │ ├── app5.py │ ├── app6.py │ ├── class0.py │ ├── class1.py │ ├── class2.py │ ├── node1.py │ ├── node1a.png │ ├── node1b.png │ ├── node1c.png │ ├── node2.py │ ├── node3.png │ ├── node3.py │ ├── node4.png │ ├── node4.py │ ├── node5.png │ └── node5.py ├── 6_gui │ ├── app.png │ ├── app.py │ ├── button1.png │ ├── button1.py │ ├── gui.rst │ ├── listbox1.png │ ├── listbox1.py │ ├── listbox2.png │ ├── listbox2.py │ ├── template.py │ ├── text1.png │ ├── text1.py │ ├── text2.png │ ├── text2.py │ ├── text3.png │ ├── text3.py │ ├── text4.png │ ├── text4.py │ └── text5.py ├── 7_sound │ ├── rpgaudio.ogg │ ├── sound.rst │ ├── sound1.png │ └── sound1.py ├── 8_platformer │ ├── app.py │ ├── hdst_tileset │ │ ├── full.png │ │ ├── green.svg │ │ ├── png │ │ │ ├── barrel.png │ │ │ ├── box.png │ │ │ ├── cloud.png │ │ │ ├── coin1.png │ │ │ ├── coin2.png │ │ │ ├── coin3.png │ │ │ ├── coin4.png │ │ │ ├── fence1.png │ │ │ ├── fence2.png │ │ │ ├── fence3.png │ │ │ ├── grass1.png │ │ │ ├── grass2.png │ │ │ ├── grass3.png │ │ │ ├── ground1.png │ │ │ ├── ground10.png │ │ │ ├── ground11.png │ │ │ ├── ground12.png │ │ │ ├── ground13.png │ │ │ ├── ground14.png │ │ │ ├── ground15.png │ │ │ ├── ground16.png │ │ │ ├── ground2.png │ │ │ ├── ground3.png │ │ │ ├── ground4.png │ │ │ ├── ground5.png │ │ │ ├── ground6.png │ │ │ ├── ground7.png │ │ │ ├── ground8.png │ │ │ ├── ground9.png │ │ │ ├── heart1.png │ │ │ ├── heart2.png │ │ │ ├── mushroom.png │ │ │ ├── pointer1.png │ │ │ ├── pointer2.png │ │ │ ├── pointer3.png │ │ │ ├── pointer4.png │ │ │ ├── rock.png │ │ │ ├── spike.png │ │ │ ├── spring1.png │ │ │ ├── spring2.png │ │ │ ├── stairs.png │ │ │ ├── water1.png │ │ │ ├── water2.png │ │ │ └── water3.png │ │ ├── preview.png │ │ └── sample.png │ ├── images │ │ ├── fall.jpg │ │ ├── player1.png │ │ └── player2.png │ ├── plateform1.py │ └── platformer.py ├── 9_board │ ├── app.png │ ├── app.py │ ├── board.rst │ ├── board0.py │ ├── board1.png │ ├── board1.py │ ├── board2.png │ ├── board2.py │ ├── board3.png │ ├── board3.py │ ├── board4.png │ ├── board4.py │ ├── board5.py │ ├── boardgames.py │ ├── chess.png │ ├── chess.py │ ├── chess │ │ ├── 1b_pawn.png │ │ ├── 1w_pawn.png │ │ ├── 2b_rook.png │ │ ├── 2w_rook.png │ │ ├── 3b_horse.png │ │ ├── 3w_horse.png │ │ ├── 4b_bishop.png │ │ ├── 4w_bishop.png │ │ ├── 5b_queen.png │ │ ├── 5w_queen.png │ │ ├── 6b_king.png │ │ └── 6w_king.png │ ├── nurikabe.png │ ├── nurikabe.py │ ├── puzzle.png │ ├── puzzle.py │ ├── pygamelib.py │ ├── sudoku.png │ └── sudoku.py ├── Makefile ├── animals │ ├── bird-icon.png │ ├── black-cat-icon.png │ ├── bulldog-icon.png │ ├── bunny-icon.png │ ├── cardinal-icon.png │ ├── cat-icon.png │ ├── chicken-icon.png │ ├── chihuahua-icon.png │ ├── cow-icon.png │ ├── crab-icon.png │ ├── dachshund-icon.png │ ├── dog-icon.png │ ├── dolphin-icon.png │ ├── donkey-icon.png │ ├── duck-icon.png │ ├── fish-icon.png │ ├── frog-icon.png │ ├── gold-fish-icon.png │ ├── hamster-icon.png │ ├── horse-icon.png │ ├── jellyfish-icon.png │ ├── kitten-icon.png │ ├── license.txt │ ├── lobster-icon.png │ ├── mouse-icon.png │ ├── octopus-icon.png │ ├── parrot-icon.png │ ├── pig-icon.png │ ├── pony-icon.png │ ├── puppy-icon.png │ ├── rabbit-icon.png │ ├── seal-icon.png │ ├── shark-icon.png │ ├── sheep-icon.png │ ├── squid-icon.png │ ├── squirrel-icon.png │ ├── tropical-fish-icon.png │ ├── tuna-icon.png │ ├── turkey-icon.png │ ├── turtle-icon.png │ └── whale-icon.png ├── background │ ├── forest.jpg │ ├── lake.jpg │ └── sunset.jpg ├── conf.py ├── console.py ├── editor │ └── editor.rst ├── hacker │ ├── hacker.py │ ├── hacker1.py │ ├── icons │ │ ├── address-book-alt.png │ │ ├── address-book.png │ │ ├── bag.png │ │ ├── basket.png │ │ ├── beer.png │ │ ├── bell.png │ │ ├── bitcoin.png │ │ ├── book-bookmark.png │ │ ├── book.png │ │ ├── box-full.png │ │ ├── box-in.png │ │ ├── box-out.png │ │ ├── box.png │ │ ├── brick-alt.png │ │ ├── brick.png │ │ ├── bubble.png │ │ ├── bubbles-alt.png │ │ ├── bubbles.png │ │ ├── building.png │ │ ├── bullhorn.png │ │ ├── calculator.png │ │ ├── calendar-clock.png │ │ ├── calendar.png │ │ ├── carton.png │ │ ├── cat.png │ │ ├── clock.png │ │ ├── cloud-down.png │ │ ├── cloud-sync.png │ │ ├── cloud-up.png │ │ ├── cloud.png │ │ ├── cog.png │ │ ├── cogs.png │ │ ├── compass.png │ │ ├── cone.png │ │ ├── dashboard-alt.png │ │ ├── dashboard.png │ │ ├── database.png │ │ ├── device-camera.png │ │ ├── device-computer.png │ │ ├── device-drive.png │ │ ├── device-laptop.png │ │ ├── device-mobile-phone.png │ │ ├── device-tablet.png │ │ ├── device-tv.png │ │ ├── disc-vinyl.png │ │ ├── disc.png │ │ ├── drop.png │ │ ├── envelope-letter.png │ │ ├── envelope.png │ │ ├── file-bookmark.png │ │ ├── file-code.png │ │ ├── file-empty.png │ │ ├── file-excel.png │ │ ├── file-exe.png │ │ ├── file-font.png │ │ ├── file-illustrator.png │ │ ├── file-indesign.png │ │ ├── file-link.png │ │ ├── file-note.png │ │ ├── file-pdf.png │ │ ├── file-photoshop.png │ │ ├── file-picture.png │ │ ├── file-powerpoint.png │ │ ├── file-premiere.png │ │ ├── file-sound.png │ │ ├── file-text.png │ │ ├── file-video.png │ │ ├── file-word.png │ │ ├── file-zip.png │ │ ├── flag-alt.png │ │ ├── flag.png │ │ ├── flask.png │ │ ├── floppy.png │ │ ├── flower.png │ │ ├── folder-document.png │ │ ├── folder-house.png │ │ ├── folder-music.png │ │ ├── folder-picture.png │ │ ├── folder-video.png │ │ ├── folder.png │ │ ├── funnel.png │ │ ├── gamepad.png │ │ ├── gift.png │ │ ├── globe.png │ │ ├── handshake.png │ │ ├── headphone.png │ │ ├── heart.png │ │ ├── house.png │ │ ├── institution.png │ │ ├── key.png │ │ ├── keyring.png │ │ ├── layers.png │ │ ├── life-buoy.png │ │ ├── light-bulb.png │ │ ├── lightning.png │ │ ├── lock-open.png │ │ ├── lock.png │ │ ├── magnify-less.png │ │ ├── magnify.png │ │ ├── map-map-marker.png │ │ ├── map-marker.png │ │ ├── map.png │ │ ├── microphone.png │ │ ├── mixer.png │ │ ├── money.png │ │ ├── monitor.png │ │ ├── news.png │ │ ├── notepad.png │ │ ├── paper-plane.png │ │ ├── paperclip.png │ │ ├── pencil.png │ │ ├── phone.png │ │ ├── pin.png │ │ ├── post-it.png │ │ ├── profile-group.png │ │ ├── profile.png │ │ ├── puzzle.png │ │ ├── radio.png │ │ ├── rss.png │ │ ├── safe.png │ │ ├── search.png │ │ ├── shield-error.png │ │ ├── shield-ok.png │ │ ├── shield-warning.png │ │ ├── shield.png │ │ ├── shop.png │ │ ├── sign-add.png │ │ ├── sign-ban.png │ │ ├── sign-check.png │ │ ├── sign-delete.png │ │ ├── sign-down.png │ │ ├── sign-error.png │ │ ├── sign-info.png │ │ ├── sign-left.png │ │ ├── sign-question.png │ │ ├── sign-right.png │ │ ├── sign-sync.png │ │ ├── sign-up.png │ │ ├── sign-warning.png │ │ ├── skull.png │ │ ├── snow-flake.png │ │ ├── social-facebook.png │ │ ├── social-google-plus.png │ │ ├── social-twitter.png │ │ ├── social-youtube.png │ │ ├── stamp.png │ │ ├── star-alt.png │ │ ├── star.png │ │ ├── sun.png │ │ ├── switch-off.png │ │ ├── switch-on.png │ │ ├── tag-alt.png │ │ ├── tag.png │ │ ├── terminal.png │ │ ├── thumb-up.png │ │ ├── trashcan-full.png │ │ ├── trashcan.png │ │ ├── user-female-alt.png │ │ ├── user-female.png │ │ ├── user-id.png │ │ ├── user-male-alt.png │ │ ├── user-male.png │ │ ├── webcam.png │ │ ├── window-layout.png │ │ ├── window-system.png │ │ ├── window.png │ │ ├── wine.png │ │ ├── wrench-screwdriver.png │ │ └── wrench.png │ ├── images │ │ ├── hacked.png │ │ ├── hacker.jpg │ │ └── screen.jpg │ └── pglib ├── index.rst ├── make.bat ├── rect │ ├── rect.py │ ├── rect.rst │ ├── rect1.png │ ├── rect1.py │ ├── rect10.png │ ├── rect10.py │ ├── rect11.png │ ├── rect11.py │ ├── rect2.png │ ├── rect2.py │ ├── rect3.png │ ├── rect3.py │ ├── rect4.png │ ├── rect4.py │ ├── rect5.png │ ├── rect5.py │ ├── rect6.png │ ├── rect6.py │ ├── rect7.png │ ├── rect7.py │ ├── rect8.png │ ├── rect8.py │ ├── rect9.png │ └── rect9.py ├── requirements.txt ├── space │ ├── images │ │ ├── space.jpg │ │ ├── spaceship.png │ │ └── ufo.png │ ├── sounds │ │ └── Intergalactic Odyssey.ogg │ ├── space.rst │ ├── space0.py │ ├── space1.py │ └── space2.py ├── sphinx.rst ├── sprite │ ├── png │ │ ├── BG │ │ │ └── BG.png │ │ ├── Object │ │ │ ├── Bush (1).png │ │ │ ├── Bush (2).png │ │ │ ├── Bush (3).png │ │ │ ├── Bush (4).png │ │ │ ├── Crate.png │ │ │ ├── Mushroom_1.png │ │ │ ├── Mushroom_2.png │ │ │ ├── Sign_1.png │ │ │ ├── Sign_2.png │ │ │ ├── Stone.png │ │ │ ├── Tree_1.png │ │ │ ├── Tree_2.png │ │ │ └── Tree_3.png │ │ └── Tiles │ │ │ ├── 1.png │ │ │ ├── 10.png │ │ │ ├── 11.png │ │ │ ├── 12.png │ │ │ ├── 13.png │ │ │ ├── 14.png │ │ │ ├── 15.png │ │ │ ├── 16.png │ │ │ ├── 17.png │ │ │ ├── 18.png │ │ │ ├── 2.png │ │ │ ├── 3.png │ │ │ ├── 4.png │ │ │ ├── 5.png │ │ │ ├── 6.png │ │ │ ├── 7.png │ │ │ ├── 8.png │ │ │ └── 9.png │ ├── sounds │ │ ├── click.wav │ │ ├── click_2.wav │ │ ├── load.wav │ │ ├── misc_menu.wav │ │ ├── misc_menu_2.wav │ │ ├── misc_menu_3.wav │ │ ├── misc_menu_4.wav │ │ ├── misc_sound.wav │ │ ├── negative.wav │ │ ├── negative_2.wav │ │ ├── positive.wav │ │ ├── save.wav │ │ └── sharp_echo.wav │ ├── sprite.rst │ └── sprite0.py ├── tiles │ ├── Overworld.tsx │ ├── gfx │ │ ├── Inner.png │ │ ├── NPC_test.png │ │ ├── Overworld.png │ │ ├── cave.png │ │ ├── character.png │ │ ├── font.png │ │ ├── log.png │ │ └── objects.png │ ├── map1.tmx │ ├── map2.tmx │ ├── map3.tmx │ ├── map4.tmx │ ├── tiled-demo │ │ ├── README.md │ │ ├── main.py │ │ └── resources │ │ │ ├── level1.tmx │ │ │ ├── overlay.png │ │ │ ├── player.png │ │ │ └── tiles.png │ ├── tiles.rst │ ├── tiles0.py │ ├── tiles1.py │ ├── tiles2.png │ ├── tiles2.py │ ├── tiles2b.png │ ├── tiles3.png │ ├── tiles3.py │ ├── tmw_desert_spacing.png │ └── tmw_desert_spacing.tsx ├── tmp.py └── todo.txt ├── images ├── cat.jpg ├── river.jpg ├── sunset.jpg └── ui │ ├── blue_boxCheckmark.png │ ├── blue_boxCross.png │ ├── blue_boxTick.png │ ├── blue_button00.png │ ├── blue_button01.png │ ├── blue_button02.png │ ├── blue_button03.png │ ├── blue_button04.png │ ├── blue_button05.png │ ├── blue_button06.png │ ├── blue_button07.png │ ├── blue_button08.png │ ├── blue_button09.png │ ├── blue_button10.png │ ├── blue_button11.png │ ├── blue_button12.png │ ├── blue_button13.png │ ├── blue_checkmark.png │ ├── blue_circle.png │ ├── blue_cross.png │ ├── blue_panel.png │ ├── blue_sliderDown.png │ ├── blue_sliderLeft.png │ ├── blue_sliderRight.png │ ├── blue_sliderUp.png │ ├── blue_tick.png │ ├── dropdownBottom.png │ ├── dropdownMid.png │ ├── dropdownTop.png │ ├── green_boxCheckmark.png │ ├── green_boxCross.png │ ├── green_boxTick.png │ ├── green_button00.png │ ├── green_button01.png │ ├── green_button02.png │ ├── green_button03.png │ ├── green_button04.png │ ├── green_button05.png │ ├── green_button06.png │ ├── green_button07.png │ ├── green_button08.png │ ├── green_button09.png │ ├── green_button10.png │ ├── green_button11.png │ ├── green_button12.png │ ├── green_button13.png │ ├── green_checkmark.png │ ├── green_circle.png │ ├── green_cross.png │ ├── green_panel.png │ ├── green_sliderDown.png │ ├── green_sliderLeft.png │ ├── green_sliderRight.png │ ├── green_sliderUp.png │ ├── green_tick.png │ ├── grey_arrowDownGrey.png │ ├── grey_arrowDownWhite.png │ ├── grey_arrowUpGrey.png │ ├── grey_arrowUpWhite.png │ ├── grey_box.png │ ├── grey_boxCheckmark.png │ ├── grey_boxCross.png │ ├── grey_boxTick.png │ ├── grey_button00.png │ ├── grey_button01.png │ ├── grey_button02.png │ ├── grey_button03.png │ ├── grey_button04.png │ ├── grey_button05.png │ ├── grey_button06.png │ ├── grey_button07.png │ ├── grey_button08.png │ ├── grey_button09.png │ ├── grey_button10.png │ ├── grey_button11.png │ ├── grey_button12.png │ ├── grey_button13.png │ ├── grey_button14.png │ ├── grey_button15.png │ ├── grey_checkmarkGrey.png │ ├── grey_checkmarkWhite.png │ ├── grey_circle.png │ ├── grey_crossGrey.png │ ├── grey_crossWhite.png │ ├── grey_panel.png │ ├── grey_sliderDown.png │ ├── grey_sliderEnd.png │ ├── grey_sliderHorizontal.png │ ├── grey_sliderLeft.png │ ├── grey_sliderRight.png │ ├── grey_sliderUp.png │ ├── grey_sliderVertical.png │ ├── grey_tickGrey.png │ ├── grey_tickWhite.png │ ├── red_boxCheckmark.png │ ├── red_boxCross.png │ ├── red_boxTick.png │ ├── red_button00.png │ ├── red_button01.png │ ├── red_button02.png │ ├── red_button03.png │ ├── red_button04.png │ ├── red_button05.png │ ├── red_button06.png │ ├── red_button07.png │ ├── red_button08.png │ ├── red_button09.png │ ├── red_button10.png │ ├── red_button11.png │ ├── red_button12.png │ ├── red_button13.png │ ├── red_checkmark.png │ ├── red_circle.png │ ├── red_cross.png │ ├── red_panel.png │ ├── red_sliderDown.png │ ├── red_sliderLeft.png │ ├── red_sliderRight.png │ ├── red_sliderUp.png │ ├── red_tick.png │ ├── yellow_boxCheckmark.png │ ├── yellow_boxCross.png │ ├── yellow_boxTick.png │ ├── yellow_button00.png │ ├── yellow_button01.png │ ├── yellow_button02.png │ ├── yellow_button03.png │ ├── yellow_button04.png │ ├── yellow_button05.png │ ├── yellow_button06.png │ ├── yellow_button07.png │ ├── yellow_button08.png │ ├── yellow_button09.png │ ├── yellow_button10.png │ ├── yellow_button11.png │ ├── yellow_button12.png │ ├── yellow_button13.png │ ├── yellow_checkmark.png │ ├── yellow_circle.png │ ├── yellow_cross.png │ ├── yellow_panel.png │ ├── yellow_sliderDown.png │ ├── yellow_sliderLeft.png │ ├── yellow_sliderRight.png │ ├── yellow_sliderUp.png │ └── yellow_tick.png ├── notes.md ├── pglib ├── __init__.py ├── app.py ├── draw.py ├── gui.py ├── platformer.py ├── test_options.py └── text.py ├── pygamelib.py └── test ├── pg_app.py └── test_node.py /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.pytest_cache/v/cache/lastfailed: -------------------------------------------------------------------------------- 1 | { 2 | "test/test_node.py": true 3 | } -------------------------------------------------------------------------------- /.pytest_cache/v/cache/nodeids: -------------------------------------------------------------------------------- 1 | [] -------------------------------------------------------------------------------- /.pytest_cache/v/cache/stepwise: -------------------------------------------------------------------------------- 1 | [] -------------------------------------------------------------------------------- /docs/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/.DS_Store -------------------------------------------------------------------------------- /docs/10_games/breakout/asteroid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/10_games/breakout/asteroid.png -------------------------------------------------------------------------------- /docs/10_games/breakout/ball.py: -------------------------------------------------------------------------------- 1 | # App with a bouncing ball 2 | 3 | from app import * 4 | 5 | class Ball: 6 | def __init__(self, file=None, size=(50, 50)): 7 | self.rect = Rect(50, 50, 20, 20) 8 | self.color = 'red' 9 | self.speed = [2, 1] 10 | if file: 11 | self.image = pygame.image.load(file) 12 | self.image = pygame.transform.scale(self.image, size) 13 | else: 14 | self.image = pygame.Surface(self.rect.size) 15 | self.image.fill(self.color) 16 | 17 | def do(self, event): 18 | # react to events 19 | if event.type == MOUSEBUTTONDOWN: 20 | self.rect.center = event.pos 21 | 22 | def update(self): 23 | # move or interact with other objects 24 | self.rect.move_ip(self.speed) 25 | 26 | def draw(self, surf): 27 | surf.blit(self.image, self.rect) 28 | 29 | if __name__ == '__main__': 30 | app = App() 31 | ball = Ball('pokemon-ball.png') 32 | app.add(ball) 33 | app.run() -------------------------------------------------------------------------------- /docs/10_games/breakout/breakout.py: -------------------------------------------------------------------------------- 1 | # Breakout game 2 | 3 | class Brick: 4 | def __init__(self): 5 | pass 6 | 7 | 8 | class Wall: 9 | def __init__(self): 10 | pass 11 | 12 | 13 | class App: 14 | def __init__(self): 15 | # does nothing 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /docs/10_games/breakout/pokemon-ball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/10_games/breakout/pokemon-ball.png -------------------------------------------------------------------------------- /docs/10_games/breakout/space.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/10_games/breakout/space.png -------------------------------------------------------------------------------- /docs/10_games/breakout/spaceship.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/10_games/breakout/spaceship.png -------------------------------------------------------------------------------- /docs/10_games/games.rst: -------------------------------------------------------------------------------- 1 | Simple games 2 | ============ 3 | 4 | Pong 5 | ---- 6 | 7 | .. image:: pong1.png 8 | 9 | .. literalinclude:: pong.py 10 | :lines: 3- 11 | 12 | :download:`pong.py` 13 | -------------------------------------------------------------------------------- /docs/10_games/pong1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/10_games/pong1.png -------------------------------------------------------------------------------- /docs/10_games/pong1.py: -------------------------------------------------------------------------------- 1 | """Create a game of pong.""" 2 | from app import * 3 | 4 | class Ball(Node): 5 | def __init__(self): 6 | speed = [1, 1] 7 | 8 | class Pong(Node): 9 | def __init__(self, **options): 10 | super().__init__(**options) 11 | self.dx = 1 12 | self.dy = 1 13 | self.ball = Node(pos=self.rect.center, size=(20, 20), bg=Color('blue')) 14 | 15 | def update(self): 16 | b = self.ball.rect 17 | f = self.rect 18 | b.move_ip((self.dx, self.dy)) 19 | if b.top < f.top or b.bottom > f.bottom: 20 | self.dy *= -1 21 | if b.left < f.left or b.right > f.right: 22 | self.dx *= -1 23 | 24 | def draw(self): 25 | pygame.draw.rect(App.screen, Color('red'), self.rect, 2) 26 | self.ball.draw() 27 | Node.draw(self) 28 | 29 | class Demo(App): 30 | def __init__(self): 31 | super().__init__() 32 | Scene(caption='PONG') 33 | Pong(size=(300, 200)) 34 | 35 | if __name__ == '__main__': 36 | Demo().run() -------------------------------------------------------------------------------- /docs/10_games/pygamelib.py: -------------------------------------------------------------------------------- 1 | ../../pygamelib.py -------------------------------------------------------------------------------- /docs/10_games/snake.py: -------------------------------------------------------------------------------- 1 | """Template for making games.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | from pygamelib import * 6 | 7 | class Snake(Shape): 8 | """Represent the snake as a list of coordinates.""" 9 | def __init__(self, board): 10 | super(Snake, self).__init__() 11 | self.board = board 12 | self.snake = [[0, 0], [1, 0], [2, 0]] 13 | self.dir = 0 14 | 15 | def draw(self): 16 | for index in self.snake: 17 | self.board.fill(index, GREEN) 18 | 19 | def on_key(self, event): 20 | print(event) 21 | d = {K_UP:0, K_DOWN:0, K_LEFT:0, K_RIGHT:0} 22 | if event.key in d: 23 | print(event) 24 | 25 | class SnakeDemo(App): 26 | """Make a subclass of the Game class.""" 27 | def __init__(self): 28 | super(SnakeDemo, self).__init__() 29 | Text('Snake', size=48, bgcolor=CYAN) 30 | Text('Eat the apples', size=24) 31 | 32 | board = Board(10, 20, pos=(200, 10)) 33 | Snake(board) 34 | 35 | if __name__ == '__main__': 36 | SnakeDemo().run() -------------------------------------------------------------------------------- /docs/1_intro/AdditiveColorMixing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/AdditiveColorMixing.png -------------------------------------------------------------------------------- /docs/1_intro/ball.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/ball.gif -------------------------------------------------------------------------------- /docs/1_intro/intro1.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | 3 | pygame.init() 4 | screen = pygame.display.set_mode((640, 240)) 5 | 6 | while True: 7 | for event in pygame.event.get(): 8 | print(event) -------------------------------------------------------------------------------- /docs/1_intro/intro2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/intro2.png -------------------------------------------------------------------------------- /docs/1_intro/intro2.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | 3 | pygame.init() 4 | screen = pygame.display.set_mode((640, 240)) 5 | 6 | running = True 7 | while running: 8 | for event in pygame.event.get(): 9 | if event.type == pygame.QUIT: 10 | running = False 11 | 12 | pygame.quit() -------------------------------------------------------------------------------- /docs/1_intro/intro3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/intro3.png -------------------------------------------------------------------------------- /docs/1_intro/intro3.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | 3 | BLACK = (0, 0, 0) 4 | RED = (255, 0, 0) 5 | GREEN = (0, 255, 0) 6 | BLUE = (0, 0, 255) 7 | 8 | YELLOW = (255, 255, 0) 9 | CYAN = (0, 255, 255) 10 | MAGENTA = (255, 0, 255) 11 | WHITE = (255, 255, 255) 12 | 13 | pygame.init() 14 | screen = pygame.display.set_mode((640, 240)) 15 | 16 | running = True 17 | while running: 18 | for event in pygame.event.get(): 19 | if event.type == pygame.QUIT: 20 | running = False 21 | 22 | print(event) 23 | 24 | screen.fill(YELLOW) 25 | pygame.display.update() 26 | 27 | pygame.quit() -------------------------------------------------------------------------------- /docs/1_intro/intro4.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | from pygame.locals import * 3 | 4 | BLACK = (0, 0, 0) 5 | RED = (255, 0, 0) 6 | GREEN = (0, 255, 0) 7 | BLUE = (0, 0, 255) 8 | 9 | YELLOW = (255, 255, 0) 10 | CYAN = (0, 255, 255) 11 | MAGENTA = (255, 0, 255) 12 | GRAY = (127, 127, 127) 13 | WHITE = (255, 255, 255) 14 | 15 | pygame.init() 16 | screen = pygame.display.set_mode((640, 240)) 17 | 18 | running = True 19 | background = GRAY 20 | while running: 21 | for event in pygame.event.get(): 22 | if event.type == pygame.QUIT: 23 | running = False 24 | if event.type == pygame.KEYDOWN: 25 | if event.key == pygame.K_r: 26 | background = RED 27 | elif event.key == pygame.K_g: 28 | background = GREEN 29 | 30 | screen.fill(background) 31 | pygame.display.flip() 32 | 33 | pygame.quit() -------------------------------------------------------------------------------- /docs/1_intro/intro5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/intro5.png -------------------------------------------------------------------------------- /docs/1_intro/intro5.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | from pygame.locals import * 3 | 4 | BLACK = (0, 0, 0) 5 | RED = (255, 0, 0) 6 | GREEN = (0, 255, 0) 7 | BLUE = (0, 0, 255) 8 | 9 | YELLOW = (255, 255, 0) 10 | CYAN = (0, 255, 255) 11 | MAGENTA = (255, 0, 255) 12 | GRAY = (127, 127, 127) 13 | WHITE = (255, 255, 255) 14 | 15 | key_dict = {K_k:BLACK, K_r:RED, K_g:GREEN, K_b:BLUE, 16 | K_y:YELLOW, K_c:CYAN, K_m:MAGENTA, K_w:WHITE} 17 | 18 | print(key_dict) 19 | 20 | pygame.init() 21 | screen = pygame.display.set_mode((640, 240)) 22 | 23 | running = True 24 | background = GRAY 25 | while running: 26 | for event in pygame.event.get(): 27 | if event.type == QUIT: 28 | running = False 29 | if event.type == KEYDOWN: 30 | if event.key in key_dict: 31 | background = key_dict[event.key] 32 | 33 | caption = 'background color = ' + str(background) 34 | pygame.display.set_caption(caption) 35 | 36 | screen.fill(background) 37 | pygame.display.update() 38 | 39 | pygame.quit() -------------------------------------------------------------------------------- /docs/1_intro/intro6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/1_intro/intro6.png -------------------------------------------------------------------------------- /docs/1_intro/intro6.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | from pygame.locals import * 3 | 4 | size = 640, 320 5 | width, height = size 6 | GREEN = (150, 255, 150) 7 | RED = (255, 0, 0) 8 | 9 | pygame.init() 10 | screen = pygame.display.set_mode(size) 11 | running = True 12 | 13 | ball = pygame.image.load("ball.gif") 14 | rect = ball.get_rect() 15 | speed = [2, 2] 16 | 17 | while running: 18 | for event in pygame.event.get(): 19 | if event.type == QUIT: 20 | running = False 21 | 22 | rect = rect.move(speed) 23 | if rect.left < 0 or rect.right > width: 24 | speed[0] = -speed[0] 25 | if rect.top < 0 or rect.bottom > height: 26 | speed[1] = -speed[1] 27 | 28 | screen.fill(GREEN) 29 | pygame.draw.rect(screen, RED, rect, 1) 30 | screen.blit(ball, rect) 31 | pygame.display.update() 32 | 33 | pygame.quit() -------------------------------------------------------------------------------- /docs/2_draw/draw1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/2_draw/draw1.png -------------------------------------------------------------------------------- /docs/2_draw/draw2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/2_draw/draw2.png -------------------------------------------------------------------------------- /docs/2_draw/mouse1.py: -------------------------------------------------------------------------------- 1 | """Print mouse event to the console.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | 6 | BLACK = (0, 0, 0) 7 | RED = (255, 0, 0) 8 | GREEN = (0, 255, 0) 9 | BLUE = (0, 0, 255) 10 | 11 | YELLOW = (255, 255, 0) 12 | CYAN = (0, 255, 255) 13 | MAGENTA = (255, 0, 255) 14 | GRAY = (127, 127, 127) 15 | WHITE = (255, 255, 255) 16 | 17 | pygame.init() 18 | screen = pygame.display.set_mode((640, 240)) 19 | 20 | running = True 21 | background = GRAY 22 | while running: 23 | for event in pygame.event.get(): 24 | if event.type == QUIT: 25 | running = False 26 | elif event.type == MOUSEBUTTONDOWN: 27 | print(event) 28 | elif event.type == MOUSEBUTTONUP: 29 | print(event) 30 | elif event.type == MOUSEMOTION: 31 | print(event) 32 | 33 | screen.fill(background) 34 | pygame.display.update() 35 | 36 | pygame.quit() -------------------------------------------------------------------------------- /docs/2_draw/mouse2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/2_draw/mouse2.png -------------------------------------------------------------------------------- /docs/2_draw/mouse2.py: -------------------------------------------------------------------------------- 1 | """Place a rectangle with the mouse.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | 6 | RED = (255, 0, 0) 7 | GRAY = (127, 127, 127) 8 | 9 | pygame.init() 10 | screen = pygame.display.set_mode((640, 240)) 11 | 12 | start = (0, 0) 13 | size = (0, 0) 14 | drawing = False 15 | running = True 16 | 17 | while running: 18 | for event in pygame.event.get(): 19 | if event.type == QUIT: 20 | running = False 21 | 22 | elif event.type == MOUSEBUTTONDOWN: 23 | start = event.pos 24 | size = 0, 0 25 | drawing = True 26 | 27 | elif event.type == MOUSEBUTTONUP: 28 | end = event.pos 29 | size = end[0] - start[0], end[1] - start[1] 30 | drawing = False 31 | 32 | elif event.type == MOUSEMOTION and drawing: 33 | end = event.pos 34 | size = end[0] - start[0], end[1] - start[1] 35 | 36 | screen.fill(GRAY) 37 | pygame.draw.rect(screen, RED, (start, size), 2) 38 | pygame.display.update() 39 | 40 | pygame.quit() -------------------------------------------------------------------------------- /docs/2_draw/mouse3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/2_draw/mouse3.png -------------------------------------------------------------------------------- /docs/2_draw/mouse4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/2_draw/mouse4.png -------------------------------------------------------------------------------- /docs/3_image/bird.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/3_image/bird.png -------------------------------------------------------------------------------- /docs/3_image/image0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/3_image/image0.png -------------------------------------------------------------------------------- /docs/3_image/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/3_image/image1.png -------------------------------------------------------------------------------- /docs/3_image/image1.py: -------------------------------------------------------------------------------- 1 | """Move an image with the mouse.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | 6 | RED = (255, 0, 0) 7 | GRAY = (150, 150, 150) 8 | 9 | pygame.init() 10 | w, h = 640, 240 11 | screen = pygame.display.set_mode((w, h)) 12 | running = True 13 | 14 | img = pygame.image.load('bird.png') 15 | img.convert() 16 | rect = img.get_rect() 17 | rect.center = w//2, h//2 18 | moving = False 19 | 20 | while running: 21 | for event in pygame.event.get(): 22 | if event.type == QUIT: 23 | running = False 24 | 25 | elif event.type == MOUSEBUTTONDOWN: 26 | if rect.collidepoint(event.pos): 27 | moving = True 28 | 29 | elif event.type == MOUSEBUTTONUP: 30 | moving = False 31 | 32 | elif event.type == MOUSEMOTION and moving: 33 | rect.move_ip(event.rel) 34 | 35 | screen.fill(GRAY) 36 | screen.blit(img, rect) 37 | pygame.draw.rect(screen, RED, rect, 1) 38 | pygame.display.update() 39 | 40 | pygame.quit() -------------------------------------------------------------------------------- /docs/3_image/image2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/3_image/image2.png -------------------------------------------------------------------------------- /docs/3_image/image3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/3_image/image3.png -------------------------------------------------------------------------------- /docs/4_text/text1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/4_text/text1.png -------------------------------------------------------------------------------- /docs/4_text/text2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/4_text/text2.png -------------------------------------------------------------------------------- /docs/4_text/text3.py: -------------------------------------------------------------------------------- 1 | """Display unicode (Japanese and pictograms).""" 2 | import pygame 3 | 4 | from pygame.locals import * 5 | import time 6 | 7 | BLACK = (0, 0, 0) 8 | RED = (255, 0, 0) 9 | GRAY = (200, 200, 200) 10 | 11 | pygame.init() 12 | screen = pygame.display.set_mode((640, 240)) 13 | 14 | s = 'Unicodeカタ日本♚♛' 15 | font0 = pygame.font.Font(None, 48) 16 | font1 = pygame.font.SysFont('arialunicode.ttf', 64) 17 | 18 | img0 = font0.render(s, True, RED) 19 | img1 = font1.render(s, True, RED) 20 | 21 | running = True 22 | background = GRAY 23 | 24 | while running: 25 | for event in pygame.event.get(): 26 | if event.type == QUIT: 27 | running = False 28 | 29 | screen.fill(background) 30 | screen.blit(img0, (20, 20)) 31 | screen.blit(img1, (20, 50)) 32 | pygame.display.update() 33 | 34 | pygame.quit() -------------------------------------------------------------------------------- /docs/5_app/anim1.py: -------------------------------------------------------------------------------- 1 | """Animation: bouger""" 2 | 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__() 8 | 9 | Scene(caption='Images') 10 | Node(bg=Color('white'), size=(80, 80), dir=(1, 0)) 11 | Node(file='animals/bird-icon.png') 12 | Node(file='animals/black-cat-icon.png') 13 | Node(file='animals/bunny-icon.png', border_col=Color('red')) 14 | Node(file='animals/gold-fish-icon.png', bg=Color('white')) 15 | Node(file='animals/cow-icon.png') 16 | 17 | if __name__ == '__main__': 18 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/app1.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | from pygame.locals import * 3 | 4 | class App: 5 | """Create a single-window app with multiple scenes.""" 6 | 7 | def __init__(self): 8 | """Initialize pygame and the application.""" 9 | pygame.init() 10 | flags = RESIZABLE 11 | App.screen = pygame.display.set_mode((640, 240), flags) 12 | 13 | App.running = True 14 | 15 | def run(self): 16 | """Run the main event loop.""" 17 | while App.running: 18 | for event in pygame.event.get(): 19 | if event.type == QUIT: 20 | App.running = False 21 | pygame.quit() 22 | 23 | if __name__ == '__main__': 24 | App().run() 25 | -------------------------------------------------------------------------------- /docs/5_app/app2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app2.png -------------------------------------------------------------------------------- /docs/5_app/app3.py: -------------------------------------------------------------------------------- 1 | from app import * 2 | 3 | class Demo(App): 4 | def __init__(self): 5 | super().__init__() 6 | 7 | Scene(caption='Intro') 8 | Text('Scene 0') 9 | Text('Introduction screen the app') 10 | 11 | Scene(bg=Color('yellow'), caption='Options') 12 | Text('Scene 1') 13 | Text('Option screen of the app') 14 | 15 | Scene(bg=Color('green'), caption='Main') 16 | Text('Scene 2') 17 | Text('Main screen of the app') 18 | 19 | App.scene = App.scenes[0] 20 | 21 | if __name__ == '__main__': 22 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/app3a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app3a.png -------------------------------------------------------------------------------- /docs/5_app/app3b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app3b.png -------------------------------------------------------------------------------- /docs/5_app/app3c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app3c.png -------------------------------------------------------------------------------- /docs/5_app/app4.py: -------------------------------------------------------------------------------- 1 | """Display different scene background images.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | Scene(img_folder='../background', file='forest.jpg', caption='Forest') 8 | Text('Forest scene', fontcolor=Color('white')) 9 | Scene(file='lake.jpg', caption='Lake') 10 | Text('Lake scene') 11 | Scene(file='sunset.jpg', caption='Sunset') 12 | Text('Sunset scene', fontcolor=Color('white')) 13 | Scene(file='', bg=Color('lightgreen'), caption='Green background') 14 | Text('Colored background scene') 15 | 16 | if __name__ == '__main__': 17 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/app4a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app4a.png -------------------------------------------------------------------------------- /docs/5_app/app4b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app4b.png -------------------------------------------------------------------------------- /docs/5_app/app4c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/app4c.png -------------------------------------------------------------------------------- /docs/5_app/app5.py: -------------------------------------------------------------------------------- 1 | """Configure App with size and shortcut options.""" 2 | 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__(size=(800, 600), shortcuts={(K_1, KMOD_NONE): 'print(123)'}) 8 | Scene() 9 | Scene(bg=Color('yellow')) 10 | 11 | if __name__ == '__main__': 12 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/app6.py: -------------------------------------------------------------------------------- 1 | from app import * 2 | 3 | class Demo(App): 4 | def __init__(self): 5 | super().__init__() 6 | 7 | Scene(caption='Intro') 8 | Text('Scene 0') 9 | Text('Introduction screen the app') 10 | Rectangle(Color('red'), Color('green'), 5) 11 | 12 | Scene(bg=Color('yellow'), caption='Options') 13 | Text('Scene 1') 14 | Text('Option screen of the app') 15 | 16 | Scene(bg=Color('lightgreen'), caption='Main') 17 | Text('Scene 2', cmd='print(self.text)') 18 | Text('Main screen of the app') 19 | Button('Scene', cmd='print(App.scene)') 20 | Button('Button 1', cmd='print(123)') 21 | Button('Button 2', cmd='print(self)') 22 | 23 | Button('Fullscreen', cmd='App.toggle_full_screen()', pos=(200, 20)) 24 | Button('Hello', cmd='print("hello")') 25 | 26 | App.scene = App.scenes[0] 27 | 28 | if __name__ == '__main__': 29 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/class0.py: -------------------------------------------------------------------------------- 1 | # name space demo 2 | name = 'global name' 3 | 4 | class Class: 5 | name = 'class name' 6 | 7 | def __init__(self): 8 | self.name = 'inst name' 9 | 10 | def func1(self): 11 | return name 12 | 13 | def func2(self): 14 | return self.name 15 | 16 | def func3(self): 17 | name = 'local name' 18 | return name 19 | 20 | @staticmethod 21 | def stat_meth(): 22 | return name 23 | 24 | @classmethod 25 | def cls_meth(cls): 26 | return name 27 | 28 | @classmethod 29 | def cls_meth2(cls): 30 | return cls.name 31 | 32 | inst = Class() 33 | 34 | print('name', name) 35 | print('Class', Class.name) 36 | print('inst', inst.name) 37 | print('func1', inst.func1()) 38 | print('func2', inst.func2()) 39 | print('func3', inst.func3()) 40 | print('stat_meth', inst.stat_meth()) 41 | print('cls_meth', inst.cls_meth()) 42 | print('cls_meth2', inst.cls_meth2()) 43 | 44 | 45 | 46 | -------------------------------------------------------------------------------- /docs/5_app/class1.py: -------------------------------------------------------------------------------- 1 | # class method 2 | 3 | class A: 4 | att = 'class attr' 5 | 6 | def __init__(self, arg, *args, **kwargs): 7 | self.att = 'instance attr' 8 | self.att2 = A.att 9 | print('Create instance...') 10 | print('type(self.__dict__) =', type(self.__dict__)) 11 | 12 | @classmethod 13 | def update_options(cls, options): 14 | print('Update class options...') 15 | print('type(cls.__dict__) =', type(cls.__dict__)) 16 | cls.att = 'updated' 17 | 18 | def print_info(obj): 19 | print('='*10, obj) 20 | for key in obj.__dict__: 21 | if not key.startswith('__'): 22 | print(f'{key} = {obj.__dict__[key]}') 23 | 24 | a = A('aa') 25 | 26 | print_info(A) 27 | a.update_options({'key':'value', 1:100}) 28 | print_info(A) 29 | print_info(a) 30 | a2 = A('aa2') 31 | print_info(a2) 32 | -------------------------------------------------------------------------------- /docs/5_app/node1.py: -------------------------------------------------------------------------------- 1 | from app import * 2 | 3 | class Demo(App): 4 | def __init__(self): 5 | super().__init__() 6 | 7 | Scene(caption='Nodes - vertical placement') 8 | Node() 9 | Node() 10 | Node() 11 | 12 | Node(pos=(200, 20), size=(200, 50)) 13 | Node() 14 | Node() 15 | 16 | Scene(caption='Nodes - horizontal placement') 17 | Node(dir=(1, 0), gap=(0, 0)) 18 | Node() 19 | Node() 20 | 21 | Node(pos=(20, 100) 22 | Node() 23 | Node() 24 | 25 | Scene(caption='Nodes - diagonal placement') 26 | Node(dir=(1, 1), gap=(0, 0)) 27 | Node() 28 | Node() 29 | 30 | if __name__ == '__main__': 31 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/node1a.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node1a.png -------------------------------------------------------------------------------- /docs/5_app/node1b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node1b.png -------------------------------------------------------------------------------- /docs/5_app/node1c.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node1c.png -------------------------------------------------------------------------------- /docs/5_app/node2.py: -------------------------------------------------------------------------------- 1 | 2 | """Nodes with color, border and image.""" 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__() 8 | 9 | Scene(caption='Nodes with color, border, image') 10 | Node(level=1, size=(100, 30), border_col = Color('cyan'), border_thick=1) 11 | Node(border_thick = 2, bg=(255, 0, 0, 127)) 12 | Node(border_thick = 4) 13 | Node(color=Color('orange')) 14 | Node(file='background/forest.jpg') 15 | 16 | Node(file='', bg=Color('yellow'), pos=(200,20), size=(100, 100)) 17 | Node(size=(100, 50)) 18 | Node() 19 | 20 | if __name__ == '__main__': 21 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/node3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node3.png -------------------------------------------------------------------------------- /docs/5_app/node3.py: -------------------------------------------------------------------------------- 1 | 2 | """Nodes which change stacking order.""" 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__() 8 | 9 | Scene(caption='Stacking order') 10 | Node(size=(100, 100), pos=(10, 10), dir=(0.2, 0.2), bg=Color('yellow')) 11 | Node(bg=Color('blue')) 12 | Node(bg=Color('red')) 13 | Node(bg=Color('green')) 14 | 15 | if __name__ == '__main__': 16 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/node4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node4.png -------------------------------------------------------------------------------- /docs/5_app/node4.py: -------------------------------------------------------------------------------- 1 | 2 | """Nodes which change stacking order.""" 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__() 8 | 9 | Scene(caption='visible, movable, resizable') 10 | Text('visible') 11 | Text('not visible', visible=False) 12 | Text('not movable', visible=True, movable=False) 13 | Text('not movable, not resizable', resizable=False) 14 | 15 | if __name__ == '__main__': 16 | Demo().run() -------------------------------------------------------------------------------- /docs/5_app/node5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/5_app/node5.png -------------------------------------------------------------------------------- /docs/5_app/node5.py: -------------------------------------------------------------------------------- 1 | 2 | """Nodes with images.""" 3 | from app import * 4 | 5 | class Demo(App): 6 | def __init__(self): 7 | super().__init__() 8 | 9 | Scene(caption='Images') 10 | Node(bg=Color('white'), size=(100, 100), dir=(1, 0)) 11 | Node(file='animals/bird-icon.png') 12 | Node(file='animals/black-cat-icon.png') 13 | Node(file='animals/bunny-icon.png', border_col=Color('red')) 14 | Node(file='animals/gold-fish-icon.png', bg=Color('white')) 15 | Node(file='animals/cow-icon.png') 16 | 17 | if __name__ == '__main__': 18 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/app.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/app.png -------------------------------------------------------------------------------- /docs/6_gui/app.py: -------------------------------------------------------------------------------- 1 | ../5_app/app.py -------------------------------------------------------------------------------- /docs/6_gui/button1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/button1.png -------------------------------------------------------------------------------- /docs/6_gui/button1.py: -------------------------------------------------------------------------------- 1 | """Display buttons with different size, color and font.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | Scene(caption='Button') 8 | Button('Button', cmd='print(self)') 9 | Button('Scene', cmd='print(App.scene)') 10 | Button('Size', size=(100, 100)) 11 | Button('Color', button_color=Color('red')) 12 | Button('Border', border_color=Color('blue')) 13 | 14 | if __name__ == '__main__': 15 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/listbox1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/listbox1.png -------------------------------------------------------------------------------- /docs/6_gui/listbox1.py: -------------------------------------------------------------------------------- 1 | """Display a ListBox with left/center/right alignement.""" 2 | from app import * 3 | 4 | atts = dir() 5 | 6 | class Demo(App): 7 | def __init__(self): 8 | super().__init__() 9 | 10 | Scene(caption='ListBox', bg=Color('beige')) 11 | ListBox(['Charlie', 'Daniel', 'Tim', 'Jack'], cmd='print(self.item)') 12 | 13 | cities = ['Amsterdam', 'Berlin', 'Cardiff', 'Dublin', 'Edinbourgh', 'Fargo', 'Greenwich', 14 | 'Harrington', 'Melbourne', 'New York', 'Oslo', 'Paris'] 15 | ListBox(cities, dir=(1, 0), wrap=True, align=1) 16 | ListBox(atts, width=350, align=2, wrap=False) 17 | 18 | if __name__ == '__main__': 19 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/listbox2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/listbox2.png -------------------------------------------------------------------------------- /docs/6_gui/listbox2.py: -------------------------------------------------------------------------------- 1 | """Display a ListBox multiple selections.""" 2 | from app import * 3 | 4 | atts = dir() 5 | 6 | class Demo(App): 7 | def __init__(self): 8 | super().__init__() 9 | 10 | Scene(caption='ListBox', bg=Color('beige')) 11 | ListBox(['Charlie', 'Daniel', 'Tim', 'Jack'], cmd='print(self.item)') 12 | 13 | cities = ['Amsterdam', 'Berlin', 'Cardiff', 'Dublin', 'Edinbourgh', 'Fargo', 'Greenwich', 14 | 'Harrington', 'Melbourne', 'New York', 'Oslo', 'Paris'] 15 | ListBox(cities, dir=(1, 0)) 16 | ListBox(atts, width=300, align=1) 17 | 18 | if __name__ == '__main__': 19 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/template.py: -------------------------------------------------------------------------------- 1 | """Template for making applications.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | Scene(caption='My application') 9 | Node() 10 | Text() 11 | Button() 12 | 13 | if __name__ == '__main__': 14 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/text1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/text1.png -------------------------------------------------------------------------------- /docs/6_gui/text1.py: -------------------------------------------------------------------------------- 1 | """Display text with different size, color and font.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | Scene(caption='Text') 8 | Text('Default text') 9 | Text('fontsize = 24', fontsize=24) 10 | Text('fontcolor = RED', fontcolor=Color('red')) 11 | Text('48 pts, blue', fontsize=48, fontcolor=Color('blue')) 12 | Text('fontbg = yellow', fontbg=Color('yellow')) 13 | 14 | Text('italic', pos=(400, 20), italic=True) 15 | Text('bold', bold=True) 16 | Text('underline', underline=True, font_bg=None) 17 | 18 | if __name__ == '__main__': 19 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/text2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/text2.png -------------------------------------------------------------------------------- /docs/6_gui/text2.py: -------------------------------------------------------------------------------- 1 | """Horizontal and vertical text alignement.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | Scene(caption='Text Alignment', bg=Color('pink')) 9 | Text('left', size=(200, 40), fontsize=24) 10 | Text('center', h_align=1) 11 | Text('right', h_align=2) 12 | Text(bg=Color('blue'), fontcolor=Color('white')) 13 | 14 | Text('top', pos=(250, 20), h_align=1) 15 | Text('middle', v_align=1) 16 | Text('bottom', v_align=2) 17 | 18 | if __name__ == '__main__': 19 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/text3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/text3.png -------------------------------------------------------------------------------- /docs/6_gui/text3.py: -------------------------------------------------------------------------------- 1 | """Text with size, alignment, fontcolor, font background...""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | Scene(caption='Text', bg=Color('pink')) 9 | Text(size=(100, 40)) 10 | Text(bg=Color('yellow'), h_align=1) 11 | Text(fontcolor=Color('red')) 12 | Text(fontbg=Color('green'), cmd='print(self.text)') 13 | 14 | Text(pos=(200, 20)) 15 | Text(italic=True, v_align=1) 16 | Text(underline=True, fontsize=24) 17 | Text(bold=True) 18 | 19 | if __name__ == '__main__': 20 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/text4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/6_gui/text4.png -------------------------------------------------------------------------------- /docs/6_gui/text4.py: -------------------------------------------------------------------------------- 1 | """Display text editable with a cursor.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | Scene(caption='Text with cursor') 8 | Text('This is a text object', size=(600, 0)) 9 | TextEdit('Text with cmd (press Enter)', cmd='print(self.text)', fontsize=24) 10 | TextEdit('You can edit this', fontcolor=Color('white')) 11 | TextEdit('It remembers the cursor position', fontsize=48) 12 | 13 | if __name__ == '__main__': 14 | Demo().run() -------------------------------------------------------------------------------- /docs/6_gui/text5.py: -------------------------------------------------------------------------------- 1 | """Display text editable with a cursor.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | Scene(caption='Text with cursor') 8 | Text('This is a text object', size=(600, 0)) 9 | TextEdit('Text with cmd (press Enter)', cmd='print(self.text)', fontsize=12, size=(400, 30)) 10 | TextEdit('You can edit this', fontcolor=Color('white')) 11 | TextEdit('It remembers the cursor position', fontsize=48) 12 | 13 | if __name__ == '__main__': 14 | Demo().run() -------------------------------------------------------------------------------- /docs/7_sound/rpgaudio.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/7_sound/rpgaudio.ogg -------------------------------------------------------------------------------- /docs/7_sound/sound.rst: -------------------------------------------------------------------------------- 1 | Playing sound 2 | ============= 3 | 4 | Making sounds 5 | ------------- 6 | 7 | The ``pygame.mixer`` module allows to play compressed OGG files or uncompressed WAV files. 8 | 9 | This checks the initialization parameters and prints the number of channels available. 10 | It opens a sound object and prays it:: 11 | 12 | print('init =', pygame.mixer.get_init()) 13 | print('channels =', pygame.mixer.get_num_channels()) 14 | App.snd = pygame.mixer.Sound('5_app/rpgaudio.ogg') 15 | App.snd.play() 16 | print('length =', App.snd.get_length()) 17 | 18 | Writes this to the console:: 19 | 20 | init = (22050, -16, 2) 21 | channels = 8 22 | length = 28.437868118286133 23 | 24 | Here is a code example: 25 | 26 | .. literalinclude:: sound1.py 27 | 28 | Which produces the following result. 29 | 30 | .. image:: sound1.png -------------------------------------------------------------------------------- /docs/7_sound/sound1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/7_sound/sound1.png -------------------------------------------------------------------------------- /docs/7_sound/sound1.py: -------------------------------------------------------------------------------- 1 | """Play a sound.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | print('init =', pygame.mixer.get_init()) 9 | print('channels =', pygame.mixer.get_num_channels()) 10 | App.snd = pygame.mixer.Sound('5_app/rpgaudio.ogg') 11 | App.snd.play() 12 | print('length =', App.snd.get_length()) 13 | 14 | Scene(caption='Sound mixer') 15 | Button('Stop', cmd='pygame.mixer.stop()') 16 | Button('Pause', cmd='pygame.mixer.pause()') 17 | Button('Unpause', cmd='pygame.mixer.unpause()') 18 | Button('Fadeout', cmd='pygame.mixer.fadeout(5000)') 19 | Button('Play', cmd='App.snd.play()') 20 | Button('Volume 0.1', cmd='App.snd.set_volume(0.1)', pos=(200, 20)) 21 | Button('Volume 0.3', cmd='App.snd.set_volume(0.3)') 22 | Button('Volume 1.0', cmd='App.snd.set_volume(1.0)') 23 | 24 | if __name__ == '__main__': 25 | Demo().run() -------------------------------------------------------------------------------- /docs/8_platformer/app.py: -------------------------------------------------------------------------------- 1 | ../5_app/app.py -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/full.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/barrel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/barrel.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/box.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/cloud.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/coin1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/coin1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/coin2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/coin2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/coin3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/coin3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/coin4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/coin4.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/fence1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/fence1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/fence2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/fence2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/fence3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/fence3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/grass1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/grass1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/grass2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/grass2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/grass3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/grass3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground10.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground11.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground12.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground13.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground14.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground15.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground16.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground4.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground5.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground6.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground7.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground8.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/ground9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/ground9.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/heart1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/heart1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/heart2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/heart2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/mushroom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/mushroom.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/pointer1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/pointer1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/pointer2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/pointer2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/pointer3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/pointer3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/pointer4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/pointer4.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/rock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/rock.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/spike.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/spike.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/spring1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/spring1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/spring2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/spring2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/stairs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/stairs.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/water1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/water1.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/water2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/water2.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/png/water3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/png/water3.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/preview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/preview.png -------------------------------------------------------------------------------- /docs/8_platformer/hdst_tileset/sample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/hdst_tileset/sample.png -------------------------------------------------------------------------------- /docs/8_platformer/images/fall.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/images/fall.jpg -------------------------------------------------------------------------------- /docs/8_platformer/images/player1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/images/player1.png -------------------------------------------------------------------------------- /docs/8_platformer/images/player2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/8_platformer/images/player2.png -------------------------------------------------------------------------------- /docs/8_platformer/plateform1.py: -------------------------------------------------------------------------------- 1 | """Template for making applications.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | Scene(caption='My application') 9 | Node() 10 | Text() 11 | Button() 12 | 13 | if __name__ == '__main__': 14 | Demo().run() -------------------------------------------------------------------------------- /docs/9_board/app.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/app.png -------------------------------------------------------------------------------- /docs/9_board/app.py: -------------------------------------------------------------------------------- 1 | ../5_app/app.py -------------------------------------------------------------------------------- /docs/9_board/board.rst: -------------------------------------------------------------------------------- 1 | Board Games 2 | =========== 3 | 4 | In this section we create the framework for board games. 5 | These games are based on a nxm grid. Each cell can have 6 | 7 | * text 8 | * color 9 | * image 10 | 11 | .. image:: board1.png 12 | 13 | Selecting cells with the mouse 14 | ------------------------------ 15 | 16 | .. image:: board2.png 17 | 18 | 19 | Adding background color 20 | ------------------------------ 21 | 22 | .. image:: board3.png 23 | 24 | Create a checkerboard pattern 25 | ----------------------------- 26 | 27 | .. image:: board4.png -------------------------------------------------------------------------------- /docs/9_board/board0.py: -------------------------------------------------------------------------------- 1 | """Simple board game.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__() 7 | 8 | Scene(caption='Board Game') 9 | Board(dir=(1, 0)) 10 | Board() 11 | Board() 12 | 13 | if __name__ == '__main__': 14 | Demo().run() -------------------------------------------------------------------------------- /docs/9_board/board1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/board1.png -------------------------------------------------------------------------------- /docs/9_board/board1.py: -------------------------------------------------------------------------------- 1 | """Draw a 4x4 board.""" 2 | 3 | import pygame 4 | import numpy as np 5 | from pygame.locals import * 6 | from pygamelib import * 7 | 8 | class BoardDemo(App): 9 | """Draw a playing board.""" 10 | def __init__(self): 11 | super(BoardDemo, self).__init__() 12 | Text('Board') 13 | Board(pos=(200, 20)) 14 | 15 | if __name__ == '__main__': 16 | BoardDemo().run() -------------------------------------------------------------------------------- /docs/9_board/board2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/board2.png -------------------------------------------------------------------------------- /docs/9_board/board2.py: -------------------------------------------------------------------------------- 1 | """Place two 4x4 boards on the screen.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | from pygamelib import * 6 | 7 | class BoardDemo2(App): 8 | """Draw two 4x4 boards and select cells with mouse click.""" 9 | def __init__(self): 10 | super(BoardDemo2, self).__init__() 11 | 12 | Text('Board', size=48) 13 | Text('click to select', size=24) 14 | Text('cmd+click multiple') 15 | Text('arrow to move') 16 | Board(pos=(200, 20)) 17 | Board(pos=(420, 20)).wrap = True 18 | 19 | if __name__ == '__main__': 20 | BoardDemo2().run() -------------------------------------------------------------------------------- /docs/9_board/board3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/board3.png -------------------------------------------------------------------------------- /docs/9_board/board3.py: -------------------------------------------------------------------------------- 1 | """Add color to the cells.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | from pygamelib import * 6 | import numpy as np 7 | 8 | class BoardDemo(App): 9 | """Draw cells in random colors.""" 10 | def __init__(self): 11 | super(BoardDemo, self).__init__() 12 | Text('Color') 13 | Text('Add random colors', size=24) 14 | 15 | n, m = 4, 8 16 | b = Board(n, m, pos=(200, 20)) 17 | b.color_list = [None, RED, GREEN, BLUE, YELLOW] 18 | b.colors = np.random.randint(0, 5, (n, m)) 19 | b.T = b.colors 20 | 21 | if __name__ == '__main__': 22 | BoardDemo().run() -------------------------------------------------------------------------------- /docs/9_board/board4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/board4.png -------------------------------------------------------------------------------- /docs/9_board/board4.py: -------------------------------------------------------------------------------- 1 | """Create a checkerboard pattern.""" 2 | 3 | import pygame 4 | from pygame.locals import * 5 | from pygamelib import * 6 | import numpy as np 7 | 8 | class BoardDemo(App): 9 | """Calculate the color pattern.""" 10 | def __init__(self): 11 | super(BoardDemo, self).__init__() 12 | Text('Checker') 13 | Text('Create a pattern', size=24) 14 | 15 | n, m = 4, 8 16 | b = Board(n, m, pos=(200, 20)) 17 | b.color_list = [None, RED] 18 | b.colors = np.fromfunction(lambda x, y: (x + y) % 2, (n, m), dtype=int) 19 | b.T = b.colors 20 | 21 | if __name__ == '__main__': 22 | BoardDemo().run() -------------------------------------------------------------------------------- /docs/9_board/chess.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess.png -------------------------------------------------------------------------------- /docs/9_board/chess.py: -------------------------------------------------------------------------------- 1 | """Chess game.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__(size=(640, 480)) 7 | 8 | Scene(caption='Chess') 9 | Chess(folder='chess') 10 | 11 | if __name__ == '__main__': 12 | Demo().run() -------------------------------------------------------------------------------- /docs/9_board/chess/1b_pawn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/1b_pawn.png -------------------------------------------------------------------------------- /docs/9_board/chess/1w_pawn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/1w_pawn.png -------------------------------------------------------------------------------- /docs/9_board/chess/2b_rook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/2b_rook.png -------------------------------------------------------------------------------- /docs/9_board/chess/2w_rook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/2w_rook.png -------------------------------------------------------------------------------- /docs/9_board/chess/3b_horse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/3b_horse.png -------------------------------------------------------------------------------- /docs/9_board/chess/3w_horse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/3w_horse.png -------------------------------------------------------------------------------- /docs/9_board/chess/4b_bishop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/4b_bishop.png -------------------------------------------------------------------------------- /docs/9_board/chess/4w_bishop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/4w_bishop.png -------------------------------------------------------------------------------- /docs/9_board/chess/5b_queen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/5b_queen.png -------------------------------------------------------------------------------- /docs/9_board/chess/5w_queen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/5w_queen.png -------------------------------------------------------------------------------- /docs/9_board/chess/6b_king.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/6b_king.png -------------------------------------------------------------------------------- /docs/9_board/chess/6w_king.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/chess/6w_king.png -------------------------------------------------------------------------------- /docs/9_board/nurikabe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/nurikabe.png -------------------------------------------------------------------------------- /docs/9_board/nurikabe.py: -------------------------------------------------------------------------------- 1 | """Nurikabe puzzle game.""" 2 | from app import * 3 | 4 | # https://en.wikipedia.org/wiki/Nurikabe_(puzzle) 5 | nurikabe1 = """ 6 | 2........2 7 | ......2... 8 | .2..7..... 9 | .......... 10 | ......3.3. 11 | ..2....3.. 12 | 2..4...... 13 | .......... 14 | .1....2.4. 15 | """ 16 | 17 | # https://www.puzzles-mobile.com/nurikabe/random/5x5-easy 18 | nurikabe2 = """ 19 | 3.... 20 | ..... 21 | ..... 22 | ..4.1 23 | .2... 24 | """ 25 | 26 | class Demo(App): 27 | def __init__(self): 28 | super().__init__() 29 | 30 | Scene(caption='Nurikabe') 31 | n = Board(dx=20, dy=20, m=9, n=10, checker=(Color('white'), Color('white'))) 32 | n.set_Num(nurikabe1) 33 | n.render() 34 | 35 | n2 = Board(dx=40, dy=40, m=5, n=5, dir=(1, 0)) 36 | n2.set_Num(nurikabe2) 37 | n2.render() 38 | 39 | if __name__ == '__main__': 40 | Demo().run() -------------------------------------------------------------------------------- /docs/9_board/puzzle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/puzzle.png -------------------------------------------------------------------------------- /docs/9_board/puzzle.py: -------------------------------------------------------------------------------- 1 | """Image puzzle.""" 2 | from app import * 3 | 4 | class Demo(App): 5 | def __init__(self): 6 | super().__init__(size=(640, 580)) 7 | 8 | Scene(caption='Photo puzzle') 9 | Puzzle(file='../../images/cat.jpg', div=(4, 4)) 10 | Puzzle(file='../../images/sunset.jpg', pos=(20, 300)) 11 | 12 | if __name__ == '__main__': 13 | Demo().run() -------------------------------------------------------------------------------- /docs/9_board/pygamelib.py: -------------------------------------------------------------------------------- 1 | ../../pygamelib.py -------------------------------------------------------------------------------- /docs/9_board/sudoku.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/9_board/sudoku.png -------------------------------------------------------------------------------- /docs/9_board/sudoku.py: -------------------------------------------------------------------------------- 1 | """Sudoko puzzle game.""" 2 | from app import * 3 | 4 | # https://en.wikipedia.org/wiki/Sudoku_solving_algorithms 5 | sudoku1 = """ 6 | 53..7.... 7 | 6..195... 8 | .98....6. 9 | 8...6...3 10 | 4..8.3..1 11 | 7...2...6 12 | .6....28. 13 | ...419..5 14 | ....8..79 15 | """ 16 | 17 | # https://www.theguardian.com/lifeandstyle/2018/apr/16/sudoku-easy-4035 18 | sudoku2 = """ 19 | 8769..... 20 | .1...6... 21 | .4.3.58.. 22 | 4.....21. 23 | .9.5..... 24 | .5..4.3.6 25 | .29.....8 26 | ..469.17334 27 | .....1..4 28 | """ 29 | 30 | class Demo(App): 31 | def __init__(self): 32 | super().__init__() 33 | 34 | Scene(caption='Sudoku') 35 | s = Sudoku(dx=20, dy=20) 36 | s.set_Num(sudoku1) 37 | s.render() 38 | 39 | Button('Reset', dir=(1, 0), cmd='print(123)') 40 | # s2 = Sudoku(dir=(1, 0)) 41 | # s2.set_Num(sudoku2) 42 | 43 | 44 | 45 | if __name__ == '__main__': 46 | Demo().run() -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- 1 | # Minimal makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line. 5 | SPHINXOPTS = 6 | SPHINXBUILD = sphinx-build 7 | SOURCEDIR = . 8 | BUILDDIR = _build 9 | 10 | # Put it first so that "make" without argument is like "make help". 11 | help: 12 | @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 13 | 14 | .PHONY: help Makefile 15 | 16 | # Catch-all target: route all unknown targets to Sphinx using the new 17 | # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). 18 | %: Makefile 19 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) -------------------------------------------------------------------------------- /docs/animals/bird-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/bird-icon.png -------------------------------------------------------------------------------- /docs/animals/black-cat-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/black-cat-icon.png -------------------------------------------------------------------------------- /docs/animals/bulldog-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/bulldog-icon.png -------------------------------------------------------------------------------- /docs/animals/bunny-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/bunny-icon.png -------------------------------------------------------------------------------- /docs/animals/cardinal-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/cardinal-icon.png -------------------------------------------------------------------------------- /docs/animals/cat-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/cat-icon.png -------------------------------------------------------------------------------- /docs/animals/chicken-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/chicken-icon.png -------------------------------------------------------------------------------- /docs/animals/chihuahua-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/chihuahua-icon.png -------------------------------------------------------------------------------- /docs/animals/cow-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/cow-icon.png -------------------------------------------------------------------------------- /docs/animals/crab-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/crab-icon.png -------------------------------------------------------------------------------- /docs/animals/dachshund-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/dachshund-icon.png -------------------------------------------------------------------------------- /docs/animals/dog-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/dog-icon.png -------------------------------------------------------------------------------- /docs/animals/dolphin-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/dolphin-icon.png -------------------------------------------------------------------------------- /docs/animals/donkey-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/donkey-icon.png -------------------------------------------------------------------------------- /docs/animals/duck-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/duck-icon.png -------------------------------------------------------------------------------- /docs/animals/fish-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/fish-icon.png -------------------------------------------------------------------------------- /docs/animals/frog-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/frog-icon.png -------------------------------------------------------------------------------- /docs/animals/gold-fish-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/gold-fish-icon.png -------------------------------------------------------------------------------- /docs/animals/hamster-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/hamster-icon.png -------------------------------------------------------------------------------- /docs/animals/horse-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/horse-icon.png -------------------------------------------------------------------------------- /docs/animals/jellyfish-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/jellyfish-icon.png -------------------------------------------------------------------------------- /docs/animals/kitten-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/kitten-icon.png -------------------------------------------------------------------------------- /docs/animals/lobster-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/lobster-icon.png -------------------------------------------------------------------------------- /docs/animals/mouse-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/mouse-icon.png -------------------------------------------------------------------------------- /docs/animals/octopus-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/octopus-icon.png -------------------------------------------------------------------------------- /docs/animals/parrot-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/parrot-icon.png -------------------------------------------------------------------------------- /docs/animals/pig-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/pig-icon.png -------------------------------------------------------------------------------- /docs/animals/pony-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/pony-icon.png -------------------------------------------------------------------------------- /docs/animals/puppy-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/puppy-icon.png -------------------------------------------------------------------------------- /docs/animals/rabbit-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/rabbit-icon.png -------------------------------------------------------------------------------- /docs/animals/seal-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/seal-icon.png -------------------------------------------------------------------------------- /docs/animals/shark-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/shark-icon.png -------------------------------------------------------------------------------- /docs/animals/sheep-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/sheep-icon.png -------------------------------------------------------------------------------- /docs/animals/squid-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/squid-icon.png -------------------------------------------------------------------------------- /docs/animals/squirrel-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/squirrel-icon.png -------------------------------------------------------------------------------- /docs/animals/tropical-fish-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/tropical-fish-icon.png -------------------------------------------------------------------------------- /docs/animals/tuna-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/tuna-icon.png -------------------------------------------------------------------------------- /docs/animals/turkey-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/turkey-icon.png -------------------------------------------------------------------------------- /docs/animals/turtle-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/turtle-icon.png -------------------------------------------------------------------------------- /docs/animals/whale-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/animals/whale-icon.png -------------------------------------------------------------------------------- /docs/background/forest.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/background/forest.jpg -------------------------------------------------------------------------------- /docs/background/lake.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/background/lake.jpg -------------------------------------------------------------------------------- /docs/background/sunset.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/background/sunset.jpg -------------------------------------------------------------------------------- /docs/editor/editor.rst: -------------------------------------------------------------------------------- 1 | Image editor 2 | ============ 3 | 4 | -------------------------------------------------------------------------------- /docs/hacker/hacker1.py: -------------------------------------------------------------------------------- 1 | """Demo for a hacker game simulating a computer desktop.""" 2 | 3 | from pglib import * 4 | 5 | class Demo(App): 6 | Scene() 7 | Text('text') 8 | Node() 9 | 10 | if __name__ == '__main__': 11 | Demo().run() -------------------------------------------------------------------------------- /docs/hacker/icons/address-book-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/address-book-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/address-book.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/address-book.png -------------------------------------------------------------------------------- /docs/hacker/icons/bag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bag.png -------------------------------------------------------------------------------- /docs/hacker/icons/basket.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/basket.png -------------------------------------------------------------------------------- /docs/hacker/icons/beer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/beer.png -------------------------------------------------------------------------------- /docs/hacker/icons/bell.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bell.png -------------------------------------------------------------------------------- /docs/hacker/icons/bitcoin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bitcoin.png -------------------------------------------------------------------------------- /docs/hacker/icons/book-bookmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/book-bookmark.png -------------------------------------------------------------------------------- /docs/hacker/icons/book.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/book.png -------------------------------------------------------------------------------- /docs/hacker/icons/box-full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/box-full.png -------------------------------------------------------------------------------- /docs/hacker/icons/box-in.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/box-in.png -------------------------------------------------------------------------------- /docs/hacker/icons/box-out.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/box-out.png -------------------------------------------------------------------------------- /docs/hacker/icons/box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/box.png -------------------------------------------------------------------------------- /docs/hacker/icons/brick-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/brick-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/brick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/brick.png -------------------------------------------------------------------------------- /docs/hacker/icons/bubble.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bubble.png -------------------------------------------------------------------------------- /docs/hacker/icons/bubbles-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bubbles-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/bubbles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bubbles.png -------------------------------------------------------------------------------- /docs/hacker/icons/building.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/building.png -------------------------------------------------------------------------------- /docs/hacker/icons/bullhorn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/bullhorn.png -------------------------------------------------------------------------------- /docs/hacker/icons/calculator.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/calculator.png -------------------------------------------------------------------------------- /docs/hacker/icons/calendar-clock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/calendar-clock.png -------------------------------------------------------------------------------- /docs/hacker/icons/calendar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/calendar.png -------------------------------------------------------------------------------- /docs/hacker/icons/carton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/carton.png -------------------------------------------------------------------------------- /docs/hacker/icons/cat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cat.png -------------------------------------------------------------------------------- /docs/hacker/icons/clock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/clock.png -------------------------------------------------------------------------------- /docs/hacker/icons/cloud-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cloud-down.png -------------------------------------------------------------------------------- /docs/hacker/icons/cloud-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cloud-sync.png -------------------------------------------------------------------------------- /docs/hacker/icons/cloud-up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cloud-up.png -------------------------------------------------------------------------------- /docs/hacker/icons/cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cloud.png -------------------------------------------------------------------------------- /docs/hacker/icons/cog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cog.png -------------------------------------------------------------------------------- /docs/hacker/icons/cogs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cogs.png -------------------------------------------------------------------------------- /docs/hacker/icons/compass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/compass.png -------------------------------------------------------------------------------- /docs/hacker/icons/cone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/cone.png -------------------------------------------------------------------------------- /docs/hacker/icons/dashboard-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/dashboard-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/dashboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/dashboard.png -------------------------------------------------------------------------------- /docs/hacker/icons/database.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/database.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-camera.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-camera.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-computer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-computer.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-drive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-drive.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-laptop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-laptop.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-mobile-phone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-mobile-phone.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-tablet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-tablet.png -------------------------------------------------------------------------------- /docs/hacker/icons/device-tv.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/device-tv.png -------------------------------------------------------------------------------- /docs/hacker/icons/disc-vinyl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/disc-vinyl.png -------------------------------------------------------------------------------- /docs/hacker/icons/disc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/disc.png -------------------------------------------------------------------------------- /docs/hacker/icons/drop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/drop.png -------------------------------------------------------------------------------- /docs/hacker/icons/envelope-letter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/envelope-letter.png -------------------------------------------------------------------------------- /docs/hacker/icons/envelope.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/envelope.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-bookmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-bookmark.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-code.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-empty.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-excel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-excel.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-exe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-exe.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-font.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-font.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-illustrator.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-illustrator.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-indesign.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-indesign.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-link.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-note.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-note.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-pdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-pdf.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-photoshop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-photoshop.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-picture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-picture.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-powerpoint.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-powerpoint.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-premiere.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-premiere.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-sound.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-sound.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-text.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-video.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-video.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-word.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-word.png -------------------------------------------------------------------------------- /docs/hacker/icons/file-zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/file-zip.png -------------------------------------------------------------------------------- /docs/hacker/icons/flag-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/flag-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/flag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/flag.png -------------------------------------------------------------------------------- /docs/hacker/icons/flask.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/flask.png -------------------------------------------------------------------------------- /docs/hacker/icons/floppy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/floppy.png -------------------------------------------------------------------------------- /docs/hacker/icons/flower.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/flower.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder-document.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder-document.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder-house.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder-house.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder-music.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder-music.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder-picture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder-picture.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder-video.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder-video.png -------------------------------------------------------------------------------- /docs/hacker/icons/folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/folder.png -------------------------------------------------------------------------------- /docs/hacker/icons/funnel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/funnel.png -------------------------------------------------------------------------------- /docs/hacker/icons/gamepad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/gamepad.png -------------------------------------------------------------------------------- /docs/hacker/icons/gift.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/gift.png -------------------------------------------------------------------------------- /docs/hacker/icons/globe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/globe.png -------------------------------------------------------------------------------- /docs/hacker/icons/handshake.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/handshake.png -------------------------------------------------------------------------------- /docs/hacker/icons/headphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/headphone.png -------------------------------------------------------------------------------- /docs/hacker/icons/heart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/heart.png -------------------------------------------------------------------------------- /docs/hacker/icons/house.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/house.png -------------------------------------------------------------------------------- /docs/hacker/icons/institution.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/institution.png -------------------------------------------------------------------------------- /docs/hacker/icons/key.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/key.png -------------------------------------------------------------------------------- /docs/hacker/icons/keyring.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/keyring.png -------------------------------------------------------------------------------- /docs/hacker/icons/layers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/layers.png -------------------------------------------------------------------------------- /docs/hacker/icons/life-buoy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/life-buoy.png -------------------------------------------------------------------------------- /docs/hacker/icons/light-bulb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/light-bulb.png -------------------------------------------------------------------------------- /docs/hacker/icons/lightning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/lightning.png -------------------------------------------------------------------------------- /docs/hacker/icons/lock-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/lock-open.png -------------------------------------------------------------------------------- /docs/hacker/icons/lock.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/lock.png -------------------------------------------------------------------------------- /docs/hacker/icons/magnify-less.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/magnify-less.png -------------------------------------------------------------------------------- /docs/hacker/icons/magnify.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/magnify.png -------------------------------------------------------------------------------- /docs/hacker/icons/map-map-marker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/map-map-marker.png -------------------------------------------------------------------------------- /docs/hacker/icons/map-marker.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/map-marker.png -------------------------------------------------------------------------------- /docs/hacker/icons/map.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/map.png -------------------------------------------------------------------------------- /docs/hacker/icons/microphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/microphone.png -------------------------------------------------------------------------------- /docs/hacker/icons/mixer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/mixer.png -------------------------------------------------------------------------------- /docs/hacker/icons/money.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/money.png -------------------------------------------------------------------------------- /docs/hacker/icons/monitor.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/monitor.png -------------------------------------------------------------------------------- /docs/hacker/icons/news.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/news.png -------------------------------------------------------------------------------- /docs/hacker/icons/notepad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/notepad.png -------------------------------------------------------------------------------- /docs/hacker/icons/paper-plane.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/paper-plane.png -------------------------------------------------------------------------------- /docs/hacker/icons/paperclip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/paperclip.png -------------------------------------------------------------------------------- /docs/hacker/icons/pencil.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/pencil.png -------------------------------------------------------------------------------- /docs/hacker/icons/phone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/phone.png -------------------------------------------------------------------------------- /docs/hacker/icons/pin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/pin.png -------------------------------------------------------------------------------- /docs/hacker/icons/post-it.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/post-it.png -------------------------------------------------------------------------------- /docs/hacker/icons/profile-group.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/profile-group.png -------------------------------------------------------------------------------- /docs/hacker/icons/profile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/profile.png -------------------------------------------------------------------------------- /docs/hacker/icons/puzzle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/puzzle.png -------------------------------------------------------------------------------- /docs/hacker/icons/radio.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/radio.png -------------------------------------------------------------------------------- /docs/hacker/icons/rss.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/rss.png -------------------------------------------------------------------------------- /docs/hacker/icons/safe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/safe.png -------------------------------------------------------------------------------- /docs/hacker/icons/search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/search.png -------------------------------------------------------------------------------- /docs/hacker/icons/shield-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/shield-error.png -------------------------------------------------------------------------------- /docs/hacker/icons/shield-ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/shield-ok.png -------------------------------------------------------------------------------- /docs/hacker/icons/shield-warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/shield-warning.png -------------------------------------------------------------------------------- /docs/hacker/icons/shield.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/shield.png -------------------------------------------------------------------------------- /docs/hacker/icons/shop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/shop.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-add.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-add.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-ban.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-ban.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-check.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-check.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-delete.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-down.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-error.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-info.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-info.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-left.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-question.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-question.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-right.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-sync.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-up.png -------------------------------------------------------------------------------- /docs/hacker/icons/sign-warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sign-warning.png -------------------------------------------------------------------------------- /docs/hacker/icons/skull.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/skull.png -------------------------------------------------------------------------------- /docs/hacker/icons/snow-flake.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/snow-flake.png -------------------------------------------------------------------------------- /docs/hacker/icons/social-facebook.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/social-facebook.png -------------------------------------------------------------------------------- /docs/hacker/icons/social-google-plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/social-google-plus.png -------------------------------------------------------------------------------- /docs/hacker/icons/social-twitter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/social-twitter.png -------------------------------------------------------------------------------- /docs/hacker/icons/social-youtube.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/social-youtube.png -------------------------------------------------------------------------------- /docs/hacker/icons/stamp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/stamp.png -------------------------------------------------------------------------------- /docs/hacker/icons/star-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/star-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/star.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/star.png -------------------------------------------------------------------------------- /docs/hacker/icons/sun.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/sun.png -------------------------------------------------------------------------------- /docs/hacker/icons/switch-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/switch-off.png -------------------------------------------------------------------------------- /docs/hacker/icons/switch-on.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/switch-on.png -------------------------------------------------------------------------------- /docs/hacker/icons/tag-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/tag-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/tag.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/tag.png -------------------------------------------------------------------------------- /docs/hacker/icons/terminal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/terminal.png -------------------------------------------------------------------------------- /docs/hacker/icons/thumb-up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/thumb-up.png -------------------------------------------------------------------------------- /docs/hacker/icons/trashcan-full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/trashcan-full.png -------------------------------------------------------------------------------- /docs/hacker/icons/trashcan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/trashcan.png -------------------------------------------------------------------------------- /docs/hacker/icons/user-female-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/user-female-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/user-female.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/user-female.png -------------------------------------------------------------------------------- /docs/hacker/icons/user-id.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/user-id.png -------------------------------------------------------------------------------- /docs/hacker/icons/user-male-alt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/user-male-alt.png -------------------------------------------------------------------------------- /docs/hacker/icons/user-male.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/user-male.png -------------------------------------------------------------------------------- /docs/hacker/icons/webcam.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/webcam.png -------------------------------------------------------------------------------- /docs/hacker/icons/window-layout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/window-layout.png -------------------------------------------------------------------------------- /docs/hacker/icons/window-system.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/window-system.png -------------------------------------------------------------------------------- /docs/hacker/icons/window.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/window.png -------------------------------------------------------------------------------- /docs/hacker/icons/wine.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/wine.png -------------------------------------------------------------------------------- /docs/hacker/icons/wrench-screwdriver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/wrench-screwdriver.png -------------------------------------------------------------------------------- /docs/hacker/icons/wrench.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/icons/wrench.png -------------------------------------------------------------------------------- /docs/hacker/images/hacked.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/images/hacked.png -------------------------------------------------------------------------------- /docs/hacker/images/hacker.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/images/hacker.jpg -------------------------------------------------------------------------------- /docs/hacker/images/screen.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/hacker/images/screen.jpg -------------------------------------------------------------------------------- /docs/hacker/pglib: -------------------------------------------------------------------------------- 1 | ../../pglib/ -------------------------------------------------------------------------------- /docs/index.rst: -------------------------------------------------------------------------------- 1 | .. Pygame tutorial documentation master file, created by 2 | sphinx-quickstart on Thu Apr 25 12:29:27 2019. 3 | You can adapt this file completely to your liking, but it should at least 4 | contain the root `toctree` directive. 5 | 6 | Welcome to making apps with Pygame! 7 | =================================== 8 | 9 | This tutorial explains how to make interactive applications and games using Pygame. 10 | The first part is a general introduction to Pygame without defining classes and objects. 11 | The second part introduces classes and objects and teaches an **object-oriented programming** 12 | approach to making apps. 13 | 14 | .. toctree:: 15 | :maxdepth: 2 16 | :caption: Contents: 17 | 18 | 1_intro/intro 19 | 2_draw/draw 20 | rect/rect 21 | 3_image/image 22 | 4_text/text 23 | 5_app/app 24 | 6_gui/gui 25 | 7_sound/sound 26 | 9_board/board 27 | 10_games/games 28 | 10_games/breakout/breakout 29 | tiles/tiles 30 | sphinx 31 | 32 | Indices and tables 33 | ================== 34 | 35 | * :ref:`genindex` 36 | * :ref:`modindex` 37 | * :ref:`search` 38 | -------------------------------------------------------------------------------- /docs/make.bat: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | pushd %~dp0 4 | 5 | REM Command file for Sphinx documentation 6 | 7 | if "%SPHINXBUILD%" == "" ( 8 | set SPHINXBUILD=sphinx-build 9 | ) 10 | set SOURCEDIR=. 11 | set BUILDDIR=_build 12 | 13 | if "%1" == "" goto help 14 | 15 | %SPHINXBUILD% >NUL 2>NUL 16 | if errorlevel 9009 ( 17 | echo. 18 | echo.The 'sphinx-build' command was not found. Make sure you have Sphinx 19 | echo.installed, then set the SPHINXBUILD environment variable to point 20 | echo.to the full path of the 'sphinx-build' executable. Alternatively you 21 | echo.may add the Sphinx directory to PATH. 22 | echo. 23 | echo.If you don't have Sphinx installed, grab it from 24 | echo.http://sphinx-doc.org/ 25 | exit /b 1 26 | ) 27 | 28 | %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% 29 | goto end 30 | 31 | :help 32 | %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% 33 | 34 | :end 35 | popd 36 | -------------------------------------------------------------------------------- /docs/rect/rect1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect1.png -------------------------------------------------------------------------------- /docs/rect/rect1.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | from pygame.locals import * 3 | 4 | SIZE = 500, 200 5 | RED = (255, 0, 0) 6 | GRAY = (150, 150, 150) 7 | 8 | pygame.init() 9 | screen = pygame.display.set_mode(SIZE) 10 | 11 | rect = Rect(50, 60, 200, 80) 12 | print(f'x={rect.x}, y={rect.y}, w={rect.w}, h={rect.h}') 13 | print(f'left={rect.left}, top={rect.top}, right={rect.right}, bottom={rect.bottom}') 14 | print(f'center={rect.center}') 15 | 16 | running = True 17 | while running: 18 | for event in pygame.event.get(): 19 | if event.type == QUIT: 20 | running = False 21 | 22 | screen.fill(GRAY) 23 | pygame.draw.rect(screen, RED, rect) 24 | pygame.display.flip() 25 | 26 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect10.png -------------------------------------------------------------------------------- /docs/rect/rect10.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | n = 50 4 | rects = random_rects(n) 5 | 6 | while running: 7 | for event in pygame.event.get(): 8 | if event.type == QUIT: 9 | running = False 10 | 11 | if event.type == KEYDOWN: 12 | if event.key == K_r: 13 | rects = random_rects(n) 14 | 15 | screen.fill(GRAY) 16 | pygame.draw.rect(screen, GREEN, rect, 1) 17 | 18 | for r in rects: 19 | if rect.colliderect(r): 20 | pygame.draw.rect(screen, RED, r, 2) 21 | else: 22 | pygame.draw.rect(screen, BLUE, r, 1) 23 | 24 | pygame.display.flip() 25 | 26 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect11.png -------------------------------------------------------------------------------- /docs/rect/rect11.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | n = 30 4 | rects = random_rects(n) 5 | 6 | while running: 7 | for event in pygame.event.get(): 8 | if event.type == QUIT: 9 | running = False 10 | 11 | if event.type == KEYDOWN: 12 | if event.key == K_r: 13 | rects = random_rects(n) 14 | 15 | screen.fill(GRAY) 16 | 17 | intersecting = [] 18 | for i in range(n-1): 19 | r0 = rects[i] 20 | for j in range(i+1, n): 21 | r1 = rects[j] 22 | if r0.colliderect(r1): 23 | intersecting.append(r0) 24 | intersecting.append(r1) 25 | break 26 | 27 | for i, r in enumerate(rects): 28 | color = RED if r in intersecting else BLUE 29 | pygame.draw.rect(screen, color, r) 30 | draw_text(str(i), r.topleft) 31 | 32 | pygame.display.flip() 33 | 34 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect2.png -------------------------------------------------------------------------------- /docs/rect/rect2.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | pts = ('topleft', 'topright', 'bottomleft', 'bottomright', 4 | 'midtop', 'midright', 'midbottom', 'midleft', 'center') 5 | 6 | running = True 7 | while running: 8 | for event in pygame.event.get(): 9 | if event.type == QUIT: 10 | running = False 11 | 12 | screen.fill(GRAY) 13 | pygame.draw.rect(screen, GREEN, rect, 4) 14 | for pt in pts: 15 | pos = eval('rect.'+pt) 16 | draw_text(pt, pos) 17 | pygame.draw.circle(screen, RED, pos, 3) 18 | 19 | pygame.display.flip() 20 | 21 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect3.png -------------------------------------------------------------------------------- /docs/rect/rect3.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | rect = Rect(50, 60, 200, 80) 4 | 5 | while running: 6 | for event in pygame.event.get(): 7 | if event.type == QUIT: 8 | running = False 9 | 10 | if event.type == KEYDOWN: 11 | if event.key == K_l: 12 | rect.left = 0 13 | if event.key == K_c: 14 | rect.centerx = width//2 15 | if event.key == K_r: 16 | rect.right = width 17 | 18 | if event.key == K_t: 19 | rect.top = 0 20 | if event.key == K_m: 21 | rect.centery = height//2 22 | if event.key == K_b: 23 | rect.bottom = height 24 | 25 | screen.fill(GRAY) 26 | pygame.draw.rect(screen, BLUE, rect) 27 | pygame.display.flip() 28 | 29 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect4.png -------------------------------------------------------------------------------- /docs/rect/rect4.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | rect0 = Rect(50, 60, 200, 80) 4 | rect = rect0.copy() 5 | 6 | while running: 7 | for event in pygame.event.get(): 8 | if event.type == QUIT: 9 | running = False 10 | 11 | if event.type == KEYDOWN: 12 | if event.key in dir: 13 | v = dir[event.key] 14 | rect.move_ip(v) 15 | 16 | screen.fill(GRAY) 17 | pygame.draw.rect(screen, BLUE, rect0, 1) 18 | pygame.draw.rect(screen, RED, rect, 4) 19 | pygame.display.flip() 20 | 21 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect5.png -------------------------------------------------------------------------------- /docs/rect/rect5.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | rect0 = rect.copy() 4 | 5 | while running: 6 | for event in pygame.event.get(): 7 | if event.type == QUIT: 8 | running = False 9 | 10 | if event.type == KEYDOWN: 11 | if event.key in dir: 12 | v = dir[event.key] 13 | rect.inflate_ip(v) 14 | 15 | screen.fill(GRAY) 16 | pygame.draw.rect(screen, BLUE, rect0, 1) 17 | pygame.draw.rect(screen, RED, rect, 4) 18 | pygame.display.flip() 19 | 20 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect6.png -------------------------------------------------------------------------------- /docs/rect/rect6.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | r0 = Rect(50, 60, 200, 80) 4 | r1 = Rect(100, 20, 100, 140) 5 | 6 | while running: 7 | for event in pygame.event.get(): 8 | if event.type == QUIT: 9 | running = False 10 | 11 | if event.type == KEYDOWN: 12 | if event.key in dir: 13 | r1.move_ip(dir[event.key]) 14 | 15 | clip = r0.clip(r1) 16 | union = r0.union(r1) 17 | 18 | screen.fill(GRAY) 19 | pygame.draw.rect(screen, YELLOW, union, 0) 20 | pygame.draw.rect(screen, GREEN, clip, 0) 21 | pygame.draw.rect(screen, BLUE, r0, 4) 22 | pygame.draw.rect(screen, RED, r1, 4) 23 | pygame.display.flip() 24 | 25 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect7.png -------------------------------------------------------------------------------- /docs/rect/rect7.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | moving = False 4 | 5 | while running: 6 | for event in pygame.event.get(): 7 | if event.type == QUIT: 8 | running = False 9 | 10 | elif event.type == MOUSEBUTTONDOWN: 11 | if rect.collidepoint(event.pos): 12 | moving = True 13 | 14 | elif event.type == MOUSEBUTTONUP: 15 | moving = False 16 | 17 | elif event.type == MOUSEMOTION and moving: 18 | rect.move_ip(event.rel) 19 | 20 | screen.fill(GRAY) 21 | pygame.draw.rect(screen, RED, rect) 22 | if moving: 23 | pygame.draw.rect(screen, BLUE, rect, 4) 24 | pygame.display.flip() 25 | 26 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect8.png -------------------------------------------------------------------------------- /docs/rect/rect8.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | rect = Rect(100, 50, 50, 50) 4 | v = [2, 2] 5 | 6 | while running: 7 | for event in pygame.event.get(): 8 | if event.type == QUIT: 9 | running = False 10 | 11 | rect.move_ip(v) 12 | 13 | if rect.left < 0: 14 | v[0] *= -1 15 | if rect.right > width: 16 | v[0] *= -1 17 | if rect.top < 0: 18 | v[1] *= -1 19 | if rect.bottom > height: 20 | v[1] *= -1 21 | 22 | screen.fill(GRAY) 23 | pygame.draw.rect(screen, RED, rect) 24 | pygame.display.flip() 25 | 26 | pygame.quit() -------------------------------------------------------------------------------- /docs/rect/rect9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/rect/rect9.png -------------------------------------------------------------------------------- /docs/rect/rect9.py: -------------------------------------------------------------------------------- 1 | from rect import * 2 | 3 | points = random_points(100) 4 | 5 | while running: 6 | for event in pygame.event.get(): 7 | if event.type == QUIT: 8 | running = False 9 | 10 | if event.type == KEYDOWN: 11 | if event.key == K_r: 12 | points = random_points(100) 13 | 14 | screen.fill(GRAY) 15 | pygame.draw.rect(screen, GREEN, rect, 1) 16 | for p in points: 17 | if rect.collidepoint(p): 18 | pygame.draw.circle(screen, RED, p, 4, 0) 19 | else: 20 | pygame.draw.circle(screen, BLUE, p, 4, 0) 21 | 22 | pygame.display.flip() 23 | 24 | pygame.quit() -------------------------------------------------------------------------------- /docs/requirements.txt: -------------------------------------------------------------------------------- 1 | pygame 2 | numpy -------------------------------------------------------------------------------- /docs/space/images/space.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/space/images/space.jpg -------------------------------------------------------------------------------- /docs/space/images/spaceship.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/space/images/spaceship.png -------------------------------------------------------------------------------- /docs/space/images/ufo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/space/images/ufo.png -------------------------------------------------------------------------------- /docs/space/sounds/Intergalactic Odyssey.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/space/sounds/Intergalactic Odyssey.ogg -------------------------------------------------------------------------------- /docs/space/space.rst: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/space/space.rst -------------------------------------------------------------------------------- /docs/sprite/png/BG/BG.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/BG/BG.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Bush (1).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Bush (1).png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Bush (2).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Bush (2).png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Bush (3).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Bush (3).png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Bush (4).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Bush (4).png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Crate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Crate.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Mushroom_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Mushroom_1.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Mushroom_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Mushroom_2.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Sign_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Sign_1.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Sign_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Sign_2.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Stone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Stone.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Tree_1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Tree_1.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Tree_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Tree_2.png -------------------------------------------------------------------------------- /docs/sprite/png/Object/Tree_3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Object/Tree_3.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/1.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/10.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/11.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/12.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/13.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/14.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/15.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/16.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/17.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/17.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/18.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/18.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/2.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/3.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/4.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/5.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/6.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/7.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/8.png -------------------------------------------------------------------------------- /docs/sprite/png/Tiles/9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/png/Tiles/9.png -------------------------------------------------------------------------------- /docs/sprite/sounds/click.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/click.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/click_2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/click_2.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/load.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/load.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/misc_menu.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/misc_menu.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/misc_menu_2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/misc_menu_2.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/misc_menu_3.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/misc_menu_3.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/misc_menu_4.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/misc_menu_4.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/misc_sound.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/misc_sound.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/negative.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/negative.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/negative_2.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/negative_2.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/positive.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/positive.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/save.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/save.wav -------------------------------------------------------------------------------- /docs/sprite/sounds/sharp_echo.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/sprite/sounds/sharp_echo.wav -------------------------------------------------------------------------------- /docs/sprite/sprite.rst: -------------------------------------------------------------------------------- 1 | Sprites 2 | ======= 3 | 4 | Free tile set 5 | https://opengameart.org/content/free-platformer-game-tileset 6 | -------------------------------------------------------------------------------- /docs/tiles/Overworld.tsx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /docs/tiles/gfx/Inner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/Inner.png -------------------------------------------------------------------------------- /docs/tiles/gfx/NPC_test.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/NPC_test.png -------------------------------------------------------------------------------- /docs/tiles/gfx/Overworld.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/Overworld.png -------------------------------------------------------------------------------- /docs/tiles/gfx/cave.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/cave.png -------------------------------------------------------------------------------- /docs/tiles/gfx/character.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/character.png -------------------------------------------------------------------------------- /docs/tiles/gfx/font.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/font.png -------------------------------------------------------------------------------- /docs/tiles/gfx/log.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/log.png -------------------------------------------------------------------------------- /docs/tiles/gfx/objects.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/gfx/objects.png -------------------------------------------------------------------------------- /docs/tiles/map2.tmx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 0,0,0,0,0,0,0,0,0,0, 6 | 0,0,0,0,0,0,0,0,0,0, 7 | 0,0,0,0,0,0,0,0,0,0, 8 | 0,0,0,0,0,0,0,0,0,0, 9 | 0,0,0,0,0,0,0,0,0,0, 10 | 0,0,0,0,0,0,0,0,0,0, 11 | 0,0,0,0,0,0,0,0,0,0, 12 | 0,0,0,0,0,0,0,0,0,0, 13 | 0,0,0,0,0,0,0,0,0,0, 14 | 0,0,0,0,0,0,0,0,0,0 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /docs/tiles/map3.tmx: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 1471,1471,1471,1471,1471,1471,1471,1471,1478,1486, 8 | 1471,1480,1445,1445,1480,1441,1442,1443,1445,1445, 9 | 1471,1480,1480,1480,1480,1449,1450,1451,1443,1453, 10 | 1471,1480,1452,1452,1480,1480,1480,1480,1442,1443, 11 | 1471,1452,1452,1453,1443,1480,1449,1449,1450,1451, 12 | 1471,1471,1471,1450,1451,1449,1457,1457,1458,1441, 13 | 1471,1471,1457,1458,1471,1457,1458,1459,1457,1486, 14 | 1471,1471,1441,1471,1471,1441,1442,1486,1486,1486, 15 | 1471,1471,1471,1471,1471,1449,1486,1486,1486,1486, 16 | 1471,1471,1471,1471,1471,1457,1486,1486,1478,1486 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /docs/tiles/tiled-demo/resources/overlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiled-demo/resources/overlay.png -------------------------------------------------------------------------------- /docs/tiles/tiled-demo/resources/player.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiled-demo/resources/player.png -------------------------------------------------------------------------------- /docs/tiles/tiled-demo/resources/tiles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiled-demo/resources/tiles.png -------------------------------------------------------------------------------- /docs/tiles/tiles0.py: -------------------------------------------------------------------------------- 1 | import pygame 2 | 3 | file = 'tmw_desert_spacing.png' 4 | image = pygame.image.load(file) 5 | rect = image.get_rect() 6 | print(image) 7 | 8 | pygame.init() 9 | screen = pygame.display.set_mode(rect.size) 10 | 11 | screen.blit(image, rect) 12 | pygame.display.update() 13 | 14 | while True: 15 | for event in pygame.event.get(): 16 | if event.type == pygame.QUIT: 17 | pygame.quit() -------------------------------------------------------------------------------- /docs/tiles/tiles2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiles2.png -------------------------------------------------------------------------------- /docs/tiles/tiles2b.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiles2b.png -------------------------------------------------------------------------------- /docs/tiles/tiles3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tiles3.png -------------------------------------------------------------------------------- /docs/tiles/tmw_desert_spacing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/docs/tiles/tmw_desert_spacing.png -------------------------------------------------------------------------------- /docs/tmp.py: -------------------------------------------------------------------------------- 1 | import pygame -------------------------------------------------------------------------------- /images/cat.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/cat.jpg -------------------------------------------------------------------------------- /images/river.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/river.jpg -------------------------------------------------------------------------------- /images/sunset.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/sunset.jpg -------------------------------------------------------------------------------- /images/ui/blue_boxCheckmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_boxCheckmark.png -------------------------------------------------------------------------------- /images/ui/blue_boxCross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_boxCross.png -------------------------------------------------------------------------------- /images/ui/blue_boxTick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_boxTick.png -------------------------------------------------------------------------------- /images/ui/blue_button00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button00.png -------------------------------------------------------------------------------- /images/ui/blue_button01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button01.png -------------------------------------------------------------------------------- /images/ui/blue_button02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button02.png -------------------------------------------------------------------------------- /images/ui/blue_button03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button03.png -------------------------------------------------------------------------------- /images/ui/blue_button04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button04.png -------------------------------------------------------------------------------- /images/ui/blue_button05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button05.png -------------------------------------------------------------------------------- /images/ui/blue_button06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button06.png -------------------------------------------------------------------------------- /images/ui/blue_button07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button07.png -------------------------------------------------------------------------------- /images/ui/blue_button08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button08.png -------------------------------------------------------------------------------- /images/ui/blue_button09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button09.png -------------------------------------------------------------------------------- /images/ui/blue_button10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button10.png -------------------------------------------------------------------------------- /images/ui/blue_button11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button11.png -------------------------------------------------------------------------------- /images/ui/blue_button12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button12.png -------------------------------------------------------------------------------- /images/ui/blue_button13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_button13.png -------------------------------------------------------------------------------- /images/ui/blue_checkmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_checkmark.png -------------------------------------------------------------------------------- /images/ui/blue_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_circle.png -------------------------------------------------------------------------------- /images/ui/blue_cross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_cross.png -------------------------------------------------------------------------------- /images/ui/blue_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_panel.png -------------------------------------------------------------------------------- /images/ui/blue_sliderDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_sliderDown.png -------------------------------------------------------------------------------- /images/ui/blue_sliderLeft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_sliderLeft.png -------------------------------------------------------------------------------- /images/ui/blue_sliderRight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_sliderRight.png -------------------------------------------------------------------------------- /images/ui/blue_sliderUp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_sliderUp.png -------------------------------------------------------------------------------- /images/ui/blue_tick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/blue_tick.png -------------------------------------------------------------------------------- /images/ui/dropdownBottom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/dropdownBottom.png -------------------------------------------------------------------------------- /images/ui/dropdownMid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/dropdownMid.png -------------------------------------------------------------------------------- /images/ui/dropdownTop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/dropdownTop.png -------------------------------------------------------------------------------- /images/ui/green_boxCheckmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_boxCheckmark.png -------------------------------------------------------------------------------- /images/ui/green_boxCross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_boxCross.png -------------------------------------------------------------------------------- /images/ui/green_boxTick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_boxTick.png -------------------------------------------------------------------------------- /images/ui/green_button00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button00.png -------------------------------------------------------------------------------- /images/ui/green_button01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button01.png -------------------------------------------------------------------------------- /images/ui/green_button02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button02.png -------------------------------------------------------------------------------- /images/ui/green_button03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button03.png -------------------------------------------------------------------------------- /images/ui/green_button04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button04.png -------------------------------------------------------------------------------- /images/ui/green_button05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button05.png -------------------------------------------------------------------------------- /images/ui/green_button06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button06.png -------------------------------------------------------------------------------- /images/ui/green_button07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button07.png -------------------------------------------------------------------------------- /images/ui/green_button08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button08.png -------------------------------------------------------------------------------- /images/ui/green_button09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button09.png -------------------------------------------------------------------------------- /images/ui/green_button10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button10.png -------------------------------------------------------------------------------- /images/ui/green_button11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button11.png -------------------------------------------------------------------------------- /images/ui/green_button12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button12.png -------------------------------------------------------------------------------- /images/ui/green_button13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_button13.png -------------------------------------------------------------------------------- /images/ui/green_checkmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_checkmark.png -------------------------------------------------------------------------------- /images/ui/green_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_circle.png -------------------------------------------------------------------------------- /images/ui/green_cross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_cross.png -------------------------------------------------------------------------------- /images/ui/green_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_panel.png -------------------------------------------------------------------------------- /images/ui/green_sliderDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_sliderDown.png -------------------------------------------------------------------------------- /images/ui/green_sliderLeft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_sliderLeft.png -------------------------------------------------------------------------------- /images/ui/green_sliderRight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_sliderRight.png -------------------------------------------------------------------------------- /images/ui/green_sliderUp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_sliderUp.png -------------------------------------------------------------------------------- /images/ui/green_tick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/green_tick.png -------------------------------------------------------------------------------- /images/ui/grey_arrowDownGrey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_arrowDownGrey.png -------------------------------------------------------------------------------- /images/ui/grey_arrowDownWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_arrowDownWhite.png -------------------------------------------------------------------------------- /images/ui/grey_arrowUpGrey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_arrowUpGrey.png -------------------------------------------------------------------------------- /images/ui/grey_arrowUpWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_arrowUpWhite.png -------------------------------------------------------------------------------- /images/ui/grey_box.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_box.png -------------------------------------------------------------------------------- /images/ui/grey_boxCheckmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_boxCheckmark.png -------------------------------------------------------------------------------- /images/ui/grey_boxCross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_boxCross.png -------------------------------------------------------------------------------- /images/ui/grey_boxTick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_boxTick.png -------------------------------------------------------------------------------- /images/ui/grey_button00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button00.png -------------------------------------------------------------------------------- /images/ui/grey_button01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button01.png -------------------------------------------------------------------------------- /images/ui/grey_button02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button02.png -------------------------------------------------------------------------------- /images/ui/grey_button03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button03.png -------------------------------------------------------------------------------- /images/ui/grey_button04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button04.png -------------------------------------------------------------------------------- /images/ui/grey_button05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button05.png -------------------------------------------------------------------------------- /images/ui/grey_button06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button06.png -------------------------------------------------------------------------------- /images/ui/grey_button07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button07.png -------------------------------------------------------------------------------- /images/ui/grey_button08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button08.png -------------------------------------------------------------------------------- /images/ui/grey_button09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button09.png -------------------------------------------------------------------------------- /images/ui/grey_button10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button10.png -------------------------------------------------------------------------------- /images/ui/grey_button11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button11.png -------------------------------------------------------------------------------- /images/ui/grey_button12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button12.png -------------------------------------------------------------------------------- /images/ui/grey_button13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button13.png -------------------------------------------------------------------------------- /images/ui/grey_button14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button14.png -------------------------------------------------------------------------------- /images/ui/grey_button15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_button15.png -------------------------------------------------------------------------------- /images/ui/grey_checkmarkGrey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_checkmarkGrey.png -------------------------------------------------------------------------------- /images/ui/grey_checkmarkWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_checkmarkWhite.png -------------------------------------------------------------------------------- /images/ui/grey_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_circle.png -------------------------------------------------------------------------------- /images/ui/grey_crossGrey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_crossGrey.png -------------------------------------------------------------------------------- /images/ui/grey_crossWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_crossWhite.png -------------------------------------------------------------------------------- /images/ui/grey_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_panel.png -------------------------------------------------------------------------------- /images/ui/grey_sliderDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderDown.png -------------------------------------------------------------------------------- /images/ui/grey_sliderEnd.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderEnd.png -------------------------------------------------------------------------------- /images/ui/grey_sliderHorizontal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderHorizontal.png -------------------------------------------------------------------------------- /images/ui/grey_sliderLeft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderLeft.png -------------------------------------------------------------------------------- /images/ui/grey_sliderRight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderRight.png -------------------------------------------------------------------------------- /images/ui/grey_sliderUp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderUp.png -------------------------------------------------------------------------------- /images/ui/grey_sliderVertical.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_sliderVertical.png -------------------------------------------------------------------------------- /images/ui/grey_tickGrey.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_tickGrey.png -------------------------------------------------------------------------------- /images/ui/grey_tickWhite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/grey_tickWhite.png -------------------------------------------------------------------------------- /images/ui/red_boxCheckmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_boxCheckmark.png -------------------------------------------------------------------------------- /images/ui/red_boxCross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_boxCross.png -------------------------------------------------------------------------------- /images/ui/red_boxTick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_boxTick.png -------------------------------------------------------------------------------- /images/ui/red_button00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button00.png -------------------------------------------------------------------------------- /images/ui/red_button01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button01.png -------------------------------------------------------------------------------- /images/ui/red_button02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button02.png -------------------------------------------------------------------------------- /images/ui/red_button03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button03.png -------------------------------------------------------------------------------- /images/ui/red_button04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button04.png -------------------------------------------------------------------------------- /images/ui/red_button05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button05.png -------------------------------------------------------------------------------- /images/ui/red_button06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button06.png -------------------------------------------------------------------------------- /images/ui/red_button07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button07.png -------------------------------------------------------------------------------- /images/ui/red_button08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button08.png -------------------------------------------------------------------------------- /images/ui/red_button09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button09.png -------------------------------------------------------------------------------- /images/ui/red_button10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button10.png -------------------------------------------------------------------------------- /images/ui/red_button11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button11.png -------------------------------------------------------------------------------- /images/ui/red_button12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button12.png -------------------------------------------------------------------------------- /images/ui/red_button13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_button13.png -------------------------------------------------------------------------------- /images/ui/red_checkmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_checkmark.png -------------------------------------------------------------------------------- /images/ui/red_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_circle.png -------------------------------------------------------------------------------- /images/ui/red_cross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_cross.png -------------------------------------------------------------------------------- /images/ui/red_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_panel.png -------------------------------------------------------------------------------- /images/ui/red_sliderDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_sliderDown.png -------------------------------------------------------------------------------- /images/ui/red_sliderLeft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_sliderLeft.png -------------------------------------------------------------------------------- /images/ui/red_sliderRight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_sliderRight.png -------------------------------------------------------------------------------- /images/ui/red_sliderUp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_sliderUp.png -------------------------------------------------------------------------------- /images/ui/red_tick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/red_tick.png -------------------------------------------------------------------------------- /images/ui/yellow_boxCheckmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_boxCheckmark.png -------------------------------------------------------------------------------- /images/ui/yellow_boxCross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_boxCross.png -------------------------------------------------------------------------------- /images/ui/yellow_boxTick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_boxTick.png -------------------------------------------------------------------------------- /images/ui/yellow_button00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button00.png -------------------------------------------------------------------------------- /images/ui/yellow_button01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button01.png -------------------------------------------------------------------------------- /images/ui/yellow_button02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button02.png -------------------------------------------------------------------------------- /images/ui/yellow_button03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button03.png -------------------------------------------------------------------------------- /images/ui/yellow_button04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button04.png -------------------------------------------------------------------------------- /images/ui/yellow_button05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button05.png -------------------------------------------------------------------------------- /images/ui/yellow_button06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button06.png -------------------------------------------------------------------------------- /images/ui/yellow_button07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button07.png -------------------------------------------------------------------------------- /images/ui/yellow_button08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button08.png -------------------------------------------------------------------------------- /images/ui/yellow_button09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button09.png -------------------------------------------------------------------------------- /images/ui/yellow_button10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button10.png -------------------------------------------------------------------------------- /images/ui/yellow_button11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button11.png -------------------------------------------------------------------------------- /images/ui/yellow_button12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button12.png -------------------------------------------------------------------------------- /images/ui/yellow_button13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_button13.png -------------------------------------------------------------------------------- /images/ui/yellow_checkmark.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_checkmark.png -------------------------------------------------------------------------------- /images/ui/yellow_circle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_circle.png -------------------------------------------------------------------------------- /images/ui/yellow_cross.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_cross.png -------------------------------------------------------------------------------- /images/ui/yellow_panel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_panel.png -------------------------------------------------------------------------------- /images/ui/yellow_sliderDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_sliderDown.png -------------------------------------------------------------------------------- /images/ui/yellow_sliderLeft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_sliderLeft.png -------------------------------------------------------------------------------- /images/ui/yellow_sliderRight.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_sliderRight.png -------------------------------------------------------------------------------- /images/ui/yellow_sliderUp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_sliderUp.png -------------------------------------------------------------------------------- /images/ui/yellow_tick.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rasql/pygame-tutorial/645ab848edc18523eecd7ec7de859d2086b4bba0/images/ui/yellow_tick.png -------------------------------------------------------------------------------- /notes.md: -------------------------------------------------------------------------------- 1 | gitignore 2 | --------- 3 | 4 | Add this to ``.gitignore`` 5 | 6 | .DS_Store 7 | .vscode 8 | 9 | If the directory is already on Github 10 | 11 | git rm -r --cached .vscode 12 | git commit -m 'Remove the now ignored directory ".vscode"' 13 | git push origin master 14 | 15 | Documentation with sphinx 16 | ------------------------- 17 | 18 | The documentation for this tutorial is created with sphinx. To create rapidly a starting framework do this: 19 | 20 | mkdir docs 21 | cd docs 22 | sphinx-quickstart 23 | 24 | To compile the documention to HTML do this:: 25 | 26 | cd docs 27 | make html 28 | 29 | Symbolic links 30 | -------------- 31 | 32 | The ``pygamelib`` file is kept in the top GitHub directory. Each subfolder has a symbolic link to it. 33 | 34 | ln -s ../pygamelib.py pygamelib.py 35 | 36 | ls -la 37 | lrwxr-xr-x 1 raphael staff 15 May 3 21:41 pygamelib.py -> ../pygamelib.py 38 | 39 | To run pygame in MacOS Catalina 40 | ------------------------------- 41 | 42 | pip3 install pygame==2.0.0.dev4 43 | 44 | -------------------------------------------------------------------------------- /pglib/__init__.py: -------------------------------------------------------------------------------- 1 | # from .app import * 2 | # from .draw import * 3 | # from .gui import * 4 | # from .platformer import * 5 | 6 | __all__ = ['app', 'draw', 'gui', 'platformer'] -------------------------------------------------------------------------------- /pglib/gui.py: -------------------------------------------------------------------------------- 1 | class Button: 2 | pass -------------------------------------------------------------------------------- /pglib/platformer.py: -------------------------------------------------------------------------------- 1 | class Map: 2 | pass -------------------------------------------------------------------------------- /pglib/text.py: -------------------------------------------------------------------------------- 1 | class Text: 2 | pass 3 | 4 | class Multitext: 5 | def __init__(self, text): 6 | self.text = text 7 | self.images = [] 8 | self.rects = [] 9 | 10 | def render_words(self): 11 | pass 12 | 13 | 14 | if __name__ == '__main__': 15 | 16 | text = 'this is a \nMULTI-LINE text.' 17 | 18 | a = text.split() 19 | print(a) 20 | -------------------------------------------------------------------------------- /test/pg_app.py: -------------------------------------------------------------------------------- 1 | ../docs/app/pg_app.py -------------------------------------------------------------------------------- /test/test_node.py: -------------------------------------------------------------------------------- 1 | from pg_app import * 2 | 3 | s0 = Scene() 4 | n0 = Node() 5 | n1 = Node() 6 | n2 = Node() 7 | 8 | def test_node(): 9 | assert App.scenes == [s0] 10 | assert App.scene == s0 11 | assert App.scene.nodes == [n0, n1, n2] 12 | 13 | if __name__ == '__main__': 14 | print('test') --------------------------------------------------------------------------------