Box spawning help...
5 posts • Page 1 of 1
Box spawning help...
I want to spawn ONE box, i got it to spawn , but it makes five instead... whats wrong? Heres the script:
- Code: Select all
(e)=>{
Scene.addbox({ collideSet := 9; Color := [0.755, 0.74400002, 0.068000004, 1.0]; size := [0.30000001, 0.1]; vel := e.normal((*)) }); scene.addpen({ color := [0.77499998, 0.764, 0.07, 0.76499999]; size := 0.1 }) }
Check out my stuff HERE!
MY WEB SITE HERE!
Sorry, I just had to.
Phundamentalist!
MY WEB SITE HERE!
Sorry, I just had to.
Phundamentalist!
Mystery wrote:I'm convinced that dezzerons scenes are all epic. He's one of the biggest underdogs of algobox.
-
Dezzeron - Posts: 296
- Joined: Tue Sep 01, 2009 12:45 am
- Location: Dark Side Of The Moon
Re: Box spawning help...
The collider that spawns the box is probobly hiting more than once.
-
Versieon - Posts: 375
- Joined: Tue Sep 01, 2009 4:45 pm
Re: Box spawning help...
I'm assuming you put this in onCollide (phun user?), it works fine here, are you sure the object isn't colliding multiple times?
EDIT: dang Versieon beat me
And the pen doesn't spawn with the box.
this code sort of works, if the spawner moves too much (very little) the pen will spawn on one of the colliding objects and not the bullet.
EDIT: dang Versieon beat me
And the pen doesn't spawn with the box.
- Code: Select all
(e)=>{Scene.addbox({ collideSet := 9; Color := [0.755, 0.74400002, 0.068000004, 1.0]; size := [0.30000001, 0.1]; vel := e.normal((*)) }); scene.addpen({ color := [0.77499998, 0.764, 0.07, 0.76499999]; size := 0.1 })}
this code sort of works, if the spawner moves too much (very little) the pen will spawn on one of the colliding objects and not the bullet.
Newbie Thymer
Intermediate Phuner
Intermediate Phuner
- Cs24
- Posts: 41
- Joined: Tue Nov 03, 2009 5:30 am
Re: Box spawning help...
That code doesnt work at all, I'll check if it's colliding multiple times... and I dont even want the pen, the code just wont delete...
Check out my stuff HERE!
MY WEB SITE HERE!
Sorry, I just had to.
Phundamentalist!
MY WEB SITE HERE!
Sorry, I just had to.
Phundamentalist!
Mystery wrote:I'm convinced that dezzerons scenes are all epic. He's one of the biggest underdogs of algobox.
-
Dezzeron - Posts: 296
- Joined: Tue Sep 01, 2009 12:45 am
- Location: Dark Side Of The Moon
Re: Box spawning help...
oh whoops wrong script
that should (...) work (typing at school)
do the colliding objects have 0 restitution? that fixes it for me
- Code: Select all
(e)=>{
Scene.addbox({ pos:=e.pos; collideSet := 9; Color := [0.755, 0.755, 0.068, 1.0]; size := [0.3, 0.1]; vel := e.normal((*)) }); }
that should (...) work (typing at school)
do the colliding objects have 0 restitution? that fixes it for me
Newbie Thymer
Intermediate Phuner
Intermediate Phuner
- Cs24
- Posts: 41
- Joined: Tue Nov 03, 2009 5:30 am
5 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 18 guests