Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

are there macros in roblox/lua similar to C?

Asked by 2 years ago

as the title suggests im looking for a way to call multiple functions with similar names that have slight variation between them, in C i would use macros to utilize that. so i was wondering is there a way to do such thing with roblox/lua?

0
Luau does not support preprocessor statements. What do you mean by "slight variation"? Ziffixture 6913 — 2y
0
I'm sure you can just execute the functions as they are. Ziffixture 6913 — 2y
0
answered cheetahjad -4 — 2y

1 answer

Log in to vote
0
Answered by 2 years ago

i want to create a gui for each type of resource, ores have a gui of their own, bars have their own and so on, so by getting the type of resource i want to call a function called for example, oreGuiCreator, and if i get a bar i call barGuiCreator. with C i could do such thing with macros, in lua i dont know

Ad

Answer this question