loosen script
12 posts • Page 1 of 1
loosen script
what is the on collide or on laser hit script, to loosen an object?
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: loosen script
I don't think there is one. However, if there is, it would look like this:
e.geom.loosen
Why?
e.geom.liquefy (if I spelt it right) liquefies the object.
e.geom.loosen
Why?
e.geom.liquefy (if I spelt it right) liquefies the object.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
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.
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.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
Re: loosen script
You can try changing the density to +inf to glue, and the normal density to unglue.
-

TC42 - Posts: 984
- Joined: Sun Jan 09, 2011 1:53 pm
- Location: $ sudo apt get-install sandwich_
Re: loosen script
Hm hm! I'm sorry, I didn't quite explain clearly enough, to loosen a geom from a HINGE, not glued to unglued. Sorry. 
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: loosen script
Use scene.my.* variables to set a value for the impulse break limit of the hinge, then when the object is hit by the laser make the scene.my.* variable = 0, therefore instantly breaking the hinge.
-

Dare - Posts: 833
- Joined: Sat Nov 21, 2009 4:27 pm
- Location: Sydney, Australia
Re: loosen script
That works. But it still doesn't quite give the same effect as Geometry Actions/Loosen.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
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.
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.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
Re: loosen script
Someone Else wrote:That works. But it still doesn't quite give the same effect as Geometry Actions/Loosen.
Didn't you read his post? He wants to loosen it from a hinge.
-

Dare - Posts: 833
- Joined: Sat Nov 21, 2009 4:27 pm
- Location: Sydney, Australia
Re: loosen script
I read the post.
I also want to access the Geom Actions / Loosen thing via Thyme.
I also want to access the Geom Actions / Loosen thing via Thyme.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
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.
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.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
Re: loosen script
the thing is, im am SPAWNING the hinge, several times over, so i cant have varibles. and i agree totally with Someone Else
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
Re: loosen script
so i cant have varibles
Yes, you can. I forget how to spawn with dynamic variables though. Doesn't it have something to do with geval?
-

TC42 - Posts: 984
- Joined: Sun Jan 09, 2011 1:53 pm
- Location: $ sudo apt get-install sandwich_
Re: loosen script
Try this code:
It declares two scene.my variables,
spawns three boxes joined together by two hinges,
and the hinges have their individual impulse break limits set to the variables.
Note that if you run this code, then in another, later collision that still happens while the boxes are falling, set scene.my.hinge1 and scene.my.hinge2 to 0, the hinges will not instantly break. Instead, they will hold together until the boxes hit something. Then the hinges will break and the boxes will fly apart.
- Code: Select all
scene.my.hinge1 = +inf;
scene.my.hinge2 = +inf;
Scene.addBox({
geomID := 28536;
pos := [15.0, -5.0];
size := [6.0, 2.0]
});
Scene.addBox({
geomID := 28535;
pos := [11.0, -5.0];
size := [6.0, 2.0]
});
Scene.addBox({
geomID := 28534;
pos := [7.0, -5.0];
size := [6.0, 2.0]
});
Scene.addHinge({
geom0 := 28536;
geom0pos := [-2.0, 0.0];
geom1 := 28535;
geom1pos := [2.0, 0.0];
impulseLimit := {scene.my.hinge1};
size := 0.7359517
});
Scene.addHinge({
geom0 := 28535;
geom0pos := [-2.0, 0.0];
geom1 := 28534;
geom1pos := [2.0, 0.0];
impulseLimit := {scene.my.hinge2};
size := 0.7359517
})
It declares two scene.my variables,
spawns three boxes joined together by two hinges,
and the hinges have their individual impulse break limits set to the variables.
Note that if you run this code, then in another, later collision that still happens while the boxes are falling, set scene.my.hinge1 and scene.my.hinge2 to 0, the hinges will not instantly break. Instead, they will hold together until the boxes hit something. Then the hinges will break and the boxes will fly apart.
Matthias Wandel is epic, in my humble opinion.
I love my brain...
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.
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.
-

Someone Else - Posts: 1147
- Joined: Sun Nov 21, 2010 10:53 pm
- Location: The Milky Way Galaxy
-

FuzzyLogicBrain - Posts: 315
- Joined: Mon Jan 31, 2011 7:48 pm
- Location: when online, on the computer. when not, probably on it anyways. ;D lulz
12 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 4 guests






