Skip to content

Instantly share code, notes, and snippets.

View lmick002's full-sized avatar

Larry Mickie lmick002

View GitHub Profile
@lmick002
lmick002 / unimap.tsx
Created April 20, 2025 17:02
react-native-maps + @teovilla/react-native-web-maps
import React from 'react';
import { Platform, StyleProp, ViewStyle } from 'react-native';
// Native types
import type {
MapViewProps as NativeMapViewProps,
Marker as NativeMarker,
Region,
LatLng,
} from 'react-native-maps';
@lmick002
lmick002 / Skillable.ts
Created January 3, 2025 22:44 — forked from Mordo95/Skillable.ts
A simple XP table / Leveling system in Typescript. Because why not. Most of the formulas have been sucked out of my thumb but work according to how I want it to
import XpTable from "./XpTable";
export default class Skillable {
protected _xp: number = 0;
get xp() {
return this._xp;
}
set xp(val) {
@lmick002
lmick002 / instagram-api_send_message.js
Created September 15, 2024 00:39 — forked from baptx/instagram-api_send_message.js
Instagram API: send direct messages from a web browser
/*
Instagram API: send direct messages from a web browser
Since April 2020, Instagram has a web version to send and read direct messages so my Instagram scripts are not longer needed and I would not recommend using them unless you really need it, to avoid being banned
(never happened to me with Instagram but WhatsApp is owned by Facebook also and they did it to users registering from an unofficial app like yowsup: https://github.com/tgalal/yowsup/commit/88b8ad9581fa22dac330ee3a05fec4e485dfa634#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5)
For browser setup, see script instagram-api_direct_messages_backup.js
Instagram web version sessionid cookie does not allow sending messages so we need to log in manually
Signature should match signed_body data (using HMAC-SHA256 with private key) but wrong signature or key may work also.
//
// ContentView.swift
// AppleMusicLyricsPlayer
//
// Created by Magesh Sridhar on 2/5/23.
//
import SwiftUI
import AVKit
@lmick002
lmick002 / AudioPlayerView.swift
Created June 28, 2023 03:04 — forked from multitudes/AudioPlayerView.swift
Audio Player written for SwiftUI - first pass
//
// AudioPlayerView.swift
// AccessibleAudioPlayer
//
// Created by Laurent B on 30/10/2021.
//
import SwiftUI
import AVKit
@lmick002
lmick002 / emojis.json
Created October 1, 2022 23:46 — forked from oliveratgithub/emojis.json
Emoji-list with emojis, names, shortcodes, unicode and html entities [massive list]
{
"emojis": [
{"emoji": "πŸ‘©β€πŸ‘©β€πŸ‘§β€πŸ‘§", "name": "family: woman, woman, girl, girl", "shortname": ":woman_woman_girl_girl:", "unicode": "1F469 200D 1F469 200D 1F467 200D 1F467", "html": "👩‍👩‍👧‍👧", "category": "People & Body (family)", "order": ""},
{"emoji": "πŸ‘©β€πŸ‘©β€πŸ‘§β€πŸ‘¦", "name": "family: woman, woman, girl, boy", "shortname": ":woman_woman_girl_boy:", "unicode": "1F469 200D 1F469 200D 1F467 200D 1F466", "html": "👩‍👩‍👧‍👦", "category": "People & Body (family)", "order": ""},
{"emoji": "πŸ‘©β€πŸ‘©β€πŸ‘¦β€πŸ‘¦", "name": "family: woman, woman, boy, boy", "shortname": ":woman_woman_boy_boy:", "unicode": "1F469 200D 1F469 200D 1F466 200D 1F466", "html": "👩‍👩‍👦‍👦", "category": "People & Body (family)", "order": ""},
{"emoji": "πŸ‘¨β€πŸ‘©β€πŸ‘§β€πŸ‘§", "name": "family: man, woman, girl, girl", "shortname": ":man_woman_girl_girl:", "unicode": "1F468 200D 1F469 200D 1F467 200D 1F467", "html": "👨‍👩&z
@lmick002
lmick002 / Freeverb.js
Created April 5, 2022 18:46 — forked from nick-thompson/Freeverb.js
An implementation of the Freeverb algorithm in JavaScript using Elementary Audio.
/* First, our Schroeder-Moorer filtered-feedback comb-filters
*
* @param {string} name – for identifying our feedback taps
* @param {number} size – for defining our feedback tap lengths
* @param {Node | number} feedback: [0, 1) – how long the reverb should ring out
* @param {Node | number} damping : [0, 1) – pole position of the lowpass filter
* @param {Node} xn – input signal to filter
*
* @see https://ccrma.stanford.edu/~jos/pasp/Feedback_Comb_Filters.html
*/
var audioCtx = new AudioContext();
myScriptProcessor = audioCtx.createScriptProcessor(16384, 1, 1);
var rawAudioTemp = new Float32Array(data); // Your raw PCM incoming data
for (i = 0 ; i < rawAudioTemp.length ; i++) {
rawAudio.push(rawAudioTemp[i]);
}
streamingNode.onaudioprocess = function(event) {
for (chan= 0 ; chan< event.outputBuffer.numberOfChannels ; chan++) {
@lmick002
lmick002 / app.js
Created May 11, 2020 18:01 — forked from jochasinga/app.js
Node/Socket.io server code for syncing data from Firebase
var Firebase = require("firebase");
var express = require("express");
// Create HTTP Server
var app = express();
var server = require("http").createServer(app);
// Attach Socket.io server
var io = require("socket.io")(server);
// Indicate port 3000 as host
var port = process.env.PORT || 3000;
@lmick002
lmick002 / DragView.swift
Created December 31, 2017 15:44 — forked from fpg1503/DragView.swift
Drag and Drop View on macOS
protocol DragViewDelegate {
var acceptedFileExtensions: [String] { get }
func dragView(dragView: DragView, didDragFileWith URL: NSURL)
}
class DragView: NSView {
required init?(coder: NSCoder) {
super.init(coder: coder)
registerForDraggedTypes([NSFilenamesPboardType, NSURLPboardType])