float rand(float n){return fract(sin(n) * 43758.5453123);}
float noise(float p){
float fl = floor(p);
float fc = fract(p);
return mix(rand(fl), rand(fl + 1.0), fc);
}
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
#!/bin/sh | |
cd "$(dirname "$0")" | |
touch .git/hooks/pre-push | |
rm .git/hooks/pre-push | |
ln -s ../../pre-push-hook.sh .git/hooks/pre-push |
This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
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
require('GlobalStrings') | |
-- generated from s_bonusStatStringTags | |
local bonusStats = { | |
[0] = "ITEM_MOD_MANA_SHORT", | |
[1] = "ITEM_MOD_HEALTH_SHORT", | |
[3] = "ITEM_MOD_AGILITY_SHORT", | |
[4] = "ITEM_MOD_STRENGTH_SHORT", | |
[5] = "ITEM_MOD_INTELLECT_SHORT", | |
[6] = "ITEM_MOD_SPIRIT_SHORT", |
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
namespace System.Web.Mvc | |
{ | |
public static class HelperExtensions | |
{ | |
public static MvcHtmlString If(this MvcHtmlString value, bool evaluation) | |
{ | |
return evaluation ? value : MvcHtmlString.Empty; | |
} | |
} | |
} |