ok, I've been saving this thread for when I started making a video explaining the scripter...and I've finally started making that video.
When you are programming you write everything in blocks which are called functions (in fallout scripts they are called procedures). Each function does something.
I have a basic understanding of functions now, thanks for taking the time to explain them.
You need to read and learn basic C++ and you will learn and understand this. Its not hard. Takes a day or 2.
Can you recommend a link to something I can read? or a youtube video or something? I may have a basic understanding of functions and header files, but I'm always open to better understanding the process.
Now For example I am working with Burn's Fo2Tweaks mod, and since his mod references RP headers, I need to also make sure I have those headers in my computer otherwise my script editor will give error cause it can't load things that have been referenced.
I'm not trying to make a mod using other people's mods, I'm trying to make a mod from scratch and documenting the process for future mod makers to reference. I may make a video explaining the concept of using other people's mods to make your mod, but since the header files are just a collection of shortcuts using basic commands anyway, there is no real point in using someone else's...
unless there is a list explaining what those shortcuts are and how they work to begin with...which I haven't seen yet, and nobody has bothered to provide links to anything like that.
If you want to have access to Sfall functions then you need to have Sfall headers. If you wanna use some functions from RP then you need to have RP headers. That's the "depending on what you wanna do" part. Having access to those function is, more than nice. It's essential. They have very useful and significant functions. Having them makes your life immeasurably easier.
This does not appear to be the case, as I've used Sfall functions without installing any of the Sfall headers from the modders pack, I've only used what came with the mapper. Check this clip to see an example:
That being said, all but one of the sfall headers from the sfall modderspack don't come with the mapper, and sfall.h (the only one that does) only has a few new lines of easily identifiable code added, so it seems pretty simple to copy over these files with minimal confusion.
Again, a link to something explaining what the RP headers actually add is more useful than just claiming they make life easier.
As for which header files, well you should definitely have sfall headers. modder's pack is sfall headers. I personally would always have RP headers as well. But again it depends on if you use any functions in them. RP headers are quite comprehensive. Have a look at them to see whats inside. Particularly having define.h from RP is very useful.
A cursory comparison of the default mapper headers to the RPU mod's headers reveals only a bunch of new headers that are specific to the new areas added in the RP mod (EPA, Abbey, Slaver Camp, etc...). This does not seem all that useful to have for making a new mod.
A text comparison of define.h between the mapper's and the RP mod's reveals minimal changes:
- 3 lines defining traits have been moved to another file (why? I don't know, doesn't seem to be any point in moving 3 lines to another file, but then I'm not a high level programmer)
- STAT_max_hit_points has been deleted
- SKILL_CONVERSANT has been changed to SKILL_SPEECH, this seems useful for readability, but not much else
- A section on combat damage that was already commented out in the original was deleted in RP's
- 3 new METARULE's were added covering: CHEM_USE_LEVEL, CAR_OUT_OF_FUEL, and MAP_GET_LOAD_AREA (whatever this does)
- 2 new #define's, covering fade-ins and fade-outs
- A section on barter that was already commented out in the original was also deleted in RP's
- 3 new #include's were added (upu.h, rpu.h, and party2.h)
That's it, those are all the changes made. I will try to look into upu.h, rpu.h and party2.h, but unless someone can explain how these other changes are at all helpful, I don't yet see any reason to replace what already comes with the mapper with RP or UP mod's.
You should probably first think about what you want to do in the first place. If your mod is based on the RPU, you use the RPU headers, if it is based on some other mod, you use the headers from that mod, etc.. There is no universal "use X and it will always work perfect"-approach here.
Fallout is using a fuckton of macros for everything so you don't have to write the same lines twice. These macros are all #defined in the headers. Now if you use the wrong headers in the wrong script, the game will compile your shit differently and thus it can lead to incompatibility with the mod(s).
tl;dr - you use the header files of the mod you want to work with.
I'm not trying to make a mod based on other people's mods, even if they are pretty impressive. I'm trying to make a mod from scratch and documenting the process so other's will have a useful guide to mod making for fallout 2.
NovaRain said:
No. The header files in the official script source are old and have some incorrect defines that will give you error/warning during compilation.
It's better to get the game header files from
UPU or
RPU, and update sfall related ones from the modderspack.
I have noticed at least one consistent error when compiling with the scripter:
Code:
End of file with no newline, supplemented newline: #endif // _GLOBAL_H_DEFINED2 O0) (1O9 )_ _ LI ( DW1O (
So it seemed prudent to fix possible future errors (and thereby making it easier for future modders to create mods) by providing directions to replace buggy headers with fixed ones...however, actually replacing global.h (along with the rest of the headers) did not remove that repeating error.
Further, comparing the actual text of the default mapper's global.h and the RP mod's global.h reveals a bunch of superficial changes that mostly apply to bug fixes for the official game and a lot of new variables for the extra maps added in the restoration process...nothing that would help new modders to make a new mod. But then global.h is supposed to be a list of global variables, not a list of new functions, so whatevs.
tl;dr
Nobody answered this question:
Am I just copying all the headers from RPU/UPU "...\scripts_src\headers\"?
...and the same question for the modderspack "...\scripting_docs\headers\"?
And the deeper I dive into these files the more it seems like the sfall modderspack might be the only useful set to include when making a mod.
Can anybody provide me with a list of functions that the UPU or RPU header's add?
My understanding is that these mod's headers aren't even necessary to make a script that's compatible with them, since the compiler simply reduces the scripted code to binary, and as such should be usable by the game engine regardless of what the header's are.
RPU and UPU headers may add more easily accessible functions...but I don't yet see what those functions are, or why I should replace these headers.