eniallator

Discord large text generator

May 23rd, 2017
387
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.61 KB | None | 0 0
  1. inputString = 'test string 0123456789'
  2. discordLargeText = ''
  3.  
  4. for i=1,#inputString do
  5.   currChar = inputString:sub(i,i):lower()
  6.  
  7.   if currChar:match('%a') then
  8.     discordLargeText = discordLargeText .. ':regional_indicator_' .. currChar .. ': '
  9.    
  10.   elseif currChar:match('%s') then
  11.     discordLargeText = discordLargeText .. ':white_large_square: '
  12.  
  13.   elseif currChar:match('%d') then
  14.     local numbers = {'zero', 'one', 'two', 'three', 'four', 'five', 'six', 'seven', 'eight', 'nine'}
  15.     discordLargeText = discordLargeText .. ':' .. numbers[currChar + 1] .. ': '
  16.   end
  17. end
  18.  
  19. print(discordLargeText)
Advertisement
Add Comment
Please, Sign In to add comment