It appears that Plus! parses messages twice. How come?
For instance if you have this code:
code:
function OnEvent_ChatWndSendMessage(oChatWnd, sMessage){
Debug.Trace(sMessage);
}
If the sent message is (!VER) command we all know that Plus! will convert that the the version information.
However if you have this code:
code:
function OnEvent_ChatWndSendMessage(oChatWnd, sMessage){
Debug.Trace(sMessage);
return oChatWnd.EditText.replace(/\(!VER\)/g, '(!VER)\nthis is a test');
}
You would expect that the returned message should be
(!VER)
this is a test
However it isn't Plus! will parse the message again after that function is complete.
Plus! should, in all reality, only parse the message after each script has completed that function if it exists. This will save CPU cycles.
I know it isn't visible to the naked eye or can't appear to be taking any more time to parse twice but it makes the poor CPU work that much harder.