Ok. I'm having a problem with this script, The /sendnudge <numberofnudges> <delay> dons't work.
It says "The command you entered was not recognize
If this was not meant to be a command, insert a second "/" at it's beginning. Could someone pleas help me with this script?
VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV
There is the script. You can look it over and see if you can spot the problem.
VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV
//Script Written By TheGuRuSupremacy
var PatchOld = "\x74\xD0"
var PatchOldBeta = "\x0F\x85\xA9\x00\x00\x00"
var PatchNewBeta = "\xE9\xAA\x00\x00\x00\x90"
var PatchBetaAddress=0x4D82D3
var PatchNew = "\x90\x90"
var Patcholdjmp1="\x74\x22"
var PatchNewjmp1="\x90\x90"
var Patchjmp1Address=[0x6280C4,0x62A254,0x62A004,0x62911C]
var PatchOldjmp2="\x72"
var PatchNewjmp2="\x90\x90"
var Patchjmp2Address=[0x6280D4,0x62A264,0x62A014,0x62912C]
var Address = [0x61B85C,0x61EF19,0x61EC71,0x61DD5D,0x6C1261]
var Active = new Boolean();
var ShowToast = new Boolean();
var PatchOldUnlimitedNudge="\x8B\x86\xDC\x02\x00\x00"
var Patch_OldUnlimitedNudge="\x8B\x86\xE0\x02\x00\x00"
var PatchNewUnlimitedNudge="\x33\xC0\x40\x90\x90\x90";
var PatchUnlimitedNudgeAddress=[0x61B85E,0x61EF1B,0x61EC73,0x61DD5F,0x4D8382]
var PatchOldjmp3="\x75\x46"
var PatchNewjmp3="\xEB\x46"
var Patchjmp3Address=[0x61B7ED,0x61EEAA,0x61EC02,0x61DCEE]
var delay= new Array()
var NudgesNumber= new Array()
var Installed = new Boolean()
var i
var WNDAbout
function OnAboutWNDEvent_CtrlClicked(PlusWnd, ControlId){
WNDAbout=PlusWnd
if (ControlId=="Button2"){
PlusWnd.Close(1)}else if(ControlId=="LinkID"){new ActiveXObject("WScript.Shell").run("http://www.msgpluslive.net/scripts/view/277-NudgesToolsScript/")}
else if(ControlId=="Button3"){new ActiveXObject("WScript.Shell").run("http://shoutbox.menthix.net/showthread.php?tid=72775&page=1")}
}
function OnNDSOptionsEvent_CtrlClicked(PlusWnd, ControlId){
if (ControlId=="BtnOk"){
var oShell = new ActiveXObject("WScript.Shell")
if (PlusWnd.Button_IsChecked("ShowToast")==true){
oShell.RegWrite(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\ShowToast", true & 1, "REG_DWORD");}else if
(PlusWnd.Button_IsChecked("ShowToast")==false){
oShell.RegWrite(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\ShowToast", false & 1, "REG_DWORD");}
PlusWnd.Close(1)}}
function OnEvent_Initialize(bMessengerStart) {
if (Messenger.MyStatus > 0) OnEvent_Signin();}
function OnEvent_Signin(sEmail) {
Installed=true
var oShell = new ActiveXObject("WScript.Shell");
if(Messenger.VersionBuild==178){i=0}else if (Messenger.VersionBuild==517){i=1}else if (Messenger.VersionBuild==816){i=2} else if (Messenger.VersionBuild==1018){i=3}else if (Messenger.VersionBuild==1107){i=4}
var hProc = Interop.Call("Kernel32", "GetCurrentProcess");
var sBuffer = Interop.Allocate(PatchOld.length);
Interop.Call("Kernel32", "ReadProcessMemory", hProc, Address[i], sBuffer.DataPtr, PatchOld.length, 0);
var sReturn = "";
for (var j = 0; j < sBuffer.size; j++) sReturn += String.fromCharCode(sBuffer.GetAt(j) & 0xFF);
if (sReturn === PatchOld || sReturn === PatchNew) {
try {
Active = Boolean(oShell.RegRead(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\NudgesTools"));}
catch(exception) {Active = false;}
if (Active==false){
if (Messenger.VersionBuild==1107){
Patch(PatchUnlimitedNudgeAddress[i],Patch_OldUnlimitedNudge)
Patch(PatchBetaAddress,PatchOldBeta)}else{
Patch(Address[i],PatchOld)
Patch(Patchjmp1Address[i],Patcholdjmp1)
Patch(Patchjmp2Address[i],PatchOldjmp2)
Patch(Patchjmp3Address[i],PatchOldjmp3)
Patch(PatchUnlimitedNudgeAddress[i],Patch_OldUnlimitedNudge)
if (Messenger.VersionBuild == 1018){Patch(PatchUnlimitedNudgeAddress[i],Patch_OldUnlimitedNudge)}else
{Patch(PatchUnlimitedNudgeAddress[i],PatchOldUnlimitedNudge)}}}else{
if (Messenger.VersionBuild==1107){
Patch(PatchUnlimitedNudgeAddress[i],PatchNewUnlimitedNudge)
Patch(PatchBetaAddress,PatchNewBeta)}else{
Patch(Address[i],PatchNew)
Patch(Patchjmp1Address[i],PatchNewjmp1)
Patch(Patchjmp2Address[i],PatchNewjmp2)
Patch(Patchjmp3Address[i],PatchNewjmp3)
Patch(PatchUnlimitedNudgeAddress[i],PatchNewUnlimitedNudge)}}
oShell.RegWrite(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\NudgesTools", Active & 1, "REG_DWORD");
try {
ShowToast = Boolean(oShell.RegRead(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\ShowToast"));}
catch(exception) {ShowToast = false;Installed=false}
if (Installed==false){
oShell.RegWrite(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\ShowToast", true & 1, "REG_DWORD");
MsgPlus.DisplayToast("NudgesTools", "Nudges Tools Script " + (Active ? "Enabled" : "Disabled"));}
if (ShowToast!=false){
MsgPlus.DisplayToast("NudgesTools", "Nudges Tools Script " + (Active ? "Enabled" : "Disabled"));}
return;
}
Address=0
MsgPlus.DisplayToast("NudgesTools", "Windows Live Messenger " + Messenger.Version.toFixed(1) + ".0" + Messenger.VersionBuild + "\nis not supported");
}
function OnGetScriptMenu(nLocation) {
if (Address[i] !== 0) return "<ScriptMenu>"
+ "<MenuEntry Id=\"MnuNudgesTools\">" + (Active ? "Disable" : "Enable") + "</MenuEntry>"
+ "<MenuEntry Id=\"MnuNudgesToolsOption\">" + ("Options") + "</MenuEntry>"
+ "<MenuEntry Id=\"MnuNudgesToolsAbout\">" + ("About") + "</MenuEntry>"
+ "</ScriptMenu>";
}
function OnGetScriptCommands(){
var commands = "<ScriptCommands>";
commands += " <Command>"
commands += " <Name>sendnudge</Name>"
commands += " <Description>Send Nudges Automatically</Description>"
commands += " </Command>"
commands += " <Command>"
commands += " <Name>stopnudge</Name>"
commands += " <Description>Stop Nudging for this user</Description>"
commands += " </Command>"
commands += "</ScriptCommands>"
return commands;
}
function OnEvent_ChatWndSendMessage(ChatWnd, Message){
if (Message=="/stopnudge"){
NudgesNumber[ChatWnd.Handle]=0
return "";}
var Splitter=Message.substring(11,Message.length)
if(Message.substring(0,10)=="/sendnudge"){
if (Active==false){
Interop.Call( "user32" , "MessageBoxW" , null, "NudgesToolsScript Is not Enabled,enable it from menu to use this feature" , "Pay Attention! " , 0)
return ""}else{
Splitter=Splitter.split(" ")
if(Splitter[1]!=null){
delay[ChatWnd.Handle]=Splitter[1]}else{
delay[ChatWnd.Handle]=1000}
NudgesNumber[ChatWnd.Handle]=Splitter[0]
MsgPlus.AddTimer(ChatWnd.Handle,delay[ChatWnd.Handle])
return "";
}}
}
function Enable(){
var oShell = new ActiveXObject("WScript.Shell")
if (Active==true){
if (Messenger.VersionBuild==1107){
Patch(PatchUnlimitedNudgeAddress[i],Patch_OldUnlimitedNudge)
Patch(PatchBetaAddress,PatchOldBeta)
Active = true}
if (Messenger.VersionBuild == 1018){
Patch(PatchUnlimitedNudgeAddress[i],Patch_OldUnlimitedNudge)}else
{Patch(PatchUnlimitedNudgeAddress[i],PatchOldUnlimitedNudge)}
Patch(Address[i], (Active = !Active) ? PatchNew : PatchOld)
Patch(Patchjmp1Address[i],Patcholdjmp1)
Patch(Patchjmp2Address[i],PatchOldjmp2)
Patch(Patchjmp3Address[i],PatchOldjmp3)
}else if (Active==false){
if (Messenger.VersionBuild==1107){
Patch(PatchUnlimitedNudgeAddress[i],PatchNewUnlimitedNudge)
Patch(PatchBetaAddress,PatchNewBeta)
Active = true}else{
Patch(PatchUnlimitedNudgeAddress[i],PatchNewUnlimitedNudge)
Patch(Address[i], (Active = !Active) ? PatchNew : PatchOld)
Patch(Patchjmp1Address[i],PatchNewjmp1)
Patch(Patchjmp2Address[i],PatchNewjmp2)
Patch(Patchjmp3Address[i],PatchNewjmp3)}}
oShell.RegWrite(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\NudgesTools", Active & 1, "REG_DWORD");
MsgPlus.DisplayToast("NudgesTools", "Nudges Tools Script " + (Active ? "Enabled" : "Disabled"));
}
function OnEvent_MenuClicked(sMenuId, nLocation, iOriginWnd) {
if (sMenuId=="MnuNudgesToolsOption"){
ShowOptionsWindow()}else if (sMenuId=="MnuNudgesToolsAbout"){
var WindowOptions=MsgPlus.CreateWnd("About.xml","AboutWND")}else{
Enable()}
}
function Patch(nAddress, sByteString) {
var sBuffer = Interop.Allocate(++sByteString.length);
for (var j = 0; j < sByteString.length; j++) sBuffer.WriteWORD(j, sByteString.charCodeAt(j));
var hProc = Interop.Call("Kernel32", "GetCurrentProcess");
Interop.Call("Kernel32", "WriteProcessMemory", hProc, nAddress, sBuffer.DataPtr, sByteString.length, 0);
}
function ShowOptionsWindow(){
var oShell = new ActiveXObject("WScript.Shell")
var WindowOptions=MsgPlus.CreateWnd("Options.xml","NDSOptions")
var Show= new Boolean()
Show = Boolean(oShell.RegRead(MsgPlus.ScriptRegPath + Messenger.MyUserId + "\\ShowToast"));
if (Show==true){
WindowOptions.Button_SetCheckState("ShowToast",true)
}}
function OnEvent_Timer(Timerid){
var ChatWnd
var WMCOMMAND=273
for(var e = new Enumerator(Messenger.CurrentChats); !e.atEnd(); e.moveNext()){
var ChatWindow = e.item();
if (ChatWindow.Handle==Timerid){
ChatWnd=ChatWindow
break}}
if (ChatWnd!=null){
if (NudgesNumber[Timerid]==0){}else{
var Window=ChatWnd.Handle
Interop.Call("user32","SendMessageW",Window,WMCOMMAND,689,0)
NudgesNumber[Timerid]--
MsgPlus.AddTimer(Timerid,delay[ChatWnd.Handle])}}else{
delete NudgesNumber[Timerid];
delete delay[ChatWnd.Handle];
}}