Skip to content

Instantly share code, notes, and snippets.

View theo5970's full-sized avatar

theo5970 theo5970

  • South Korea
  • 11:20 (UTC +09:00)
View GitHub Profile
@theo5970
theo5970 / BitArray256.cs
Last active February 12, 2025 05:51
C# BitArray (256-bit struct)
using System.Collections;
using System.Numerics;
using System.Runtime.CompilerServices;
using System.Runtime.Intrinsics;
using System.Runtime.Intrinsics.X86;
using System.Text;
public unsafe struct BitArray256 : IEquatable<BitArray256>
{
public const int ByteCount = 4;
@theo5970
theo5970 / SecureIntFloat.cs
Last active March 16, 2023 03:06
C# int, float XOR encryption & decryption simple library.
using System;
using System.Runtime.InteropServices;
[StructLayout(LayoutKind.Explicit, Pack = 1)]
public struct SecureInt
{
private static Random random = new Random();
[FieldOffset(0)] private byte byte0;
@theo5970
theo5970 / readme.md
Last active August 15, 2017 04:04
'Toggle' 맵 파일구조

'Toggle' 맵 파일 구조설계


1. 맵 정보 데이터:

맵 크기: 가로, 세로 각각 8비트 씩

총 16비트 = 2바이트

2-1. 블럭 기본 데이터

2-1-1. 좌표(x, y) : 각각 4비트

@theo5970
theo5970 / uuid.js
Created April 12, 2017 02:39
Fast UUID v4 in Javascript
// use uuid() to generate uuid v4. (minified)
function uuid(){let a=[];for(let b=0;b<36;b++){let c;if(8==b||13==b||18==b||23==b)c="-";else{let a=Math.floor(Math.random()*defined_chars.length);c=defined_chars[a]}a.push(c)}return a.join("")}var defined_chars=["a","b","c","d","e","f","0","1","2","3","4","5","6","7","8","9"]
## Java
*.class
*.war
*.ear
hs_err_pid*
## Robovm
robovm-build/