Off Topic
    • Categories
    • Tags
    • Users
    • Groups
    • Amazon
    • OT Fundraiser
    • Register
    • Login

    The OFFICIAL programming thread

    Tech
    22
    1.4k
    10.4k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • KilemallK
      Kilemall Careful, railroad agent @A Former User
      last edited by

      @hog said in The OFFICIAL programming thread:

      I feel like I’m asking for help with my homework here but, anyway, if anyone wants to venture an opinion it will be welcome:

      I’ve got this code snippet in glsl that takes a vector of two values (e.g. an x and y coordinate pair) and returns a pseudo random number between 0.0 and 1.0.

      float rand(vec2 co){
          return fract(sin(dot(co, vec2(12.9898, 78.233))) * 43758.5453);
      }
      

      The problem is that I need to pull 4 random values for the same x, y coordinate. I was going to make the second and subsequent call pass back the previous result as both the x,y and values but then any x,y pair that shares the same first result will also have the same subsequent values. I’d like more randomness or differentiation.

      Edit: actually having written it out, I’ve got an idea. For each additional value I need, I’ll multiply the original vector by the previous random value that’s produced and call it with that.

      That’s a function built into UWP world generation in Traveller.

      Roll world size 2d6-2.
      Roll atmosphere 2d6-7+size.
      Roll hydrographics 2d6-7+size- if size=0 then hydro=0, if atmo 01,1 or A+ then -4.

      Roll population 2d6-2.
      Roll government 2d6-7+pop
      Roll law level 2d6-7+gov

      So the bigger the world the thicker the atmosphere and the more water it can retain (gravity).

      The more pop the more the simpler government structures won’t do, and the more restrictive governments cause higher law levels- more things are regulated/illegal, more police hassle, more bribery/corruption.

      https://i.imgur.com/hX2CMMZ.jpg

      Never go full Lithu-
      Twain

      No editing is gonna save you now-
      Wingmann

      http://s3.amazonaws.com/rrpa_photos/72217/DSC_2528.JPG

      http://s3.amazonaws.com/rrpa_photos/20416/PTOB 101_resize.jpg

      1 Reply Last reply Reply Quote 0
      • ?
        A Former User
        last edited by A Former User

        - YouTube

        I couldn’t get a simple sword slash animation looking even passable so I got my wife to film me wielding a broom and then slowed it down and freeze framed it to see where the arms and legs should be.

        1 Reply Last reply Reply Quote 4
        • tiggerT
          tigger
          last edited by

          Neat

          1 Reply Last reply Reply Quote 0
          • tiggerT
            tigger
            last edited by

            You need a Reddit channel or something.

            ? 1 Reply Last reply Reply Quote 0
            • ?
              A Former User @tigger
              last edited by A Former User

              @tigger I don’t know if I’m right person for that kind of thing. Id have to start grooming my eyebrows regularly for one thing.

              1 Reply Last reply Reply Quote 1
              • JerrayeJ
                Jerraye
                last edited by

                That video really speaks to me.


                Potat

                1 Reply Last reply Reply Quote 1
                • ?
                  A Former User
                  last edited by A Former User

                  Maybe we need a game dev thread. Anyway, I’m pleased the below was relatively easy to do.

                  - YouTube

                  The character and sword are on separate spritesheets so I can swap out the sword for different weapons. But you can see that the sword doesn’t render where the character would obscure it. In Blender you can use a “holdout” setting on a collection to get that effect easily.

                  Edit: actually that video does a crap job of highlighting what I mean. In the below spritesheet you can see that in one frame (maybe when the character is facing north and is resting) the only thing you can see of the sword is just the highlighted part because the character’s body obscures the rest:

                  ee3a24cc-f62a-4f6e-bab0-9a9b3d7a6915-image.png

                  1 Reply Last reply Reply Quote 3
                  • Gators1G
                    Gators1
                    last edited by

                    @Jerraye @Hog Make sure you get your mocap right…

                    NVIDIA’s New AI: Journey Into Virtual Reality!

                    alt text

                    ? 1 Reply Last reply Reply Quote 3
                    • ?
                      A Former User @Gators1
                      last edited by

                      @gators1 That’s impressive. It’s just amazing what Software Engineers are doing these days.

                      1 Reply Last reply Reply Quote 3
                      • ?
                        A Former User
                        last edited by

                        For the mother fucking loss:

                        Work added my personal Github account to their private org and Github subscribed me to every bloody repo they have.

                        You automatically watched these repositories because you’ve been given access to them

                        I’ve got to click 69 individual links and manually unsubscribe from each one.

                        fe7762e8-87ae-4a9e-8f56-b3b84e4d26a1-image.png

                        rote7R 1 Reply Last reply Reply Quote 1
                        • Gators1G
                          Gators1
                          last edited by

                          69 huh? Giggity!

                          alt text

                          1 Reply Last reply Reply Quote 0
                          • rote7R
                            rote7 @A Former User
                            last edited by

                            @hog said in The OFFICIAL programming thread:

                            For the mother fucking loss:

                            Work added my personal Github account to their private org and Github subscribed me to every bloody repo they have.

                            You automatically watched these repositories because you’ve been given access to them

                            I’ve got to click 69 individual links and manually unsubscribe from each one.

                            fe7762e8-87ae-4a9e-8f56-b3b84e4d26a1-image.png

                            Maybe use wget, some bash scripting and curl to do the job?

                            fffg

                            ? 1 Reply Last reply Reply Quote 0
                            • ?
                              A Former User @rote7
                              last edited by A Former User

                              @rote7 said in The OFFICIAL programming thread:

                              Maybe use wget, some bash scripting and curl to do the job?

                              I think there’s an API where you can probably do it even easier. It’s probably a toss up on which is quicker to do - manual or via code - if you factor in having to learn how to call and use the API.

                              In any case, it’s an asinine action on Github’s part. It would much be less of a nuisance if they just sold my email address to viagra spammers since Gmail would at least remove them automatically from my inbox.

                              1 Reply Last reply Reply Quote 1
                              • Gators1G
                                Gators1
                                last edited by

                                You have erectile dysfunction? Damn that sucks.

                                alt text

                                1 Reply Last reply Reply Quote 1
                                • ?
                                  A Former User
                                  last edited by

                                  b77a7380-4cb3-4487-a493-0e838deb2ebd-image.png

                                  Given his user name, I really want to reply:

                                  Now listen cunt, I don’t know how you think you can see my screen but it definitely isn’t visible.

                                  ? 1 Reply Last reply Reply Quote 4
                                  • PakoonP
                                    Pakoon
                                    last edited by

                                    Chris Kubecka 🇵🇷🇨🇿🇳🇱 🇺🇦 secevangelism bsky on Twitter

                                    ♙♙♙ Michael Waltz added you to the group.

                                    1 Reply Last reply Reply Quote 1
                                    • ?
                                      A Former User @A Former User
                                      last edited by

                                      @hog said in The OFFICIAL programming thread:

                                      b77a7380-4cb3-4487-a493-0e838deb2ebd-image.png

                                      Given his user name, I really want to reply:

                                      Now listen cunt, I don’t know how you think you can see my screen but it definitely isn’t visible.

                                      Well that was a weird turn around.

                                      I was frustrated with the low value response (“hur, I don’t even use your operating system but I can see the caret on my screen so you must be able to, dur”. And I didn’t have much hope of the issue being seen by anyone who knew anything since there are 5K open issues on their github. I’ve got a day job now and I have enough frustration there so I wrote a polite, if slightly pissy reply, and closed the issue. About an hour later the original author of Godot reopened my issue himself, diagnosed the problem and suggested some things to try which confirmed the cause and gave me a workaround.

                                      It’s the alpha release of their new 4.0 version and I don’t have to use it but it’s gratifying that they responded.

                                      1 Reply Last reply Reply Quote 3
                                      • ?
                                        A Former User
                                        last edited by

                                        9cd5cff9-c571-44b1-a93c-cbffdaf3960b-image.png

                                        Javascript is 26 years old now. It has long stopped being the new kid on the block and it never bore even the slightest resemblance to Java. Can they stop fucking doing this please?

                                        KilemallK 1 Reply Last reply Reply Quote 0
                                        • KilemallK
                                          Kilemall Careful, railroad agent @A Former User
                                          last edited by

                                          @hog said in The OFFICIAL programming thread:

                                          9cd5cff9-c571-44b1-a93c-cbffdaf3960b-image.png

                                          Javascript is 26 years old now. It has long stopped being the new kid on the block and it never bore even the slightest resemblance to Java. Can they stop fucking doing this please?

                                          This is what you get when you use Bing.

                                          https://i.imgur.com/hX2CMMZ.jpg

                                          Never go full Lithu-
                                          Twain

                                          No editing is gonna save you now-
                                          Wingmann

                                          http://s3.amazonaws.com/rrpa_photos/72217/DSC_2528.JPG

                                          http://s3.amazonaws.com/rrpa_photos/20416/PTOB 101_resize.jpg

                                          Gators1G ? 2 Replies Last reply Reply Quote 1
                                          • Gators1G
                                            Gators1 @Kilemall
                                            last edited by

                                            @kilemall said in The OFFICIAL programming thread:

                                            @hog said in The OFFICIAL programming thread:

                                            9cd5cff9-c571-44b1-a93c-cbffdaf3960b-image.png

                                            Javascript is 26 years old now. It has long stopped being the new kid on the block and it never bore even the slightest resemblance to Java. Can they stop fucking doing this please?

                                            This is what you get when you use Bing.

                                            My vaccine scar hurt when I read this post.

                                            alt text

                                            1 Reply Last reply Reply Quote 5
                                            • First post
                                              Last post