Last active
December 25, 2023 07:54
-
-
Save nizamparkerz/49b1b55eb5afd0301eb7b2c02acdd10f to your computer and use it in GitHub Desktop.
Mention type 2 with forwarded and small thumbnail
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const { | |
| AUDIO_DATA, SUDO | |
| } = require('../config'); | |
| const { | |
| Function, | |
| getBuffer, | |
| toAudio, | |
| addAudioMetaData | |
| } = require('../lib/') | |
| const logo = 'https://i.imgur.com/M1ekNyS.jpeg' | |
| var audios = ['https://i.imgur.com/bJXy5Lx.mp4','https://i.imgur.com/pY6KM3L.mp4','0https://i.imgur.com/pZtHmtO.mp4','https://i.imgur.com/1A52m9e.mp4','https://i.imgur.com/rpRd87U.mp4','https://i.imgur.com/uMCCHm3.mp4','https://i.imgur.com/1K2mk0A.mp4','https://i.imgur.com/XYMz3Gy.mp4','https://i.imgur.com/oLXfqYK.mp4','https://i.imgur.com/m8nil18.mp4','https://i.imgur.com/74t90FG.mp4','https://i.imgur.com/9wEyaQG.mp4','https://i.imgur.com/4urhcXz.mp4','https://i.imgur.com/cB07kbW.mp4','https://i.imgur.com/loTXfKe.mp4','https://i.imgur.com/IFWLr5G.mp4','https://i.imgur.com/FtbgXkx.mp4','https://i.imgur.com/6mcVMpP.mp4','https://i.imgur.com/3U3onAK.mp4','https://i.imgur.com/ib4Eh8I.mp4','https://i.imgur.com/GXvMsd2.mp4','https://i.imgur.com/SUdzLTG.mp4','https://i.imgur.com/9ZwNZfN.mp4','https://i.imgur.com/CsTfMfP.mp4','https://i.imgur.com/C2r9ZnK.mp4','https://i.imgur.com/CJ9k57h.mp4','https://i.imgur.com/DsWGqiB.mp4','https://i.imgur.com/VfWlH0G.mp4','https://i.imgur.com/zqnId0B.mp4','https://i.imgur.com/zcAIuE7.mp4','https://i.imgur.com/zs3OK4p.mp4','https://i.imgur.com/eZcw7nX.mp4','https://i.imgur.com/kDDqlsZ.mp4','https://i.imgur.com/r1z0f96.mp4','https://i.imgur.com/5oyn9Ph.mp4','https://i.imgur.com/CTSPX7w.mp4','https://i.imgur.com/3DBNYxH.mp4','https://i.imgur.com/roBWqvt.mp4','https://i.imgur.com/9AQALd2.mp4','https://i.imgur.com/R7kV5Ie.mp4','https://i.imgur.com/fiN7QmZ.mp4'] | |
| Function({ | |
| pattern: 'mention ?(.*)', | |
| fromMe: true, | |
| dontAddCommandList: true | |
| }, async (m, text) => { | |
| return; | |
| }); | |
| Function({ | |
| on: 'text', | |
| fromMe: false | |
| }, async (m, match, client) => { | |
| try { | |
| var men = m.mentionedJid[0].split('@')[0] | |
| } catch { | |
| return; | |
| } | |
| if (m.mentionedJid && m.mentionedJid[0] && SUDO.includes(men) || m.client.user.jid.includes(men)) { | |
| const audio = audios[Math.floor(Math.random() * audios.length)] | |
| const Audio = await getBuffer(audio) | |
| const options = {} | |
| options.contextInfo = { | |
| forwardingScore: 999, | |
| isForwarded: true, | |
| } | |
| let image = await getBuffer(AUDIO_DATA.split(';')[2]) | |
| let image_1 = await getBuffer('https://i.imgur.com/fj2WE83.jpeg') | |
| let tumb = image || image_1 | |
| let image2 = await getBuffer(logo) | |
| try { | |
| var res = await toAudio(Audio, 'mp4') | |
| } catch (e) { | |
| return await m.client.sendMessage(m.client.user.id, { | |
| text: `Error on parsing audio \n ${e}\n${audio}\delete this url from audio list` | |
| }) | |
| } | |
| return m.client.sendMessage(m.chat, { | |
| audio: res, | |
| mimetype: 'audio/mpeg', | |
| ptt: true, | |
| waveform: [90,20,0,0,0,0,90,0,10,0,90,0,0,0,0,20,90], | |
| contextInfo: { | |
| forwardingScore: 999, | |
| isForwarded: true, | |
| externalAdReply: { | |
| title: "ɴɪᴢᴀᴍ®™♂️", | |
| body: "don't touch here bruh 🤯", | |
| mediaType: 1, | |
| thumbnail: image2, | |
| renderLargerThumbnail: false, | |
| sourceUrl: 'https://instagram.com/am__nizam?igshid=YmMyMTA2M2Y=', | |
| showAdAttribution: false, | |
| } | |
| } | |
| }, { | |
| quoted: m.data | |
| }) | |
| } | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment