What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » Snarl

Snarl
Author: Message:
superaktieboy
New Member
*


Posts: 4
Joined: Jun 2010
RE: Snarl
right, i have the final "product", no clue how to bundle it and all, and to be quite frank, it's worthless since it requires other steps for installation.. first of all download snarl CMD and put the .exe in your windows folder (or anywhere else for that matter)
http://tlhan-ghun.de/?q=node/59

then download the icon attached and put it somewhere,

then copy and paste the following into a new script and edit the top 4 variables.

Javascript code:
/**
 * Just edit the variables.
 */

var boolDontNotifyOnBusy = true; // disable on Busy? true for yes, false for no
var boolNotifyOnSignOut = true; // notify when a contact signs out? true for yes, false for no
var sSnarlCMD = "C:\\Windows\\Snarl_CMD.exe"; // The location to snarl CMD, make sure you escape backslashes (type \\ instead of \)
var sMSNIcon = "C:\\Windows\\icon.png"; // [optional] The location to MSN icon.
 
 
// don't edit anything below this line unless you know what you're doing
 
var oChatWnds = {};
var boolMessengerLocked = false;
 
function OnEvent_ChatWndSendMessage(pChatWnd, sMessage) {
    oChatWnds[pChatWnd.Handle] = sMessage;
}
 
function OnEvent_ChatWndReceiveMessage(pChatWnd, sOrigin, sMessage, nKind) {
 
    if (oChatWnds[pChatWnd.Handle] === sMessage) {
        delete oChatWnds[pChatWnd.Handle];
    } else {
        if (!(Messenger.MyStatus == 4 && boolDontNotifyOnBusy == true)) {
            var re = new RegExp("\([0-9][0-9]:[0-9][0-9]\)", 'ig');
            if(re.exec(sOrigin.substring(0, 7))) {
                sOrigin = sOrigin.substring(7);
            }
            snarl_notify(sOrigin+"\n"+sMessage);
        }
    }
}
 
function OnEvent_ContactSignin(sEmail) {
    snarl_notify(getContactByEmail(sEmail).Name+"\nhas just signed in");
}
 
function OnEvent_ContactSignout(sEmail) {
    if(boolNotifyOnSignOut == true) {
        snarl_notify(getContactByEmail(sEmail).Name+"\nsigned out");
    }
}
 
function OnEvent_ChatWndDestroyed(pChatWnd) {
    delete oChatWnds[pChatWnd.Handle];
}
 
function snarl_notify(sMessage) {
    if(boolMessengerLocked == false && sSnarlCMD != '') {
        sSnarlIcon = '';
        if(sMSNIcon != '') {
            sSnarlIcon = ' "'+sMSNIcon+'"';
        }
        new ActiveXObject('WScript.Shell').Exec(sSnarlCMD+' snShowMessage 5 "Windows Live Messenger" "'+MsgPlus.RemoveFormatCodes(sMessage)+'"'+sSnarlIcon);
    }
}
 
function getContactByEmail(sEmail) {
    var Contacts = Messenger.MyContacts;
    return Contacts.GetContact(sEmail);
}
 
function OnEvent_MessengerUnlocked() {
    boolMessengerLocked = false;
}
 
function OnEvent_MessengerLocked() {
    boolMessengerLocked = true;
}



and matty, thanks for the help.. :)

.png File Attachment: icon.png (70.8 KB)
This file has been downloaded 133 time(s).

This post was edited on 06-22-2010 at 01:47 AM by superaktieboy.
06-22-2010 01:44 AM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
Snarl - by AnyaAlstreim on 05-12-2009 at 02:21 PM
RE: Snarl - by superaktieboy on 06-21-2010 at 06:26 PM
RE: Snarl - by matty on 06-21-2010 at 06:41 PM
RE: Snarl - by superaktieboy on 06-21-2010 at 08:29 PM
RE: Snarl - by matty on 06-21-2010 at 09:55 PM
RE: Snarl - by superaktieboy on 06-22-2010 at 01:09 AM
RE: Snarl - by superaktieboy on 06-22-2010 at 01:44 AM
RE: Snarl - by whiz on 06-22-2010 at 09:13 AM
RE: Snarl - by matty on 06-22-2010 at 12:58 PM


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On