Jump to content




\n, ...

lua

  • You cannot reply to this topic
6 replies to this topic

#1 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 09 March 2016 - 04:42 PM

Are there other chars, which do the same work like /n?

Edited by Sewbacca, 10 March 2016 - 06:23 PM.


#2 MKlegoman357

  • Members
  • 1,170 posts
  • LocationKaunas, Lithuania

Posted 09 March 2016 - 04:45 PM

\r - carriage return
\z - the byte 0 (0x0)
\t - tab
\b - backspace (I think it's also called bell, not too sure)

That's some I can remember right now off the top of my head.

#3 KingofGamesYami

  • Members
  • 3,002 posts
  • LocationUnited States of America

Posted 09 March 2016 - 04:51 PM

Quote

\a bell
\b back space
\f form feed
\n newline
\r carriage return
\t horizontal tab
\v vertical tab
\\ backslash
\" double quote
\' single quote
\[ left square bracket
\] right square bracket

http://www.lua.org/pil/2.4.html

#4 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 09 March 2016 - 05:41 PM

I mean, are there other chars, which do the same work like \n, so creates a new line?

#5 Lyqyd

    Lua Liquidator

  • Moderators
  • 8,465 posts

Posted 09 March 2016 - 05:49 PM

You can adjust the cursor position. Why are you looking for duplicates of the newline character that aren't the newline character?

#6 Anavrins

  • Members
  • 775 posts

Posted 09 March 2016 - 06:03 PM

There's also \0 \1 \2 ... \128 ... \255, etc... which are the same as string.char(0) string.char(1) string.char(2) string.char(128) string.char(255), etc...
The newline byte is 0x0A, which means you can also newline with \10.

Edited by Anavrins, 09 March 2016 - 06:05 PM.


#7 Sewbacca

  • Members
  • 450 posts
  • LocationStar Wars

Posted 09 March 2016 - 09:43 PM

I solved it
Thanks anyway!





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users