Coding Pong in C from Scratch | Completing Player Movements | Ep. 2

Поділитися
Вставка
  • Опубліковано 21 лис 2024

КОМЕНТАРІ • 10

  • @insadeyt
    @insadeyt 11 днів тому +3

    I usually don't comment but your videos are helping me a lot like the amount of knowledge I just gained in these videos are crazy. Thank you so much 😊. I am subbed ♥️.

    • @HirschDaniel
      @HirschDaniel  11 днів тому

      Thanks a lot! That's good motivation for the next videos!

  • @ElaineParra
    @ElaineParra 11 днів тому

    Right on time right on path! thanks

  • @aventyrskonsulterna
    @aventyrskonsulterna 8 днів тому

    Another great video! Has not seen ep3 yet! BUT! I ChatGPT:ed (is that cheating?) the conflicting paddle-movement and got this : (then it works for multiple players) Delete this if cheating. :)
    const Uint8 *keyState = SDL_GetKeyboardState(NULL);
    if (keyState[SDL_SCANCODE_DOWN]) {
    move_player( surface, &pl1, 1 );
    }

    • @HirschDaniel
      @HirschDaniel  7 днів тому +1

      Nah, it's not cheating! Any solution is welcome. It doesn't matter where it's from. Did you test it and is it working? If yes, awesome!

    • @aventyrskonsulterna
      @aventyrskonsulterna 7 днів тому

      @@HirschDaniel yep it's working! ;)

    • @HirschDaniel
      @HirschDaniel  7 днів тому +1

      awesome!

  • @povijarrro
    @povijarrro 11 днів тому

    Hello. I think (May be wrong) it is dependent on keyboard (hw one) how and how many keys it sends.

    • @HirschDaniel
      @HirschDaniel  11 днів тому

      Yes that is probably the case, thanks a lot!

    • @Nico-mi2pr
      @Nico-mi2pr 9 днів тому

      Could it also be the key repeat rate and delay configured in the OS?
      I’m also thinking about something involving the WSL, but I’m not entirely sure about this