As i'm learning TorqueScript, I've always had trouble with this line. I'm learning from ThinInvisible's old post, and I'm trying to create a roulette game in chat by myself. With this code failing, it makes the roulette game impossible, because of the clientCmdChatMessage being necessary to it. Here it is!
(Yes, I know chatbots are annoying unless they're only a calculator. Yes I will delete it after it works.)
package chatBot {
function clientCmdChatMessage(%a,%b,%c,%msg,%cp,%name,%cs,%msg) {
if (%msg $= "testing testing 123") {
if (%name $= "Ark7") {
commandToServer('messageSent',"Your testing is win!");
}
}
}
};
activatePackage(chatBot);