This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| dragengine:modules:dragonscript:behavior_attachable_randomizegeometry [2025/10/28 14:52] – created dragonlord | dragengine:modules:dragonscript:behavior_attachable_randomizegeometry [2025/10/28 17:14] (current) – removed dragonlord | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | {{tag> | ||
| - | <WRAP youarehere> | ||
| - | [[: | ||
| - | </ | ||
| - | |||
| - | * [[behaviors_use_cases|Behaviors Explained: By Use-Case]] | ||
| - | * [[behaviors_a_to_z|Behaviors Explained: From A to Z]] | ||
| - | |||
| - | ====== ECABehaviorRandomizeGeometry ====== | ||
| - | |||
| - | Attachable element behavior randomizing geometry of element. | ||
| - | |||
| - | Upon adding the behavior to an element the geometry of the element is randomized. After this point the behavior has no effect anymore and can be removed if desired. | ||
| - | |||
| - | Main use for this behavior though is using attachable behavior factory by adding the behavior to an element in the world editor. Used this way the randomization is applied during factory create behavior call without actually adding the behavior to the element. This way the randomization is applied once during element instantiation without keeping the behavior around. Randomization uses element stub properties with prefix '' | ||
| - | |||
| - | ====== Element Class Properties ====== | ||
| - | |||
| - | Element class properties have the prefix '' | ||
| - | |||
| - | ===== position ===== | ||
| - | |||
| - | Move element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== positionMinimum ===== | ||
| - | |||
| - | Move element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== positionMaximum ===== | ||
| - | |||
| - | Move element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== rotation ===== | ||
| - | |||
| - | Rotate element by a random amount in degrees from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== rotationMinimum ===== | ||
| - | |||
| - | Rotate element by a random amount in degrees from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== rotationMaximum ===== | ||
| - | |||
| - | Rotate element by a random amount in degrees from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: 3-point float vector | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== scale ===== | ||
| - | |||
| - | Uniformly scale element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: float | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== scaleMinimum ===== | ||
| - | |||
| - | Uniformly scale element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: float | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ===== scaleMaximum ===== | ||
| - | |||
| - | Uniformly scale element by a random amount from the range '' | ||
| - | |||
| - | * Full name: '' | ||
| - | * Type: float | ||
| - | * Default value: '' | ||
| - | * Example (*.deeclass): | ||
| - | |||
| - | ====== Required Behaviors ====== | ||
| - | |||
| - | This behavior does not required other behaviors. | ||
| - | |||
| - | ====== Optional Behaviors ====== | ||
| - | |||
| - | This behavior does not support optional behaviors. | ||
| - | |||
| - | ====== Persistency ====== | ||
| - | |||
| - | This behavior does not required element class to be persistable (setPersistable). | ||
| - | |||
| - | ====== API Documentation ====== | ||
| - | |||
| - | # | ||
| - | |||
| - | Since DragonScript Module Version '' | ||
| - | |||
| - | ====== Use Cases ====== | ||
| - | |||
| - | * Randomize scaling and rotation of elements to make worlds less uniform. | ||