Who cook the soup? Confusion [我煮汤 = I cook soup, this has confused who cook the soup..can you tell me grammer points how not to confuse with subject and object in this scenario:]
I am translating this sentence,
他第一次为我煮汤，是在妈妈离家的那一天
“he first time do I cook soup.” My literal translation
But actual translation is “he made soup for me for the first time ....”
Text as below for context:
爸爸有一个星期没有来送汤了。真搞不懂他，已经退休了，又没事做，煮点汤有什么难的？好不容易等到他给我送汤，却不是熬出来的“好东西”。有时连肉块都省了，和以前那醇厚的味道比起来，真是天渊之别！我已经喝惯了爸爸煮的汤。他第一次为我煮汤，是在妈妈离家的那一天。我当时不知道妈妈为何要离家出走，后来才明白她是认为爸爸没出息。为什么她这么残忍，她可以不要爸爸，怎么可以不要我呢？
The fundamental sentence is 他煮湯 (he cooks soup). The subject is 他 and the object is 湯, or the thing that is cooked.

You may consider 第一次 (the first time) and 為我 (for me) as adverbial phrases. They describe how the soup was cooked by Father.

為+sb, 替+sb, and 幫+sb indicate the action is done on behalf of someone. They behave like 給+sb. E.g.:

我為你打掃了房間 I cleaned the room for you.
他替我做功課 He does homework for me.
我幫她買了雞蛋 I bought eggs for her.