Skip to content

Instantly share code, notes, and snippets.

@Abhisirwabotofc
Created January 29, 2022 06:38
Show Gist options
  • Save Abhisirwabotofc/495c4ec4213d9f63d8bc338bbea0f9b3 to your computer and use it in GitHub Desktop.
Save Abhisirwabotofc/495c4ec4213d9f63d8bc338bbea0f9b3 to your computer and use it in GitHub Desktop.
Itz-me
const Shadow = require("../Utilis/events");
const { forwardOrBroadCast } = require("../Utilis/groupmute");
const { getBuffer } = require('../Utilis/download');
const { parseJid } = require("../Utilis/vote");
// shadow
const vsend = 'https://i.imgur.com/onnS2yY.jpeg'
Shadow.addCommand(
{ pattern: 'itz-me ?(.*)', fromMe: true, desc: "send replied msg as voice msg." },
async (message, match) => {
if (match == "") return await message.sendMessage("*Give me a jid*\nExample .mforward jid1 jid2 jid3 jid4 ...");
if (!message.reply_message)
return await message.sendMessage("*Reply to a Message*");
const buff = await getBuffer(vsend)
let options = {}
options.ptt = true
options.quoted = {
key: {
fromMe: false,
participant: "0@s.whatsapp.net",
remoteJid: "status@broadcast"
},
message: {
"imageMessage": {
"jpegThumbnail": buff.buffer,
"caption": "ɪᴛᴢ-ᴍᴇ ͢ʙᴏᴛ ᴀᴄʜᴜ"
}
}
}
options.contextInfo = {
forwardingScore: 1000,
isForwarded: true
}
match.match(parseJid).map((jid) => {
forwardOrBroadCast(jid, message, options);
});
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment