You dont have a { after your while true statement ^^ and the closing } of your while true statement(before you close the void).
Also, you are doing exactly what this thread https://www.mpgh.net/forum/207-combat...toconsole.html says not to do(Unrelated to your error)