Learning Lua: How to use if - then (and else) in Lua scripting

preview_player
Показать описание
Unlock the power of Lua programming with my latest book, "Learning Lua." Whether you're a beginner or an experienced coder, this comprehensive guide will take you on a journey to mastering Lua. Get your copy now:

In Part 9, we learn about using if-then comparisons.

Рекомендации по теме
Комментарии
Автор

Getting to the good stuff now! Great tutorial.

jamesbuildwise
Автор

Crystal clear teaching! (coming from a Spanish teacher) Thank you.

BrockCochran
Автор

These tutorial videos have helped me a lot. Thank you so much for putting the effort and time into this.

Anonumos
Автор

I was scared to deviate from my learning method but this is really good !10/10. In addition to that your voice is smooth and relaxing.

thediamondpro
Автор

Hello Brian: I don't believe LUA has the traditional SQL "CASE" statement, have you covered an alternative (SELECT, WHEN etc?). An alternative to nested IF's. I have situation, when it meets the first instance of a WHEN, to perform the assignment and jump out. Sometimes, multiple IF THENs get a bit too complex looking.

BaconEggUSA
Автор

so basically the if-then else script is just


"ok if the variable is equal to this then
do this
but if not then
do this"

josenunez
Автор

LOGICAL OPERATOR


print(4 and 5) --> 5
print(nil and 13) --> nil
print(false and 13) --> false
print(4 or 5) --> 4
print(false or 5) --> 5


sir please explain this part

lavishsinghal
join shbcf.ru