Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Overwhelmed to the Point of Giving Up (Again)
Paddy™ Offline
Posting Freak

Posts: 1,351
Threads: 43
Joined: Feb 2012
Reputation: 224
#1
Overwhelmed to the Point of Giving Up (Again)

This is probably my third real attempt to get into modding SOMA, and I'm still as baffled as I was in 2015. I'm stuck at the very beginning of the process, and was hoping someone could put me out of my misery and just tell me what to do so I can actually start building levels etc. Feel free to patronise me, treat me like an absolute dumbo!

Get me from "nothing" to "having a mod/map I can playtest/edit". I'm OK with the level editor, so don't worry about that part. I just don't know if I should be saving my map in a separate folder, or if I should use the "mods" folder inside the SOMA directory (the editors keep opening the main directory, so I dunno). When the tutorials talk about editing config files, I don't know if I should be editing the main files, or copying them somewhere to be edited separately, or what. If I'm playtesting a map, does it mean I can't play the main game without unediting the config files again? Do I have to manually build a directory structure to mirror that of the main game for the mod to work? What's CodeLite for? Why can't I just use Notepad++ to do scripting, for instance?

This is the sort of stuff that's making my brain ache, just basic concepts about where things are supposed to go, and the wiki/videos are just making me even more confused because they seem to presuppose a level of knowledge about this stuff that I don't have.

So, pretend I'm a foreign exchange student with very little English and whose mother drank heavily and constantly rode poorly-maintained rollercoasters during pregnancy.

Thanks for your help/patience, lads Heart

12-04-2017, 10:24 AM
Find
Abion47 Offline
Senior Member

Posts: 369
Threads: 22
Joined: Oct 2015
Reputation: 46
#2
RE: Overwhelmed to the Point of Giving Up (Again)

  • I just don't know if I should be saving my map in a separate folder, or if I should use the "mods" folder inside the SOMA directory (the editors keep opening the main directory, so I dunno).

Strictly speaking, you can save your mod files anywhere you like. However, the general rule of thumb is, yes, to save your mod files within a "mods" folder inside the SOMA directory, further separated inside a folder specific to the mod you are working on. For example, if you are working on a mod called "DarkPlace", then your files should be saved within the folder "<your SOMA directory>/mods/DarkPlace". (One reason for doing this is because the mod launcher automatically checks the "mods" folder for runnable mods.)

From there, convention would state that you should separate your mod files the same way that SOMA does, i.e. with a "maps" folder, a "config" folder, a "script" folder, an "entities" folder, etc.
  • When the tutorials talk about editing config files, I don't know if I should be editing the main files, or copying them somewhere to be edited separately, or what.

There are two modes of modding. First is when you're actively developing, tinkering, or concepting mod ideas. Second is when you're preparing a mod for release.

When actively developing, it's convenient to edit SOMA's config files themselves. This is because, when you run SOMA in developer mode (i.e. with the "SomaDev.bat" file), it loads the SOMA config files, not the config files of your mod. Because of this, if your mod is dependent on your config files, if, for example, you are working with custom entities, modules, or lang entries, you generally have to add these changes to the SOMA configs in order for them to appear in SOMA's developer mode.

When you're packaging your mod for release, however, then your mod needs to have its own versions of the changes you made (for reasons that I hope are obvious). Because of this, if you only make your changes to SOMA's files, it can be difficult to track down everything that you did and copy it to your own mod folder. Therefore, the recommendation is that everytime you make a change to the SOMA files, you make the same change to a version of the file that you copied to your mod's folder.
  • If I'm playtesting a map, does it mean I can't play the main game without unediting the config files again?

It depends on if you made changes to SOMA's files and what they were. If all you did was add new maps, maybe some custom entities, then it probably wouldn't affect the main game at all. If you customized scripts or made a module with a persistent effect, however, then yes, your changes will be reflected in SOMA itself. To prevent this, one handy practice is, whenever you find yourself about to edit a SOMA core file, make a backup of that file. That way you can switch between the original file and your modded version without losing either one.
  • Do I have to manually build a directory structure to mirror that of the main game for the mod to work?

Strictly speaking, the only thing your mod needs to work is a "resources.cfg" file and an "entry.hpc" file, and both should be in your mod's root folder. From there, nothing else is absolutely mandatory in terms of naming scheme or folder structure. That being said, it will be easier for you to understand the layout of the files and how they work together if you stick to SOMA's convention, at least until you understand how it all comes together.
  • What's CodeLite for? Why can't I just use Notepad++ to do scripting, for instance?

You can absolutely do scripting in Notepad++, or any raw text editor you choose. The reason CodeLite is convenient is that it is an IDE, which offers perks like autocompletion and Intellisense. It's become a bit of a hassle to work in where HPL3 is concerned, though, so personally I recommend using VS Code (a sort of middle ground between a text editor and a full IDE) and following the guide on the wiki on how to get it set up for Angelscript and HPL3.

12-04-2017, 11:03 AM
Find
Paddy™ Offline
Posting Freak

Posts: 1,351
Threads: 43
Joined: Feb 2012
Reputation: 224
#3
RE: Overwhelmed to the Point of Giving Up (Again)

Thank you so much for this, it's a great help! You've pretty much covered everything.

Thanks for taking the time, greatly appreciated Smile

(This post was last modified: 12-04-2017, 09:06 PM by Paddy™.)
12-04-2017, 09:06 PM
Find




Users browsing this thread: 1 Guest(s)