Lines Matching refs:totalWeight
443 $totalWeight = 0;
448 $totalWeight += (int) $arr[1];
468 array_push($toc, $this->dadaMakeHeadline($words, $totalWeight)); // $toc
477 echo $this->dadaMakeParagraph($words, $totalWeight);
484 echo $this->dadaMakeSection($words, $totalWeight, $hl);
488 private function dadaMakeSection($words, $totalWeight, $hl) { argument
510 $sec .= $this->dadaMakeParagraph($words, $totalWeight);
517 private function dadaMakeHeadline($words, $totalWeight) { argument
528 array_push($hlArr, $this->dadaSelectRandomWord($words, $totalWeight));
540 private function dadaMakeParagraph($words, $totalWeight) { argument
547 array_push($paragraph, $this->dadaMakeSentence($words, $totalWeight));
554 private function dadaMakeSentence($words, $totalWeight) { argument
562 array_push($sentence, $this->dadaSelectRandomWord($words, $totalWeight));
569 private function dadaSelectRandomWord($list, $totalWeight) { argument
572 $rand = mt_rand(0, $totalWeight);