View Full Version : Animation starts randomly
Median
23rd Oct 2006, 07:54 PM
Hi!
Is it possible to make animations of objects start at certain time or randomly. I was thinking something like: fridge and doors opens, televisions goes on and off, dolls "playing" (<--- i have to get this after i saw that chucky doll ;) ) and some other "haunted house" stuff..
I thought if i make whole new "creepy" set of furniture for my haunted house
TIA
Smonaff
24th Oct 2006, 02:20 AM
Yes, this can all be set up in the objects Function - Main.
example:
0: [prim 0x0008] Random Number (Local 0x0000, Literal 0x003C) true:1 false:error
it 1: [global 0x016F] Idle - Minutes (Local 0x0000) true:2 false:error
2: (Have this line call the BHAV that does the animation) true:0 false:0
This will generate a random number between 0 and 60 and then idle for that many minutes, next it calls the BHAV that does the animation and then the process starts all over again with a new random number being selected.
note: make sure not to remove anything vital from Function - Main when adding any lines to it.
Median
24th Oct 2006, 08:24 AM
thanks! i'll give it a try
Median
24th Oct 2006, 07:20 PM
erm.. if functions - main is (private), can i do anything with it? i remember i've read something that you cant finger it if its locked or something..
sorry its been awhile since i played with simpe.. ;)
edit: typos
Median
24th Oct 2006, 08:03 PM
nevermind, i figured it out :P
Smonaff
24th Oct 2006, 08:13 PM
Private just means that it is used in the package only and not by any other package. You should be able to modify it without any problems.
vBulletin v3.0.14, Copyright ©2000-2013, Jelsoft Enterprises Ltd.