Want to see a super annoying if, else statement?
I r t3h sux at programming, lol.
I r t3h sux at programming, lol.
Code:
if (tempStr == "OemTilde") { hasBeenChecked = "~"; return hasBeenChecked; } else if (tempStr == "Capital") { hasBeenChecked = " *Capslock* "; //I hate dealing with these...blah. return hasBeenChecked; } if (tempStr == "Oem5") { hasBeenChecked = "\\"; return hasBeenChecked; } else if (tempStr == "Oemplus") { // bool shiftKeyDown = gkh.ShiftKeyDown; //bool operator used to determine if (shiftKeyDown == true) //if the shift key is depressed (duh). { hasBeenChecked = "+"; //is depressed return hasBeenChecked; } else { hasBeenChecked = "="; //is not depressed return hasBeenChecked; } } else if (tempStr == "OemMinus") { // bool shiftKeyDown = gkh.ShiftKeyDown; //bool for shift key depression if (shiftKeyDown == true) { hasBeenChecked = "_"; //depressed return hasBeenChecked; } else { hasBeenChecked = "-"; //not depressed return hasBeenChecked; } } else if (tempStr == "D0") { if (shiftKeyDown == true) { hasBeenChecked = ")"; return hasBeenChecked; } else { hasBeenChecked = "0"; return hasBeenChecked; } } else if (tempStr == "D9") { if (shiftKeyDown == true) { hasBeenChecked = "("; return hasBeenChecked; } else { hasBeenChecked = "9"; return hasBeenChecked; } } else if (tempStr == "D8") { if (shiftKeyDown == true) { hasBeenChecked = "*"; return hasBeenChecked; } else { hasBeenChecked = "8"; return hasBeenChecked; } } else if(tempStr == "D7") { if (shiftKeyDown == true) { hasBeenChecked = "&"; return hasBeenChecked; } else { hasBeenChecked = "7"; return hasBeenChecked; } } else if (tempStr == "D6") { if (shiftKeyDown == true) { hasBeenChecked = "^"; return hasBeenChecked; } else { hasBeenChecked = "6"; return hasBeenChecked; } } else if(tempStr == "D5") { if (shiftKeyDown == true) { hasBeenChecked = "%"; return hasBeenChecked; } else { hasBeenChecked = "5"; return hasBeenChecked; } } else if(tempStr == "D4") { if (shiftKeyDown == true) { hasBeenChecked = "$"; return hasBeenChecked; } else { hasBeenChecked = "4"; return hasBeenChecked; } } else if(tempStr == "D3") { if (shiftKeyDown == true) { hasBeenChecked = "#"; return hasBeenChecked; } else { hasBeenChecked = "3"; return hasBeenChecked; } } else if (tempStr == "D2") { if (shiftKeyDown == true) { hasBeenChecked = "@"; return hasBeenChecked; } else { hasBeenChecked = "2"; return hasBeenChecked; } } else if (tempStr == "D1") { if (shiftKeyDown == true) { hasBeenChecked = "!"; return hasBeenChecked; } else { hasBeenChecked = "1"; return hasBeenChecked; } }
Comment