| [5352] | 1 | // Example particle systems | 
|---|
|  | 2 |  | 
|---|
|  | 3 | // Exudes greeny particles which float upwards | 
|---|
| [5689] | 4 | particle_system Examples/GreenyNimbus | 
|---|
| [5352] | 5 | { | 
|---|
|  | 6 | material        Examples/FlarePointSprite | 
|---|
|  | 7 | point_rendering true | 
|---|
|  | 8 | // point rendering means size is controlled by material | 
|---|
|  | 9 | // provide fallback sizes for hardware that doesn't support point sprite | 
|---|
|  | 10 | particle_width  30 | 
|---|
|  | 11 | particle_height 30 | 
|---|
|  | 12 | cull_each       false | 
|---|
|  | 13 | cull_each       false | 
|---|
|  | 14 | quota           10000 | 
|---|
|  | 15 | billboard_type  point | 
|---|
|  | 16 |  | 
|---|
|  | 17 | // Area emitter | 
|---|
|  | 18 | emitter Box | 
|---|
|  | 19 | { | 
|---|
|  | 20 | angle           30 | 
|---|
|  | 21 | emission_rate   30 | 
|---|
|  | 22 | time_to_live    5 | 
|---|
|  | 23 | direction       0 1 0 | 
|---|
|  | 24 | velocity        0 | 
|---|
|  | 25 | colour_range_start  1 1 0 | 
|---|
|  | 26 | colour_range_end    0.3 1 0.3 | 
|---|
|  | 27 | width           60 | 
|---|
|  | 28 | height          60 | 
|---|
|  | 29 | depth           60 | 
|---|
|  | 30 | } | 
|---|
|  | 31 |  | 
|---|
|  | 32 | // Make em float upwards | 
|---|
|  | 33 | affector LinearForce | 
|---|
|  | 34 | { | 
|---|
|  | 35 | force_vector      0 100 0 | 
|---|
|  | 36 | force_application add | 
|---|
|  | 37 | } | 
|---|
|  | 38 |  | 
|---|
|  | 39 | // Fader | 
|---|
|  | 40 | affector ColourFader | 
|---|
|  | 41 | { | 
|---|
|  | 42 | red -0.25 | 
|---|
|  | 43 | green -0.25 | 
|---|
|  | 44 | blue -0.25 | 
|---|
|  | 45 | } | 
|---|
|  | 46 |  | 
|---|
|  | 47 |  | 
|---|
|  | 48 | } | 
|---|
|  | 49 |  | 
|---|
|  | 50 | // A sparkly purple fountain | 
|---|
| [5689] | 51 | particle_system Examples/PurpleFountain | 
|---|
| [5352] | 52 | { | 
|---|
|  | 53 | material        Examples/Flare2 | 
|---|
|  | 54 | particle_width  20 | 
|---|
|  | 55 | particle_height 40 | 
|---|
|  | 56 | cull_each       false | 
|---|
|  | 57 | quota           10000 | 
|---|
|  | 58 | billboard_type  oriented_self | 
|---|
|  | 59 |  | 
|---|
|  | 60 | // Area emitter | 
|---|
|  | 61 | emitter Point | 
|---|
|  | 62 | { | 
|---|
|  | 63 | angle           15 | 
|---|
|  | 64 | emission_rate   75 | 
|---|
|  | 65 | time_to_live    3 | 
|---|
|  | 66 | direction       0 1 0 | 
|---|
|  | 67 | velocity_min    250 | 
|---|
|  | 68 | velocity_max    300 | 
|---|
|  | 69 | colour_range_start  0 0 0 | 
|---|
|  | 70 | colour_range_end    1 1 1 | 
|---|
|  | 71 | } | 
|---|
|  | 72 |  | 
|---|
|  | 73 | // Gravity | 
|---|
|  | 74 | affector LinearForce | 
|---|
|  | 75 | { | 
|---|
|  | 76 | force_vector      0 -100 0 | 
|---|
|  | 77 | force_application add | 
|---|
|  | 78 | } | 
|---|
|  | 79 |  | 
|---|
|  | 80 | // Fader | 
|---|
|  | 81 | affector ColourFader | 
|---|
|  | 82 | { | 
|---|
|  | 83 | red -0.25 | 
|---|
|  | 84 | green -0.25 | 
|---|
|  | 85 | blue -0.25 | 
|---|
|  | 86 | } | 
|---|
|  | 87 | } | 
|---|
|  | 88 |  | 
|---|
|  | 89 |  | 
|---|
|  | 90 | // A downpour | 
|---|
| [5689] | 91 | particle_system Examples/Rain | 
|---|
| [5352] | 92 | { | 
|---|
|  | 93 | material        Examples/Droplet | 
|---|
|  | 94 | particle_width  20 | 
|---|
|  | 95 | particle_height 100 | 
|---|
|  | 96 | cull_each       true | 
|---|
|  | 97 | quota           10000 | 
|---|
|  | 98 | // Make common direction straight down (faster than self oriented) | 
|---|
|  | 99 | billboard_type  oriented_common | 
|---|
|  | 100 | common_direction 0 -1 0 | 
|---|
|  | 101 |  | 
|---|
|  | 102 | // Area emitter | 
|---|
|  | 103 | emitter Box | 
|---|
|  | 104 | { | 
|---|
|  | 105 | angle           0 | 
|---|
|  | 106 | emission_rate   100 | 
|---|
|  | 107 | time_to_live    5 | 
|---|
|  | 108 | direction       0 -1 0 | 
|---|
|  | 109 | velocity        50 | 
|---|
|  | 110 | colour_range_start  0.3 1 0.3 | 
|---|
|  | 111 | colour_range_end    0.7 1 0.7 | 
|---|
|  | 112 | width           1000 | 
|---|
|  | 113 | height          1000 | 
|---|
|  | 114 | depth           0 | 
|---|
|  | 115 | } | 
|---|
|  | 116 |  | 
|---|
|  | 117 | // Gravity | 
|---|
|  | 118 | affector LinearForce | 
|---|
|  | 119 | { | 
|---|
|  | 120 | force_vector      0 -200 0 | 
|---|
|  | 121 | force_application add | 
|---|
|  | 122 | } | 
|---|
|  | 123 |  | 
|---|
|  | 124 | } | 
|---|
|  | 125 |  | 
|---|
|  | 126 | // A jet engine (of sorts) | 
|---|
| [5689] | 127 | particle_system Examples/JetEngine1 | 
|---|
| [5352] | 128 | { | 
|---|
|  | 129 | material                Examples/Flare | 
|---|
|  | 130 | particle_width  25 | 
|---|
|  | 131 | particle_height 25 | 
|---|
|  | 132 | cull_each               false | 
|---|
|  | 133 | quota                   200 | 
|---|
|  | 134 | billboard_type  point | 
|---|
|  | 135 |  | 
|---|
|  | 136 | emitter Point | 
|---|
|  | 137 | { | 
|---|
|  | 138 | angle 5 | 
|---|
|  | 139 | emission_rate 100 | 
|---|
|  | 140 | time_to_live    1 | 
|---|
|  | 141 | direction       0 -1 0 | 
|---|
|  | 142 | velocity_min    250 | 
|---|
|  | 143 | velocity_max    300 | 
|---|
|  | 144 | colour_range_start  1 1 0.5 | 
|---|
|  | 145 | colour_range_end    1 0.8 0.3 | 
|---|
|  | 146 |  | 
|---|
|  | 147 | } | 
|---|
|  | 148 | affector ColourFader | 
|---|
|  | 149 | { | 
|---|
|  | 150 | red -0.25 | 
|---|
|  | 151 | green -1 | 
|---|
|  | 152 | blue -1 | 
|---|
|  | 153 | } | 
|---|
|  | 154 |  | 
|---|
|  | 155 | } | 
|---|
| [5689] | 156 | particle_system Examples/JetEngine2 | 
|---|
| [5352] | 157 | { | 
|---|
|  | 158 | material                Examples/Flare | 
|---|
|  | 159 | particle_width  15 | 
|---|
|  | 160 | particle_height 15 | 
|---|
|  | 161 | cull_each               false | 
|---|
|  | 162 | quota                   200 | 
|---|
|  | 163 | billboard_type  point | 
|---|
|  | 164 |  | 
|---|
|  | 165 | emitter Point | 
|---|
|  | 166 | { | 
|---|
|  | 167 | angle 3 | 
|---|
|  | 168 | emission_rate 100 | 
|---|
|  | 169 | time_to_live    1 | 
|---|
|  | 170 | direction       0 -1 0 | 
|---|
|  | 171 | velocity_min    350 | 
|---|
|  | 172 | velocity_max    400 | 
|---|
|  | 173 | colour_range_start  0.5 1 1 | 
|---|
|  | 174 | colour_range_end    0.3 0.8 1 | 
|---|
|  | 175 |  | 
|---|
|  | 176 | } | 
|---|
|  | 177 | affector ColourFader | 
|---|
|  | 178 | { | 
|---|
|  | 179 | red -1 | 
|---|
|  | 180 | green -1 | 
|---|
|  | 181 | blue -0.5 | 
|---|
|  | 182 | } | 
|---|
|  | 183 |  | 
|---|
|  | 184 | } | 
|---|
|  | 185 |  | 
|---|
|  | 186 | // Exudes aureola particles which around the model float upwards | 
|---|
| [5689] | 187 | particle_system Examples/Aureola | 
|---|
| [5352] | 188 | { | 
|---|
|  | 189 | material        Examples/Aureola | 
|---|
|  | 190 | particle_width  200 | 
|---|
|  | 191 | particle_height 200 | 
|---|
|  | 192 | cull_each       false | 
|---|
|  | 193 | quota           100 | 
|---|
|  | 194 | billboard_type  perpendicular_common | 
|---|
|  | 195 | common_direction 0 1 0 | 
|---|
|  | 196 | common_up_vector 0 0 1 | 
|---|
|  | 197 |  | 
|---|
|  | 198 | // Area emitter | 
|---|
|  | 199 | emitter Box | 
|---|
|  | 200 | { | 
|---|
|  | 201 | angle           30 | 
|---|
|  | 202 | emission_rate   4 | 
|---|
|  | 203 | time_to_live    5 | 
|---|
|  | 204 | position        0 -100 0 | 
|---|
|  | 205 | direction       0 1 0 | 
|---|
|  | 206 | velocity_min    0 | 
|---|
|  | 207 | velocity_max    30 | 
|---|
|  | 208 | colour_range_start  0.3 0.3 0.3 0.0 | 
|---|
|  | 209 | colour_range_end    0.8 0.8 0.8 0.0 | 
|---|
|  | 210 | width           10 | 
|---|
|  | 211 | height          10 | 
|---|
|  | 212 | depth           30 | 
|---|
|  | 213 | } | 
|---|
|  | 214 |  | 
|---|
|  | 215 | // Make em float upwards | 
|---|
|  | 216 | affector LinearForce | 
|---|
|  | 217 | { | 
|---|
|  | 218 | force_vector      0 70 0 | 
|---|
|  | 219 | force_application add | 
|---|
|  | 220 | } | 
|---|
|  | 221 |  | 
|---|
|  | 222 | // Fader | 
|---|
|  | 223 | affector ColourFader2 | 
|---|
|  | 224 | { | 
|---|
|  | 225 | red1 +0.4 | 
|---|
|  | 226 | green1 +0.4 | 
|---|
|  | 227 | blue1 +0.4 | 
|---|
|  | 228 | alpha1 +0.7 | 
|---|
|  | 229 |  | 
|---|
|  | 230 | red2 -0.25 | 
|---|
|  | 231 | green2 -0.25 | 
|---|
|  | 232 | blue2 -0.25 | 
|---|
|  | 233 | alpha2 -0.3333 | 
|---|
|  | 234 |  | 
|---|
|  | 235 | state_change 3.5 | 
|---|
|  | 236 | } | 
|---|
|  | 237 |  | 
|---|
|  | 238 | // Rotater | 
|---|
|  | 239 | affector Rotator | 
|---|
|  | 240 | { | 
|---|
|  | 241 | rotation_range_start 0 | 
|---|
|  | 242 | rotation_range_end 360 | 
|---|
|  | 243 | rotation_speed_range_start 0 | 
|---|
|  | 244 | rotation_speed_range_end 180 | 
|---|
|  | 245 | } | 
|---|
|  | 246 | } | 
|---|
|  | 247 |  | 
|---|
|  | 248 |  | 
|---|
| [5689] | 249 | particle_system Examples/Swarm | 
|---|
| [5352] | 250 | { | 
|---|
|  | 251 | quota   3000 | 
|---|
|  | 252 | material        Examples/Flare2 | 
|---|
|  | 253 | particle_width  12 | 
|---|
|  | 254 | particle_height 24 | 
|---|
|  | 255 | cull_each       true | 
|---|
|  | 256 | renderer        billboard | 
|---|
|  | 257 | sorted  true | 
|---|
|  | 258 | local_space     false | 
|---|
|  | 259 | billboard_type  oriented_self | 
|---|
|  | 260 |  | 
|---|
|  | 261 | emitter Box | 
|---|
|  | 262 | { | 
|---|
|  | 263 | angle   180 | 
|---|
|  | 264 | colour  1 1 1 1 | 
|---|
|  | 265 | colour_range_start      1 1 1 1 | 
|---|
|  | 266 | colour_range_end        1 1 1 1 | 
|---|
|  | 267 | direction       0 1 0 | 
|---|
|  | 268 | emission_rate   30 | 
|---|
|  | 269 | position        0 0 0 | 
|---|
|  | 270 | velocity        50 | 
|---|
|  | 271 | velocity_min    50 | 
|---|
|  | 272 | velocity_max    1 | 
|---|
|  | 273 | time_to_live    20 | 
|---|
|  | 274 | time_to_live_min        20 | 
|---|
|  | 275 | time_to_live_max        20 | 
|---|
|  | 276 | duration        0 | 
|---|
|  | 277 | duration_min    0 | 
|---|
|  | 278 | duration_max    0 | 
|---|
|  | 279 | repeat_delay    0 | 
|---|
|  | 280 | repeat_delay_min        0 | 
|---|
|  | 281 | repeat_delay_max        0 | 
|---|
|  | 282 | width   80 | 
|---|
|  | 283 | height  80 | 
|---|
|  | 284 | depth   80 | 
|---|
|  | 285 | } | 
|---|
|  | 286 |  | 
|---|
|  | 287 | affector ColourFader | 
|---|
|  | 288 | { | 
|---|
|  | 289 | red     -0.05 | 
|---|
|  | 290 | green   0 | 
|---|
|  | 291 | blue    0 | 
|---|
|  | 292 | alpha   0 | 
|---|
|  | 293 | } | 
|---|
|  | 294 |  | 
|---|
|  | 295 | affector DeflectorPlane | 
|---|
|  | 296 | { | 
|---|
|  | 297 | plane_point     0 -50 0 | 
|---|
|  | 298 | plane_normal    0 1 0 | 
|---|
|  | 299 | bounce  1 | 
|---|
|  | 300 | } | 
|---|
|  | 301 |  | 
|---|
|  | 302 | affector DeflectorPlane | 
|---|
|  | 303 | { | 
|---|
|  | 304 | plane_point     0 50 0 | 
|---|
|  | 305 | plane_normal    0 -1 0 | 
|---|
|  | 306 | bounce  1 | 
|---|
|  | 307 | } | 
|---|
|  | 308 |  | 
|---|
|  | 309 | affector DeflectorPlane | 
|---|
|  | 310 | { | 
|---|
|  | 311 | plane_point     50 0 0 | 
|---|
|  | 312 | plane_normal    -1 0 0 | 
|---|
|  | 313 | bounce  1 | 
|---|
|  | 314 | } | 
|---|
|  | 315 |  | 
|---|
|  | 316 | affector DeflectorPlane | 
|---|
|  | 317 | { | 
|---|
|  | 318 | plane_point     -50 0 0 | 
|---|
|  | 319 | plane_normal    1 0 0 | 
|---|
|  | 320 | bounce  1 | 
|---|
|  | 321 | } | 
|---|
|  | 322 |  | 
|---|
|  | 323 | affector DeflectorPlane | 
|---|
|  | 324 | { | 
|---|
|  | 325 | plane_point     0 0 50 | 
|---|
|  | 326 | plane_normal    0 0 -1 | 
|---|
|  | 327 | bounce  1 | 
|---|
|  | 328 | } | 
|---|
|  | 329 |  | 
|---|
|  | 330 | affector DeflectorPlane | 
|---|
|  | 331 | { | 
|---|
|  | 332 | plane_point     0 0 -50 | 
|---|
|  | 333 | plane_normal    0 0 1 | 
|---|
|  | 334 | bounce  1 | 
|---|
|  | 335 | } | 
|---|
|  | 336 |  | 
|---|
|  | 337 | affector DirectionRandomiser | 
|---|
|  | 338 | { | 
|---|
|  | 339 | randomness      60 | 
|---|
|  | 340 | } | 
|---|
|  | 341 | } | 
|---|
|  | 342 |  | 
|---|
|  | 343 |  | 
|---|
| [5689] | 344 | particle_system Examples/Snow | 
|---|
| [5352] | 345 | { | 
|---|
|  | 346 | quota   2000 | 
|---|
|  | 347 | material        Examples/Flare | 
|---|
|  | 348 | particle_width  4 | 
|---|
|  | 349 | particle_height 4 | 
|---|
|  | 350 | cull_each       true | 
|---|
|  | 351 | renderer        billboard | 
|---|
|  | 352 | sorted  true | 
|---|
|  | 353 | local_space     false | 
|---|
|  | 354 | billboard_type  point | 
|---|
|  | 355 |  | 
|---|
|  | 356 | emitter Box | 
|---|
|  | 357 | { | 
|---|
|  | 358 | angle   0 | 
|---|
|  | 359 | colour  1 1 1 1 | 
|---|
|  | 360 | colour_range_start      1 1 1 1 | 
|---|
|  | 361 | colour_range_end        1 1 1 1 | 
|---|
|  | 362 | direction       0 -1 0 | 
|---|
|  | 363 | emission_rate   100 | 
|---|
|  | 364 | position        0 200 0 | 
|---|
|  | 365 | velocity        20 | 
|---|
|  | 366 | velocity_min    20 | 
|---|
|  | 367 | velocity_max    20 | 
|---|
|  | 368 | time_to_live    20 | 
|---|
|  | 369 | time_to_live_min        20 | 
|---|
|  | 370 | time_to_live_max        20 | 
|---|
|  | 371 | duration        0 | 
|---|
|  | 372 | duration_min    0 | 
|---|
|  | 373 | duration_max    0 | 
|---|
|  | 374 | repeat_delay    0 | 
|---|
|  | 375 | repeat_delay_min        0 | 
|---|
|  | 376 | repeat_delay_max        0 | 
|---|
|  | 377 | width   200 | 
|---|
|  | 378 | height  200 | 
|---|
|  | 379 | depth   1 | 
|---|
|  | 380 | } | 
|---|
|  | 381 |  | 
|---|
|  | 382 | affector DeflectorPlane | 
|---|
|  | 383 | { | 
|---|
|  | 384 | plane_point     0 0 0 | 
|---|
|  | 385 | plane_normal    0 1 0 | 
|---|
|  | 386 | bounce  0 | 
|---|
|  | 387 | } | 
|---|
|  | 388 |  | 
|---|
|  | 389 | affector DirectionRandomiser | 
|---|
|  | 390 | { | 
|---|
|  | 391 | randomness      10 | 
|---|
|  | 392 | } | 
|---|
|  | 393 | } | 
|---|
|  | 394 |  | 
|---|
|  | 395 |  | 
|---|