This file contains 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
<?php | |
use Illuminate\Auth\UserInterface; | |
use Illuminate\Auth\Reminders\RemindableInterface; | |
use \Eloquent; | |
class User extends Eloquent implements UserInterface, RemindableInterface | |
{ |
This file contains 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
#if (${NAMESPACE}) | |
<?php namespace ${NAMESPACE}; | |
#else | |
<?php | |
#end | |
use Eloquent; | |
class ${NAME} extends Eloquent { |
This file contains 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
A small non-complete example design and implementation of Observables/Tasks integrated into events. | |
It is inspired by a mix of classic Observables and .NET's Tasks/SynchronizationContext. |
This file contains 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
{ | |
"version": { | |
"name": "13w41a", | |
"protocol": 0 | |
}, | |
"players": { | |
"max": 100, | |
"online": 5, | |
"sample":[ | |
{"name":"Thinkofdeath", "id":""} |
This file contains 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; | |
public class TimeOfDayManager : MonoBehaviour | |
{ | |
public float secondsInFullDay = 120f; | |
[HideInInspector] | |
public float timeMultiplier = 1f; |
This file contains 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; | |
using System.Collections.Generic; | |
using System; | |
[Serializable] | |
public class Graph : ScriptableObject | |
{ | |
[SerializeField] |
This file contains 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
public static class ReadableID | |
{ | |
static readonly string[] syllables = new string[256]; | |
public static void initOnce() | |
{ | |
string[] consonants = new string[] { "b", "br", "c", "ch", "d", "f", "fr", "g", "h", "j", "k", "kn", "l", "m", "n", "p", "pr", "qu", "r", "s", "st", "sl", "sc", "t", "tr", "v", "w", "x", "z" }; | |
string[] vowels = new string[] { "a", "e", "i", "o", "u", "y", "ae", "ee", "ea", "ai" }; | |
for (int i = 0; i < syllables.Length; ++i) | |
{ |
This file contains 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 TMPro; | |
using UnityEngine; | |
using UnityEngine.UI; | |
public class SliderValueText : MonoBehaviour | |
{ | |
[SerializeField] | |
[Tooltip("The text shown will be formatted using this string. {0} is replaced with the actual value")] | |
private string formatText = "{0}°"; |
This file contains 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
var tyme = Application('Tyme2') | |
var myproject = tyme.projects().filter(p => p.name() === 'MY PROJECT')[0] | |
getSpendTimes = t => t.taskrecords().reduce((acc,curr) => acc + curr.timedduration(),0) | |
getSubTimes = t => t.subtasks().reduce((acc,curr) => acc + getSpendTimes(curr),0) | |
getTotalSpendTimes = t => getSpendTimes(t) + getSubTimes(t) |
This file contains 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
static Vector2 L = new Vector2(); | |
static Vector2 N = new Vector2(); | |
static Vector2 tmp = new Vector2(); | |
static Vector2[] points = new Vector2[] { | |
new Vector2(), new Vector2(), new Vector2(), new Vector2() | |
}; | |
static Vector2[] tmpBoundary = new Vector2[] { | |
new Vector2(), new Vector2() | |
}; |
OlderNewer