<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0" xml:base="https://www.programmez.com/" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Pong</title>
    <link>https://www.programmez.com/</link>
    <description></description>
    <language>fr</language>
    
    <item>
  <title>PONG en Python et pygame</title>
  <link>https://www.programmez.com/actualites/pong-en-python-et-pygame-39269</link>
  <description>&lt;span class=&quot;field field--name-title field--type-string field--label-hidden&quot;&gt;PONG en Python et pygame&lt;/span&gt;
&lt;span class=&quot;field field--name-uid field--type-entity-reference field--label-hidden&quot;&gt;&lt;span&gt;francoistonic&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;field field--name-created field--type-created field--label-hidden&quot;&gt;&lt;time datetime=&quot;2026-04-01T08:12:31+02:00&quot; title=&quot;Mercredi, 1 avril 2026 - 08:12&quot; class=&quot;datetime&quot;&gt;mer, 1 Avr 2026 - 08:12&lt;/time&gt;
&lt;/span&gt;


  &lt;div class=&quot;inline__links&quot;&gt;&lt;nav class=&quot;links inline nav links-inline&quot;&gt;&lt;span class=&quot;comment-forbidden nav-link&quot;&gt;&lt;a href=&quot;/user/login?destination=/actualites/pong-en-python-et-pygame-39269%23comment-form&quot;&gt;Se connecter&lt;/a&gt; ou &lt;a href=&quot;/user/register?destination=/actualites/pong-en-python-et-pygame-39269%23comment-form&quot;&gt;s&#039;inscrire&lt;/a&gt; pour publier un commentaire&lt;/span&gt;&lt;/nav&gt;
  &lt;/div&gt;

&lt;div class=&quot;btn btn-light&quot;&gt;
      &lt;a href=&quot;/actualites/outils&quot; hreflang=&quot;fr&quot;&gt;Outils&lt;/a&gt;
  &lt;/div&gt;

&lt;div class=&quot;mots-cles-actualite d-flex flex-wrap gap-2&quot;&gt;
      &lt;div class=&quot;btn&quot;&gt;&lt;a href=&quot;/actualites/pong&quot; hreflang=&quot;fr&quot;&gt;Pong&lt;/a&gt;&lt;/div&gt;
      &lt;div class=&quot;btn&quot;&gt;&lt;a href=&quot;/actualites/claude&quot; hreflang=&quot;fr&quot;&gt;Claude&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;

      &lt;div class=&quot;field field--name-field-image-actualite field--type-entity-reference field--label-hidden field__items&quot;&gt;
              &lt;div class=&quot;field__item&quot;&gt;&lt;div&gt;
  
  
  &lt;div class=&quot;field field--name-field-media-image field--type-image field--label-visually_hidden&quot;&gt;
    &lt;div class=&quot;field__label visually-hidden&quot;&gt;Image&lt;/div&gt;
              &lt;div class=&quot;field__item&quot;&gt;  &lt;img loading=&quot;lazy&quot; src=&quot;/sites/default/files/styles/large/public/images_actus/capture_decran_2026-04-01_a_08.09.52.png.webp?itok=UZD122bU&quot; class=&quot;image-style-large&quot; /&gt;


&lt;/div&gt;
          &lt;/div&gt;

&lt;/div&gt;
&lt;/div&gt;
          &lt;/div&gt;
  
            &lt;div class=&quot;clearfix text-formatted field field--name-body field--type-text-with-summary field--label-hidden field__item&quot;&gt;&lt;p&gt;Pong a été le premier jeu vidéo ayant connu un succès mondial. Le gameplay est très simple et le graphisme limité à son minimum. Mouse vs Python propose un PONG généré par Claude. Le projet utilise Python 3 et pygame.&amp;nbsp;&lt;/p&gt;

&lt;p&gt;Le prompt de départ est très simple : please create the pong videogame using Python et pygame. Give the user à way to start a new game and keep score. Par défaut, on demande à Claude de générer un jeu Pong avec les 2 joueurs, la balle, gérer le score et proposer un menu de démarrage. Trois classes sont définies : Paddle (pour les palettes des joueurs), Ball (pour gérer la balle qui rebondit) et PongGame pour la logique du jeu.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Les constantes du jeu définissent l&#039;affichage, par défaut 800x600, et la vitesse de la balle. Le code le plus critique est la gestion de la collision : handle_collision. Il utilise colliderect() de pygame pour détecter la collision. Pour le rendu, deux fonctions sont utilisées : draw_menu pour afficher le menu et draw_game pour le rendu du jeu proprement dit (paddles, balle, score, les éléments du jeu).&lt;/p&gt;
&lt;p&gt;Source :&amp;nbsp;&lt;a href=&quot;https://blog.pythonlibrary.org/2026/03/30/vibe-coding-pong-with-python-and-pygame/&quot;&gt;https://blog.pythonlibrary.org/2026/03/30/vibe-coding-pong-with-python-and-pygame/&lt;/a&gt;&lt;/p&gt;
&lt;/div&gt;
      &lt;section class=&quot;field field--name-field-commentaire-actu field--type-comment field--label-above comment-wrapper&quot;&gt;
  
  

  
&lt;/section&gt;
</description>
  <pubDate>Wed, 01 Apr 2026 06:12:31 +0000</pubDate>
    <dc:creator>francoistonic</dc:creator>
    <guid isPermaLink="false">78805 at https://www.programmez.com</guid>
    </item>

  </channel>
</rss>
