code:
var x_img = 1;
function OnEvent_Timer(sTimerId) {
if (sTimerId == "slider" && Messenger.MyStatus == 3){
x_img++;
if (x_img == 4) {
x_img = 0;
Messenger.MyDisplayPicture = MsgPlus.ScriptFilesPath + "\\images\\online.jpg";
}
else Messenger.MyDisplayPicture = MsgPlus.ScriptFilesPath + "\\images\\online" + x_img + ".jpg";
MsgPlus.AddTimer("slider", 20000);
}
}
Edit: Don't hate me because I streamline code