Skip to content

Instantly share code, notes, and snippets.

View drawcode's full-sized avatar
😎
Shipping product

Ryan Christensen drawcode

😎
Shipping product
View GitHub Profile
@drawcode
drawcode / custom_game_engines_small_study.md
Created April 24, 2020 19:20 — forked from raysan5/custom_game_engines_small_study.md
A small state-of-the-art study on custom engines

CUSTOM GAME ENGINES: A Small Study

a_plague_tale

A couple of weeks ago I played (and finished) A Plague Tale, a game by Asobo Studio. I was really captivated by the game, not only by the beautiful graphics but also by the story and the locations in the game. I decided to investigate a bit about the game tech and I was surprised to see it was developed with a custom engine by a relatively small studio. I know there are some companies using custom engines but it's very difficult to find a detailed market study with that kind of information curated and updated. So this article.

Nowadays lots of companies choose engines like Unreal or Unity for their games (or that's what lot of people think) becaus

@drawcode
drawcode / publickey-git-error.markdown
Created April 5, 2020 03:45 — forked from adamjohnson/publickey-git-error.markdown
Fix "Permission denied (publickey)" error when pushing with Git

"Help, I keep getting a 'Permission Denied (publickey)' error when I push!"

This means, on your local machine, you haven't made any SSH keys. Not to worry. Here's how to fix:

  1. Open git bash (Use the Windows search. To find it, type "git bash") or the Mac Terminal. Pro Tip: You can use any *nix based command prompt (but not the default Windows Command Prompt!)
  2. Type cd ~/.ssh. This will take you to the root directory for Git (Likely C:\Users\[YOUR-USER-NAME]\.ssh\ on Windows)
  3. Within the .ssh folder, there should be these two files: id_rsa and id_rsa.pub. These are the files that tell your computer how to communicate with GitHub, BitBucket, or any other Git based service. Type ls to see a directory listing. If those two files don't show up, proceed to the next step. NOTE: Your SSH keys must be named id_rsa and id_rsa.pub in order for Git, GitHub, and BitBucket to recognize them by default.
  4. To create the SSH keys, type ssh-keygen -t rsa -C "[email protected]". Th
@drawcode
drawcode / cert_convert.sh
Created March 21, 2019 04:36 — forked from jmervine/cert_convert.sh
openssl: convert cert from p7b to crt (or cer)
openssl pkcs7 -print_certs -in old.p7b -out new.crt
# openssl pkcs7 -print_certs -in old.p7b -out new.cer
@drawcode
drawcode / fraksl.pde
Created November 26, 2018 21:10 — forked from nimaid/fraksl.pde
Fraksl Processing Script
/*
A port of the Fraksl Android App by Ella Jameson
WASD to move, QE to rotate, [UP][DOWN] to zoom, P to take a picture in the sketch directory
*/
void mirror_screen()
{
loadPixels();
for(int row = 0; row < height; row++)
{
@drawcode
drawcode / generate-ssh-key.sh
Last active July 16, 2018 08:59 — forked from grenade/01-generate-ed25519-ssh-key.sh
Correct file permissions for ssh keys and config.
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/id_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/github_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "[email protected]" -f ~/.ssh/mozilla_rsa
@drawcode
drawcode / string.compress.js
Created June 24, 2018 03:05 — forked from fliptopbox/string.compress.js
JavaScript String compression
/*
@fliptopbox
LZW Compression/Decompression for Strings
Implementation of LZW algorithms from:
http://rosettacode.org/wiki/LZW_compression#JavaScript
Usage:
var a = 'a very very long string to be squashed';
var b = a.compress(); // 'a veryāăąlong striċ to bečquashed'
@drawcode
drawcode / gist:077fafd287b420e906c75d7071e21c60
Created December 6, 2017 06:26 — forked from ichord/gist:9808444
demo of using pdf.js to extract pages to images
<script src="http://cdnjs.cloudflare.com/ajax/libs/processing.js/1.4.1/processing-api.min.js"></script><html>
<!--
Created using jsbin.com
Source can be edited via http://jsbin.com/pdfjs-helloworld-v2/8598/edit
-->
<body>
<canvas id="the-canvas" style="border:1px solid black"></canvas>
<input id='pdf' type='file'/>
<!-- Use latest PDF.js build from Github -->
@drawcode
drawcode / gist:642739b4abba5e054b285d9c8496dea5
Created January 30, 2017 07:44 — forked from prashantvc/gist:5213961
Send email with multiple attachments (Xamarin.Android)
public static void Email(Context context, string emailTo, string emailCC, string subject, string emailText, List<string> filePaths)
{
var email = new Intent(Intent.ActionSendMultiple);
email.SetType("text/plain");
email.PutExtra(Intent.ExtraEmail, new string[]{emailTo});
email.PutExtra(Intent.ExtraCc, new string[]{emailCC});
var uris = new List<IParcelable>();
filePaths.ForEach(file=> {
@drawcode
drawcode / gist:9de295798963495d97f219cdab6d9965
Created August 25, 2016 01:11 — forked from bgrins/gist:1789787
C# Multipart File Upload
// Implements multipart/form-data POST in C# http://www.ietf.org/rfc/rfc2388.txt
// http://www.briangrinstead.com/blog/multipart-form-post-in-c
public static class FormUpload
{
private static readonly Encoding encoding = Encoding.UTF8;
public static HttpWebResponse MultipartFormDataPost(string postUrl, string userAgent, Dictionary<string, object> postParameters)
{
string formDataBoundary = String.Format("----------{0:N}", Guid.NewGuid());
string contentType = "multipart/form-data; boundary=" + formDataBoundary;
@drawcode
drawcode / prime[31] + Vuforia
Created March 20, 2016 07:38 — forked from prime31/prime[31] + Vuforia
Activity override system that will work with Vuforia. Note that this is provided as-is and we do not provide support for working with Vuforia.
- download the jar file from here: https://mega.co.nz/#!pd81gYBA!ui33ktU2xDqmcsYOv5oSZ6v-niPp1ofwh02naT7Vqbs Note that anytime you import any other plugins make sure that file doesn't get overwritten!
- overwrite the file with the same name in the Plugins/Android folder with the downloaded jar
- generate an AndroidManifest.xml file
- add the required permissions for Vuforia to the generated AndroidManifest.xml (see their docs for the details)