Ah OK, my code that Aiden posted will work for you with minimal edits to account for the extra two motors, and actually if those are using Y cables no edit is required.
#ERROR!! 10429: Instance NattyMan0007.laughingStop hung at runtime.
Think about a function as essentially placing a piece of code into the autonomous section - or having a reference to some code that RobotC essentially treats the same as something you would just write directly into the autonomous section. That means we want to as a general statement, if not only for readability, place our while(true) loops outside of the function and in the task.
With the autonomous code, we generally want to shy away from using infinate loops anyway however and look at how a holonomic drive actually works. Why does the code that Cody posted actually act on the wheels that way and cause your robot to move in that specific way? Using that we can manipulate the movement of the robot in certain ways.
As a first, remove the while(true) loops from your code and place all the appropriate code in a for( timeperiod ) piece. Something along the lines of:
function ( x, y, rot, time ) {
for( int counterVar = 0; counterVar > time; time++ ) {
// Code here for affecting your drive.
delay( unit of time )