Spyke
SGG
lemmy.world

Honestly back when I was a kid this is how I thought games were made, every possible image of a game was already saved and according to your input it just loaded the next image.

I stopped thinking that with 3d games

154
0opsreply
lemm.ee

I thought that they were managing that stuff on a per-pixel basis, no engine, assets, or other abstractions, just raw-dogging pixel colors.

And before I even played video games at all I was watching somebody play some assassin's creed game I think and I thought the player had to control every single limb qwop-style.

54
lemmy.blahaj.zone

In the first few Assassin's Creed games, they did use the idea of a Puppeteer system for the control scheme, although it wasn't physics-based or anywhere near as hard as QWOP. Each of the controllers face buttons performed actions associated with each limb, and the right trigger would swap between low profile actions and high profile actions.

In the top right of the screen, there was always a UI element showing what the buttons did at that moment in that context, which might've been why you thought it was a QWOP style system. It's not exactly what you were thinking of at the time, but you were closer than you realise.

23

Not quite "Time Killers" level of limb to button assignment, but a line that I had not drawn in the AC control scheme!

2

Apparently ai is learning to do that first thing you said about pure pixel management. It's crazy that it works at all

1
Scooptareply
programming.dev

Even with 2D games that's basically impossible. Only time it could work is with turn based games and then...you end up with this post lol.

26
Wolf314159reply
startrek.website

I see you've never played "Dragon's Lair", where every scene was cell animated and the player "chose" the path that the animation would take.

17

That one ran on a laserdisc, right? Like a CAV disc so it could very quickly move the laser to one of a couple of places for basically a win/lose decision, overlaying some graphics over top for the game UI?

2

LOL, I've actually heard of it, but I have not played it. Ofc that game never even crossed my mind when writing my comment haha. I suppose choose your own adventure style books also fall into this category.

2
papalonianreply
lemmy.world

I remember having a thought one day as a young kid while interacting with a DVD main menu (the kind that had clips from the movie playing in the background, and would play a specific clip depending on what menu you went in to).

"This is basically how video games work, there's a bunch of options you can choose from and depending on what you do it shows you something. Videogames are just DVD menus with way more options."

I grew up to not be a programmer.

19

The game Myst actually worked kind of like a DVD menu with more options.

7

Its not terribly far off from pre rendered or FMV games like Myst are doing it.

6

It does work like that a little bit, like with sprites they've often hard-coded the frames of animation, so when you push a button it loads the correct image, like Mario's jumping frame with his hand in the air. But there are such things as tilesets, and sprite positions, and all that good stuff.

4
lemmy.world

I remember speculating as a (small) kid that the AI soldiers in Battlefront II's local multiplayer might be real people employed by the developer. Not the brightest child was I.

3

I remember as a kid seeing my older brother talk to people on a mic and thought he was talking to the characters in the game

3

This is what I believed. And I tried to trick the game by doing movements and inputs no one could have planed. Never outdid that planning somehow. They were on to me!

2

I grew up mostly with the PS2 and above and I thought the same thing 😅. I did think there had to be a better way though

2
Grendelreply
tiny.tilde.website

@VoidJuiceConcentrate @maris

Right?

pretty sure there are more possible chess positions than atoms in the earth (universe?), so even if every atom of our planet were converted to transistors there'd be no way to fully represent all possibilities.

23
Zinkreply
programming.dev

This was a fun one to look up. https://en.wikipedia.org/wiki/Shannon_number

It looks like the number of valid chess positions is in the neighborhood of 10^40 to 10^44, and the number of atoms in the Earth is around 10^50. Yeah the latter is bigger, but the former is still absolutely huge.

Let's assume we have a magically amazing diamond-based solid state storage system that can represent the state of a chess square by storing it in a single carbon atom. The entire board is stored in a lattice of just 64 atoms. To estimate, let's say the total number of carbon atoms to store everything is 10^42.

Using Avogadro's number, we know that 6.022x10^23 atoms of carbon will weigh about 12 grams. For round numbers again, let's say it's just 10^24 atoms gives you 10 grams.

That gives 10^42 / 10^24 = 10^18 quantities of 10 grams. So 10^19 grams or 10^16 kg. That is like the mass of 100 Mount Everests just in the storage medium that can store multiple bits per atom! That SSD would be the size of a small large moon!

39
lemmy.world

Assuming your math is correct (and I have no reason to doubt that it is) a mass of 10^16 kg would actually be a pretty small moon or moderately sized asteroid. That's actually roughly the mass of Mars' moon Phobos (which is the 75th largest planetary moon in the Solar System).

7

I was thinking of 10^16kg diamond storage inside a larger SSD that’s the size of a large moon, similar to how a real SSD has data stored in tiny little slivers of silicon inside a much much larger device.

I should have explained that one better. It’s easy to imply such details to keep text shorter.

2
Tjareply
programming.dev

Out of curiosity, why did you say planetary moon? Is there any other kind?

1
lime!reply
feddit.nu

i think you did the weight approximation in the wrong order, 10^24^ is a lot bigger than 6×10^23^. so you can probably double the final weight.

3
Zinkreply
programming.dev

10^24 is a lot bigger than 6×10^23

Well yeah it’s almost double, but I wrote the comment as a mental estimation of the order of magnitude, so it doesn’t change the substance of the discussion.

I mean at the beginning I arbitrarily picked a number in that 10^40 to 10^44 range and that’s a factor of 1:10,000 rather than 1:2, lol.

2

Slightly less than double, actually. (Doesn't really change the meat of the argument or anything though.)

2

yeah yeah, cosmological approximations and all that, but there's still a bit of difference between "planetoid" and "gas giant" :P

1
programming.dev

valid chess positions is in the neighborhood of 10^40^ to 10^44^

Lol, big board you're playing with....

2
Zinkreply
programming.dev

If you don’t limit it to valid positions/arrangements it’s like 10^120. Closer to the “number of X in the observable universe” caliber of number.

2

So I think I was wrong, but you are too lmao.

10^120^ is the number of valid game-trees, or valid ~80 move games.

The much smaller number I quoted above, though, IS the valid positions, I was thinking it was actually the trimmed down "truly valid" game-tree sequences.

Isn't math fun? Limitless ways for us to be wrong!

2
feddit.uk

At university I had an introductory C course where one assignment was to write a program that searched a 4x4 array of booleans for groups of cells set to true. Groups had to be rectangles, powers of 2 in width and height, and could wrap (i.e. they could go off the right edge and back on the left edge). We had to submit our programs by e-mail and printed form one week later. The prof. marked the paper versions and the TA ran and tested the digital. One slight problem, if you used the university owned printers, they charged for print outs. A few pence per page to cover costs and stop people abusing the rather nice high quality printers the computer faculty had.

I'd always enjoyed programming and whilst C was new to me, using another language wasn't a big problem. As I worked on it I realised the problem wasn't as straightforward as I first thought, but I spent a few hours on it that evening and had a solution I was happy with.

Penny was a student on the course whose approach to academia was memorization. She didn't consume, process, and apply concepts. She just remembered them. Her favourite subject was maths. While the rest of us were struggling to derive some formula, she'd have just committed the process to memory.

Penny was complaining a lot on this programming assignment. She didn't understand why the assignment was so hard for an introductory class. I didn't judge. I know some people find programming hard, but I didn't feel I could help her much without jeopardising my own mark. There's only so much uniqueness in a small program and if she just copied my solution we'd both get penalised for plagiarism. I did mention to her the cases I'd found tricky to get right was when two groups overlapped. If one group completely covered a smaller one you'd only report the bigger one, but if not you'd report both groups.

I heard, through her boyfriend, that that week had involved many long evenings working on this assignment, but she turned up at the next class solution in hand. Obviously stressed, she carried a pile of paper of several hundred pages. She had written a program that consisted of an if-statement for every possible group size and location. About a hundred different possible groups. Each condition written with constant value indices into the array. To cope with the overlapping groups problem, checks for smaller groups also checked that no larger group also covered this area. No loops. No search algorithm. Just a linear program of if-statements.

Apparently debugging this has been a nightmare. Cut and paste errors everywhere, but when I'd told her about overlapping groups aspect it had blown her mind. There always seemed to be a combination she hadn't accounted for. Multiple times she thought she was done, only to find a corner case she'd missed. And just to kick her when she was down, she'd paid for multiple printouts, each one costing about £10 only to find a problem afterwards.

This consistent A grade student who sailed through everything by relying on her memory had been broken by being asked to create an algorithm rather than remember one. She got credit for submitting a solution that compiled and solved some cases, but I doubt the professor got past the first page of that huge printout.

Penny had worked really hard for that D.

76
Hawkreply
lemmy.dbzer0.com

Lol why does this entire text sound like a setup for that last sentence

65

I wonder if people who think AI is "just a bunch of if statements" think programs work like Penny thought they did

1

Fair, I regret my comment - was a dumb joke in response to the last line of this wall of text (which I'm guessing was a joke)

3
buttnuggetreply
lemmy.world

Professor was an idiot if it gave a D for a working solution. Getting it working is the grade, optimizing is the next step.

-10
Iambusreply
lemmy.world

The downvotes says you're retarded, give it up dickhead 😂

1
buttnuggetreply
lemmy.world

So if your moral and intellectual superior was being upvoted, you’d concede me being right? You’re even dumber than I first assessed. Run along worthless dumbfuck, leave your superior alone.

-6
Iambusreply
lemmy.world

Lmao what a retarded fucknut you are, please eradicate yourself for the good of humanity 😂

1

I’m sorry but it’s not my problem that you deserve the death penalty. Run along, little guy.

-4

For efficiency you should you GOTO, so you can join trees that end up in same position.

Like those create your own adventures books.

3
feddit.org

This is actually what made me start my programming journey. Made small games using PowerPoint until I was starting to make an level editor on a 12x12 grid. My father thankfully stopped me pretty early on and showed me Game Maker 7. Not sure for how long i would have continued.

33
gerryflapreply
feddit.nl

Are you me lol? I did exactly the same, and at some point I started computing how many slides I had to make to make anything larger and I pivoted. My dad didn't know this stuff but I also ended up at gamemaker

13
x0x7reply
lemmy.world

I did the same but it was the TI-83 plus calculator. This was in middle school. Eventually I made games for it a more reasonable way. But I spent a month thinking this is how games were made, by knowing every possible image of the game and knowing how to map from one image state to another based on the controls.

There's something kind of plato's cave to say about it. When all you see are images on the screen you think that's the state.

Makes you wonder if there is something deeper we refuse to see because we got down to a level of state we could actually work with. Could it be RAM is not really the program state, and only what you think the program state is?

2

Oh the TI-83 Plus also definitely was the subject of my experimentation during that time, or maybe a bit after it. But then with the programming mode and actual code. The TI-83 Plus is actually what got me the advice to study computer science. During a physics class we got a lesson on modelling in some silly programming language. Because it was going very slow, I translated the program/simulation my teacher was showing to the calculator. At the end of the lesson I came up to her and showed it to her. She was like "That's impressive, you should look into computer science". Somehow I hadn't considered that before

2
lemm.ee

hey, there is an inherent fun in maing games/programs using things that were never meant to.

once i did a CPU/RAM emulator using excel, so you could see every bit.

it was fun to make loops, and programs

4
lemmy.world

This is how I got into game development myself. I used to use Javascript to make dumb little interactive games in the early 2000s before it was ever meant to do such things, emulating what is now modern day HTML5 canvas and such

3
lemm.ee

bes way to learn is by doing what you're not supposed to

1
lemmy.world

True enough! Mistakes are the best teacher. That said, I'm still making games in Javascript to this day, so I guess you can say I haven't learned enough lol.

2

Considering that enough pro's are doing the same, perhaps you didn't really do it wrong?

1

I suddenly feel in good company. I got my start doing crazy things with PowerPoint and Excel because it was what I knew.

3
lemmy.world

This reminds me of one of my very first programs, a tic-tac-toe game I wrote in high school. It displayed hardcoded grids of Xs and Os and blanks very similar to what's shown here. This approach worked because of the much more limited move possibilities. The program could always win if it made the first move, and always win or tie if the human moved first, depending on if the human made mistakes. I wish I still had the code.

29
Tjareply
programming.dev

Did the program cheat? Tic tac toe is a tie if opponents play correctly.

17

I'm probably remembering it wrong, it was a long time ago. It definitely always either won or tied but could never lose, because it knew the right responses to every move. No, it didn't cheat lol.

2
ratreply
lemmy.dbzer0.com

Placing moves in invalid locations, passing a turn, or making multiple moves on one turn?

4
lemmy.world

There are no invalid locations in tic Tac toe, passing a turn provides no advantage, I suppose you could take extra turns to cheat.

1

An invalid turn would be something like placing a move on top of an already-filled square or outside of the 9 grid spaces. It seems obvious to a human that you can't do these things, but computer bugs have a tendency to do things you don't expect. And yes, passing a turn doesn't provide an advantage, but I listed it because it's still technically cheating.

1

This is supposed to be a joke but sadly a lot of beginner tutorials on coding Tic-Tac-Toe teach this

23

As a middle schooler I used Power Point to make FMV games for my friends and classmates, and it was basically this. Just, like, SO MANY slides

20
xep
fedia.io

This is where you'd normally go "there must be a better way..."

17

This is a great advertisment for what real developers do. You shouldn't just crank out the first idea that works. You should be doing something that is smarter and sensible.

1

I'm familiar with issues like this. Lots of copy/pasting with little edits here and there all the way down.

2

They are doing it dumb. You can text output chess but you just need to keep track of where the pieces are in code, then when you are ready to output, place the characters. Saves so much time. /s

2
lemm.ee

not to get epistemological,

but I hate that technically there's only a limited number of moves in chess, and therefore the best move is there, maybe there's a strategic where white will always win, but we'll never know because the number of variations likely is larger than atoms in the universe.

1
lemmy.world

On the lower end of estimates, the number of unique chess board configurations is 10^120, often referred to as the Shannon number. The universe doesn't stand a chance.

6

maybe a distant future technology could compute that, Clarktech style

2
exprreply
programming.dev

In modern chess, engines have gotten good enough that we generally do know the top moves and humans can't beat them. We can even numerically assess someone's chess play with a computer, which we call "accuracy". Obviously they can always be improved further, and there are a handful of situations where they might misevaluate, but it's still pretty incredible.

Engines have only made chess more exciting as they have shattered a lot of old theory and helped people find a lot of new and innovative ideas. They are an incredible aid in analysis and tournament prep.

5
lemm.ee

yhea, but engines still act as if it is an unsolved game.

while in theory, given that the number of moves is limited, in theory one colour would always win.

3
lemmy.world

The solution to chess is almost certainly a draw, since this is what all top engine chess converges to. Otherwise you are completely correct: chess is unsolved and will likely never be solved.

4

one AI that always manages to draw in chess is Stable diffusion and dalle...

/j

0