Page 1 of 1

Oncollide unfunctionable *Never Mind*

PostPosted: Sun Sep 06, 2009 7:13 pm
by Ian151
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:

Re: Oncollide unfunctionable *Never Mind*

PostPosted: Sun Sep 06, 2009 10:05 pm
by Versieon
just delete it then..

Re: Oncollide unfunctionable *Never Mind*

PostPosted: Mon Sep 07, 2009 3:05 am
by Ian151
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...

Re: Oncollide unfunctionable *Never Mind*

PostPosted: Mon Sep 07, 2009 6:58 pm
by Versieon
Yea, turns out that the serch bar was left out, hopefully they will fix it soon, they said they would!