Skip to content

Instantly share code, notes, and snippets.

Subject: [PATCH] Gen 4: Fix targeting of encored moves in doubles
---
data/mods/gen4/moves.js | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/data/mods/gen4/moves.js b/data/mods/gen4/moves.js
index 308a58c6f..be46a2a5b 100644
--- a/data/mods/gen4/moves.js
+++ b/data/mods/gen4/moves.js
@jmclemo6
jmclemo6 / dpd.cs
Last active February 25, 2018 18:41
Decodes 9 digit DPD to a decimal value
static public System.UInt32 GetDecimalFromDPD(this System.Collections.BitArray input) {
/* 36 bits because the three 10 bit quantities will expand to 12 bits each */
var Bits = new System.Collections.BitArray(36);
/* I could probably shorten this with a loop, but I haven't taken the time to figure that logic out. */
System.Boolean bit_0, bit_1, bit_2, bit_3, bit_4, bit_5, bit_6, bit_7, bit_8, bit_9;
/* Since we have 32 bit of space, but only 30 bits of data we ignore the first two bits */
/* This decodes the first 10 bits of data */
bit_0 = input[2];
@jmclemo6
jmclemo6 / canvas_mail_script.js
Created January 10, 2018 21:35
UTK CS Discord Mass Mail Script
// Your browser must support ES6 async / await, Promises, and Template Strings for this to work.
// Do not remove the sleeps to make it faster. They are there to allow time for the Ajax calls that Canvas makes to process.
// If you are on a slow connection, you might need to increase the length of the sleep calls.
// I've also made it up to you to click the send button. Be sure to check that you pasted your invite url correctly.
// To run this:
// * Go to the page on Canvas where you can see your messages from the class you want to send the invite to.
// * Open your browser's console using F12 or by right clicking and then selecting "Inspect Element".
// * Paste the below code into your console window and hit enter.
// * Then enter add_students("INSERT_INVITE_URL_HERE"); into your console window and hit enter.
// * The script will run and then all you have to do is proofread and hit send!