There's two issues you are dealing with, from looking at the full code you linked above.
1) You're stack isn't being setup properly to use arguments (especially more than four) for the standard MIPS o32 calling conventions. The other answers do a good job of pointing you to help on this.
2) The 'printf' you are using doesn't use standard calling convention whatsoever. If you see the comments:
## printf--
## A simple printf-like function. Understands just the basic forms
## of the %s, %d, %c, and %% formats, and can only have 3 embedded
## formats (so that all of the parameters are passed in registers).
## If there are more than 3 embedded formats, all but the first 3 are
## completely ignored (not even printed).
## Register Usage:
## $a0,$s0 - pointer to format string
## $a1,$s1 - format argument 1 (optional)
## $a2,$s2 - format argument 2 (optional)
## $a3,$s3 - format argument 3 (optional)
## $s4 - count of formats processed.
## $s5 - char at $s4.
## $s6 - pointer to printf buffer
Nothing is expected to be passed on the stack. (Remember $s0-6 aren't stack-related). You can provide to this function $a0-> format string, and 3 arguments (in $a1, $a2, and $a3).
Note these comments suggests says it destroys $s0-$s6, though from the incomplete code, I can say how much is restored without tracing through it. In short, this printf you found, might be handy, but it does not use stack conventions you should be learning and it is pretty limited. Assuming you have permission to use it, see about getting permission to modify and just rewrite the interface to something sane. Keep in mind having to call the function multiple times if you need to print out more than 3 variables at a time isn't a big deal (if it is, just write a wrapper).