Begin Lua-scripting [closed]

2020-05-14 06:07发布

I'm at a stage where I am forced to learn Lua, so do you have any suggestions on how I do this? I don't have a lot of experience with any other scripting languages than PHP.

So, some suggestions on "head start Lua"-pages?

EDIT

As an addition to the wonderful tutorial pages, could you please suggest any "programs" I could make that will help me learn Lua? Imagine I would want to learn Pointers in C++, I'd make a Linked List. I want to touch the basics in Lua but meanwhile be open to pretty advanced stuff.

标签: scripting lua
7条回答
贼婆χ
2楼-- · 2020-05-14 06:47

Funny to see all these elaborate lists (though they are certainly correct). Back in 2002, I read about the first 20+ pages of the Lua reference manual, and started using it. It really is that simple. Lua (and ANSI C) are of the few languages that really fit in one's mind all at once - and stay there. For the others, at least I need to constantly do some relearning.

Be aware that getting to think in Lua will take time. I think mine was 6 months or so. When coming from C/C++, we tend to solve problems in certain ways. Lua might offer better means (i.e. via use of tables) but it takes a while to start seeing those. This transition to a higher abstraction level is similar to the Assembler->C shift in the 1980's. Many people still coded a while in C as if it only were a portable assembler.

查看更多
登录 后发表回答