GetRandomPercent (scripting)

Post » Tue Jun 19, 2012 3:01 am

Is their a event/function for this?

Cant seem to find a command that does the same thing.

:confused:
User avatar
NAkeshIa BENNETT
 
Posts: 3519
Joined: Fri Jun 16, 2006 12:23 pm

Post » Mon Jun 18, 2012 1:31 pm

http://www.creationkit.com/RandomInt_-_Utility
User avatar
mike
 
Posts: 3432
Joined: Fri Jul 27, 2007 6:51 pm

Post » Tue Jun 19, 2012 3:31 am

You can use Utility.RandomInt() (default min max are 0 and 100, so no need to add them)

Edit : ninja'd
User avatar
City Swagga
 
Posts: 3498
Joined: Sat May 12, 2007 1:04 am

Post » Mon Jun 18, 2012 2:40 pm

Yep thats what I thought about using...

Can anyone come up with an example how it might be used in a "If" function?

For example if it generates a int number between 1 and 25 then "whatever" happens.

:biggrin:
User avatar
Tanya
 
Posts: 3358
Joined: Fri Feb 16, 2007 6:01 am

Post » Tue Jun 19, 2012 1:03 am

I think this would work :

if Utility.RandomInt(1,100) <= 25;what happensendif
User avatar
Monika
 
Posts: 3469
Joined: Wed Jan 10, 2007 7:50 pm


Return to V - Skyrim