Refactoring my Apple Game into MULTIPLE C Source Files

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

КОМЕНТАРІ • 11

  • @angelpena3297
    @angelpena3297 Рік тому +1

    great videos man!

  • @ELECTO796
    @ELECTO796 Місяць тому

    Good videos

  • @jlebrech
    @jlebrech Рік тому +1

    can you make videos on starting a project from scratch with cmake, say with external deps (enet + bullet) with ability to compile for android?

    • @andrewhamelcodes712
      @andrewhamelcodes712  Рік тому +1

      I don't think I'll bother with CMake, but I will say that enet will definitely come and Android is a maybe

    • @user-ek2jc1xf3y
      @user-ek2jc1xf3y 4 місяці тому

      @@andrewhamelcodes712 cmake is the best!! never turning back to other build systems

    • @InvisibleBoy-cb3dr
      @InvisibleBoy-cb3dr 2 місяці тому

      Come back bro pls ​@@andrewhamelcodes712

  • @ankurmallick7154
    @ankurmallick7154 Рік тому

    Hello, I cant see this in the original apple catcher. Did you update that?

    • @andrewhamelcodes712
      @andrewhamelcodes712  Рік тому

      I have no idea how I never noticed this. Just updated the repo now, thanks!

  • @arnoldbr8418
    @arnoldbr8418 Рік тому +1

    The makefile won't detect changes to header files: I have an issue where I define my #define's in a file, where I have put things like a ZOOM constant for the camera. But then when I modify the ZOOM and recompile, it seems like the new value won't be compiled. Are there additional steps, maybe something in the makefile, to update when a header file is changed?

    • @andrewhamelcodes712
      @andrewhamelcodes712  Рік тому +2

      The Makefile mentions a "clean" target, which will remove all the object files and force make to recompile everything. There is no other way to make header-only changes force source files to recompile. So generally when I make header only changes I clean and make again for safety.
      As a hack, if you know the header file is only in one or two source files, you can make a small change to those source files (like adding a comment or whitespace somewhere) and that should work too, but I highly recommend setting up the clean target instead.
      Unfortunately I forgot to cover it in this video, but there's a small tweak you'll need to make to the clean target for it to work. I simply replaced the windows "del" line with
      del $(OBJS) $(PROJECT_NAME)$(EXT)
      Which for me works a charm.

    • @arnoldbr8418
      @arnoldbr8418 Рік тому +1

      @@andrewhamelcodes712 Thank you very much for the answer! Your videos are very well edited, with a good pace and really helpful.