From 0ab2f9e7290d1fe4e777da4235d7318c04c3f9bc Mon Sep 17 00:00:00 2001
From: March 7th <71698422+aiko-chan-ai@users.noreply.github.com>
Date: Sun, 17 Apr 2022 20:42:00 +0700
Subject: [PATCH] update
---
Document/User.md | 23 +++++++++++++++++++++++
package-lock.json | 18 +++++++++---------
package.json | 2 +-
3 files changed, 33 insertions(+), 10 deletions(-)
diff --git a/Document/User.md b/Document/User.md
index 11f71a0..7e90c2f 100644
--- a/Document/User.md
+++ b/Document/User.md
@@ -183,16 +183,39 @@ Update soon ~
New: You can now add custom images for RPC !
> Tutorial:
+
+New Method - require ver 1.1.1 - latest
+
+```js
+const RPC = require('discord-rpc-contructor');
+const r = new RPC.Rpc()
+ .setApplicationId('817229550684471297')
+ .setType(0)
+ .setState('State')
+ .setName('Name')
+ .setDetails('Details')
+ .setAssetsLargeImage(await RPC.getImageCustom(imageURL1)) // Custom image
+ .setAssetsLargeText('Youtube')
+ .setAssetsSmallImage(await RPC.getImageCustom(imageURL2)) // Custom image
+ .setAssetsSmallText('Bot')
+client.user.setActivity(r.toDiscord().game);
+```
+
+Old Method
+
+ Step 1: Send photos by embed.thumbnail
+
```js
const embed = new MessageEmbed().setThumbnail('image url');
const msg = await channel.send({ embeds: [embed] });
```
+ Step 2: Get proxyURL from message.embeds[0].thumbnail.proxyURL
+
```js
const proxyURL = msg.embeds[0].thumbnail.proxyURL;
```
+ Step 3: Put the URL in the constructor
+
```js
const RPC = require('discord-rpc-contructor');
const r = new RPC.Rpc()
diff --git a/package-lock.json b/package-lock.json
index 7750446..f28d6c3 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "discord.js-selfbot-v13",
- "version": "1.3.7",
+ "version": "1.3.9",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "discord.js-selfbot-v13",
- "version": "1.3.7",
+ "version": "1.3.9",
"license": "GNU General Public License v3.0",
"dependencies": {
"@discordjs/builders": "^0.12.0",
@@ -21,7 +21,7 @@
"chalk": "^4.1.2",
"discord-api-types": "^0.31.1",
"discord-bettermarkdown": "^1.1.0",
- "discord-rpc-contructor": "^1.1.0",
+ "discord-rpc-contructor": "^1.1.1",
"discord.js": "^13.6.0",
"form-data": "^4.0.0",
"json-bigint": "^1.0.0",
@@ -4470,9 +4470,9 @@
"integrity": "sha512-UbNg+sO//W3gmEUrzAZ5klDIaVP8Vwnnt0cpqK+5b38/XqGy4mFXv6sdtYZrK+uFow3R4yWzTHMFP9wFF2QHXw=="
},
"node_modules/discord-rpc-contructor": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/discord-rpc-contructor/-/discord-rpc-contructor-1.1.0.tgz",
- "integrity": "sha512-QPRD2nUSDh2P5YqNvydVftC1OEVb5PC7G+98b96FzCE9UZ5tTf1zc1YK08KM9sAC5APKlukyLHYhCJ3kzVU6RA==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/discord-rpc-contructor/-/discord-rpc-contructor-1.1.1.tgz",
+ "integrity": "sha512-tOEY9lnVhuDSD1FXT5szmwlVyYu+D7tIwKcWz88kRsCbGDrrquxfW9y8ZTv1YcPYjNq72jNJkSQhbhntLIarpg==",
"dependencies": {
"node-fetch": "^2.6.7"
}
@@ -16431,9 +16431,9 @@
"integrity": "sha512-UbNg+sO//W3gmEUrzAZ5klDIaVP8Vwnnt0cpqK+5b38/XqGy4mFXv6sdtYZrK+uFow3R4yWzTHMFP9wFF2QHXw=="
},
"discord-rpc-contructor": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/discord-rpc-contructor/-/discord-rpc-contructor-1.1.0.tgz",
- "integrity": "sha512-QPRD2nUSDh2P5YqNvydVftC1OEVb5PC7G+98b96FzCE9UZ5tTf1zc1YK08KM9sAC5APKlukyLHYhCJ3kzVU6RA==",
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/discord-rpc-contructor/-/discord-rpc-contructor-1.1.1.tgz",
+ "integrity": "sha512-tOEY9lnVhuDSD1FXT5szmwlVyYu+D7tIwKcWz88kRsCbGDrrquxfW9y8ZTv1YcPYjNq72jNJkSQhbhntLIarpg==",
"requires": {
"node-fetch": "^2.6.7"
}
diff --git a/package.json b/package.json
index 6d07ae6..1bd8b87 100644
--- a/package.json
+++ b/package.json
@@ -57,7 +57,7 @@
"chalk": "^4.1.2",
"discord-api-types": "^0.31.1",
"discord-bettermarkdown": "^1.1.0",
- "discord-rpc-contructor": "^1.1.0",
+ "discord-rpc-contructor": "^1.1.1",
"discord.js": "^13.6.0",
"form-data": "^4.0.0",
"json-bigint": "^1.0.0",