public void SearchForClues(Toggle heroDetecting, Toggle sideDetecting) { if (ClueMaster.numberOfCluesFound < ClueMaster.maxNumberOfClues) { Debug.Log("Obtaining additional clues"); //The characters' ability to find more clues is based on their intellect vs. some kind of difficulty int clueDifficulty = Random.Range(0, 5); //0 to 9? 10? 11? Should it be less random, and more calculated, like the activities? int heroRolledInt = 0; int sideRolledInt = 0; //If the Hero is obtaining clues if (heroDetecting.isOn) { heroRolledInt = (int)(StatsPlayer.valueInt * Random.Range(.5f, 1.5f)); } //If the Sidekick is obtaining clues if (sideDetecting.isOn) { sideRolledInt = (int)(StatsSidekick.valueInt * Random.Range(.5f, 1.5f)); } int totalRolledInt = (heroRolledInt + sideRolledInt); if (totalRolledInt >= clueDifficulty) { ClueMaster.GetAClue(); } else { Debug.Log("You failed to find another clue"); } //TOMAYBEDO Alternatively, they are guaranteed to find a clue, but there is some equal trade-off to not participating in the current activity //Takes more time to do (longer waitforseconds), less/no experience boost, more mental stress? //Debug.Log(ClueMaster.numberOfCluesFound); } else { Debug.Log("You have obtained the maximum number of clues to assist in your investigation"); } }
void DetermineIfClueFound() { //%chance of finding a "First Clue" on accomplishing the activity //TODO Knock down to 10% chance or so later (ALSO DO THE SAME ELSEWHERE, WHENEVER DETERMINING "chanceClueFound") //or have it influenced by the activity's difficulty/rarity/whatever int chanceClueFound = Random.Range(0, 100); if (NightHighTierManager.isHighTierActivityHere) { //High-tier activities give the player a better chance to find a clue chanceClueFound = (int)(chanceClueFound / 2); } if (ClueMaster.numberOfCluesFound < ClueMaster.maxNumberOfClues) { if (NightHighTierManager.isHighTierActivityHere) { //if (NightHighTierManager.gangInvolved == ClueMaster.gangInvolvedInEvent) { if (chanceClueFound < 100) { ClueMaster.GetAClue(); //Display each clue when found clueText.text = ("Clue found: " + ClueMaster.mostRecentClue); } //} } else { //if (NightManager.gangInvolved == ClueMaster.gangInvolvedInEvent) { if (chanceClueFound < 100) { ClueMaster.GetAClue(); //Display each clue when found clueText.text = ("Clue found: " + ClueMaster.mostRecentClue); } //} } } }