Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View KinoAR's full-sized avatar
🏠
Working from home

Kino KinoAR

🏠
Working from home
View GitHub Profile
//=============================================================================
// How To Use
//=============================================================================
*
* This plugin uses both the ASK system and Rem System; we use comments
* to make them work together and make your life easier.
*
* First, create a new comment in RPGMaker MV.
* Within the comment type <lbite> </lbite>
* Inside that comment you type the text files you want to attach line by line.
//=============================================================================
// Introduction
//=============================================================================
*
* This plugin is completely touched based at the moment. This is based off
* FF14's Grid Inventory system. As of right now, you have quite a few options
* in terms of grid size, and items. You can also have tabs based on your inven-
* tory size (multiple pages). It comes with a mini window to open the inventory.
*
//=============================================================================
@KinoAR
KinoAR / Saber_Heart.js
Created November 25, 2016 18:08
Saber Heart Script Calls
//=============================================================================
// Script Calls
//=============================================================================
Saber.getWeapon(weaponName)
//Example
Saber.getWeapon("Rampart");
//Gets the weapon by the name in the database.
Saber.levelupWeapon(weaponName);
@KinoAR
KinoAR / DesktopAppPackage.json
Created November 26, 2016 20:19
A package.json for developing webkit applications using react, ES6, and other necessary files.
{
"name": "MyDesktopApp",
"version": "1.0.0",
"main": "index.html",
"description": "Tool Description",
"window": {
"title": "MyWebKit"
},
"repository": {
"type": "git",
@KinoAR
KinoAR / BasicReduce.js
Last active November 30, 2016 04:56
Array.Reduce JavaScript Tutorial Code
'use strict';
//Basic Reduce
let array = [1, 2, 3, 4, 5];
let result = array.reduce(function(sum, element) {
//Increase sum by element amount
sum += element;
console.log(sum); //1, 3, 6, 10, 15
return sum; //return the current sum for the next iteration
}, 0);
@KinoAR
KinoAR / ObjectReduce.js
Last active November 30, 2016 04:57
Array.Reduce JavaScript Tutorial Code
'use strict'
//Object Reduce
let names = ['Ray', 'Hiro', 'Ross'];
let obj = names.reduce(function(finalObj, name, index){
//Create new property on object based on index (1, 2, 3) and assign name to it
index+=1;
finalObj[index] = name;
console.log(finalObj[index]);
return finalObj; //return the object for the next iteration
}, {});
@KinoAR
KinoAR / ObjectAssignComposition.js
Created December 10, 2016 18:57
A gist showcasing object composition, using Object.Assign
//=============================================================================
// Object.Assign
//=============================================================================
class Robot {
constructor(name) {
this._name = name;
}
@KinoAR
KinoAR / ObjectAssignSimpleAssignment.js
Created December 10, 2016 19:11
A gist showcasing Object.Assign simple assignment of a function's properties.
//=============================================================================
// Object.Assign 2
//=============================================================================
class Printer {
static printLine() {
console.log('============================================\n');
}
}
@KinoAR
KinoAR / RegExPatterns1.js
Created December 19, 2016 18:27
Tutorial Code for Regular Expressions
//=============================================================================
// RegExPatterns.js
//=============================================================================
'use strict';
//Pattern for: <cooldown: 12 >
//Pattern 1 matches < cooldown : 12 >, <cooldown:12>, <cooldown: 12>, etc
/<\s*cooldown\s*:\s*(\d+\.*\d*)\s*>/ig;
//Pattern 2 matches <cooldown:12> Only
@KinoAR
KinoAR / RegExPatterns2.js
Last active December 19, 2016 18:57
Tutorial Code for Regular Expressions Part 2
//=============================================================================
// RegExPatterns.js
//=============================================================================
//Reading note tag from skill data in RMMV: $dataSkills is for skill data.
$dataSkills.slice(1).forEach(function(skill) {
'use strict';
let data = /<\s*cooldown\s*:\s*(\d+\.*\d*)\s*>/ig.exec(skill.note);
if(data !== null ) {