GODPAPER | All Packages | All Classes | Index | Frames No Frames |
PM_PRNG

Package | de.polygonal.math
Class | public class PM_PRNG
Inheritance | PM_PRNG Object

Public Properties

| Property | Defined By
--- | --- | ---
|  | seed : uint set seed with a 31 bit unsigned integer between 1 and 0X7FFFFFFE inclusive. | PM_PRNG

Public Methods

| Method | Defined By
--- | --- | ---
|  | PM_PRNG() | PM_PRNG
|  | nextDouble():Number provides the next pseudorandom number as a float between nearly 0 and nearly 1.0. | PM_PRNG
|  | nextDoubleRange(min:Number, max:Number):Number provides the next pseudorandom number as a float between a given range. | PM_PRNG
|  | nextInt():uint provides the next pseudorandom number as an unsigned integer (31 bits) | PM_PRNG
|  | nextIntRange(min:Number, max:Number):uint provides the next pseudorandom number as an unsigned integer (31 bits) betweeen a given range. | PM_PRNG

Property Detail

seed | property

`public var seed:uint`

set seed with a 31 bit unsigned integer between 1 and 0X7FFFFFFE inclusive. don't use 0!

Constructor Detail

PM_PRNG | () | Constructor

`public function PM_PRNG()`

Method Detail

nextDouble | () | method

`public function nextDouble():Number`

provides the next pseudorandom number as a float between nearly 0 and nearly 1.0.

Returns

| `Number`

nextDoubleRange | () | method |

`public function nextDoubleRange(min:Number, max:Number):Number`

provides the next pseudorandom number as a float between a given range.

Parameters

| `min:Number`
| `max:Number`

Returns

| `Number`

nextInt | () | method |

`public function nextInt():uint`

provides the next pseudorandom number as an unsigned integer (31 bits)

Returns

| `uint`

nextIntRange | () | method |

`public function nextIntRange(min:Number, max:Number):uint`

provides the next pseudorandom number as an unsigned integer (31 bits) betweeen a given range.

Parameters

| `min:Number`
| `max:Number`

Returns

| `uint`

Thu Jan 16 2014, 01:11 PM +08:00