Skip to content

Instantly share code, notes, and snippets.

View AngeloCore's full-sized avatar

Angelo II AngeloCore

  • Bulgaria
  • 09:30 (UTC +03:00)
  • X @angiva7
View GitHub Profile
@stueccles
stueccles / array.verse
Last active June 18, 2024 03:14
A Verse module that adds useful functions to Verse Arrays including Map, Reduce etc.
using { /Verse.org/Random }
Array<public> := module:
# Makes an `array` with only unique elements
(Input:[]t where t:subtype(comparable)).Unique<public>()<transacts>:[]t =
var UniqueArray : []t = array{}
for (Value : Input):
if (UniqueArray.Find[Value] > -1) {}
else:
@ghostrider-05
ghostrider-05 / discord_app_protocols.md
Last active June 29, 2024 17:47
An unofficial list of discord app protocol routes

Discord app protocol routes

Home:

  • /: discord://-/
  • friends: discord://-/channels/@me/
  • nitro: discord://-/store
  • shop: discord://-/shop
  • message requests: discord://-/message-requests
  • family centre: discord://-/family-center
@AngeloCore
AngeloCore / permissions
Last active June 14, 2024 14:02
All discord.js permissions | discord.js permissions list, hasPermission, permissionFor and more
* Numeric permission flags. All available properties:
* * `CREATE_INSTANT_INVITE` (create invitations to the guild)
* * `KICK_MEMBERS`
* * `BAN_MEMBERS`
* * `ADMINISTRATOR` (implicitly has *all* permissions, and bypasses all channel overwrites)
* * `MANAGE_CHANNELS` (edit and reorder channels)
* * `MANAGE_GUILD` (edit the guild information, region, etc.)
* * `ADD_REACTIONS` (add new reactions to messages)
* * `VIEW_AUDIT_LOG`
* * `PRIORITY_SPEAKER`
@AngeloCore
AngeloCore / index.js
Last active January 1, 2022 16:33
Discord.js v12 Inline Reply Powered by npmjs.com/discord-reply EASY!!! For help: https://www.npmjs.com/package/discord-reply
const discord = require('discord.js');
require('discord-reply'); //⚠️ IMPORTANT: put this before your discord.Client()
const client = new discord.Client();
client.on('ready', () => {
console.log(client.user.tag)
});
client.on('message', async message => {
if (message.content.startsWith('!reply')) {
@jeffchao
jeffchao / mappable.spec.js
Created March 28, 2013 23:58
Implementation of Array.prototype.map() in Javascript
// Run using jasmine-node.
// e.g.: jasmine-node file_name.spec.js
Array.prototype.mymap = function (callback) {
var obj = Object(this);
if (obj.length === 0) return null;
if (typeof(callback) === 'undefined') return null;
for (var i = 0, o; o = obj[i]; i++) {