Splitting up the files for a Project
Author |
Message |
astgenator
|
Posted: Sun Sep 06, 2009 3:32 pm Post subject: Splitting up the files for a Project |
|
|
is there any way(for organization purposes) to use more than one turing file for a program? Lets say for a game, all of your battle scripts go in one file, all of your chat scripts go in another and so on. Basically is it possible to use code from another file?
Any help is appreciated. |
|
|
|
|
|
Sponsor Sponsor
|
|
|
[Gandalf]
|
Posted: Sun Sep 06, 2009 7:01 pm Post subject: RE:Splitting up the files for a Project |
|
|
Yes, generally this is done by creating a module or class and importing that file using import. There should be a few tutorials on this (for example this one), or you can look up the import keyword in Turing's built-in help.
Alternatively, you can basically 'copy-paste' the code from the other file using the include keyword, as described here. |
|
|
|
|
|
|
|