Page 3 of 3
Re: Object systems or LÖVE should have one
Posted: Sun Jun 02, 2013 1:56 am
by Lafolie
Hexenhammer wrote:
Lua actually makes many decisions for you and forces a pretty immutable structure on you.
This is not true, T-Bone even demonstrated this:
vrld wrote:A fundamental concept in the design of Lua is to provide meta-mechanisms for implementing features, instead of providing a host of features directly in the language.
I cannot perceive of how you could make such a statement when Lua tables are one of the most mutable data structures around. In fact, they're so mutable that one of the first things people learn in Lua is that there are several ways to iterate through them, depending on the chosen format.
Hexenhammer wrote:
It only feels "free form" compared to something like Java. If you want "freedom" look at Forth, LISP or C.
That's a largely subjective statement. For many Lua offers freedom in liberation from lower level necessities and clean abstractions.
Re: Object systems or LÖVE should have one
Posted: Sun Jun 02, 2013 8:24 am
by Hexenhammer
T-Bone wrote:
I didn't miss the part where you said it should be an optional component. How could I choose not to use it if it wasn't optional?
I thought you meant you wouldn't use LÖVE if it came with an optional class system.
Re: Object systems or LÖVE should have one
Posted: Sun Jun 02, 2013 9:01 am
by Hexenhammer
Lafolie wrote:Hexenhammer wrote:
Lua actually makes many decisions for you and forces a pretty immutable structure on you.
This is not true
It is
In fact, they're so mutable that one of the first things people learn in Lua is that there are several ways to iterate through them, depending on the chosen format.
Let us talk again in a few years maybe.
Re: Object systems or LÖVE should have one
Posted: Sun Jun 02, 2013 1:46 pm
by Lafolie
I fear that you forget yourself, and that you also forget the very words you just read (assuming you are not so foolish). I cited vrld's citation which clearly states that this is not the case.
There will be no built-in class system in love. Others have lost this pointless battle before you clicked the create topic button.
Furthermore, you should not be so dismissive of those who argue for your own sake. Listen to reason, it is the way forward.
Re: Object systems or LÖVE should have one
Posted: Thu Jun 06, 2013 5:20 pm
by LuaWeaver
Plu wrote:When I ran my first project in LÖVE, I included the 30log library, which literally took like 5 minutes to find, include and use.
But it's not even required... my current project uses even less class based stuff and I'm just using pure Lua and some tables to get things working. I like the freedom it gives. Personally I think that letting people figure out everything for themselves except the stuff that´s both slow and really complicated and basic is a good choice. It makes LÖVE an excellent choice for people who want to really learn how to build games.
As nice as it is if someone has pre-chewed everything, you won't actually learn anything. Building your own simple object class in a few hours teaches you more about object design than working with an existing library for a few weeks. Actually building a platform game starting with your own physics implementation teaches you a lot more than just clicking on together in gamemaker.
I find LÖVE to be incredibly educational, and that's a trait you don't see in many modern languages. It almost seems designed to teach you by letting you fiddle around, where other languages and programs teach you by making you sit through weeks of tutorials to show you every button and every little thing someone else has already built for you before you can actually try to mess around with it.
For many other languages, learning them is a chore. Learning to use LÖVE is a fun game in itself.
This is a statement I totally agree with. A few years ago, I
was still am just a naive kid who wants to make a game, but I've grown and developed so much with this. In an embarrassing failure, I
made this. I didn't even understand what OOP was at the time! I struggled to make a connect four game for a while and gave up and now I have about a dozen half finished projects lying about on my computer.
But you know what? I've grown a lot. When I came here, I knew very little, and this engine has seriously helped me. I've now read PiL twice and can say I understand all of it, which is something I wouldn't have been able to do without this engine.
This is to counter the arguments of saying that getting those newbies who don't know anything about programming (yet) shouldn't be here - rather, we should welcome them with open arms and help them. There is no way I would've stayed if the community hadn't been so helpful at the time. Hell, if this community had been rude to me, I probably wouldn't even be programming right now - which is my plan for life. I might be getting an internship at the Cleveland Clinic as a programmer
at the age of 14, which just goes to show that being nice to a stranger over the internet can actually change a life for a young person.
Re: Object systems or LÖVE should have one
Posted: Fri Jun 07, 2013 7:18 am
by Karai17
tl;dr use hump.class and get over it.
Re: Object systems or LÖVE should have one
Posted: Fri Jun 07, 2013 9:13 pm
by qaisjp
Karai17 wrote:tl;dr use hump.class and get over it.
tl;dr use middleclass and get over it.
point is, any class system is useful. but why should love have one when the lua doesn't have one?
1. It's useful.
2. You don't HAVE to use it. (unless it was mentioned somewhere in here that love.*.* should use oop)
if love would use object libraries/class, what features should be used?
Re: Object systems or LÖVE should have one
Posted: Fri Jun 07, 2013 9:44 pm
by Karai17
If you want to use class-style oop, then use a class system. If you'd rather not, then don't. If you want interoperable code, use one that conforms to class commons. Hard coding a class system into love is just not a good idea.
Re: Object systems or LÖVE should have one
Posted: Fri Jun 07, 2013 11:23 pm
by Inny
This dead horse has probably been well beaten by now, so the last thing I want to chime in with is that I've been experimenting with an Entity-Component style design, and I've determined that not having a class system in the way makes it easier to do the type of things I want to do. Furthermore, the closest thing to "component-style design" that any of the existing class systems offers is Mixins. I'm starting to really get behind the idea that tables are good enough and classes are an unnecessary overhead.
Re: Object systems or LÖVE should have one
Posted: Fri Jun 07, 2013 11:27 pm
by Karai17
Tables are amazing.