If the "set aside" happens after the first play then how does it get 2 more cards and 2 more actions?
I know some cards specify "during the clean up phase". Should "set aside" and "trash" default to "clean up phase" or always happen immediately? Can you only get the "trash" benefit if done as only the second option (I.e. Engineer, Mining Village) and not at all on cards like Feast?
Well, this is actually not very complicated. When you play a card, you follow
all of the instructions on the card from top to bottom, except for the ones that you can't. Generally, cards are supposed to do literally exactly what's printed on them, word-for-word, so it's almost as if you were reading program code.
So, this is what happens when you play Encampment with Throne Room:
Throne Room tells you to play an Action card from your hand twice, so you choose Encampment.
You play Encampment.
You get +2 Cards.
You get +2 Actions.
You may reveal a Gold or a Plunder. If you don't, Encampment is set aside.
You play Encampment again.
You get +2 Cards.
You get +2 Actions.
You may reveal a Gold or a Plunder. If you don't, Encampment is set aside.
This is what happens with Mining Village:
Throne Room tells you to play an Action card from your hand twice, so you choose Mining Village.
You play Mining Village.
You get +1 Card.
You get +2 Actions.
You may trash Mining Village. (let's assume that you choose to trash it here)
If you trashed Mining Village, you get +$2, so you get it because you trashed it.
You play Mining Village again.
You get +1 Card.
You get +2 Actions.
You attempt to follow the instruction "You may trash this", but it fails because the card is already in the trash.
If you trashed Mining Village, you get +$2, but you didn't because it was already in the trash so you don't get +$2.
This is how it works for Feast:
Throne Room tells you to play an Action card from your hand twice, so you choose Feast.
You play Feast.
You trash Feast.
You gain a card costing up to $5.
You play Feast again.
You attempt to trash Feast, but it fails because it's already in the trash.
You gain a card costing up to $5.