Z_new = Z ^ (B/A)
Z_new = Z * (B/A)^2
/** | |
* Json Frame Array Sprite Sheet Importer | |
* | |
* Creates a new MovieClip in the library, then for each frame in the imported spritesheet | |
* animation this script will create a bitmap-filled shape on the timeline of the newly-created | |
* movieclip. | |
*/ | |
var LIBRARY_FOLDER = 'imported-sprites'; | |
var dom = fl.getDocumentDOM (); |
<!DOCTYPE html> | |
<html> | |
<style> | |
body { background: #fff; } | |
#paper { background: #ccc; } | |
</style> | |
<body> | |
<canvas id="paper" width="800" height="600"></canvas> | |
</body> | |
<script src="/socket.io/socket.io.js"></script> |
'use strict'; | |
var playerModes = require('../../game/player').modes; | |
/** | |
* This module exports a single function that checks a game state and | |
* its latest diff for game sound triggers and plays the appropriate | |
* sounds on the provided AudioPlayer object. | |
*/ |
module Main ( | |
main | |
) where | |
import Control.Monad.State | |
import Control.Monad.Reader | |
import Data.Word | |
import Foreign | |
import Graphics.UI.SDL |
default: all | |
all: public/index.html | |
public/index.html: index.html | |
cpp index.html | sed '/^#.*/d' > public/index.html |
#!/usr/bin/env bash | |
cd /Applications/Google\ Drive.app/Contents/Resources | |
for file in $(find . -depth 1 | grep 'inverse.*png'); do | |
echo "Fixing $file ..." | |
cp "$file" "$(printf "$file" | sed 's/-inverse//')" | |
done | |
echo 'Done!' |
using System; | |
using System.Collections.Generic; | |
using System.Xml; | |
using UnityEditor; | |
using UnityEngine; | |
public class StarlingAtlasSlicer | |
{ | |
[MenuItem("CONTEXT/TextureImporter/Slice Sprite Using XML")] | |
static public void SliceUsingXML(MenuCommand command) |
using UnityEngine; | |
using System; | |
using System.Collections.Generic; | |
public class CubicSplineWalker | |
{ | |
readonly Vector2 _anchor0; | |
readonly Vector2 _control0; | |
readonly Vector2 _control1; | |
readonly Vector2 _anchor1; |
<!DOCTYPE html> | |
<html> | |
<body> | |
<canvas id="paper" width="1024" height="768"></canvas> | |
<script> | |
// --------------------------------------------------------------------------- | |
var canvas = document.getElementById("paper"); | |
var ctx = canvas.getContext("2d"); | |
var mouse = {}, keys = {}; | |
canvas.addEventListener('mousemove', function(e) { |