Page 1 of 1
So I have no idea what I'm doing...
Posted: Sat Jan 25, 2014 10:13 pm
by wildwolfofdark
I'm trying to figure out how to make my own module but I have no idea where to start. I figure making a beginning map would work but no idea how. Any and all help is appreciated.
Re: So I have no idea what I'm doing...
Posted: Sun Jan 26, 2014 12:42 am
by Castler
Have you checked the wiki at
http://te4.org/wiki/T4_Modules_Howto_Guide? The "Getting Started" page there should get you going, and other pages cover more specific topics.
I'd recommend starting with one of the example modules (as described on the wiki) then either adding basic features (inventory, character sheets, etc. - again, see the wiki) or starting work on whatever will make your module unique.
Re: So I have no idea what I'm doing...
Posted: Sun Jan 26, 2014 3:15 am
by Marson
A module will probably be a hefty investment. I've been programming since the early 80's and am familiar with basic ideas of OOP, but some of the code Darkgod came up with made my eyes glaze over. Starting with an addon might be the way to go, say for a race or class. That way you aren't biting off a huge chuck of code to learn all at once.
Re: So I have no idea what I'm doing...
Posted: Mon Jan 27, 2014 1:14 am
by Grey
Module-making isn't hard at all. Check out some of the other modules made for simpler games to poach code from.
Re: So I have no idea what I'm doing...
Posted: Tue Jan 28, 2014 7:08 pm
by Sradac
Marson wrote:A module will probably be a hefty investment. I've been programming since the early 80's and am familiar with basic ideas of OOP, but some of the code Darkgod came up with made my eyes glaze over. Starting with an addon might be the way to go, say for a race or class. That way you aren't biting off a huge chuck of code to learn all at once.
Also keep in mind LUA technically isnt object oriented, so that might be why its throwing you off. It "looks" like it is but its about the same as javascript when it comes down to it.
Re: So I have no idea what I'm doing...
Posted: Tue Jan 28, 2014 10:49 pm
by Marson
Very good point. Yeah, the table shenanigans is exactly what I had to adapt to.
Re: So I have no idea what I'm doing...
Posted: Wed Jan 29, 2014 8:49 am
by darkgod
What are your eyes glazing over ?

Re: So I have no idea what I'm doing...
Posted: Wed Jan 29, 2014 11:37 pm
by Marson
Well, it's not so much *your* code as this being my first experience with LUA. I was assuming LUA was another C++like. It's been 10 years since I've coded on a daily basis, and that was mostly old versions of PHP and VB. Sometimes trying to backtrack through a chain can leave me a little lost. I've never been comfortable with "self", "parent", "this", etc., though I understand their power. My brain works better when an explicit name is used everywhere, even though that's bad practice. Heck, in some ways I'm still stuck in BASIC.
Re: So I have no idea what I'm doing...
Posted: Thu Jan 30, 2014 8:35 am
by darkgod
Ahah I see

Re: So I have no idea what I'm doing...
Posted: Thu Jan 30, 2014 10:25 am
by Zireael
You could look at the example module or at Grey's work or at Qi Daozei or Veins of the Earth. Seriously, when I started Veins, I knew even less than you, Marson.
Re: So I have no idea what I'm doing...
Posted: Thu Jan 30, 2014 2:53 pm
by Marson
I'm getting acclimated now. To be honest, I'm very much a hack*, but I'm comfortable in those shoes. I've done a lot of code diving this past week, and I'm learning stuff new to me that I probably should have known back in the day. Gaps like that is one of the hazards of being self-taught, but that's how I love to learn. This has been a lot of fun—even if I do mutter oaths to Crom every 8.72 minutes or so.
*"Hack" as in the old writer's term. If I had been born a decade or two earlier, I probably would have ended up working in some old garage slapping cars back together with duck tape and a smile.