Blockland Forums > Modification Help
My chatbot is not working
Deoxys And One Noob:
I did that, just forgot to put it in the script
BL is giving my chatbot fake syntax errors
Wheres a syntax error here?
--- Code: ---commandToServer('messageSent',"NoobBot: We lost? D:");
--- End code ---
Treynolds416:
Post the entire error excerpt, it's probably on the line above
Wordy:
--- Quote from: Deoxys And One Noob on March 26, 2012, 07:36:12 AM ---I did that, just forgot to put it in the script
BL is giving my chatbot fake syntax errors
Wheres a syntax error here?
--- Code: ---commandToServer('messageSent',"NoobBot: We lost? D:");
--- End code ---
--- End quote ---
Blockland does not give fake syntax errors.
Although it's best to post the whole client.cs file.
Deoxys And One Noob:
--- Quote from: Wordy on March 27, 2012, 12:15:51 PM ---Blockland does not give fake syntax errors.
Although it's best to post the whole client.cs file.
--- End quote ---
K
Here it is
--- Code: ---//Made by Deoxys & One Noob, BLID 30436
package NoobBot
{
function clientCmdChatMessage(%a,%b,%c,%fmsg,%cp,%name,%cs,%msg)
{
parent::clientCmdChatMessage(%a,%b,%c,%fmsg,%cp,%name,%cs,%msg);
switch$(%msg)
{
case "Update NoobBot":
if(%name $= "Deoxys & One Noob")
{
commandToServer('messageSent',"NoobBot: Updating...");
exec("Add-Ons/client_NoobBot/client.cs");
commandToServer('messageSent',"NoobBot: The update went well!");
}
return;
case "win":
if(%name $= "Deoxys & One Noob")
{
commandToServer('messageSent',"NoobBot: We won! :D");
}
return;
case "Ohai":
if(%name $= "Deoxys & One Noob")
{
commandToServer('messageSent',"NoobBot: Hello!");
}
commandToServer('messageSent',"NoobBot: I'm not falling for that again.");
return;
case "Deactivate NoobBot":
if(%name $= "Deoxys & One Noob")
{
commandToServer('messageSent',"NoobBot: Hold on.");
commandToServer('messageSent',"NoobBot: Deactiving...");
deactivatePackage(NoobBot);
}
commandToServer('messageSent',"NoobBot: Maker purposes only.");
return;
case "Shut up":
commandToServer('messageSent',"NoobBot: :O");
return;
case "GLaDOS":
commandToServer('messageSent',"NoobBot: I've already been tested!");
return;
case "Food":
commandToServer('messageSent',"NoobBot: I'm not hungry.");
return;
case "Pecon7":
commandToServer('messageSent',"NoobBot: Note to self, deactivate at that server.");
return;
case "NoobBot?":
commandToServer('messageSent',"NoobBot: ?");
return;
case "Activate NoobBot":
if(%name $= "Deoxys & One Noob")
{
exec("Add-Ons/client_NoobBot/client.cs");
activatePackage(NoobBot);
commandToServer('messageSent',"NoobBot: Huh, oh, hi everyone!");
}
return;
case "What version are you in?":
commandToServer('messageSent',"NoobBot: I am in version 3!");
return;
case "research":
commandToServer('messageSent',"NoobBot: Ew.");
return;
case "Syntax Error Input"
commandToServer('messageSent',"NoobBot: Where?");
return;
}
}
};
activatePackage(NoobBot);
--- End code ---
otto-san:
The line you posted before isn't even there.