|>> || 1515457792956.jpg -(61079B / 59.65KB, 189x280) Thumbnail displayed, click image for full size. Your body is always gonna use muscle as a fuel source. You will never be able to utilize only fat. |
If you are looking to lose weight, the best way to retain muscle is to continue to work out to stimulate the muscles (and essentially tell your body "hey I still need this") and to take in sufficient protein, at least 40 grams a day for most people (I think, yknow, that's just an estimate, research this number more yourself if you're worried)
If you're trying to bulk, don't worry that much. The energy you're using during your resistance training is coming from glycogen that has been prepared in your body already. You'll only be depleted of it if you haven't eaten carbs in a while, like, since early the day before. (This is why ketosis kicks in after 2 days of no carbs; your body needs to create things in your body that give more direct access to fat as a fuel instead of glycogen.)
The thing is, if you're bulking, you're eating enough carbs already ***. Eating carbs shortly after your workout helps replace the glycogen you use during the workout, which is incredibly helpful for building muscle, since your body is gonna go "fuck, I need more glycogen" and it'll be able to just use the carbs instead of trying to burn fat and muscle to achieve its mission.
*** I can't, however, say on how this comment about "enough carbs" affects your actual workout capabilities. I don't know enough about how much you need in what time range in order to do a complete weight-training workout, for example. I do believe that you don't need to eat too much much, though, for your energy, unless you've been fasting or something recently. For example, you probably don't want to work out after not eating anything for the last 16 hours. I think it'll cripple your max potential. Again, these are just numbers being thrown, and I'm not that well-versed in this so I can't really say.
Note, though, that you should NEVER eat 30 mins or less before a workout. Consuming carbs will increase the insulin in your blood, which is an ANABOLIC response. You do not want your body to be busy BUILDING energy reserves while you work out, you want it to be breaking down energy as much as it can so you can be as strong as you can be. You want this response immediately after your workout, though, so you can start building that muscle up once it's ripped to shreds from your killer bench press. This is why people eat non-complex carbs right after working out.