Howdy Alex -
Have you stepped through your logic using F7 etc to see where your logic is off? That can be extremely helpful.
My first question is your loop:
start: 
finditem YFM G_2 
if #findid <> x
   { 
   ignoreitem #findid 
   gosub body 
   } 
goto start:
So what you're saying here is:
1) To find a corpse within 2 tiles - fine
2) If you find one, and it's #findid isn't x - umm, well this does work although you may be better off using #findkind
3) Ignore what you just found - huh?
4) Now go to the body sub
Then, in the body sub, you're setting #lobjectid but you've commented out anything that sets your %body variable.
I'm thinking you might want to look at a few things, here is something similar (untested though, I'm at work). First, I got rid of the Goto - coder preference 

 you can still use if you'd like! Next, you find the item then immediately set a variable to that itemid. Away to the sub you go and when you return you ignore that variable and go back to looping.
While in the sub you can your backpackid so you don't need the yucky click command. I also set your lastobject to your actual %Body variable for consistency. Then, I replaced your events with exevent including the dropc replacing the click, just a little nicer this way - less likely to give you issues. Finally, I threw in a little loop that says "keep looking through this corpse (finditem) and drag any item or stack you find (exevent drag #findid #findstack) to my backpack (exevent dropc #backpackid) until there is nothing left (Until #findkind = -1). Then return to the findcorpse loop.
Check it out -
Repeat
   finditem YFM G_2 
   if #findkind <> -1
      { 
      set %Body #findid
      gosub Body
      ignoreitem %Body
      } 
Until #FALSE
 
sub Body 
   set #lobjectid %Body
   nextcpos 15 15 
   event macro 17 
   wait 15 
   repeat
      finditem * C_ , %Body
      exevent drag #findid #findstack
      wait 10 
      exevent dropc #backpackid
      wait 15
   Until #findkind = -1
return
Does this make sense?
Feel free to fire away!!
X