News for hackers. Stuff that matters.
Re:Why video game doors are so hard to get right [video] by egypturnash on Monday September 06, 2021 @02:52PM (#28436754)
Watch the video, it goes into detail about why doors are hard, especially as you start moving from "press space when near the door to make it slide into the wall" to "the door is a physics-simulated object that interacts with all the other physics-simulated objects in the game, and which players and NPCs will open in a realistic fashion that involves blending pre-fab animation with the location of the handle/knob relative to the character instead of vaguely waving a canned animation in the direction of the door as it magically opens".

Never mind a door simulated at the level of "I am opening it just wide enough for me to get outside with some food and water for the semi-feral cats who live under my house, with minimum opportunity for them to run inside before they're distracted with that food, also I have to kick it to get it open now because this is New Orleans and the house just settled a little more after Ida and now the frame's a little less square". Which is an interaction I have with a door every morning without ever thinking about the door.

There's also a quote from a lead developer at an AAA team saying that doors are the hardest thing to get right. Everything in a video game is a thin veneer of illusion, and doors are surprisingly complex in how they have to interact with every level of that illusion.

[dead]
Re:Why video game doors are so hard to get right [video] by midnightclubbed on Tuesday September 07, 2021 @01:28AM (#28441238)
Many games do simulate/animate/synchronize doors with their own custom systems because doors are way more complex and problematic than 99% of other in-game objects.
Re:Why video game doors are so hard to get right [video] by short_sells_poo on Monday September 06, 2021 @03:42PM (#28437195)
There are some things that generalize in game development, mamy don't. How you implement a door can very much depend on the sort of game you are building. And it can absolutely get complicated simply by the fact that you'll likely need to hand roll your solutions.

I haven't worked in game dev in decades, but I remember that just network synchronization could be tricky because the degree to which a door is open could lead to very different outcomes in a game. Eg take a shooter game:

Does the door block/deflect bullets?

Yes? Well now you need to make sure to synchronize clients really cleverly because each player will see a different state of the door depending on their latency. Whether they can shoot through the opening is relative to each clients' reference frame.

Oh, just make the server decide you say? Well, now all your inputs have a perceptible delay because your client has to wait for confirmation from the server, or you'll often see jarring prediction error correction when the thing you predicted is wrong.

A huge amount of research and work has gone into this and yet there's still no silver bullet.

That you think this is all solved just says that you know very little of the problem area - which is ok - but then you should not be making broad and confident statements about it. A touch of humility doesn't hurt.

Re:Why video game doors are so hard to get right [video] by faanghacker on Monday September 06, 2021 @03:49PM (#28437285)
Except network issues were not mentioned in the video. Moving the goalposts.
Re:Why video game doors are so hard to get right [video] by short_sells_poo on Monday September 06, 2021 @03:56PM (#28437361)
It was just an example of conceptually simple things that are hard in games. Are you disagreeing with what I wrote?
Re:Why video game doors are so hard to get right [video] by faanghacker on Monday September 06, 2021 @04:02PM (#28437429)
Not at all. Network issues make everything in games more complicated, not just bullets going through doors.

Everything in games can be complicated: physics, doors, AI, network. Even the first line of that video description.

I think that just proves my original point: it's clickbait to single out doors as being exceptionally hard versus everything else in game design.

Re:Why video game doors are so hard to get right [video] by short_sells_poo on Monday September 06, 2021 @04:52PM (#28437988)
> I think that just proves my original point: it's clickbait to single out doors as being exceptionally hard versus everything else in game design.

That's a fair point, but I think the charitable reading of the title is that amongst all the complicated things, a conceptually simple object like a door can still be very deceptively complex.

I sometimes get an urge to work on the myriad of game ideas I've written down over the years. And every time I remind myself that what I really like is the "idea" of making a game, not the actual process. Because the actual process is a draining, thankless and often rage inducing process. The actual building of a game is 95% of the time spent on stupid little details like making a door work properly.

And it is for that reason that I really admire game developers, particularly indie ones. It takes an insane amount of willpower, mental fortitude and wits to take a game from idea to playable product. And you then have to contend with one of the most toxic and volatile consumer groups in existence.

Re:Why video game doors are so hard to get right [video] by faanghacker on Monday September 06, 2021 @04:58PM (#28438033)
> I sometimes get an urge to work on the myriad of game ideas I've written down over the years. And every time I remind myself that what I really like is the "idea" of making a game, not the actual process. Because the actual process is a draining, thankless and often rage inducing process. The actual building of a game is 95% of the time spent on stupid little details like making a door work properly.

Yeah, I agree. I actually started out learning programming as a pre-teen by making my own games. It can be a lot of fun at times, but a lot of frustration too, and I can see how the latter eclipses the former as as you scale into a more complex game and with a bigger team.

It's not an easy job that's for sure.