collideSet help.
2 posts • Page 1 of 1
collideSet help.
So, recently, I've been trying learning more about the thyme scriping. Once I learned how to use the collideSet script, I was thinking about making a bowling alley. Since there is 10 pins in a bowling game and 10 different collision layers, it could have been a big advantage to make an alley, but the problem is that I couldn't fing a way to randomize the collision layer for the bowling ball so the scores can vary depending of the collisions of the bowling ball. Is there a way to randomizr the collideSet number? (sorry if my sentences aren't clear, englist isn't my first language)
- Copsicle
- Posts: 1
- Joined: Sat May 26, 2018 12:30 am
Re: collideSet help.
since Algodoo doesn't support bitwise operators, you gotta make collisions like this:
collideset = 0;
for(10,(i)=>{
collideset = collideset + rand.boolean*2^i
});
collideset = 0;
for(10,(i)=>{
collideset = collideset + rand.boolean*2^i
});
- FRA32
- Posts: 229
- Joined: Wed Dec 03, 2014 9:51 pm
2 posts • Page 1 of 1
Who is online
Users browsing this forum: No registered users and 19 guests