When Python is too Slow for my Steam Game

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

КОМЕНТАРІ • 187

  • @DaFluffyPotato
    @DaFluffyPotato  4 місяці тому +25

    Wishlist Yawnoc!
    store.steampowered.com/app/2824730/Yawnoc/
    I mentioned that Python can be easily used for nearly any 2D game but not 3D. For those who are curious, the reasoning against using it for 3D is actually unrelated to performance. Most 3D games nowadays are made with an engine + scripting combination. Since there aren't any major engines that primarily support Python as a scripting language, it's not particularly easy to make 3D games with Python. Of course it can still be done (see my last 2 videos). It's just not very easy to get into with the current tooling. Things may be completely different in the future.

    • @ultimateownsz
      @ultimateownsz 4 місяці тому +1

      Why don't you make games in godot? It has gdscript, very similair to python's syntax

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +5

      I prefer my tooling over engines typically (basically a custom engine specifically for the types of things I make). I've used Godot for VR projects and it's been good, but I get annoyed when there's something I could easily do on a low level, but the engine abstractions make it difficult.

    • @snbv5real
      @snbv5real 4 місяці тому

      It's less that there aren't any major engines that primarily support python as a scripting language, than it is that python doesn't make it easy to be used as a scripting language.

    • @morning_thor
      @morning_thor 4 місяці тому

      @@DaFluffyPotato Probably you already know this but since Godot is open-source, you could even make modifications at the engine.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +2

      Modifying the rendering pipeline in Godot is not a simple task.

  • @petthepotat
    @petthepotat 4 місяці тому +148

    In conclusion, GPU comes in clutch every time. Love the video Potato Master.

    • @nathanfranck5822
      @nathanfranck5822 4 місяці тому +7

      Sir got lucky with the algorithm, there's a tonne of important algos (like sorting) that are very parallelism resistant and don't run great on the GPU. Running an algorithm on compiled CPU code will always be faster in those cases

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +14

      That's what options 1 & 2 were for. In the case of sorting, Python's built in sorting function is already written in C.

    • @msqrt
      @msqrt 4 місяці тому +3

      @@nathanfranck5822 while I agree on the principle, sorting is not a great example. If your list is long enough, a GPU will sort it significantly faster.

  • @PascalCavalier0404
    @PascalCavalier0404 4 місяці тому +25

    By far the most talented PyGam dev out there. Ever considered writing a book on this? I would 100 buy it. Will be looking out for when the game is released man! you rock!

  • @sharpenednoodles
    @sharpenednoodles 4 місяці тому +13

    Never seen your channel or work before, but i immediately thought that a shader would be your solution! I'd never really considered python for game dev before. Yawnoc looks very fun - wish listed!

  • @Acheronthewolf
    @Acheronthewolf 4 місяці тому +2

    Potato's problem solving skills are goals. The things I've learned with your videos have applied to more than just learning to make games, I've applied a lot of concepts I've come to understand thanks to you in a lot of different ways, and even made some discoveries of my own in regards to how to attack unique issues I had. Thank you for your content, and I'm looking forward to Yawnoc!

  • @electrictrojan6719
    @electrictrojan6719 4 місяці тому +45

    Shaders exist at the meeting place between mathematics, computing and art. They're really nice.

    • @undeadpresident
      @undeadpresident 4 місяці тому +5

      Except for dealing with the all the code split up in multiple places just to get one thing done and all the obscure crap that's done under the hood that you have to learn about and the documentation that often leaves you more confused after reading it than before.

  • @madbanana22
    @madbanana22 4 місяці тому +33

    TL;DR: if your python code is too slow, use C

    • @igorthelight
      @igorthelight 4 місяці тому +2

      There are so many ways to improve performance beside "just use C" ;-)
      This video is just about that.

    • @undeadpresident
      @undeadpresident 4 місяці тому +6

      @@igorthelight C is pretty nice if you are doing things that require accessing a lot of data, which Python is very poor at. C is a simple, clear, and direct language. GPU programming is a lot more complicated even to do simple things. Can get crazy performance though.

    • @igorthelight
      @igorthelight 4 місяці тому +1

      @@undeadpresident Agree

    • @Khallduon
      @Khallduon 2 місяці тому

      Use chat gpt

    • @igorthelight
      @igorthelight 2 місяці тому

      @@Khallduon Use ChatGPT to learn new concepts, not to just write for you.
      Also - it still writes buggy code so you should be a good programmer to use what it writes ;-)

  • @kklol07
    @kklol07 4 місяці тому +1

    this is such a dope coincidence, i was talking to my friend about inefficiency of the code in my cellular automaton code and you uploaded it today!!!!!!!!!!

  • @6IGNITION9
    @6IGNITION9 4 місяці тому +12

    >a gun that builds walls
    🦅

  • @RictorScale
    @RictorScale 4 місяці тому +5

    many technical limitations have led to incredible creative choices in gamings history :D

  • @ronitsingh9955
    @ronitsingh9955 4 місяці тому +1

    Every new video of yours is like a fiery new inspiration. Even though didn't understand most of it..
    Keep going!

  • @BarneyCodes
    @BarneyCodes 4 місяці тому +3

    Great video, I love shaders and this is a perfect application for them! The water colour effect that you showed off looks awesome by the way, I might have to try recreating it at some point!

  • @helioshyperion
    @helioshyperion 4 місяці тому +12

    Hey! Nice stuff!
    It was cool to see my Smoothlife(L) shadertoy shader in the thumbnail and the video :)
    Would appreciate if you could put some links in the description to the referenced shadertoy shader(s). Thanks!

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +12

      Oops, sorry! I added them. Normally I do a zoom-out or something on my sources (note the titles/channels on the YT videos and the zoom-out on the Lenia shadertoy). I forgot that I never did that on your Smoothlife(L) shader.

  • @Ranakade
    @Ranakade 3 місяці тому +1

    Python's data science and math capabilities is what keeps me coming back to Pygame.

  • @KucheKlizma
    @KucheKlizma 4 місяці тому

    Thanks, your content is quite inspiring.

  • @kklol07
    @kklol07 4 місяці тому +1

    oh okay, thanks for this, perfect timing, i was working on cellular automaton! yesterday!!!!!

  • @djlclopez128
    @djlclopez128 4 місяці тому +2

    Your game featured here reminds me of some of the art and design in Cave Story. Love the channel, thank you!

  • @codewithram5303
    @codewithram5303 4 місяці тому

    Your games are always great by conceptually and graphically

  • @iamtimsson
    @iamtimsson 4 місяці тому

    kick butt keep it up you got this all ready

  • @RenderingUser
    @RenderingUser 4 місяці тому +16

    Bro casually uses the coolest sht ive ever seen in a video game as Broll (1:38)

  • @ciCCapROSTi
    @ciCCapROSTi 4 місяці тому +3

    Hah, shaders. Damn, I'm gonna have to learn those eventually, inevitably.

  • @Skeffles
    @Skeffles 4 місяці тому

    Fantastic to see you consider the solutions to get the game ready. I wonder if Mojo can (or will in the near future) help with this kind of performance 🤔
    Either way, good luck getting the game to release!

  • @theemeraldbee
    @theemeraldbee 4 місяці тому +7

    It would be incredibly interesting if you made a video about how to program shader code. It's such an important skill, but so incredibly hard to get into and begin your journey. There are so many tutorials on how to do exactly what you want, but what about making a tutorial for figuring it out yourself?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +5

      I'm still mostly using shaders for simple things, so I don't think I'm ready to make that type of video yet.

  • @funkydiddykong
    @funkydiddykong 4 місяці тому +10

    Eve Online actually uses stackless python for pretty much all ui and logic in the game with native interfaces to the rendering engine.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +2

      I haven't checked, but wasn't stackless Python just used for the servers?

  • @papakamirneron2514
    @papakamirneron2514 4 місяці тому +1

    Honestly I feel like once you have your own standard “wrapper” around pygame it must be quite a fun time creating a game. I’ve moved away from game dev personally because I despise rendering with my entire soul but this looks awesome!

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      Graphics programming is probably my favorite part of gamedev.

    • @itsmenatika
      @itsmenatika 4 місяці тому

      Ya the beginning is the weirdest one, you mostly don't see anything important or weird simple sprites. The more complex your "wrapper", the more everything becomes easier. The most hard part is when you need optimization or just change something and a lot of things is based around that in your game, that's where it becomes harder the more complex your wrapper is

    • @mint4up2zio3
      @mint4up2zio3 4 місяці тому

      Oh it is! Spend a lot of time figuring out how to render what you want and you never have to worry about it again. Your possibilities expand and you can realise your game designs faster. It’s a nice bonus that Python is relatively easy to pick up.

    • @itsmenatika
      @itsmenatika 4 місяці тому

      @@mint4up2zio3 ya and even rewrittng something that you've done earlier is easier. I had a huge problems with collisions in the past but today I recreated it faster and better

  • @DeusEx3
    @DeusEx3 4 місяці тому

    That's a shader. Dude, blew my mind.

  • @qwertyman123
    @qwertyman123 4 місяці тому +4

    very nice

  • @TommyLikeTom
    @TommyLikeTom 4 місяці тому +7

    Clever coding can really save your game. I implemented my own A star path-finding/search algorithm in Godot that runs each square over multiple frames, allowing hundreds of pawns to path-find at once. Distributing processes over multiple frames in an amazing trick.
    Maybe I am just wishful but I believe that there will be a system that compiles python as C, and that it will be open source and built into godot. I know such systems exist already, but right now I think it's most productive to build fast in python.
    I also State-Machine absolutely everything, which drastically improves performance.

    • @BitTheByte
      @BitTheByte 4 місяці тому +1

      Cross compiling code often kills the performance benefits offered by the languages. You are better off learning c++ and making modules in godot

    • @Neuroszima
      @Neuroszima 4 місяці тому

      mojo

  • @RugbugRedfern
    @RugbugRedfern 4 місяці тому +2

    This is super cool! Is there a performance hit from parsing the completed texture on the CPU for collision/other data required for the game?
    Also, I love that we both ended up using images to load levels for the competition, MSPaint is a slept on level editor :P

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +2

      As long as the texture is small, it's pretty fast (not profiled, but should easily be

  • @uyiomoragbon5728
    @uyiomoragbon5728 4 місяці тому +1

    That's when C++ comes in 💪

  • @JoeCavZero
    @JoeCavZero 4 місяці тому +6

    Very cool
    have you tried go with raylib ?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +4

      I tried it years ago, but there were some bugs in the Python wrapper at the time. I haven't had a reason to use anything other than Pygame and ModernGL when it comes to Python-based games.

  • @maverickstout25
    @maverickstout25 4 місяці тому +1

    When John carmack was bottle necked with C on doom he just read a white paper and implemented a scientific approach to graphics rendering. So no big deal, all you have to do is ground breaking code! ;p

  • @fueledbycoffee583
    @fueledbycoffee583 4 місяці тому +7

    One question. i may have missed it but what about the performance penalty of getting the x,y information of each cell back and forward from the shader for collision detection and everything else?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +6

      I actually only have to pass the texture back and forth once per automata step, which only occurs every now and then. In terms of a single step, the pass is just a small texture in both directions, which is super fast. I haven't profiled it, but it doesn't really affect performance (so it's probably

    • @fueledbycoffee583
      @fueledbycoffee583 4 місяці тому +1

      @@DaFluffyPotato thats amazing!

    • @leighrobinson
      @leighrobinson 4 місяці тому

      @@DaFluffyPotato I take it you then have to parse that texture back into the tilemap/collision acceleration structures? Or is the map size such that brute force still is ok with python?

  • @JH-pe3ro
    @JH-pe3ro 4 місяці тому +1

    While I've travelled the Pygame path in an earlier life, I distrust extending my dependency chain any more than necessary these days, and framework-based development these days tends to be an update treadmill where there are plenty of underlying dependencies that make breaking changes - so the dev environment is richly structured, complex, and makes it hard to bring up the project again after time away from it or changing machines.
    As a result of this I've made a hard turn towards coding in Forth for actual retro machines. It's not bad - it's also interpreted, and you can do live editing with it. It can be pretty portable since the core is small and the only major assumptions are with machine word size and memory layout. Supremely self-contained. It does mean substantially more DIY to get through the early stages since most Forth systems have very little built in, but you can get it exactly how you want it. Wouldn't go this route if I were trying for this kind of GPU-accelerated 2D, though - it'd be easier for me to start in Godot and hammer away at the extension system as necessary to make the critical path go fast. The problem is mostly that once you try to make a game in the modern fashion, the expected featureset explodes, so my take on that is to go ahead and swallow one large dependency that has a lot of momentum around it.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      Over the 11 years that I've used Pygame, it's been pretty stable as a library with few dependencies (since it wraps SDL). I've definitely run into some of those issues with ModernGL since it's newer and still maturing though. My game Hue Flowing can be a bit of a challenge to get running from source as a result.

  • @evilkittyofdoom195
    @evilkittyofdoom195 4 місяці тому +1

    Nice !

  • @bubblyphysics
    @bubblyphysics 4 місяці тому

    I just noticed there was a new video release! You added a weapon that creates walls! (Similar to my old idea)

  • @gsestream
    @gsestream 4 місяці тому +4

    compile to faster native code, or just pre-push graphics and other logic to gpu etc.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +4

      that's the video

    • @gsestream
      @gsestream 4 місяці тому +1

      @@DaFluffyPotato great

    • @Ali-Britco
      @Ali-Britco 4 місяці тому +1

      This is the best comment section I've read in a while.

  • @EndlessEnergy
    @EndlessEnergy 4 місяці тому +4

    This disproves the myth of "Python is easy", it's easy in some ways and very cringe/difficult in others (C++ guy, no bias). Nice vid, keep it up!

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +2

      Python is easy. It just has a very high skill ceiling.

  • @hillybankok
    @hillybankok 4 місяці тому +1

    Hi gary!
    Nice to meet you!

  • @Volt-Eye.
    @Volt-Eye. 4 місяці тому +3

    Understood 0️⃣
    Enjoyed 1️⃣
    😂😂😂

  • @ChickenPiez0
    @ChickenPiez0 4 місяці тому

    I love your pixel art style any tips? This would help alot.

  • @tucan7112
    @tucan7112 4 місяці тому

    neural cellural automata might be cool as well like neural worms

  • @GamerDevIND
    @GamerDevIND 4 місяці тому +1

    2:55 neural network confirmed

  • @ryuukkkoko874
    @ryuukkkoko874 2 місяці тому

    latest version of python has a JIT, it's not enabled by default, give it a try

  • @PhuocThanginh-oo8jj
    @PhuocThanginh-oo8jj 4 місяці тому

    would you learn ursina as a future tool? Cuz ur game is cool but i am using ursina so I cant actually make it.

  • @dylanthecool101
    @dylanthecool101 4 місяці тому

    great game can't wait and if you don't mind me asking what price do you expect the game to be since something this good deserves to cost money I would like to know how much so I can save up for it because it seems like a game I would enjoy ok I'm going to end this paragraph now

  • @rrrrmrmr
    @rrrrmrmr 3 місяці тому

    Woah what's that watercolor game? It looks insane

  • @razshneider2375
    @razshneider2375 4 місяці тому

    I was surprised you didnt mention Cython
    I use it in my job and it works great
    You write some python with extra syntax and compile it to c and then binary
    Just running plain code throught the cython compiler shouls boost your performance

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      I didn't mention it because I didn't check to see if it would cause issues with Pygame or other libraries used in Python gamedev. It's likely a valid option though.

  • @SeanStClair-cr9jl
    @SeanStClair-cr9jl 4 місяці тому

    I'm curious, super naive suggestion but would you have any interest in just compiling the python code? I believe there are some OOTB solutions for that. I'm in a compiler construction class rn and the performance increase has been rly cool to see
    Edit: Oop nvm u literally just mentioned compilation haha

  • @wicked_sash
    @wicked_sash 4 місяці тому

    Cant you also add another cpu thread just for the cellular automata

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      That doesn't provide enough of a performance boost and it also makes the code significantly more complicated.

  • @BurnerWah
    @BurnerWah 4 місяці тому +6

    Thank you Andrew Cunningham for bringing me here, I enjoyed this

    • @Akrob55555
      @Akrob55555 4 місяці тому

      Where did he post about it?

    • @matiasgarciacasas558
      @matiasgarciacasas558 4 місяці тому

      ​@@Akrob55555as far as I know the only connection between them is that he recently made a video about a cancelled blackthorneprod dev challenge (devs make a game without communicating), and some people speculated that the previous dev to him was DaFluffyPotato based on the artstyle.

  • @erc0re526
    @erc0re526 4 місяці тому

    Nice! I expected to find Numba JIT or a similar solution (somehow knew rewriting to a lower level language wasn't your solution) and I'm surprised shaders do the trick! You said in other comments you work as C++ dev, how does it "affect"/help your views as a python programmer? Did you choose python for its development speed?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      Yes, I use Python for development speed. My tooling is also all in Python and Pygame, so switching to anything else would set me back a fair bit.
      I learned most lower level topics while using Python before really getting into C++, so nearly everything I do in C++ except syntax and the build process is already well within my knowledge. For reference, my job is embedded SWE for rocket hardware.

    • @erc0re526
      @erc0re526 4 місяці тому

      @@DaFluffyPotato This sounds like very strict C++ indeed... Coding in python must be a breeze when you get home!

  • @skueuemusic2670
    @skueuemusic2670 4 місяці тому

    yellow bullets on yellow background seems a little hard to read, making the bullets a much darker, or made from a more saturated color, would make the combat MUCH more readable

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      I plan on adding accessibility settings to recolor certain things for visibility. I like the way the game looks at the moment and I don't really experience issues when I play, but the features will be useful for anyone who needs more clarity.

  • @Freddy78909
    @Freddy78909 4 місяці тому

    To be fair to Python, doing 4 million checks per frame is a lot for any game

  • @MathGoOli
    @MathGoOli 4 місяці тому

    1:37 I never managed to compile pygame. Looks as hard as write code in C

  • @onnot701
    @onnot701 2 місяці тому

    I wonder about python 3.13 and GIL etc speed

  • @undeadpresident
    @undeadpresident 4 місяці тому

    I took the route thus far of writing functions in C and calling them using ctypes. Quick and easy and useful when you have a lot of data to iterate through since Python data accesses are so slow. Using the GPU is taking it to the next level though.
    I've been learning OpenGl and I fucking hate working with it. Just the whole way it works rubs me wrong, but I realize it has good functionality so I'm doing it anyway. Maybe someday I won't hate it so much.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      If you're using PyOpenGL or a traditional C/C++ binding, I recommend ModernGL. It's an object-oriented interface for ModernGL instead of a state machine.

    • @undeadpresident
      @undeadpresident 4 місяці тому

      @@DaFluffyPotato yeah that looks like the way to go using Python.
      I've been using OpenGL in straight C though.
      The way I've avoided most of the state-machine crap is using the Direct State Access (DSA) functions.
      I still encounter a lot of technical difficulties though.....it could use better documentation.

  • @Harald723
    @Harald723 4 місяці тому

    You chould try Go for your next project, its simple and performant

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      I was considering trying Go next year, but not for gamedev.

    • @Harald723
      @Harald723 4 місяці тому

      @@DaFluffyPotato I use it for games and I like it, but we all are diffrent

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

    cool beens

  • @HairyPixels
    @HairyPixels 4 місяці тому +2

    How is it possible that in 2024 there's is a python compiler which produces machine code? that has to exist right?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +3

      2:14 I mentioned that PyPy does this in the video.

    • @nathanfranck5822
      @nathanfranck5822 4 місяці тому

      Mojo comes to mind

    • @HairyPixels
      @HairyPixels 4 місяці тому

      @@DaFluffyPotato never heard of it before, why aren't you using PyPy then?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      Mainly because I just never started. Also I don't have much of a need for it and the support for some modules is a bit finicky. It may have more portability issues as well.
      For Pygame specifically, the heavy lifting is already done in C, so it doesn't help in most cases (although the case in this video would benefit from it).

  • @healky
    @healky 4 місяці тому +1

    Pog Game

  • @Neuroszima
    @Neuroszima 4 місяці тому

    I hate numba, also Mojo exists now. I hope it will enable better execution times with python like vocabulary and make it possible to get optimizations for gaming as well. So far, it mostly is DS language

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

    I wish I could try playing it on a mac

  • @nevokrien95
    @nevokrien95 4 місяці тому

    If you need custom C code for this or Cuda/wgpu I could do it

  • @bubblyphysics
    @bubblyphysics 4 місяці тому

    Did you see my old idea? I'm curious.

  • @SolTheIdiot
    @SolTheIdiot 4 місяці тому

    One question, how does your gun aim, is it based on the cursor? If so, how does it get an angle to rotate at? Sorry if this seems invasive or annoying.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      Yes, it uses the cursor. The cursor just has to get converted to world coordinates and you can take the difference of that position with the player position. Taking the arctangent of the difference gives you the angle.

    • @SolTheIdiot
      @SolTheIdiot 4 місяці тому

      @@DaFluffyPotato cool, thanks!

  • @sayorancode
    @sayorancode 4 місяці тому

    wait how do you make a map editor ? , also how are maps stored (i store all my maps as images rn and need help)

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      My 6 hour Pygame tutorial has a section in it where I make a level editor if you're interested. Most people use preexisting editors such as Tiled though.

  • @spyro_dr
    @spyro_dr 4 місяці тому

    Its simpler to optimize the code.(I programma rpg maker like game in python and pygame and rewriten the code 3 times because itwas to slow.)

  • @lubba64
    @lubba64 4 місяці тому

    Rust is easy to use with python too as another idea

  • @pik910
    @pik910 4 місяці тому

    Have a look at Odin. You can build libraries and use them in python in many languages easier than C. It is an easy process, just ask your friendly llm. Odin has in-built SIMD support and is easy to write, might me a good fit.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      Interesting. It could be useful in some cases where a lot of performant modules are needed, but there is a tradeoff in the build process (most people can easily build C, but haven't used Odin). That wouldn't be an issue for most people, but a lot of people like to run the source for my projects.

  • @alexbork4250
    @alexbork4250 4 місяці тому

    > Python
    > game
    Bro literally used potato instead of meat for steak

  • @dlld6944
    @dlld6944 4 місяці тому

    Is it possible to make an income as a single game dev?

    • @igorthelight
      @igorthelight 4 місяці тому

      Yep!
      Google "games created by a single developer".
      But that's not easy.

    • @dlld6944
      @dlld6944 4 місяці тому

      @@igorthelight It seems to be the exception. Are you able to finance yourself?

    • @igorthelight
      @igorthelight 4 місяці тому

      @@dlld6944 Well, just watch some interviews with those developers. They do struggle. I made a few non-commercial small games, so my story doesn't matter 😅

  • @distantforest2481
    @distantforest2481 4 місяці тому +1

    Great stuff. Too many people are quick to jump ship to another language when they run into pythons performance issues. The original point of python is to have quick dev times for the higher level stuff, and if you need to do some performance heavy stuff, you can create small 'addon' functions in like in C, or in this case shaders. That way you get the best of both worlds; the speedy dev times of python, and the performance of C.

  • @davidcooke5594
    @davidcooke5594 3 місяці тому

    I think this is genius and I love your vids, but a 14th nov release date! Stresses me out just thinking about it….just put 2025 and enjoy playing about with it!

  • @TheSchoolofJ
    @TheSchoolofJ 4 місяці тому +1

    Have you thought about releasing a performant (but minimal) version of the game, and then spend more time dealing with getting the more complex aspects to run smoothly?
    I feel like it would be good to start generating curiousity about the game, but moreso because sensitive aspects such as game speed and frame rate need a lot of care, especially to make sure you don't shoot yourself in the foot in the future. Especially since some of the potential fixes might only work in specific scenarios 😅.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +2

      Yawnoc has never actually had performance issues since I knew that smooth life would lag before implementing it (although I will admit I took advantage of knowing about that outcome for this video idea). It's perfectly fine with the shader implementation from this video. Runs at ~400fps.

    • @nathanfranck5822
      @nathanfranck5822 4 місяці тому

      Shaders sometimes work different on Intel, Nvidea or AMD (or Qualcomm) hardware, so pegging them to gameplay can get tricky! I remember some disappointments seeing my game tested on other people's computers...

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      I have multiple PCs and laptops (Nvidia, AMD, and Intel graphics) to test with. Plus I'll have a demo to get initial testing with. Generally older versions of OpenGL should be pretty reliable. I've been using 3.3.

  • @SkyFly19853
    @SkyFly19853 4 місяці тому

    How about IronPython ?

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      Haven't looked into it

    • @SkyFly19853
      @SkyFly19853 4 місяці тому

      @@DaFluffyPotato
      I see.
      because I am developing a video game in IronPython.

  • @lbp_chessguy5640
    @lbp_chessguy5640 4 місяці тому

    I love Python, but I think it's time for me to transition to C++.

  • @tanjibulanimations5653
    @tanjibulanimations5653 4 місяці тому

    hey bro make a game using pyglet

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      I'd rather use ModernGL (see my last 2 videos).

  • @童貞翻訳サービス
    @童貞翻訳サービス 4 місяці тому +3

    bro will do anything but write c++ code lul😊

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +9

      My job is C++

    • @mgord9518
      @mgord9518 4 місяці тому

      Probably because C++ is horrid to program in

  • @фиданимамов
    @фиданимамов Місяць тому

    1) did you try use __slots__ ?
    2) did you try use pypy?
    3) did you try use cython with new syntax?

  • @dottedboxguy
    @dottedboxguy 4 місяці тому +8

    being bottlenecked by your language sounds horrid, i'll pass on python for anything else than prototyping (although i'm biased because i'm a little engine nerd, and am more interested by tech than games, i imagine the overhead you get from usin python correctly isn't all that far from using a general purpose engine, but i'm still very doubtful)

    • @annyman4743
      @annyman4743 4 місяці тому +1

      fax, python is made for scientific purposes. we should use languages actually made for software/game dev the way it's intended.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +3

      You'll get bottlenecked in all sorts of places depending on your tooling (including your needs to update things if you roll it yourself) regardless of language, library, or engine choice. In the case of C++ and OpenGL, you'll be bottlenecked on scalability for many things until you write systems using the proper data structures. I will agree that the bottlenecks in that case are the most straightforward. On the other end with engines, there's a mess of random bottlenecks (that you may or may not have control over) depending on the engine.
      I benefit from Python due to development speed for game logic on top of my prebuilt tooling. My approach has been competitively proven in game jams, but it's definitely not for everyone.

    • @dottedboxguy
      @dottedboxguy 4 місяці тому

      @@DaFluffyPotato i would think maintaining a python codebase would be really hard, because even if it's easy to do stuff, it's also really easy to get lost and have all sorts of weird stuff happen because it's too lenient on what you can do, i would believe structuring a python codebase is as important as in any other language

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому

      For people new to Python or working in teams I agree. However, I rarely lose any time to Python-specific bugs or getting lost. Additionally, since I started with Python, I abuse the type looseness to quickly write some things that would have to be written with more steps due to type management in languages like C++.

    • @dottedboxguy
      @dottedboxguy 4 місяці тому

      @@DaFluffyPotato i don't personally think it's worth spending time to be really good at python to have kind of acceptable perfs when you could be learning something else that in the end will lead to better results. byeah as you said python is really good for throwing things together quickly, so ig in the case of gamejams it must work great, i couldn't imagine what it'd take to do a gamejam in like C or C++

  • @umcanalsemvidanoyoutube8840
    @umcanalsemvidanoyoutube8840 4 місяці тому

    Lua > Python
    Love2D > PyGame

  • @valentinrafael9201
    @valentinrafael9201 18 годин тому

    Need python optimized? Learn Cython

  • @vaporvee
    @vaporvee 4 місяці тому

    Or just use godot for easy syntax

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      I prefer my tooling when possible. I've used Godot for VR projects though.

  • @Zeropointill
    @Zeropointill 4 місяці тому +3

    Why don't you just change language? Says here you have a computer science degree, why limit yourself to poor performance at the cost of simplicity? There's no way you couldn't manage with a low level language, isn't that like literally your bread and butter? I'm a fucking dumbass and I still won't touch python because simplicity isn't what I'm looking for, nevermind the crap performance although that's a huge part of it too.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +8

      As I mentioned at the start of the video, I can make games quicker with Python. I made an example out of a potential problem to demonstrate how you handle these types of issues. I wrote the shader-based system in a couple hours, so it wasn't ever a roadblock since I've run into these situations before. C++ wouldn't have saved me time on this specific issue (and I actually use C++ for work) and it certainly would've wasted exorbitant amounts of time in the scope of the entire game.

    • @joaquinginestet4813
      @joaquinginestet4813 4 місяці тому +1

      ​@@DaFluffyPotato So a more complex language is better for making a game, but since you dont do this as your main work and also dont have infinite time and resources you choose python, that isn't the best but is good for making the thing fast?

    • @umcanalsemvidanoyoutube8840
      @umcanalsemvidanoyoutube8840 4 місяці тому

      ​@@DaFluffyPotatouse Lua ❤

  • @andreasmpintas9073
    @andreasmpintas9073 4 місяці тому

    Have you ever considered using AI art? It takes time editing the art but the result would be impressive, graphics wise.

  • @AnthonyCook78
    @AnthonyCook78 4 місяці тому

    I blame your optimisation

  • @latenmuniz773
    @latenmuniz773 4 місяці тому +1

    First comment!

  • @bluzenkk
    @bluzenkk 4 місяці тому

    or use RUST~~~

  • @chesterhackenbush
    @chesterhackenbush 4 місяці тому

    Python is SLOOOOOOW. However AI compilers that can convert your barely adequate Python code into C and Raylib are just around the corner... so rejoice and write bouncy plasmas and 3d cubes from the 1980's and know that nobody really cares.

  • @kyleabent
    @kyleabent 4 місяці тому

    Not very helpful. You didn't say anything new this video.

  • @koteelok2014
    @koteelok2014 4 місяці тому

    Using python just to use python. 0 benefit for your games.

    • @DaFluffyPotato
      @DaFluffyPotato  4 місяці тому +1

      You ignored the first 30s of the video. It dramatically improves the development speed. I compete with people who are using other languages and engines in time restricted game jams all the time and consistently perform well. Yawnoc originated in a competition where it won against 5 other developers who were using engines. I also recently won 2 Ludum Dare medals for my Python games.
      99% of game logic is not actually very processing intensive. The rendering pipelines can be, but that's mostly 3D games.

    • @annyman4743
      @annyman4743 4 місяці тому

      just use a statically typed and compiled language bro