CSG:Subtract operation

About advanced scenes, and the Thyme scripting language used in Algodoo.

CSG:Subtract operation

Postby edwardfanboy » Sun May 29, 2011 2:57 am

Say I have any polygon.

I want to simulate it being broken gradually by a laser.
I want to have it spawn a circle at e.pos (done it) and make it do a CSG:subtract to break the polygon on its OnlaserHit event.

The question is: Can you do a CSG operation using Thyme? If so, how? :? :? :? :? :? :? :? :? :? :?
92% of teenagers have resorted to rap music. If you are part of the 8% who listens to real music, put this in your signature.
90% of teenagers today would die if Myspace/Facebook were completely destroyed. If you are one of the 10% who would be laughing their heads off, add this to your signature.
edwardfanboy
 
Posts: 10
Joined: Sun May 29, 2011 2:49 am

Re: CSG:Subtract operation

Postby Someone Else » Sun May 29, 2011 6:55 pm

I don't think so.
Not that I know of.
You could, however, break the polygon up into a bunch of smaller pieces, glue them together, use a code like this:
Code: Select all
for(2, (i)=>{
        scene.addCircle({
            pos := e.pos;
            radius := 0.50000000000000000;
            killer := true
        })
    })

and lag your computer to death.

If this were a suggestion, I would support it!
Matthias Wandel is epic, in my humble opinion.
I love my brain...
TC42 wrote:Also, your sig is too big, please change it.

ARE YA HAPPY NOW?????

Thymechanic/Phundamentalist

Recently, I discovered something a lot of you probably already knew: Minecraft is awesome.
Due to this, I may not be as active as usual for a while.
User avatar
Someone Else
 
Posts: 1147
Joined: Sun Nov 21, 2010 10:53 pm
Location: The Milky Way Galaxy


Return to Thyme scripting

Who is online

Users browsing this forum: No registered users and 3 guests