What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » [Request] Alert on specific message

Pages: (3): « First « 1 [ 2 ] 3 » Last »
[Request] Alert on specific message
Author: Message:
glargle
New Member
*


Posts: 11
Joined: Jul 2007
O.P. RE: [Request] Alert on specific message
Thanks, but I'm still not getting any sound. I'm using:

code:
MsgPlus.PlaySound("C:\\Program Files\\Messenger Plus! Live\\Scripts\\Wakealert\\wakeupfaggot.mp3");
07-18-2007 04:58 AM
Profile E-Mail PM Find Quote Report
davidpolitis
Full Member
***


Posts: 371
Reputation: 16
Joined: Aug 2006
RE: RE: [Request] Alert on specific message
quote:
Originally posted by glargle
Thanks, but I'm still not getting any sound. I'm using:

code:
MsgPlus.PlaySound("C:\\Program Files\\Messenger Plus! Live\\Scripts\\Wakealert\\wakeupfaggot.mp3");

Try the following :P

code:
MsgPlus.PlaySound("\C:\\Program Files\\Messenger Plus! Live\\Scripts\\Wakealert\\wakeupfaggot.mp3");

You could also use a toast to play the sound and say what word from the array the received message contained if you really want to :P

This post was edited on 07-18-2007 at 07:22 AM by davidpolitis.
07-18-2007 06:39 AM
Profile PM Find Quote Report
Spunky
Former Super Mod
*****

Avatar

Posts: 3658
Reputation: 61
35 / Male / Flag
Joined: Aug 2006
RE: [Request] Alert on specific message
Just to explain... a relative path is relative to the scripts folder so it would be easier to copy the sound file there and just use the filename in the script.

An absoloubte path is from the drive letter, but to show the script that it's an absoloubte path, you need to put a single slash at the beginning of the path.
<Eljay> "Problems encountered: shit blew up" :zippy:
07-18-2007 12:25 PM
Profile PM Find Quote Report
davidpolitis
Full Member
***


Posts: 371
Reputation: 16
Joined: Aug 2006
RE: RE: [Request] Alert on specific message
quote:
Originally posted by SpunkyLoveMuff
Just to explain... a relative path is relative to the scripts folder so it would be easier to copy the sound file there and just use the filename in the script.

An absoloubte path is from the drive letter, but to show the script that it's an absoloubte path, you need to put a single slash at the beginning of the path.

:$ sorry, knew you could do that with toasts, but not with this, not really good at JS.
07-18-2007 01:36 PM
Profile PM Find Quote Report
glargle
New Member
*


Posts: 11
Joined: Jul 2007
O.P. RE: [Request] Alert on specific message
I'm messing up something because it's still not working. I've tried the relative and absoloute things but still fails :\

Here's the whole thing, I must be doing something wrong.

code:
var word = new Array(
"!wake",
"!wakeup",
"!wakewake"
);
var re = RegExp("\b"+word.join("\b|\b")+"\b","i");

function OnEvent_ChatWndReceiveMessage(ChatWnd,Origin,Message,MessageKind){
if(Origin != Messenger.MyName && re.test(Message)){
MsgPlus.PlaySound("\C:\\Program Files\\Messenger Plus! Live\\Scripts\\Wakealert\\wakeupfaggot.mp3");
}
}
07-18-2007 02:50 PM
Profile E-Mail PM Find Quote Report
Spunky
Former Super Mod
*****

Avatar

Posts: 3658
Reputation: 61
35 / Male / Flag
Joined: Aug 2006
RE: [Request] Alert on specific message
use
code:
MsgPlus.ScriptFilesPath+"\\wakeupfaggot.mp3"

and place the mp3 in the script folder (Wakealert folder)
<Eljay> "Problems encountered: shit blew up" :zippy:
07-18-2007 03:47 PM
Profile PM Find Quote Report
glargle
New Member
*


Posts: 11
Joined: Jul 2007
O.P. RE: [Request] Alert on specific message
Still nothing. Does it work for you guys or is it a problem on my end?
07-18-2007 04:00 PM
Profile E-Mail PM Find Quote Report
Spunky
Former Super Mod
*****

Avatar

Posts: 3658
Reputation: 61
35 / Male / Flag
Joined: Aug 2006
RE: [Request] Alert on specific message
try seeing what the function returns...
code:
Debug.Trace(MsgPlus.PlaySound("wakeupfaggot.mp3));
If it's false, then it won't play... I just tried it a few times with a test script and it works when it wants tbh
<Eljay> "Problems encountered: shit blew up" :zippy:
07-18-2007 04:20 PM
Profile PM Find Quote Report
glargle
New Member
*


Posts: 11
Joined: Jul 2007
O.P. RE: [Request] Alert on specific message
When I change that, the debugger says

code:
Error: Expected ')' (code: -2146827282)
       File: Wakealert.js. Line: 11.

I don't know what I'm messing up.
07-18-2007 04:28 PM
Profile E-Mail PM Find Quote Report
Spunky
Former Super Mod
*****

Avatar

Posts: 3658
Reputation: 61
35 / Male / Flag
Joined: Aug 2006
RE: [Request] Alert on specific message
my mistake...

forgot the end quote around the file name :$
<Eljay> "Problems encountered: shit blew up" :zippy:
07-18-2007 05:14 PM
Profile PM Find Quote Report
Pages: (3): « First « 1 [ 2 ] 3 » Last »
« Next Oldest Return to Top Next Newest »


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