Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Text rpg question
#6
Don't use "IF" in such cases. Better take "Select Case". Here ya go:
Code:
Key$=IINKEY$
SELECT CASE Key$
CASE "W": Way$ = "North"
CASE "S": Way$ = "South"
CASE "A": Way$ = "West"
CASE "D": Way$ = "East"
END SELECT
"Select case" is times faster than "if" if you want to compare a variable not only one time with some values.
B 4 EVER
Reply


Messages In This Thread
Text rpg question - by Placeborick - 03-03-2003, 06:17 PM
Text rpg question - by na_th_an - 03-03-2003, 07:18 PM
hmm - by Placeborick - 03-03-2003, 07:37 PM
Text rpg question - by na_th_an - 03-03-2003, 07:39 PM
Text rpg question - by NovaProgramming - 03-05-2003, 11:03 PM
Text rpg question - by ak00ma - 03-05-2003, 11:43 PM
Text rpg question - by NovaProgramming - 03-06-2003, 10:57 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)