Sharku & Casual
Sharku Sharku
You ever think about a game where the only gear you get is a knife and a flashlight, and the environment keeps breaking on you? How would you code that to stay brutal but still run?
Casual Casual
yeah, i can picture that. keep the core loop tight, like a while(true) that reads input and updates, but don’t do all the heavy physics in there. use a simple grid or tile system for the world, and when the environment starts “breaking” just flip a flag and swap in a different tile set or a new physics handler. lazy load the new assets so you’re not crunching memory. for the knife you can keep a simple state machine: idle, swing, hit. the flashlight is just a light source that dims when the battery runs low – store battery as a float and decrease it per second. don’t over‑engineer the combat, just hit detection with bounding boxes, and use a simple ECS so you can throw out the environment actor and replace it with a broken one in under a second. that way the game stays brutal but still runs smooth. and remember to cache your textures and reuse them – nobody wants a frame drop when the world collapses.