Also a do loop is almost the same as a for and a while, just the fact that a do loop does the loop first then checks requirements.
NPC Code:
do {
//actions;
//increment;
} while (condition);
That is the basic format incase anyone who doesn't know, wants to.