Audible PM v1.0

Started by Bigguy, September 07, 2006, 07:45:15 PM

Previous topic - Next topic

URPG

Can i change the sound that is played?

Can users switch it on/off in their Profile?

Bigguy

Version 2 members should be able to switch it on/off. v1.5 members will only hear it once or twice then it shuts off. Yes you should be able to change the file and 1 small line of code. I don't have the code open right now or I could tell you what that is.

URPG

There is no version 2 (yet)? :(

Bigguy

No not yet but it is being worked on.

URPG

*evil smile*

Hurry up, or my members may go insane by the sound ;)

Bigguy

Have you installed version 1.5 yet. ??? That version only lets the "You've got mail" sound go off 1 or 2 times then quits.

URPG

Yes, it's 1.5 that i have installed, and no complains... not yet anyway, i know my people...

Xarcell

This is a cool mod. I enjoyed it. However it doesn't seem to work every time.

It only seems to work on the first PM and that's it. Isn't it supposed to say "you've got mail" everytime you get a new PM?

Bigguy

Yes everytime a new PM comes in it should sound off. The 1.5 version only sounds off once or twice and the first version goes off until your read the email.

Xarcell

For me it doesn't sound off on each new PM. Only the very first one i got. Not for any after...

Bigguy

I haven't heard of this happening before. can you uninstall and re-install it to see what happens.

Xarcell

I uninstalled and reinstalled. It doesn't work at all...

Bigguy

You are using v1.5 ??? Check to see if the edits were taken out of the index.template.php file. There is no reason why it shouldn't work unless the gotmail.swf was removed or another mod changed the code somewhere.

Xarcell

I looked in the template and here's what I found:

if ((isset($_SESSION['unread_sound']) && $_SESSION['unread_sound'] < $context['user']['unread_messages']) || (!isset($_SESSION['unread_sound']) && $context['user']['unread_messages'] >= 1))
{
echo '
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="     http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="0" height="0" id="gotmail" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="gotmail.swf" />
<param name="quality" value="high" />
<param name="bgcolor" value="#ffffff" />
<embed src="gotmail.swf" quality="high" bgcolor="#ffffff" width="1" height="1" name="gotmail" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>';

// Save a session so it wont loop
$_SESSION['unread_sound'] = $context['user']['unread_messages'];
}     if($context['TPortal']['showtop']==1)


That doesn't look right so I changed it to:

if ((isset($_SESSION['unread_sound']) && $_SESSION['unread_sound'] < $context['user']['unread_messages']) || (!isset($_SESSION['unread_sound']) && $context['user']['unread_messages'] >= 1))
{
echo '
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="     http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="0" height="0" id="gotmail" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="gotmail.swf" />
<param name="quality" value="high" />
<param name="bgcolor" value="#ffffff" />
<embed src="gotmail.swf" quality="high" bgcolor="#ffffff" width="1" height="1" name="gotmail" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
</object>';
}
// Save a session so it wont loop
$_SESSION['unread_sound'] = $context['user']['unread_messages'];
     if($context['TPortal']['showtop']==1)


and now it works fine. BTW, I was using the TP version...

Xarcell

Any chance we can get someone to make a "you've got messages" voiceover?


Bigguy


Gobo

here are some new sound styles I have made in SWF file format for anyone wanting to use it

download zip pack here

Simply rename the file you wish to use and replace on your server accordingly

enjoy

PS: not to mod maker - if u can also put this on the 1st post so that users have more alternatives :)

Bigguy

You DON"T want me to put it on the first post ???

Gobo

lool that was a typo i meant "note" to the mod maker

yup put it in the 1st post - feel free to use

ill be posting more files over time so that this mod has like a lot of variety :D

Xarcell

I tested your TP install and it does not install properly. You might want to check your xml.

Advertisement: