onIdle
21 posts • Page 1 of 1
onIdle
onIdle would be pretty much the exact opposite of onCollide. If we had onIdle then we would be able to have noncolliding parts have scripts that are running all the time and we would be able to have a script that runs all the time but "pauses" when something hits it and then "resumes" when nothing is hitting it. Do you get what I mean?
-

standardtoaster - Posts: 606
- Joined: Mon Aug 31, 2009 7:57 pm
Re: onIdle
There is essentially a way of doing this. If you have a part where one laser consistantly hits it, and then apply another laser, the laser that hit it lasts code seems to end up taking presidence over the last piece.
I cant remember exactly how it worked but i used such an idea in my seven segment display, i think it was mainly for color change. however, if you applied a check to the color of that box, you have a positive and negetive occurance from it.
I cant remember exactly how it worked but i used such an idea in my seven segment display, i think it was mainly for color change. however, if you applied a check to the color of that box, you have a positive and negetive occurance from it.

-

Torpedo - Posts: 120
- Joined: Mon Aug 31, 2009 8:51 pm
Re: onIdle
Torpedo wrote:There is essentially a way of doing this. If you have a part where one laser consistantly hits it, and then apply another laser, the laser that hit it lasts code seems to end up taking presidence over the last piece.
I cant remember exactly how it worked but i used such an idea in my seven segment display, i think it was mainly for color change. however, if you applied a check to the color of that box, you have a positive and negetive occurance from it.
Yes, but having onIdle would make scripting noncolliding objects and the like a hell of a lot easier.
-

standardtoaster - Posts: 606
- Joined: Mon Aug 31, 2009 7:57 pm
Re: onIdle
standardtoaster wrote: ... have scripts that are running all the time ...
But then someone will end up accidentally, while working on their scene, putting a spawn code in the onIdle box that was meant for the onCollide box, while working on a really big giant important scene of awesomeness. Algodoo will then crash, and then every time they try opening Algodoo back up again it will load the onExitSave scene and Algodoo will just end up crashing again, they will have to delete the scene to get Algodoo running again. Then said person will come to these forums and complain about how easy it is to get onIdle and onCollide mixed up, and will then fight to have onIdle abolished.
Or, someone could create something really awesome with this type of thing, and you will be praised for suggesting this.
Either way, I support.
-

Laraso - Posts: 241
- Joined: Tue Sep 01, 2009 12:54 am
- Location: What are you, a stalker?
Re: onIdle
Laraso wrote:standardtoaster wrote: ... have scripts that are running all the time ...
But then someone will end up accidentally, while working on their scene, putting a spawn code in the onIdle box that was meant for the onCollide box, while working on a really big giant important scene of awesomeness. Algodoo will then crash, and then every time they try opening Algodoo back up again it will load the onExitSave scene and Algodoo will just end up crashing again, they will have to delete the scene to get Algodoo running again. Then said person will come to these forums and complain about how easy it is to get onIdle and onCollide mixed up, and will then fight to have onIdle abolished.
Or, someone could create something really awesome with this type of thing, and you will be praised for suggesting this.
Either way, I support.
Your first argument is basically the same thing as saying that onHitByLaser is to easily confused with onCollide. If that's the case then just copy and paste the script from one place to another. Either way, thanks for the support. ;D
-

standardtoaster - Posts: 606
- Joined: Mon Aug 31, 2009 7:57 pm
Re: onIdle
standardtoaster wrote:Your first argument is basically the same thing as saying that onHitByLaser is to easily confused with onCollide. ... Either way, thanks for the support. ;D
Well... Someone could confuse the two, but then it would only screw up everything if it got hit by a laser. And the chances of that happening before someone has time to realize the problem then fix it aren't very high I don't think.
But with onIdle, scripts are running all the time, everytime!
And your welcome. I'm slowly getting ideas on a few things I could make with this.
-

Laraso - Posts: 241
- Joined: Tue Sep 01, 2009 12:54 am
- Location: What are you, a stalker?
Re: onIdle
Won't onIdle cause a hell of a lot of lag?
-

Sonic - Posts: 1467
- Joined: Tue Sep 01, 2009 6:18 pm
- Location: America!!!
Re: onIdle
not if you set a refresh timer in it.
also,
also,
RicH wrote:IN AN EFFORT TO RAISE MY POST COUNT
support.
Jrv wrote:TC42 wrote:Quite honestly, I didn't think anyone on 4chan has that good a use of grammar, spelling, usage, mechanics, ect.
But I've never been there, so I may be wrong.
GTFO newfgt
-

RA2lover - Posts: 607
- Joined: Mon Aug 31, 2009 8:43 pm
- Location: Brazil
Re: onIdle
Supported
-

niffirg1 - Posts: 376
- Joined: Mon Aug 31, 2009 10:31 pm
- Location: The Great American South!
Re: onIdle
I do think this would be usefull. support
-

Versieon - Posts: 375
- Joined: Tue Sep 01, 2009 4:45 pm
Re: onIdle
RA2lover wrote:RicH wrote:IN AN EFFORT TO RAISE MY POST COUNT
support.
ditto (to both those
TheWinkits wrote:They both looks of cuking amazing
-

Chronos - [Most Active Member 2010]
- Posts: 4457
- Joined: Mon Aug 31, 2009 6:00 pm
- Location: Californania
Re: onIdle
Now that I think about it, it would probobly be more usefull if it was an "onalways" script box. Tht way you could have things running all the time and able to collide or have it function like onidle. That way we could have both functions it one script area instead of just onidle
-

Versieon - Posts: 375
- Joined: Tue Sep 01, 2009 4:45 pm
Re: onIdle
After Ivanlul's question about this kind of thing I tried to make a solution for it and here it is:
http://www.algodoo.com/forum/viewtopic.php?f=13&t=2136
I just posted it here in case that anyone is still interested in using something like onIdle
You can also do this with the code
http://www.algodoo.com/forum/viewtopic.php?f=13&t=2136
I just posted it here in case that anyone is still interested in using something like onIdle
Versieon wrote:Now that I think about it, it would probobly be more usefull if it was an "onalways" script box. Tht way you could have things running all the time and able to collide or have it function like onidle. That way we could have both functions it one script area instead of just onidle
You can also do this with the code
Last edited by KarateBrot on Sun May 09, 2010 4:26 pm, edited 1 time in total.

-

KarateBrot - Posts: 825
- Joined: Mon Aug 31, 2009 7:32 pm
- Location: Germany
Re: onIdle
A while ago I was creating a scene. But I needed to make a loop for spawned movable objects. I couldn't find a way to solve this, but with an onIdle/loop script it would! Support!
Cave Johnson wrote:Do you know who I am? I'm the man who's gonna burn your house down! With the lemons! I'm gonna get my engineers to invent a combustible lemon that burns your house down!
-

Matten - Posts: 435
- Joined: Mon Apr 05, 2010 2:03 pm
- Location: The Netherlands
Re: onIdle
Uhm... To make something execute all the time, follow KarateBrot's link to the howto.
.. ,__,_____
. / __.==--" - - - - - - - - ""
./#(-'
.`-' From http://www.ascii-art.de/. Modded by me to work in Arial.
. / __.==--" - - - - - - - - ""
./#(-'
.`-' From http://www.ascii-art.de/. Modded by me to work in Arial.

a Mammoth wrote:be boring and interesting.
I didn't know you could go up 3.1.3! Thanks Mystery person!Mystery wrote:If you were jailbreaker you shouldn't have when't up the 3.1.3
-

Dakta - Posts: 417
- Joined: Sat Sep 12, 2009 4:36 pm
Re: onIdle
This could be useful in certain situations, but not all. Anyway I'll support because it could come in handy.

I don't suffer from insanity. I enjoy every minute of it.
-

Rrobba - [Best Sig 2010]
- Posts: 1480
- Joined: Mon Aug 31, 2009 6:01 pm
- Location: Gibraltar
Re: onIdle
Dakta wrote:Uhm... To make something execute all the time, follow KarateBrot's link to the howto.
I mean that the spawned objects need a loop, and with Karatebrot's way I would have a lot of script. With a loop script it would be very easy
Cave Johnson wrote:Do you know who I am? I'm the man who's gonna burn your house down! With the lemons! I'm gonna get my engineers to invent a combustible lemon that burns your house down!
-

Matten - Posts: 435
- Joined: Mon Apr 05, 2010 2:03 pm
- Location: The Netherlands
Re: onIdle
Admittedly yes, but I still say that implementing every single user requested feature is a stupid effort that leaves the software with too many things to reasonably support.
.. ,__,_____
. / __.==--" - - - - - - - - ""
./#(-'
.`-' From http://www.ascii-art.de/. Modded by me to work in Arial.
. / __.==--" - - - - - - - - ""
./#(-'
.`-' From http://www.ascii-art.de/. Modded by me to work in Arial.

a Mammoth wrote:be boring and interesting.
I didn't know you could go up 3.1.3! Thanks Mystery person!Mystery wrote:If you were jailbreaker you shouldn't have when't up the 3.1.3
-

Dakta - Posts: 417
- Joined: Sat Sep 12, 2009 4:36 pm
Re: onIdle
well just to add, an object's zdepth (objects in front of other objects) determines the priority over other scripts
so if you have too lasers both doing a script, the one that is on top of the other (overlapping) will take script priority
I support this though
so if you have too lasers both doing a script, the one that is on top of the other (overlapping) will take script priority
I support this though
- fox11trot
- Posts: 62
- Joined: Tue Sep 01, 2009 7:25 am
Re: onIdle
i only like it if it contains a refresh timer limit thingy coz otherwise it would be a lag monster
- Mr_Stabby
- Posts: 155
- Joined: Wed Dec 16, 2009 12:16 am
21 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 5 guests





