This file contains 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
<? | |
$GID = 1;//id группы | |
$UID = 1;//id того, кому слать стату | |
$token = "";//токен с offline и без прав | |
function wflog($txt,$rew){ //запись в файл | |
if($rew) | |
file_put_contents("xd.txt", $txt.PHP_EOL, FILE_APPEND); | |
else | |
file_put_contents("xd.txt", $txt.PHP_EOL); |
This file contains 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
function UnityAssetMergerGenerator(assetnum,assetparts){ | |
var q = 'copy /b '; | |
for(var i=0;i<=assetparts;i++){ q+='"sharedassets'+assetnum+'.assets.split'+i+'" + ' } | |
q = q.substr(0,q.length-2) + '"sharedassets'+assetnum+'.assets"' | |
return q; | |
} |
This file contains 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
addEventListener 'mousewheel', (e) -> | |
switch e.deltaX | |
when -100 | |
atom.workspace.getActivePane().activatePreviousItem() | |
when 100 | |
atom.workspace.getActivePane().activateNextItem() | |
return |
This file contains 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
Public Domain |
This file contains 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 ps = require('current-processes') | |
const _ = require('lodash') | |
const fs = require('fs') | |
function saveData(){ | |
ps.get(function(err, processes) { | |
for(let prc of processes){ | |
delete prc.mem | |
} | |
let sorted = _.sortBy(processes, 'cpu') |
This file contains 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
import urequests as rq | |
import utime as t | |
class VKAPI(object): | |
def __init__(self): | |
self.token = "REPLACE_THIS_WITH_YOUR_TOKEN" | |
def _sendRequest(self, method, prm): | |
prm["access_token"] = self.token | |
prm["v"] = "5.101" | |
par = self._q(prm) | |
qu = "https://api.vk.com/method/"+method+"/?"+par |
This file contains 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
// MULTI-CORE J2ME JAR HASHER | EXCLUDES EVERYTHING INSIDE MANIFEST FOLDER TO IGNORE MANIFEST-ONLY-CHANGES | (c) Remixer Dec 2019 | License: CC BY-NC 4.0 | |
// usage: node jarhasher.js "C:/path/to/folder_with_jar_files_only_with_forward_slashes" CPU_LOGICAL_CORES HASHLIMIT | |
// output: 2 files hashed.json, corrupted.json | |
// output format: [["filename","md5","sha1"],...] | |
const os = require('os') | |
const JSZip = require("jszip"); | |
const fs = require("fs") | |
const crypto = require('crypto') | |
const cluster = require('cluster'); |
This file contains 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
//Warning: fixed size is only kept for .push() method | |
//Usage: | |
//let arr = new FixedSizeArrayLifo(2) | |
//arr.push(123); ... | |
class FixedSizeArrayLiFo extends Array { | |
constructor(size) { | |
super() | |
this.#size = size | |
} |
This file contains 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
#input: [H (0 to 360), S (0 to 100), L (0 to 100)] | |
#output: [R (0 to 255), G (0 to 255), B (0 to 255)] | |
#reference: https://gist.github.com/PaulKinlan/d4053acfffd49abfa197a8d370a18337 | |
def hsl_to_rgb(HSLlist): | |
H, S, L = HSLlist | |
S = S / 100 | |
L = L / 100 | |
C = (1 - abs(2 * L - 1)) * S | |
X = C * (1 - abs(((H / 60) % 2) - 1)) | |
m = L - C / 2; |
This file contains 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
Element.prototype.createEvent = function(name, ...params) { | |
return new CustomEvent(name, ...params) | |
} | |
console.info = function(...args) { | |
console.log(...args) | |
} | |
//this is just a placeholder | |
class SVGElement { |
OlderNewer