cinera_handmade.network/cmuratori/hero/code/code056.hmml

33 lines
2.9 KiB
Plaintext
Raw Normal View History

[video output=day056 member=cmuratori stream_platform=twitch stream_username=handmade_hero project=code title="Switch from Tiles to Entities" vod_platform=youtube id=NMfx9eVrNmQ annotator=csnover annotator=schme annotator=debiatan]
[0:00][Intro]
[1:44][Recap]
[5:18][Scaling low-frequency entity updates]
[16:45][Revising the tile map]
[18:30][Thinking about changing tile map to store entities instead of tiles]
[22:48][Options for how to reference entities in memory]
[29:26][Storing entities in tile entity blocks]
[33:32][Thinking of a technique to improve low entity access]
[34:34][Going in the other direction]
[36:09][Removing invalid code]
[38:04][Thinking about the size of the tile_map TileChunkHash]
[41:45][Renaming tile_map to world]
[55:55][Debugging refactoring]
[57:00][Recap]
[58:37][Q&A][:speech]
[58:59][Do you still expect the gameplay to be broadly grid-based even without tiles?]
[59:44][Could you use reflection to help handle the entities and world chunks?]
[1:00:53][Will everything in the game be an entity even if it does not need collision detection or movement?]
[1:02:02][Don't you think most of the storage concerns stem from having just high and low entities and would be solved by having more granularity there so you have more and smaller arrays of entities with some particular aspect?]
[1:02:47][You mentioned considering having the world chunks store a fixed entity count and then add multiple chunks to the hash table if necessary to store more entities. If you were to go that route, how would you compare one chunk to another? Multiple chunks would have the same X,Y,Z.]
[1:04:16][In terms of handling entity compression and decompression, where would you grab/store the state of objects that are coming in and out of the update scope?]
[1:04:47][Why do you call C compiled with a C++ compiler “C++”?]
[1:05:23][Why can't world_position just have a pointer to a world_chunk instead of all those AbsTiles? Then Offset_ is relative to the world_chunk.]
[1:07:24][I didn't get to watch the entire stream so I don't know if you considered it, but why don't you have a flag for “about to be deleted” that every entity checks against and nulls pointers. Have it visible for all entities for one frame.]
[1:08:27][Do you think the todo puzzler will be handled tomorrow, and do you often sleep on decisions like that?]
[1:09:31][(follow-up) What I was getting to is that we seem to be working towards what's called the Entity Component system where what we call now “high” and “low” are just components alongside anything else we want to add to entities later.]
[1:10:38][Seeing that the computer handles 1 million entities without lagging, do we really need to worry about the performance hit coming from one extra pointer dereference?]
[1:12:30][Will entities be able to transfer from one chunk to another?]
[1:12:52][Will we start using the entity system for something other than players/walls soon or will the renderer come first?]
[1:13:58][End][:speech]
[/video]