This file contains hidden or 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
| using UnityEngine; | |
| using System.Collections; | |
| //#pragma strict | |
| //#pragma implicit | |
| //#pragma downcast | |
| // Require a character controller to be attached to the same game object | |
| // I had to initally comment out the following RequireComponent | |
| // line to make it compile and allow attaching to my Main Camera; |
This file contains hidden or 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
| qApp->setStyle(QStyleFactory::create("fusion")); | |
| QPalette palette; | |
| palette.setColor(QPalette::Window, QColor(53,53,53)); | |
| palette.setColor(QPalette::WindowText, Qt::white); | |
| palette.setColor(QPalette::Base, QColor(15,15,15)); | |
| palette.setColor(QPalette::AlternateBase, QColor(53,53,53)); | |
| palette.setColor(QPalette::ToolTipBase, Qt::white); | |
| palette.setColor(QPalette::ToolTipText, Qt::white); | |
| palette.setColor(QPalette::Text, Qt::white); |
This file contains hidden or 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
| #define USE_ROBIN_HOOD_HASH 1 | |
| #define USE_SEPARATE_HASH_ARRAY 1 | |
| template<class Key, class Value> | |
| class hash_table | |
| { | |
| static const int INITIAL_SIZE = 256; | |
| static const int LOAD_FACTOR_PERCENT = 90; | |
| struct elem |
This file contains hidden or 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
| #include <stdio.h> | |
| #include <assert.h> | |
| #include <msgpack.h> | |
| typedef struct some_struct { | |
| uint32_t a; | |
| uint32_t b; | |
| float c; | |
| } some_struct; |
This file contains hidden or 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
| // Unlit texture shader which casts shadow on Forward/Defered | |
| Shader "Unlit/Texture CastShadow" { | |
| Properties { | |
| _MainTex ("Base (RGB) Trans (A)", 2D) = "white" {} | |
| } | |
| SubShader { | |
| Tags {"Queue"="Opaque" } | |
| LOD 100 |
This file contains hidden or 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
| eXtreme Go Horse (XGH) Process | |
| Quelle: http://gohorseprocess.wordpress.com | |
| Übersetzung ursprünglich von https://gist.github.com/Neffez/f8d907ba8289f14e23f3855011fa4e2f | |
| 1. Ich denke, also ist es nicht XGH. | |
| In XGH wird nicht gedacht, es wird das erste gemacht, was in den Sinn kommt. Es gibt auch keine zweite Option, die erste ist schneller. | |
| 2. Es gibt 3 Wege ein Problem zu lösen: den richtigen Weg, den falschen Weg und den XGH Weg, welcher exakt wie der falsche ist, aber schneller. |
This file contains hidden or 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
| ;SMBDIS.ASM - A COMPREHENSIVE SUPER MARIO BROS. DISASSEMBLY | |
| ;by doppelganger (doppelheathen@gmail.com) | |
| ;This file is provided for your own use as-is. It will require the character rom data | |
| ;and an iNES file header to get it to work. | |
| ;There are so many people I have to thank for this, that taking all the credit for | |
| ;myself would be an unforgivable act of arrogance. Without their help this would | |
| ;probably not be possible. So I thank all the peeps in the nesdev scene whose insight into | |
| ;the 6502 and the NES helped me learn how it works (you guys know who you are, there's no |
This file contains hidden or 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
| using System.Collections; | |
| using System.Collections.Generic; | |
| public class GameEvent | |
| { | |
| } | |
| public class Events | |
| { | |
| static Events instanceInternal = null; |
This file contains hidden or 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
| using UnityEngine; | |
| using System.Collections; | |
| public class NaturalOrientation : MonoBehaviour { | |
| public static int ORIENTATION_UNDEFINED = 0x00000000; | |
| public static int ORIENTATION_PORTRAIT = 0x00000001; | |
| public static int ORIENTATION_LANDSCAPE = 0x00000002; | |
| public static int ROTATION_0 = 0x00000000; |
This file contains hidden or 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
| using System.Security.Cryptography; | |
| using System.Text; | |
| namespace Snippets | |
| { | |
| public static class SHA1Util | |
| { | |
| /// <summary> | |
| /// Compute hash for string encoded as UTF8 | |
| /// </summary> |