[Xerte] The Fellowship of the Ring

Paul Swanson Paul.Swanson at harlandfs.com
Wed Oct 27 23:07:03 BST 2010


Found this on the interwebs, seems to work:

 

// draw circles in movie clip "it" centered at x,y

// with radius r and color c in 0xffffff format

function drawCircle(it,x,y,r,c){

    a=r*0.414213562;

    b=r*0.707106781;

 

    with(eval(it)){

        lineStyle(4,c);

        moveTo(x+r,y);

        curveTo(x+r,y-a,x+b,y-b);

        curveTo(x+a,y-r,x,y-r);

        curveTo(x-a,y-r,x-b,y-b);

        curveTo(x-r,y-a,x-r,y);

        curveTo(x-r,y+a,x-b,y+b);

        curveTo(x-a,y+r,x,y+r);

        curveTo(x+a,y+r,x+b,y+b);

        curveTo(x+r,y+a,x+r,y);

    }

}

 

// usage example: draws a red circle 100 pixels wide

// centered at 100,100 in the myMovie movie clip

drawCircle('myMovie',100,100,50,'0xff0000');

 

You just need to replace 'myMovie' with the id of a graphics icon.

 

From: xerte-bounces at lists.nottingham.ac.uk
[mailto:xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Dave Burnett
Sent: Wednesday, October 27, 2010 2:48 PM
To: Xerte list
Subject: RE: [Xerte] The Fellowship of the Ring

 


I want to be able to see through it, like a ring.


> From: Patrick.Lockley at nottingham.ac.uk
> To: xerte at lists.nottingham.ac.uk
> Date: Wed, 27 Oct 2010 22:34:44 +0100
> Subject: RE: [Xerte] The Fellowship of the Ring
> 
> You can draw it with lines or just draw a big circle and a smaller one
inside?
> ________________________________________
> From: xerte-bounces at lists.nottingham.ac.uk
[xerte-bounces at lists.nottingham.ac.uk] On Behalf Of Dave Burnett
[d_b_burnett at hotmail.com]
> Sent: Wednesday, October 27, 2010 10:11 PM
> To: Xerte list
> Subject: [Xerte] The Fellowship of the Ring
> 
> Can I draw a hollow circle, a.k.a. a ring?
> 
> Dave
> " I'm not just the founder of Prototype, I'm also a member."
> _______________________________________________
> Xerte mailing list
> Xerte at lists.nottingham.ac.uk
> http://lists.nottingham.ac.uk/mailman/listinfo/xerte
> This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment. Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham.
> 
> This message has been checked for viruses but the contents of an
attachment
> may still contain software viruses which could damage your computer
system:
> you are advised to perform your own checks. Email communications with
the
> University of Nottingham may be monitored as permitted by UK
legislation.

This message and any attachment are intended solely for the addressee
and may contain confidential information. If you have received this
message in error, please send it back to me, and immediately delete it.
Please do not use, copy or disclose the information contained in this
message or in any attachment. Any views or opinions expressed by the
author of this email do not necessarily reflect the views of the
University of Nottingham. 

This message has been checked for viruses but the contents of an
attachment may still contain software viruses which could damage your
computer system: you are advised to perform your own checks. Email
communications with the University of Nottingham may be monitored as
permitted by UK legislation. 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.nottingham.ac.uk/pipermail/xerte/attachments/20101027/25955a88/attachment.html


More information about the Xerte mailing list