Full On Retardation

I know I must be doing SOMETHING wrong, because ive been at this for freaking 2 hours (I know, im THAT NOOB at Lua) and I haven’t figured out a fix. I switched the contentations around, tried renameing the Variables, even tryed putting quotation marks around the
's to fix it, but no luck.

myName=“Jason”
Msg(…myName…
" )
Msg( "Hello “…myName…”
")
Msg(“I was just taking a shower.”…myName…“Do you want to join me?”
")
Msg(“Oh no!”…myName…“slipped and fell on the floor!”…myName…“needs to go to the hospital!”
")
Msg(“One black spider.”
“Two black spiders.”
“Three black spiders.”
"There goes the spiders.
")

… concatenates 2 strings. Strings are enclosed by ‘’, “” or []. Try again.

It may look like a jumble to me, but I think that the problem is something to do with the way you are using myName (no, that’s not funny).

doesn’t need quotation marks. I assume that’s mainly what is going wrong.


myName="Jason"
Msg(myName.."
" )
Msg("Hello "..myName.."
")
Msg("I was just taking a shower "..myName..". Do you want to join me?
")
Msg("Oh no! "..myName.." slipped and fell on the floor! "..myName.." needs to go to the hospital!
")
Msg("One black spider.
Two black spiders.
Three black spiders.
There goes the spiders.
")

Try this

Thanks. My major mistake was making the last line of code have cotations around the
, instead of making them at the very end of the sentence. Thanks.

No problem. It took me a few mins to look up, though. It can be murder when you are staring something straight in the face.

I don’t even code LUA yet. Maybe when I get more time I’ll start. :eng101:

Lua’s fun once you learn the basics, like I am. I like the problem solving involved, though it makes me rage half the time.

Suggest you make “MyName” a local var.

What if it needs to be a global variable?

he probably means in this particular situation, but it really doesn’t matter, he’s just messing with lua, so in truth it’d be best if he kept it global( for the sake of causing confusion so early on )

Im going through the Lua Tut series, so yes, im messing with code at the moment. Im not very advanced yet, as im at Functions at the moment.