I have been programming in c++ for a year now just wondering if you can use records in lua as I looked online but found nothing about records.

Not sure if I’m right or not, but I think the closest thing (in Lua) is tables

Note I have NO knowledge whatsoever of C++, so I’m probably completely wrong.

If I am wrong, could you give a rough explanation of what records are?

By the way, I searched ‘Lua records’ and the first thing that came up was this other Lua table tutorial thing, so tables are probably similar to records…

I think it’s more like SQL. gmod supports sql by default, and can have mysql support with a c++ binary.

If you’re talking about this kind of records, we don’t natively have them, but you can use one of many OOP lua implementations to do it.

But keep in mind that you CAN’T enforce datatypes, this is a non-typed language and as such there’re ways to go around any implementation you try to do if they could do it.