| 924 | } |
| 925 | |
| 926 | void SfxrNode::explosion() |
| 927 | { |
| 928 | setDefaultBeep(); |
| 929 | _waveType->setEnumeration(NOISE); |
| 930 | if (rnd(1)) |
| 931 | { |
| 932 | _startFrequency->setValue(sqr(0.1f + frnd(0.4f))); |
| 933 | _slide->setValue(-0.1f + frnd(0.4f)); |
| 934 | } |
| 935 | else |
| 936 | { |
| 937 | _startFrequency->setValue(sqr(0.2f + frnd(0.7f))); |
| 938 | _slide->setValue(-0.2f - frnd(0.2f)); |
| 939 | } |
| 940 | if (rnd(4) == 0) |
| 941 | _slide->setValue(0); |
| 942 | if (rnd(2) == 0) |
| 943 | _repeatSpeed->setValue(0.3f + frnd(0.5f)); |
| 944 | _attack->setValue(0); |
| 945 | _sustainTime->setValue(0.1f + frnd(0.3f)); |
| 946 | _decayTime->setValue(frnd(0.5f)); |
| 947 | if (rnd(1)) |
| 948 | { |
| 949 | _phaserOffset->setValue(-0.3f + frnd(0.9f)); |
| 950 | _phaserSweep->setValue(-frnd(0.3f)); |
| 951 | } |
| 952 | _sustainPunch->setValue(0.2f + frnd(0.6f)); |
| 953 | if (rnd(1)) |
| 954 | { |
| 955 | _vibratoDepth->setValue(frnd(0.7f)); |
| 956 | _vibratoSpeed->setValue(frnd(0.6f)); |
| 957 | } |
| 958 | if (rnd(2) == 0) |
| 959 | { |
| 960 | _changeSpeed->setValue(0.6f + frnd(0.3f)); |
| 961 | _changeAmount->setValue(0.8f - frnd(1.6f)); |
| 962 | } |
| 963 | } |
| 964 | |
| 965 | void SfxrNode::powerUp() |
| 966 | { |