/ Published in: ActionScript 3
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
// This can only be done then the registration point is top left and objects don't have graphics in its negative space // horizontal alignment b.y = a.y + (a.height - b.height) * 0.5; // vertical alignment b.x = a.x + (a.width - b.width) * 0.5;