What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » is there somthing wrong with this script..?

is there somthing wrong with this script..?
Author: Message:
joosh00
New Member
*

Avatar

Posts: 12
30 / Male / Flag
Joined: Mar 2008
O.P. Huh?  is there somthing wrong with this script..?
Well ive started to creat this script, it sends random jokes when you tell it too. it all works fine exept for 1 bit, that bit is when you open a conversation and you click the script button its there but when i try and click on it it doesnt work, but it works if you type in the command. anyway please help...

Here is the script...

code:
//This script is created by Josh Brand
//Version - 1.0
//Released
//Last Updated
//Created for the Messenger Plus!

/*Changelog
0.1 - Script Created
0.2 - Made it functional
0.3 - Fixed most spelling/grammar mistakes
0.4 - Fixed bugs and some more grammar mistakes
0.5 - Fixed "unidentified" error =D (first real bug solved!)
0.6 - Added other insults!
0.7 - Added about window! =D
1.0 - Final Version! Finally!
*/

var sArray = new Array();
sArray[0] = "How did the blonde try to kill the bird? She threw it off a cliff.";
sArray[1] = "Did you hear about the blonde secretary who cut her fingers off so that she could write short hand?";
sArray[2] = "Your mom's so fat that Nasa octually orbits her.";
sArray[3] = "I'm not a steady drinker - my hand shakes too much.'";
sArray[4] = "Yo momma so ugly, she make blind muthafuckas cry.";
sArray[5] = "1 Tequila, 2 Tequila, 3 Tequila, Floor.";
sArray[6] = "How do you start an onion race?   Onion marks! Get set! Go!";
sArray[7] = "Your mom.";
sArray[8] = "Your mom owes me money, you douche!";
sArray[9] = "Just cause you went to prom with Merv the Perv.";
sArray[10] = "Your mom is like a brick, flat on both sides and gets laid by Mexicans.";
sArray[11] = "Your Mom has a really nice hat...";
sArray[12] = "Don't worry, Your Mom is still a virgin. You were a backdoor baby.";
sArray[13] = "Your mom is poop.";


function OnEvent_ChatWndSendMessage(ChatWnd, Message){
    if(Message.substr(0,8).toLowerCase()=="/jokes"){
        var i = Math.floor((Math.random()*(sArray.length-1)));
        return "[c=blue]"+sArray[i]+"[/c]";
    }

}

function OnGetScriptCommands(){
    var commands = '<ScriptCommands>';
        commands+='<Command>';
            commands+='<Name>Jokes</Name>';
            commands+='<Description>Sends a joke</Description>';
        commands+='</Command>';
        commands+='</ScriptCommands>';
    return commands;
}

function OnEvent_MenuClicked(MenuItemId, Location, OriginWnd){
    if(MenuItemId=="jk"){
        OriginWnd.SendMessage(OnEvent_ChatWndSendMessage("", "/jokes"));
    }
    if(MenuItemId=="about"){
        WndAbout = MsgPlus.CreateWnd("WndAbout.xml", "WndAbout");
    }
}

function OnGetScriptMenu(nLocation){
    var ScriptMenu = "<ScriptMenu>\n";
    if(nLocation===2){
        ScriptMenu    +=    "<MenuEntry Id=\"JK\">Jokes</MenuEntry>";
        ScriptMenu    +=    "<Separator/>";
    }
    ScriptMenu    +=    "<MenuEntry Id=\"about\">About</MenuEntry>";
    ScriptMenu    += "</ScriptMenu>";
    return ScriptMenu;
}


oh and 1 more thing... the about box works fine.

Thanks ~joosh00~
03-26-2008 04:34 PM
Profile E-Mail PM Find Quote Report
« Next Oldest Return to Top Next Newest »

Messages In This Thread
is there somthing wrong with this script..? - by joosh00 on 03-26-2008 at 04:34 PM
RE: is there somthing wrong with this script..? - by pollolibredegrasa on 03-26-2008 at 04:45 PM
RE: is there somthing wrong with this script..? - by joosh00 on 03-26-2008 at 04:49 PM
RE: is there somthing wrong with this script..? - by Jesus on 03-26-2008 at 05:09 PM
RE: is there somthing wrong with this script..? - by joosh00 on 03-26-2008 at 05:42 PM
RE: is there somthing wrong with this script..? - by joosh00 on 03-27-2008 at 12:03 AM
RE: is there somthing wrong with this script..? - by pollolibredegrasa on 03-27-2008 at 12:10 AM
RE: is there somthing wrong with this script..? - by joosh00 on 03-27-2008 at 12:16 AM
RE: is there somthing wrong with this script..? - by CookieRevised on 03-27-2008 at 01:15 AM
RE: is there somthing wrong with this script..? - by joosh00 on 03-27-2008 at 01:32 AM
RE: is there somthing wrong with this script..? - by Naruto-SR on 03-27-2008 at 01:51 AM
RE: is there somthing wrong with this script..? - by joosh00 on 03-27-2008 at 02:07 AM
RE: is there somthing wrong with this script..? - by roflmao456 on 03-27-2008 at 02:32 AM
RE: is there somthing wrong with this script..? - by joosh00 on 03-27-2008 at 02:34 AM


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