TinTin++ Mud Client Manual

Command: #loop {<start>} {<finish>} {<variable>} {commands}

         Like a for statement, loop will loop from start to finish incrementing
         or decrementing by 1 each time through.  The value of the loop counter
         is stored in the provided variable, which you can use in the commands.

Example: #loop 1 3 loop {get all $loop.corpse}
         This equals 'get all 1.corpse;get all 2.corpse;get all 3.corpse'.

Example: #loop 3 1 cnt {drop $cnt\.key}
         This equals 'drop 3.key;drop 2.key;drop 1.key'.

Related: break, continue, foreach, list, parse, repeat, return and while.