Game Maker Text Box Engine Oil

Posted on by admin
Game Maker Text Box Engine Oil Rating: 5,0/5 8852 reviews

I just recently purchased Game Maker Studio! I am loving it so far. I have been working on transferring my project from Game Maker Classic into Studio. Mostly everything works fine but I had to rewrite a new dialogue engine since some functions are no longer supported. The main problem was the Text box engine. It has to be totally redesigned.

Features of my Text box Engine:

  • Typewriter effect – The text will slowly appear on screen.
  • Word Wrapping
  • Speed up text by pressing the Cancel Key
  • Splits Text into another text box if the limit is reached
  • Continue Cursor appears when text box is filled with text
  • Textboxy is a simple and straightforward textbox engine for GameMaker Studio 2. For documentation and changes, please see the GitHub repository. A global config script to adjust the engine without having to dig into the code at all.
  • Jul 3, 2018 - Creating a textbox engine for a role playing game can be a daunting task. Textboxes seem simple at first, but soon become a nightmare of.

The HappyTear Text Engine is a powerful and fully customizable dialogue engine for RPGs, platformer and pretty much every kind of game. Scritti politti cupid and psyche 85 rar. Note: It does currently not work on HTML5. It should work on all other platforms and was tested on Linux, Windows and Android.

Also added a question text box: Il commissario montalbano video puntate.

Other minor improvements:

  • Tile-based collision (No need to invisible solid objects)
  • Animated tiles

Happy Holidays everyone!

Advertisements
  1. //argument0 = the text
  2. //argument1 = whether or not to draw the box at the end
  3. //argument3 = whether or not to draw the text box
  4. //` = white text
  5. //{ = blue text
  6. global.drawingtext = true //the game is drawing text
  7. if argument2 = true //if it is the first time through
  8. self.position = 1//set the position as 1
  9. }
  10. global.more = argument1
  11. global.font = spr_letters //set the font at the beggining of the script
  12. //sets the postion of the pointer, so it knows how much text should be drawn
  13. if keyboard_check(vk_enter) = true //if enter is pushed
  14. self.done = true //you are done
  15. self.position = string_length(global.text) //end the text
  16. self.curstring = global.text //set the string to the text
  17. keyboard_clear(vk_enter) //stop generating events
  18. if self.done = false //if the text line isn't done
  19. self.curstring = string_copy(global.text, 1, self.position) //the first line is a part of the actual first line
  20. if string_length(self.curstring) = string_length(global.text) //if the text is done
  21. self.done = true //this line is done
  22. }
  23. if self.done = false //if not all text is done
  24. self.position += 1 //add one to the position
  25. if argument3 = true //if you should draw the text box
  26. draw_sprite(spr_textbox, 0, view_xview[1] + 16, view_yview[1] + 160) //draw the text box
  27. self.pointx = 22 //a little to the right..
  28. for(i = 1; i < string_length(self.curstring) + 1; i += 1) //once for every character
  29. self.lettertemp = string_copy(self.curstring, i, 1) //get the letter
  30. {
  31. self.pointy += 16 //go down a line
  32. if self.lettertemp <> ' ' and self.lettertemp <> '~' //if it isn't a space or a tilde
  33. if self.lettertemp <> '`' and self.lettertemp <> '^' and self.lettertemp <> '{' and self.lettertemp <> '}' //if it's not changing the font
  34. self.todraw = scr_getletter(self.lettertemp) //get the imagesingle of the value
  35. draw_sprite(global.font, self.todraw, view_xview[1] + self.pointx, view_yview[1] + self.pointy)
  36. }
  37. {
  38. {
  39. }
  40. {
  41. }
  42. {
  43. }
  44. {
  45. }
  46. }
  47. {
  48. }
  49. {
  50. self.pointy += 16 //move down for the next letter
  51. self.pointx = 22 //reset to the start of the line
  52. }
  53. screen_refresh() //refreshes the screen so you can actually see it
  54. if self.done = true and global.more = true //if we need to draw an arrow
  55. draw_sprite(spr_textmore, 0, view_xview[1] + 155, view_yview[1] + 216) //draw the arrow
  56. {
  57. sleep(30)
  58. scr_dialogbox(argument0, argument1, false, argument3) //do it all again
  59. else //yer done!
  60. screen_refresh() //refresh the screen
  61. sleep(30)
  62. keyboard_clear(vk_shift)
  63. global.drawingtext = false //get on with your regular life
  64. ___________________________________________________________________________________________________________________
  65. letter = argument0
  66. if ord(letter) >= ord('A') and ord(letter) <= ord('Z') //if it is an uppercase letter
  67. return (32 + (ord(letter) - ord('A'))) //return a value for the letter
  68. if ord(letter) >= ord('a') and ord(letter) <= ord('z') //if it is a lowercase letter
  69. return (64 + (ord(letter) - ord('a'))) //return a value for the letter
  70. if letter = '!' //exclamation mark
  71. return 0
  72. if letter = '' //quotations
  73. return 1
  74. if letter = '#' //number sign
  75. return 2
  76. if letter = '$' //dollar sign
  77. return 3
  78. if letter = '%' //percent sign
  79. return 4
  80. if letter = '&' //ampersand
  81. return 5
  82. if letter = '' //semi-qute
  83. return 6
  84. if letter = '(' //parentheses
  85. return 7
  86. if letter = ')' //parentheses
  87. return 8
  88. if letter = '*' //asterisk
  89. return 9
  90. if letter = '+' //plus sign
  91. return 10
  92. if letter = ',' //comma
  93. return 11
  94. if letter = '-' //dash
  95. return 12
  96. if letter = '.' //period
  97. return 13
  98. if letter = '/' //slash
  99. return 14
  100. if letter = '0' //0
  101. return 15
  102. if letter = '1' //1
  103. return 16
  104. if letter = '2' //2
  105. return 17
  106. if letter = '3' //3
  107. return 18
  108. if letter = '4' //4
  109. return 19
  110. if letter = '5' //5
  111. return 20
  112. if letter = '6' //6
  113. return 21
  114. if letter = '7' //7
  115. return 22
  116. if letter = '8' //8
  117. return 23
  118. if letter = '9' //9
  119. return 24
  120. if letter = ':' //colon
  121. return 25
  122. if letter = ';' //semi colon
  123. return 26
  124. if letter = '<' //less than
  125. return 27
  126. if letter = '=' //equal to
  127. return 28
  128. if letter = '>' //greater than
  129. return 29
  130. if letter = '?' //question mark
  131. return 30
  132. if letter = '@' //at sign
  133. return 31
  134. if letter = '[' //bracket
  135. return 58
  136. if letter = ' //slash
  137. return 59
  138. if letter = ']' //bracket
  139. return 60
  140. if letter = '^' //carot
  141. return 61
  142. if letter = '_' //underscore
  143. return 62
  144. if letter = '' //quotation mark
  145. return 63