How would I go about making Text Boxes and have questions with answers (I only need 3 possible answers) in my game?
If anyone has played Dungeons of Fayte, I'd like to mimic that kind of textbox. I would also like to be able to use fonts, and have the textbox be fit to the view I have in the game.
How do I make Text Boxes and Questions?
Started by ZaoMonichi, Jun 13 2012 03:27 AM
5 replies to this topic
#1
Posted 13 June 2012 - 03:27 AM
#2
Posted 13 June 2012 - 03:32 AM
It can all work out using the draw event, just create objects for the invisible "answer button" to be able to be clicked on
#3
Posted 13 June 2012 - 03:38 AM
Well, I'm not terribly familiar with draw events and a lot of things in scripting. Also, I'd like this set up to be activated with the Z key, not clicking.
#4
Posted 13 June 2012 - 03:50 AM
You need to have a variable for the answer or maybe an array would be best, 1 for the question and 1 for the answer and if the two match its correct.
Example. The first question's answer is in the 4th slot
There prob is a better way but its hard to suggest it w/o knowing more about your game
You could also use 1 2d array instead where 0,1 is the question portion and 1,1 is the answer portion
([1,1] means question 1 [1,1] means answer 1)
Example. The first question's answer is in the 4th slot
question[1] = 0 // 1 is the question number 0 is the first choice, 1 is the second etc answer[1] = 3 // 1 is the question number 3 is the correct answer // when you tap left or right select a different possible answer add or sub 1 to question[1] if question[1] = answer[1] // correct answer selected
There prob is a better way but its hard to suggest it w/o knowing more about your game
You could also use 1 2d array instead where 0,1 is the question portion and 1,1 is the answer portion
([1,1] means question 1 [1,1] means answer 1)
Edited by kupo15, 13 June 2012 - 03:52 AM.
#5
Posted 13 June 2012 - 04:00 AM
gm help file search for messages use built in ones
#6
Posted 13 June 2012 - 04:03 AM
You need to have a variable for the answer or maybe an array would be best, 1 for the question and 1 for the answer and if the two match its correct.
Example. The first question's answer is in the 4th slotquestion[1] = 0 // 1 is the question number 0 is the first choice, 1 is the second etc answer[1] = 3 // 1 is the question number 3 is the correct answer // when you tap left or right select a different possible answer add or sub 1 to question[1] if question[1] = answer[1] // correct answer selected
There prob is a better way but its hard to suggest it w/o knowing more about your game
You could also use 1 2d array instead where 0,1 is the question portion and 1,1 is the answer portion
([1,1] means question 1 [1,1] means answer 1)
If you'd like to play what my game would be very similar too, check out http://forums.tigsou...p?topic=10372.0 (Dungeons of Fayte)
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users











