/ Published in: ActionScript 3
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
// Draw left and right arrows // Pass through the graphics layer of an Sprite public static function drawLeft(pGraphics : Graphics) : void { pGraphics.moveTo(0, 0); pGraphics.drawRect(0, 0,5,1); pGraphics.drawRect(1, -1,1,1); pGraphics.drawRect(2, -2,1,1); pGraphics.drawRect(1, 1,1,1); pGraphics.drawRect(2, 2,1,1); } public static function drawRight(pGraphics : Graphics) : void { pGraphics.moveTo(0, 0); pGraphics.drawRect(0, 0,5,1); pGraphics.drawRect(4, -1,1,1); pGraphics.drawRect(3, -2,1,1); pGraphics.drawRect(4, 1,1,1); pGraphics.drawRect(3, 2,1,1); }