• 0 Posts
  • 207 Comments
Joined 1 year ago
cake
Cake day: July 1st, 2023

help-circle

  • I used to be an avid reader but as I got older and busier I just couldn’t find the time.

    Then when I did have time there was always distractions, or other things I could be doing.

    So now I read primarily via audiobooks through Libby and my library.

    I read 130 books or so last year that way.

    Mowing the yard? Audiobook.

    Long drive? Audiobook.

    Waiting at the doctors? Audiobook.

    Dishes? Audiobook.

    And then when I’m really invested I’ll relax by playing some mindless game while I listen. Think match 3 or bejeweled.

    Just engaging enough to keep me from getting bored while listening but not so much that I can’t do both.

    Balatro, BABA is you? Bad candidates for playing and listening.

    The last couple of years I burned through the wheel of time series, all of Brandon Sanderson’s books (except skyward which I haven’t gotten to), a lot of Adrian Tchaikovsky, and others.





  • I don’t write games but a lot of people that do often say something similar. Do play tests for the concept/mechanics.

    This way you don’t spend time/energy and resources on art and assets that won’t be used, etc.

    Similar to a minimal viable product in regular dev or, perhaps a better analogy, technical demos.

    You want to write a site or app that fetches API data for GPS, calendar and Weather and show them together? You don’t start with the UI. You start with:

    • Can I get the GPS coordinates
    • Can I call another API and get the weather for those coordinates?
    • Can I get the coordinates or other info for some future location?
    • Can I send that to get the weather?

    Once you know you can and that it “works” you build around it.

    So like you said. I have boxes, and this other box (or static PNG of a cat) moves around them and when I move this way it drops the box down on another box.

    Does that work? Does it feel “fun” to arrange them? No, it feels tedious or can’t get the collision right? Then let’s try a different angle or taking the part that did work and iterating on it.

    This also leaves you open to random bugs that end up being “fun” when you lean into them.

    Game Makers Toolkit has some good videos on his journey making “Mind over Magnet”. Here’s the playlist.

    https://youtube.com/playlist?list=PLc38fcMFcV_uH3OK4sTa4bf-UXGk2NW2n

    There’s also PirateSoftware whose entire stream is devoted to “go and make games”









  • I see a lot of good answers here but let’s try it from another angle.

    How do we get randomness from a function or formula?

    For starters let’s setup a few simple rules.

    Every time our random function is called we’ll

    • Take the last output from a variable we call LAST_RESULT
    • If there’s no value in LAST_RESULT we’ll assume the value is 1
    • We run a set of calculations storing the value in a variable we call X
    • We store the result of these calculations in LAST_RESULT
    • We return this new “random” number.

    So let’s call it.

    > Random()
    Since LAST_RESULT is undefined SET LAST_RESULT to the value of 1
    Set X to the result of this calculation 
       (LAST_RESULT+1) * 3
    

    X is now 6

    Set X to the result of this calculation
       (X + 7) / 2
    

    X is now 7

    Set X to the result of this calculation (rounding to the nearest whole number)
       X/LAST_RESULT
    

    X is now 7

    Set LAST_RESULT to the value of X
    

    LAST_RESULT is now 7

    Return the value of X as the result 
    

    Result is 7

    Ok. So let’s call it again

     > Random()
    Set X to the result of this calculation 
       (LAST_RESULT+1) * 3
    

    X is now 24

    Set X to the result of this calculation
       (X + 7) / 2
    

    X is now 16

    Set X to the result of this calculation (rounding to the nearest whole number)
       X/LAST_RESULT
    

    X is now 2

    Set LAST_RESULT to the value of X
    

    LAST_RESULT is now 2

    Return the value of X as the result
    

    Result is 2

    And if we call it again we get seemingly random results

    Random() Result is 4

    Random() Result is 3

    But the next time you run it you’ll get the same results in the same order. 7, then 2 then 4 then 3

    So what you need is something to “seed” the random number calculation.

    Something like

    SetRandomSeed Set LAST_RESULT to the current second of the day

    Then when you call Random after this it starts with that as the prior results and gives seemingly random results.

    Of course my calculations are rough and probably fail/repeat after so many calls but it gives you an idea of how this works.

    So the trick is to get noise for the seed. That could be the number of non leap seconds since 00:00:00 UTC on Thursday, 1 January 1970 (Unix epoch)

    Or the temperature reading of a CPU chip.

    Maybe it’s the ratio of red vs yellow from a camera feed looking at lava lamps.

    Or the current users average typing speed.

    An additional note. Many of those would not be “cryptographically” secure for encryption because they can easily be determined by a third party. We all experience the same “Unix epoch” within a few milliseconds if our system clocks are properly set for example. Or monitored from afar and reproduced (hacked webcam shows they had just typed the following letters in the previous 27 seconds that we know the “algorithm” uses, etc.




  • It’s not at all. I’m saying it was good then and it is now.

    It’s gotten heavier and more technical but that’s because as it goes on you learn and it gets deeper. And yet they still find a way to make it accessible even though they’re obviously still only scratching the surface.

    As a counter point via science is really good but tries to avoid the deep math as much as possible while explaining the concepts behind it. All the while it’s been pure science and less of the popular topic as a way to introduce the science.