Personally, I have a task list or task board (there are a number of ways to do it, a lot of development uses Kanban or Agile methods). I'll usually then sort them by priority and complexity (think length of time, difficulty). Usually this helps with having a strict list on what needs to get done and prevents me from adding anything to a project unless I feel it is ABSOLUTELY for the benefit of the final product.
I also have reasonably strict working hours for myself and try my best to keep to those. I am pretty well known for not being great at it. I definitely still deal with "my brain won't shut off and stop thinking about it" and then I'll usually pick up a small task and complete that or chip away at something larger. I know some people use Pomodoro timers to essentially force themselves to take breaks or swap tasks. Most websites and tools that have them will allow you to select your own work vs. break time ratio.
While I'm not a games generalist, I do frequently split into different "departments" of game production, which I find can help with passion burnout for me. I'll split days or weeks into time I'm going to focus on art, programming, etc. If I find myself growing dissatisfied with what I'm working on, I'll try and wrap it up ASAP (whether that be finishing the task or marking what is left) and then swap to something else.
Is it perfect? No. Does it work for me? Most of the time.