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
private function getSort() | |
{ | |
var sortval:Float = 0; | |
var curAngle = loop(((FlxG.camera.angle-90) * Math.PI) / 180); | |
var r = Math.sqrt(Math.pow(top.getGraphicMidpoint().x - player.x, 2) + Math.pow(top.getGraphicMidpoint().y - player.y, 2)); | |
var phi = Math.atan2(top.getGraphicMidpoint().x - player.x, top.getGraphicMidpoint().y - player.y) + Math.PI; | |
var topAngle = curAngle; | |
var botAngle = loop(curAngle + Math.PI); |
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 ishihara = new FlxSprite(0, 0, "assets/ishihara2.png"); | |
for (x in 0...Std.int(ishihara.width)) | |
{ | |
for (y in 0...Std.int(ishihara.height)) | |
{ | |
var cur = ishihara.framePixels.getPixel(x, y); | |
var cs = StringTools.hex(cur, 6); | |
var r = Std.parseInt("0x" + cs.substr(0, 2)); | |
var g = Std.parseInt("0x" + cs.substr(2, 2)); |
NewerOlder