Lines Matching refs:totalWeight
464 $totalWeight = 0;
469 $totalWeight += (int) $arr[1];
489 array_push($toc, $this->dadaMakeHeadline($words, $totalWeight)); // $toc
498 echo $this->dadaMakeParagraph($words, $totalWeight);
505 echo $this->dadaMakeSection($words, $totalWeight, $hl);
509 private function dadaMakeSection($words, $totalWeight, $hl) { argument
531 $sec .= $this->dadaMakeParagraph($words, $totalWeight);
538 private function dadaMakeHeadline($words, $totalWeight) { argument
549 array_push($hlArr, $this->dadaSelectRandomWord($words, $totalWeight));
561 private function dadaMakeParagraph($words, $totalWeight) { argument
568 array_push($paragraph, $this->dadaMakeSentence($words, $totalWeight));
575 private function dadaMakeSentence($words, $totalWeight) { argument
583 array_push($sentence, $this->dadaSelectRandomWord($words, $totalWeight));
590 private function dadaSelectRandomWord($list, $totalWeight) { argument
593 $rand = mt_rand(0, $totalWeight);