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 https = require('https'); | |
/** | |
* Define our function | |
*/ | |
const ytSearchResult = (song) =>{ | |
// return promised result | |
return new Promise((resolve, reject) =>{ |
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 udp = require('dgram'); | |
// Create udp socket | |
const client = udp.createSocket('udp4'); | |
const ip = ''; | |
const port = 0; | |
// TSource Engine Query - normal query | |
const hex = Buffer.from('ffffffff54536f7572636520456e67696e6520517565727900', 'hex') |
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 lowdb from 'lowdb'; | |
import FileSync from 'lowdb/adapters/FileSync'; | |
interface Teams { | |
team_name: string; | |
team_short_name: string; | |
team_logo_name: string; | |
team_description: string; | |
} | |
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
// Demo example on https://repl.it/repls/SpottedUnwieldyMenu | |
// This will work | |
normalFunction(); | |
function normalFunction(){ | |
console.log('common dummy text'); | |
} | |
// This will not work |
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
<?php | |
$firstArray = [ | |
'ID' => '57ef1717-b222-57b651', | |
'session' => [ | |
'sessionID' => '8c776739-276059', | |
'timestamp' => '2020-03-13Z', | |
'place' => '/' | |
] | |
]; |
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
HLTV Documentation Version 3.1.1.1/4.1.1.1 | |
Content | |
------------------------------------------------------------------------------- | |
1. Overview | |
2. Spectating Games |
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
<?php | |
/* | |
This script subscribes to oncliententerview event, and fires callback on function. | |
In my function I took event invoker and his database id. | |
Later I used that dbid to find specific information about user. | |
Purpose is to assign new group if ip of invoker matches our allowed arrays. | |
*/ | |
require_once('TeamSpeak3/TeamSpeak3.php'); |
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
<?php | |
include_once('TeamSpeak3/TeamSpeak3.php'); | |
// Connection configuration | |
$login_name = 'serveradmin'; // query login info | |
$login_password = ''; // =||= | |
$ip = 'localhost'; // ex. 127.0.0.1/ 254.13.121.12 | |
$query_port = '10011'; // default 10011 | |
$virtualserver_port= '9987'; // virtual server port | |
$group = '7'; // Specific group |
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
<?php | |
// First include our framework that we are gonna use | |
// You can download it from here https://github.com/planetteamspeak/ts3phpframework | |
include_once('TeamSpeak3/TeamSpeak3.php'); | |
// Connection configuration | |
$login_name = 'serveradmin'; // query login info | |
$login_password = '9kg6eRKk'; // =||= | |
$ip = 'localhost'; // ex. 127.0.0.1/ 254.13.121.12 | |
$query_port = '10011'; // default 10011 |