Well I made this code/someone helped me with it. Anyway what it does is that everytime someone say "Hey" to me I reply "Hi <their name>! Time to chat again
". Now if the user says "Hey" again I want me to not reply back again. This is my code:
code:
function OnEvent_ChatWndReceiveMessage(ChatWnd, Origin, Message, MessageKind)
{
var variable = 0;
}
if (Message.match("Hey") && variable == 0)
{
ChatWnd.SendMessage('Hi ' + Origin + '! Time to chat again ');
variable = 1;
}
else
{
ChatWnd.SendMessage(':yay:');
}
function OnEvent_Uninitialize(MessengerExit)
{
}
And the :yay: thingy is just there so I know it works, I will delete that later when it works
Just one problem... it doesn't work
So please help