![]() |
|
#2
|
|||
|
|||
|
If you are storing all these cubes in a list, then you can use the random.choice() function to get a random cube from the list. Example code:
Code:
import random # List containing all cube objects cubeList = [...] # Select a random cube from the list randomCube = random.choice(cubeList) |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| retrieve Object names | Geoffrey | Vizard | 11 | 12-11-2009 05:26 AM |
| Can you link the position of a tracker to the orientation of an object? | michaelrepucci | Vizard | 1 | 09-19-2008 11:23 AM |
| Getting object position in screen coordinates | v-Salik | Vizard | 1 | 10-19-2007 04:41 PM |
| picking problem... | k_iwan | Vizard | 2 | 07-27-2007 08:57 PM |
| rotate to object | jargon | Vizard | 1 | 08-08-2005 01:20 PM |