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

Questions about Object Oriented Programming?

Asked by 5 years ago
Edited 5 years ago

I have always wondered which is better for Roblox game development, OOP or procedural? Also, I do not get the point of using it, and why it is used so much by developers. I have not got a slightest clue on how to use it. I feel like this technique is hidden in the Roblox DevHub and Roblox DevForums. Should I use it, and how do I use it in a game engine like Roblox? Is this an outdated technique used by developers 2+ years ago, or is it still commonly used by developers on Roblox?

Appreciate it if you replied.

0
OOP will always be better. OOP is vaguely about organization and code readability. It's not outdated. If you've ever used Javascript, it's basically the same. Treat lua tables like objects: tables can contain every datatype (most importantly for oop - functions). ModuleScripts are like Classes which can/would serve the same purpose. pidgey 548 — 5y
0
If you don't know how to use it, it's not a big deal. Although it is a fundamental of programming. OOP is really good at keeping code coupled (all code related), whereas everything in one script can be loosely coupled which isn't optimal. pidgey 548 — 5y
0
If you want to learn about it, I don't suggest doing it on Lua to do so. Try Java for instance (The IDE's will serve you well for OOP) pidgey 548 — 5y
0
tl;dr oop sucks (also oop basically useless in lua xd) Fifkee 2017 — 5y

Answer this question