Suppose you have some sounds in your selection that you'd like ZDoom to play more rarely than others. Say you've added a couple new alert sounds for the Zombieman, and want him to (rarely) exclaim "aw crap!" or "I'm hungry!"
Currently, you're forced to do this:
Code: Select all
$random grunt/sight
{
grunt/sight1
grunt/sight1
grunt/sight1
grunt/sight1
grunt/sight2
grunt/sight2
grunt/sight2
grunt/sight2
grunt/sight3
grunt/sight3
grunt/sight3
grunt/sight3
grunt/sight4
grunt/sight5
}
Note how long and messy this is.
Suppose you could do this, instead:
Code: Select all
$random grunt/sight
{
grunt/sight1 4
grunt/sight2 4
grunt/sight3 4
grunt/sight4 1
grunt/sight5 1
}
(Of course, not specifying a wight defaults to 1. Also, I guess a weight of 0 would keep it from even being added, for whatever reason.)
Suppose you have some sounds in your selection that you'd like ZDoom to play more rarely than others. Say you've added a couple new alert sounds for the Zombieman, and want him to (rarely) exclaim "aw crap!" or "I'm hungry!"
Currently, you're forced to do this:[code]$random grunt/sight
{
grunt/sight1
grunt/sight1
grunt/sight1
grunt/sight1
grunt/sight2
grunt/sight2
grunt/sight2
grunt/sight2
grunt/sight3
grunt/sight3
grunt/sight3
grunt/sight3
grunt/sight4
grunt/sight5
}[/code]Note how long and messy this is.
Suppose you could do this, instead:[code]$random grunt/sight
{
grunt/sight1 4
grunt/sight2 4
grunt/sight3 4
grunt/sight4 1
grunt/sight5 1
}[/code](Of course, not specifying a wight defaults to 1. Also, I guess a weight of 0 would keep it from even being added, for whatever reason.)