Author Topic: Problems with Script_Me  (Read 391 times)

If you're going to insult me for my lack of knowledge in Torque, get out of this topic.
Quote from: Console.log
Loading Add-On: Script_Me (CRC:1818850524)
Add-Ons/Script_Me/server.cs Line: 7 - Syntax error.
>>> Some error context, with ## on sides of error halt:
/Just an incredibly easy script made my KoopaScooper, BL_ID 9805.



function serverCmdMe(%client, %arg, %arg1, %arg2, %arg3, %arg4, %arg5, %arg6, %arg7, %arg8, %arg9, %arg10, %arg11)

{

  if(!%arg)

  {

    return()##;##

  }

  if(!%arg1)

  {

    messageAll('MsgForceAdmin', "\c2" @ %client.getPlayerName() @ " " @ %arg @ ".");

    return();

  }

  if(!%arg2)

  {

    messageAll('MsgForceAdmin', "\c2" @ %client.getPlayerName() @ " " @ %arg @ %arg1 @ ".");

    return();
>>> Error report complete.

ADD-ON "Script_Me" CONTAINS SYNTAX ERRORS
I have been working on this script for about a week and this is the same error I keep getting.
Is it because I'm using "!%var" wrong?
Am I just a terrible coder?

Using MsgForceAdmin will play the boop song for a start, so you might not want to do that.

Secondly, return isn't a function so it doesn't need the (), it should just be "return;"

Using MsgForceAdmin will play the boop song for a start, so you might not want to do that.

Secondly, return isn't a function so it doesn't need the (), it should just be "return;"
Ok, so that's what it was. My inexperience with Torque.
Thank you, Ephialtes.