Premium Only Content
No Game Engine Game Dev: Word Sleuth 036: Two bugs and std container hunting
Streamed on 2024-08-22 (https://www.twitch.tv/thediscouragerofhesitancy)
Game Engines are for sissies!
I started off with some bugs that had crept in during some of the major refactors of the last week or two. The first bug was with text color not updating correctly. With a bit of tracing I found the issue to be similar to what we found before ... the colors weren't being applied all the way to the end of the desired colors list. Really it should just always match the quad capacity, so there's now a TODO item for that.
The second bug was about a texture not showing up right. It turns out that I had an array index out of bounds write in the ShaderStore that was overwriting the array in TextureStore, but it took some digging to figure that out. Once I spotted it, the cause for the error was easy to identify and the fix was easy. In ShaderWarehouse there are pairs of files: vertex shader and fragment shader. So I know the number of files is 8. However, a shader program takes one of each, so the ShaderStore has room for 4. Then, when I request a Shader from the ShaderStore, the index was with respect to the 8 files in ShaderWarehouse and needed to be adjusted to the number of shader programs in ShaderStore. With a little indexing magic, all was well with the world once more.
Then it was time to continue the hunt for standard library containers. I have found that every time I use one, it can be refactored away into something more basic and just as functional. So I removed the std::vector from VertexBufferLayout with relative ease. Then I started on the last std container in my code base. It is the ActionSequence scheduler. Instead of keeping lists, each ActionSequence maintains more internal state (Idle, Waiting and Running) and the Scheduler has an ActionSequence pool. This should eliminate all allocations/frees nicely. It very nearly works, but there is still a bug or two I am working through. On Monday I should have eliminated all std containers and be in a good working state.
-
9:03
MattMorseTV
14 hours ago $10.58 earnedTrump’s America First CALL TO ACTION.
14.5K49 -
17:33
a12cat34dog
21 hours agoRUMBLE TAKEOVER @ DREAMHACK | VLOG | {HALLOWEEN 2025}
40K25 -
10:48
GritsGG
14 hours agoWarzone Stadium Easter Egg! Unlock Grau Blueprint EASY!
6.51K2 -
LIVE
Lofi Girl
3 years agolofi hip hop radio 📚 - beats to relax/study to
446 watching -
1:43:54
TruthStream with Joe and Scott
3 days agoStuey and Elisa V interview Joe and Scott Q, AI, Glutathione, Tylenol etc 11/5 #510
10K6 -
29:15
BlabberingCollector
2 days agoHarry Potter X Fortnite, Fans Reee Over Trans Rights, NEW Audiobooks Are OUT, Wizarding Quick Hits
28.8K3 -
1:20:42
The Connect: With Johnny Mitchell
6 days ago $11.54 earnedThe Truth Behind The U.S. Invasion Of Venezuela: Ed Calderon Exposes American Regime Change Secrets
35.5K24 -
2:10:18
FreshandFit
6 hours agoAfter Hours w/ Girls
128K35 -
2:06:29
TimcastIRL
12 hours agoAirlines Cancel Over 700 Flights, Travel APOCALYPSE Is Now, Trump Says END FILIBUSTER | Timcast IRL
233K115 -
9:02:44
SpartakusLIVE
17 hours agoTOXIC Solos on ARC Raiders || Friday Night HYPE - WZ or Redsec Later?
77.2K2