I enjoyed this heavily LOL
The name is Markis, learnin’ C# for the first time. First course on Udemy that I’ve invested some time into, so I’m excited!
// Start is called before the first frame update
void Start()
{
Debug.Log("Yo, what's good B?! Welcome to my game!");
Debug.Log("Aye bruh, pick uh number dawg, somethin' easy though, aiight?");
Debug.Log("I'mma let it be like uhhhh....oh, aiight. Highest choice iz: " + max);
Debug.Log("Lowest numbah is: " + min);
Debug.Log("You get it yet? Aiight, BET. I'mma get'cho numbuh on'na FIRST TRY!!! So...is yo number higher den...: " + guess);
Debug.Log("Press the Arrow Up Key = Higher, Press Arrow Down = Lower, Enter Key = I got it right! I'm too crispy at dis, huh? :O");
int max = +1;
}
// Update is called once per frame
void Update()
{
if (Input.GetKeyDown(KeyCode.UpArrow))
{
min = guess;
guess = (max + min) / 2;
Debug.Log("Aiight, so it's higher? Bet. Is et:" + guess);
}
else if (Input.GetKeyDown(KeyCode.DownArrow))
{
max = guess;
guess = (max + min) / 2;
Debug.Log("Lower? I was WAY off! What about:" + guess);
}
else if (Input.GetKeyDown(KeyCode.Return))
{
Debug.Log("TOLD YOU! FIRST TRYYY!");
}
}
}