Skip to content

Instantly share code, notes, and snippets.

View iSnakeBuzz's full-sized avatar
🎯
Focusing

Martín iSnakeBuzz

🎯
Focusing
View GitHub Profile
@hirbod
hirbod / withDisableForcedDarkModeAndroid.js
Last active May 15, 2024 00:00
Expo Config Plugin to disable forced Dark mode.
// disable forced dark mode to prevent weird color changes on
// certain android devices (Xiaomi MIUI and others enforcing dark mode with view analyzing)
// create a file like "plugins/withDisableForcedDarkModeAndroid.js". Insert this content and edit your app.config.js/app.json
/*
"expo": {
...
...
...
"plugins": [
@lacoski
lacoski / gist:3e0ee45d4276be9d6dca689366197026
Created August 11, 2020 03:50 — forked from dotcomputercraft/gist:0947eb7ed6b3b5cc14b6
increase max number of ulimit open file and max user processes in Linux.
1- Step : open the sysctl.conf and add this line fs.file-max = 65536
vi /etc/sysctl.conf add end of line
fs.file-max=500000
save and exit.
2. Step : vi /etc/security/limits.conf and add below the mentioned
* soft nproc 500000
@artem-bondar
artem-bondar / csharp.json
Last active February 18, 2021 17:49
Unity code snippets for Visual Studio Code
{
"Unity MonoBehaviour": {
"prefix": "MonoBehaviour",
"description": "Unity MonoBehaviour class template.",
"body": [
"using UnityEngine;",
"",
"public class ${TM_FILENAME_BASE} : MonoBehaviour",
"{",
"\t$0",
@YoungOG
YoungOG / .java
Created December 30, 2018 07:44
Here's the god damn "magic" kohi knockback, maybe people can stop believing in magic some day and just play the fucking game. Credit to OCN's SportBukkit for the relog fix
knockbackFriction = 2.0D;
knockbackHorizontal = 0.35D;
knockbackVertical = 0.35D;
knockbackVerticalLimit = 0.4D;
knockbackExtraHorizontal = 0.425D;
knockbackExtraVertical = 0.085D;
@eltrueno
eltrueno / Example.java
Last active February 23, 2024 15:37
Scrollable Menu by el_trueno
private static ScrollableMenuModel getModel(){
ItemStack air = new ItemStack(Material.AIR);
ItemStack nextpage = nolore(Material.ARROW, 1, 0, "§ePágina siguiente");
ItemStack previouspage = nolore(Material.ARROW, 1, 0, "§ePágina anterior");
ItemStack shop = nolore(Material.EMERALD, 1, 0, "§aVolver a la tienda");
ScrollableMenuModel menumodel = new ScrollableMenuModel(54, air,
new ScrollableMenuSlot(ScrollableMenuSlot.SlotType.DECORATION, null, 0)
, new ScrollableMenuSlot(ScrollableMenuSlot.SlotType.NEXT_PAGE, nextpage, 41)
, new ScrollableMenuSlot(ScrollableMenuSlot.SlotType.PREVIOUS_PAGE, previouspage, 39)
, new ScrollableMenuSlot(ScrollableMenuSlot.SlotType.ITEM, null, 10,11,12,13,14,15,16,19,20,21,22,23,24,25,28,29,30,31,32,33,34)
@602723113
602723113 / NPC.jar
Created May 10, 2018 12:38 — forked from DanielTheDev/NPC.java
Bukkit/Spigot NPC Util 1.12
package com.plugin.npc;
import com.mojang.authlib.GameProfile;
import com.mojang.authlib.properties.Property;
import net.minecraft.server.v1_12_R1.*;
import org.bukkit.Bukkit;
import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.craftbukkit.v1_12_R1.entity.CraftPlayer;
@procrastinatio
procrastinatio / haproxy_rate_limiting.md
Created October 25, 2017 06:04
Rate limiting with HAproxy

Introduction

So HAProxy is primalery a load balancer an proxy for TCP and HTTP. But it may act as a traffic regulator. It may also be used as a protection against DDoS and service abuse, by maintening a wide variety of statistics (IP, URL, cookie) and when abuse is happening, action as denying, redirecting to other backend may undertaken ([haproxy ddos config], [haproxy ddos])

@cmlewis
cmlewis / Convert FLV to MP4 using ffmpeg
Created October 18, 2016 21:16
Convert FLV to MP4 using ffmpeg
_
@lopspower
lopspower / README.md
Last active July 17, 2024 00:29
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

Download This sample on Google Play Store

@fadookie
fadookie / CameraAnchor.cs
Last active April 29, 2024 12:19
Screen-relative anchoring component for Unity3D. Find more Unity code at http://www.eliotlash.com/2015/01/unity3d-components-and-code-snippets/
/***
* This script will anchor a GameObject to a relative screen position.
* This script is intended to be used with ViewportHandler.cs by Marcel Căşvan, available here: http://gamedev.stackexchange.com/a/89973/50623
* It is also copied in this gist below.
*
* Note: For performance reasons it's currently assumed that the game resolution will not change after the game starts.
* You could not make this assumption by periodically calling UpdateAnchor() in the Update() function or a coroutine, but is left as an exercise to the reader.
*/
/* The MIT License (MIT)