Oncollide unfunctionable *Never Mind*

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

Oncollide unfunctionable *Never Mind*

Postby Ian151 » Sun Sep 06, 2009 7:13 pm

I tried checking the code frequently and found it to fail each time. I even transferred the code to another object that the box will collide with. I have the box hitting the oncollide box on a hinge. Idk if this is affecting it but I get this error a few times in the scene.

- - Warning: FixJointEntity:: add to simulation had body not in sim

But now that I think about it that could be in another scene I made where I created fixjoints.

Here is the code that seems as if it was never there...

Code: Select all
(e)=>{
    scene.addcircle({         collideset := 4;         radius := 0.4;         color := [0.5, 0.5, 1, 1];         restitution := 1;         oncollide := (e)=>{             e.other.team == 2 ? {                 e.other.hp = e.other.hp - 40;                 e.other.hp <= 0 ? {e.other.density = NaN} : {};                 e.this.density = NaN             } : {};             e.other.team == 0 ? {e.this.density = NaN} : {}         };         drawborder := false;         drawcake := false     }) }


Any help would be greatly appreciated. I shall even post the end result on algobox and here if you would like.

EDIT: Oh wow... I feel really dumb... I missed e.pos so nvm this thread is useless sorry for the mistake :crazy:
"THE BEST 2 PLAYER SCENE EVER MADE!!!" - ianno
http://www.algodoo.com/algobox/details.php?id=24204
Image
User avatar
Ian151
 
Posts: 47
Joined: Tue Sep 01, 2009 12:02 am

Re: Oncollide unfunctionable *Never Mind*

Postby Versieon » Sun Sep 06, 2009 10:05 pm

just delete it then..
User avatar
Versieon
 
Posts: 375
Joined: Tue Sep 01, 2009 4:45 pm

Re: Oncollide unfunctionable *Never Mind*

Postby Ian151 » Mon Sep 07, 2009 3:05 am

Versieon wrote:just delete it then..

I would but after the second time of searching I couldn't even see such a button or option! This forum is confusing, I'm sorry.
Along with that I can't find a search feature either, I thought the search bar on the banner would help but I still feel like I can't use this website correctly...
"THE BEST 2 PLAYER SCENE EVER MADE!!!" - ianno
http://www.algodoo.com/algobox/details.php?id=24204
Image
User avatar
Ian151
 
Posts: 47
Joined: Tue Sep 01, 2009 12:02 am

Re: Oncollide unfunctionable *Never Mind*

Postby Versieon » Mon Sep 07, 2009 6:58 pm

Yea, turns out that the serch bar was left out, hopefully they will fix it soon, they said they would!
User avatar
Versieon
 
Posts: 375
Joined: Tue Sep 01, 2009 4:45 pm


Return to Thyme scripting

Who is online

Users browsing this forum: No registered users and 1 guest

cron