Difference between revisions of "Talk:Tutorial:Modding Tutorial"

From Official Factorio Wiki
Jump to: navigation, search
(Created page with "== Chapter 6 The Lua code == I would like to point out that it is not mandatory to use require util/defines. Require gives no additional access to game. Just access to the fil...")
 
(Future of this page: new section)
Line 1: Line 1:
 
== Chapter 6 The Lua code ==
 
== Chapter 6 The Lua code ==
 
I would like to point out that it is not mandatory to use require util/defines. Require gives no additional access to game. Just access to the file it loads. In your code you need require defines because you use defines.events.ontick, but you could just use number to avoid need of defines just like you have in getinventory(). Now i dont remember what was in utils, but you can check it out in core/lualib -folder and if there is some function you need you have option to require the file, copy/paste the function or write your own function. [[User:Rk84|Rk84]] ([[User talk:Rk84|talk]]) 00:26, 7 May 2013 (CEST)
 
I would like to point out that it is not mandatory to use require util/defines. Require gives no additional access to game. Just access to the file it loads. In your code you need require defines because you use defines.events.ontick, but you could just use number to avoid need of defines just like you have in getinventory(). Now i dont remember what was in utils, but you can check it out in core/lualib -folder and if there is some function you need you have option to require the file, copy/paste the function or write your own function. [[User:Rk84|Rk84]] ([[User talk:Rk84|talk]]) 00:26, 7 May 2013 (CEST)
 +
 +
== Future of this page ==
 +
 +
Anyone knowledgeable or interested enough to check out how much of this page is out of date? I like the format of guiding you through the creation of a very simple mod, good for beginners to get an idea. So I do think this page or something like it should be included for modding. I'm adding a link to this page from the main Modding page to keep it on the radar. [[User:BenWo|BenWo]] ([[User talk:BenWo|talk]]) 06:47, 15 May 2014 (CEST)

Revision as of 04:47, 15 May 2014

Chapter 6 The Lua code

I would like to point out that it is not mandatory to use require util/defines. Require gives no additional access to game. Just access to the file it loads. In your code you need require defines because you use defines.events.ontick, but you could just use number to avoid need of defines just like you have in getinventory(). Now i dont remember what was in utils, but you can check it out in core/lualib -folder and if there is some function you need you have option to require the file, copy/paste the function or write your own function. Rk84 (talk) 00:26, 7 May 2013 (CEST)

Future of this page

Anyone knowledgeable or interested enough to check out how much of this page is out of date? I like the format of guiding you through the creation of a very simple mod, good for beginners to get an idea. So I do think this page or something like it should be included for modding. I'm adding a link to this page from the main Modding page to keep it on the radar. BenWo (talk) 06:47, 15 May 2014 (CEST)