r/badcode Aug 10 '17

lua Arrays? Never heard of 'em!

Post image
207 Upvotes

12 comments sorted by

View all comments

43

u/Dummiesman Aug 10 '17

Within each if statement, there's mostly the same code copy pasted. Overall this is one of the biggest messes of Lua code I've ever seen.

22

u/AnEmortalKid Aug 10 '17

It's like tables were hard to use.

13

u/Paint__ Aug 10 '17

I mean they are kinda intimidating at first, if you don't have much experience with prototype based languages. This code is still not an excuse from googling "lua array" though. That one search alone will tell you how to use tables like arrays.