Difference between revisions of "Modding"

From Software Inc.
Jump to navigation Jump to search
 
(199 intermediate revisions by 6 users not shown)
Line 1: Line 1:
Modding in Software Inc. is completely data driven. Software Inc. loads XML files found in the "Mods" folder of the root of the game when it launches.
+
Mods in Software Inc. can be defined in simple text-based files or using C# and compiling code for the game to load. You can add new software types, furniture, translations and room textures using only the [[TyD|TyD]] file format.  
  
A mod should be placed in its own folder in the "Mods" folder and can optionally contain each of the following folders: "[[Modding#Companies|Companies]]", "[[Modding#Company types|CompanyTypes]]", "[[Modding#Events|Events]]", "[[Modding#Name generators|NameGenerators]]", "[[Modding#Scenarios|Scenarios]]" and "[[Modding#Software types|SoftwareTypes]]".
+
== Debugging console ==
 +
You'll need the in-game console to properly test your mods and check if everything is working as it should. The debugging console is enabled by binding the console key at the bottom of the key binding menu in the options window. More information about how to use console can be found on [[Console]].
  
The root of your mod can additionally include a Personalities.xml file to add new [[Modding#Personalities|personalities]] to the game.
+
== Folder structure ==
 +
Unless downloaded from the Steam Workshop, mods are placed in the root of the game folder, depending on which type of mod you are making. Each mod should be placed in its own folder within the following folders (Note that these folders might not exist in the first place, so you should create them yourself):
 +
* Software types and personalities should be placed in the '''Mods''' folder.
 +
* Furniture should be placed in the '''Furniture''' folder.
 +
* Room, path and roof textures should be placed in the '''Materials''' folder.
 +
* C# code and dll files should be placed in the '''DLLMods''' folder.
 +
* Translations should be placed in the '''Localization''' folder.
  
== Software types ==
+
== Meta file ==
Software types are the types of software you can choose to develop in Software Inc. in the design document window. Software types can be added to the game by creating an XML file in the "SoftwareTypes" folder.
+
Each mod will take its name from the folder it is in. However, you can customize the '''Name''', '''Description''' and '''Author''' of your mod by adding a meta.tyd file to the root of your mod's folder, containing the specified records. This file will be created automatically when you edit your mod in-game (Not implemented yet as of Alpha 11.4.7).
  
=== Tags ===
+
== Localizations ==
A software type XML file should contain the following tags:
+
Please go to [https://translate.coredumping.com translate.coredumping.com] to help translate the game.
  
{|class="wikitable"
+
== Mod types ==
|SoftwareType
+
=== Data mod ===
|This is the root tag, which all tags should be a child to. If this tag has the attribute Override="True", all tags are optional and will override the content of a software type by the same name. You can use this to override some values of the built-in software types. Note that if you override the Features tag, you will delete all features from the software type.
+
[[Data Modding|Read the documentation here.]]
|-
 
|Name
 
|The name of the software as it will appear in dropdown lists, etc.
 
|-
 
|Delete
 
|Optional tag which deletes the software type from the game, if it is set to TRUE
 
|-
 
|Category
 
|How the field of the software will be referred to in articles, e.g. games are categorized as "Gaming"
 
|-
 
|Description
 
|The contents of the tooltip that will appear when hovering over the software type in the dropdown menu in the design document window.
 
|-
 
|Unlock
 
|Which year this software type will unlock, e.g. <Unlock>1995</Unlock>
 
|-
 
|Random
 
|How much sales will vary. When a product is released, a random number is chosen and it is weighted using this number, and it will be multiplied for all sales. As an example, for games it is 0.5, since you can't count on good sales for a game, but for operating systems, it is 0, since they are generally in demand and necessary for a computer to work, so sales won't vary that much.
 
|-
 
|Popularity
 
|How popular a software type is, which limits the maximum amount of income. Operating system have 1 and games have 0.8.
 
|-
 
|OSSpecific
 
|Whether you need to choose an operating system for this software.
 
|-
 
|OneClient
 
|Whether this software is for contract work. This does not currently work as expected, so you should probably avoid setting this to TRUE.
 
|-
 
|InHouse
 
|Whether you can lock this software to your own company. This makes sense for game engines, but not for games for example.
 
|-
 
|NameGenerator
 
|The [[Modding#Name generators|name generator]] to use for simulated companies or for when the player clicks the name button in the design document.
 
|-
 
|Needs
 
|All software types that this software type depends on, each need should be defined in a <Name> tag in the <Needs> tag. This will be deprecated at some point in the future and decided by feature dependencies instead.
 
|-
 
|Features
 
|All [[Modding#Features|features]] that this software can implement.
 
|}
 
  
=== Example ===
+
Data mods can add, change or remove software types, AI company types, name generators and employee personalities. This is all done with [[TyD|TyD]] files, however software can have scripts attached using [[SIPL|SIPL]].
<pre><SoftwareType>
 
<Name>Test Software</Name>
 
<Description>This is part of a test mod. If you develop a perfect version, 50% of the population will want it, but 10% might randomly not want it.</Description>
 
<Random>0.1</Random>
 
<Popularity>0.5</Popularity>
 
<OSSpecific>TRUE</OSSpecific>
 
<OneClient>FALSE</OneClient>
 
<InHouse>FALSE</InHouse>
 
<Category>Test</Category>
 
<NameGenerator>testgen</NameGenerator>
 
<Needs>
 
<Name>Visual Tool</Name>
 
</Needs>
 
<Features>
 
<Feature Forced="TRUE">
 
<Name>Test feat 1</Name>
 
<Description>This feature will always be selected unless superseded by a feature with this as "From".</Description>
 
<DevTime>2</DevTime>
 
<Innovation>0</Innovation>
 
<Usability>1</Usability>
 
<Stability>1</Stability>
 
<CodeArt>1</CodeArt>
 
<Dependencies></Dependencies>
 
</Feature>
 
<Feature From="Test feat 1">
 
<Name>Test feat 2</Name>
 
<Description>This feature takes 6 months to make and has 4/6 Usability.</Description>
 
<DevTime>6</DevTime>
 
<Innovation>1</Innovation>
 
<Usability>4</Usability>
 
<Stability>1</Stability>
 
<CodeArt>1</CodeArt>
 
<Dependencies>
 
<Dependency Software="Visual Tool">Image viewing</Dependency>
 
</Dependencies>
 
</Feature>
 
<Feature>
 
<Name>Test feat 3</Name>
 
<Description>This feature takes just as many artists as programmers and offers no stability.</Description>
 
<DevTime>5</DevTime>
 
<Innovation>1</Innovation>
 
<Usability>1</Usability>
 
<Stability>0</Stability>
 
<CodeArt>0.5</CodeArt>
 
<Dependencies>
 
<Dependency Software="Test Software">Test feat 2</Dependency>
 
</Dependencies>
 
</Feature>
 
</Features>
 
</SoftwareType></pre>
 
  
=== Features ===
+
=== Furniture ===
Features are defined in the Feature tag of Software types. Optinally a base.xml file can be placed in the "SoftwareTypes" folder with feature definitions, which will then be added to all software. If the root tag of the base.xml file contains the attribute Override = "TRUE", it will remove any base features already defined, this would remove the built-in QA feature for example.
+
[[Furniture Modding|Read the documentation here.]]
  
==== Tags ====
+
You can add furniture using .obj 3D object files. The furniture modding system, while only using [[TyD|TyD]] files, allows you to change pretty much anything about your furniture that would be possible to change from within the game's engine.
  
{|class="wikitable"
+
=== Materials ===
|Feature
+
[[Material Modding|Read the documentation here.]]
|This is the root tag, which all tags should be a child to. If this tag has the attribute Forced = "TRUE", then this will be implemented by default and the player won't be able to un-tick it, unless it is superseded by another feature. If this tag has the From = "FeatureName" tag, this feature will supersede the feature called "FeatureName", and you can then build entire dependency trees like this.
 
|-
 
|Name
 
|The name of the feature as it will appear in feature panel in the design document window
 
|-
 
|Category
 
|An optional tag that controls which specialization a product belongs to. If it is omitted the feature will belong to the base skill level of a field, usually described as "General" in Software Inc. which is controlled by the employees main skill in a role. Otherwise the employees specialization skill will control how well, if at all, they work with this feature. This can be 2D, 3D, Network, etc. You can add new specializations to the game using this tag.
 
|-
 
|Description
 
|The contents of the tooltip that will appear when hovering over the feature in the design document window.
 
|-
 
|Unlock
 
|Which year this feature will unlock, e.g. <Unlock>1995</Unlock>. Specializations will unlock, when the first feature which uses it unlocks.
 
|-
 
|DevTime
 
|How many months it takes to develop this feature
 
|-
 
|Innovation, Usability, Stability
 
|These three tags are normalized, so you can put in any number. 3, 4 and 5 would result in 3/12, 4/12 and 5/12. Innovation controls how long the product will stay interesting to customers. Usability controls how well customers will like the product and in extension, your company. Stability controls bugs and how much skill your employees will gain from working on the feature.
 
|-
 
|CodeArt
 
|The coding to art balancing of the feature. 1 will mean this feature only requires programmers whereas 0 will mean it only requires artists.
 
|-
 
|Server
 
|A value indicating how much server hosting power this feature requires. It is scaled with DevTime and popularity, so it should probably be somewhere between 0 and 1.
 
|-
 
|Dependencies
 
|What features this feature depends on to be available, this can be features in the current product, features in other products or features in supported operating system. Note that opretaing system feature dependencies are taken as an intersection, so if a features relies on 3D in an operating system, ALL chosen operating systems must support 3D. A dependency should be defined as &lt;Dependency Software="Operating System"&gt;3D&lt;/Dependency&gt;
 
|}
 
  
== Name generators ==
+
Material mods allow you to load textures into the game for interior walls, exterior walls, floors, roofs and paths.
The random name generator uses a tree like structure to generate random strings of words. Generators will be loaded from txt files located in the "NameGenerators" folder and their name will match their file names, minus ".txt". If you name a name generator the same thing as one of the built-in name generators, they will merge their nodes and words, you can use this to expand the words of a built-in name generator.
 
  
=== Example ===
+
=== Code mod ===
 +
[[Code Modding|Read the documentation here.]]
  
Here is an example of how a name generator can be structured in the text file:
+
If you want to dive even further, you can put .cs files directly with the game, and it will compile and load your scripts on startup. For more control, you can compile your own DLL files for the game to load.
  
<pre>-start(base)
+
=== Localizations ===
-base(base2,end,stop)
+
To create a localization you can copy the English folder from the Localization folder and fill in your own text in the appropriate fields. Localization files are written entirely in [[TyD|TyD]], to be easily human-readable.
Hello
 
Hi
 
-base2(end,stop)
 
, you
 
-end(stop)
 
.</pre>
 
This would create a generator that can generate the strings:
 
#Hello
 
#Hi
 
#Hello.
 
#Hi.
 
#Hello, you
 
#Hi, you
 
#Hello, you.
 
#Hi, you.
 
It works by starting from the first node "start" (nodes are the ones with a hyphen in front of the name), it appends a random string from the list of strings below it (in this case there’s nothing to pick), it then picks a random node from the parenthesis of the current node (which can only be "base" in this case), and then it continues until it reaches the node stop. There is a limit to how far it will go, depending on how many nodes there are, to avoid an infinite loop.
 
  
== Company types ==
+
Localizations can also contain '''femalefirstnames.txt''', '''malefirstnames.txt''' and '''lastnames.txt''' files to overwrite the default employee names in the game. These should contain a list of names separated by new lines, ordered by how common the name is.
Company types are the types of company that the game will simulate. If you don't define company types for your new software types, the software will not be released by the AI.
 
  
=== Tags ===
+
====Helpful console commands====
 
+
* '''COMPARE_LOCALIZATION''' X Y - Compares what has changed between between localization X and Y, Y should almost always be "English"
{|class="wikitable"
+
* '''CONVERT_LOCALIZATION_TYD''' X - Converts localization named X from XML to TyD
|CompanyType
+
* '''RELOAD_LOCALIZATION''' - Reloads all localizations, but does not update UI instantly when in-game
|This is the root tag, which all tags should be a child to.
 
|-
 
|Specialization
 
|The name/tag of the company type. If you pick a name of one of the built-in company types, you can override it. Note that this only works for Alpha 4.5+
 
|-
 
|Chance
 
|There is a 25% chance of a company launching each month and it's type will be chosen randomly, based on this number weighted between other company types. In-game this is 15 for game companies and 2 for OS companies.
 
|-
 
|Types
 
|The types of software this company will develop. It should have children "Type" tags with a Name = "SoftwareTypeName" attribute and a chance value between 0 and 1, e.g. <Type Name="Game">0.5</Type>. A random software type will be chosen randomly, but weighted based on this number. Afterwards this number will also decide whether the company actually decides to release the software. OS companies only have Operating System defined here, with a value of 0.1, which means they will only release operating systems, and there is a 90% chance they will decide against releasing it each month.
 
|}
 
 
 
== Scenarios ==
 
Nothing here yet
 
 
 
=== Events ===
 
Nothing here yet
 
 
 
=== Companies ===
 
Nothing here yet
 
 
 
== Personalities ==
 
Nothing here yet
 

Latest revision as of 18:01, 6 April 2026

Mods in Software Inc. can be defined in simple text-based files or using C# and compiling code for the game to load. You can add new software types, furniture, translations and room textures using only the TyD file format.

Debugging console

You'll need the in-game console to properly test your mods and check if everything is working as it should. The debugging console is enabled by binding the console key at the bottom of the key binding menu in the options window. More information about how to use console can be found on Console.

Folder structure

Unless downloaded from the Steam Workshop, mods are placed in the root of the game folder, depending on which type of mod you are making. Each mod should be placed in its own folder within the following folders (Note that these folders might not exist in the first place, so you should create them yourself):

  • Software types and personalities should be placed in the Mods folder.
  • Furniture should be placed in the Furniture folder.
  • Room, path and roof textures should be placed in the Materials folder.
  • C# code and dll files should be placed in the DLLMods folder.
  • Translations should be placed in the Localization folder.

Meta file

Each mod will take its name from the folder it is in. However, you can customize the Name, Description and Author of your mod by adding a meta.tyd file to the root of your mod's folder, containing the specified records. This file will be created automatically when you edit your mod in-game (Not implemented yet as of Alpha 11.4.7).

Localizations

Please go to translate.coredumping.com to help translate the game.

Mod types

Data mod

Read the documentation here.

Data mods can add, change or remove software types, AI company types, name generators and employee personalities. This is all done with TyD files, however software can have scripts attached using SIPL.

Furniture

Read the documentation here.

You can add furniture using .obj 3D object files. The furniture modding system, while only using TyD files, allows you to change pretty much anything about your furniture that would be possible to change from within the game's engine.

Materials

Read the documentation here.

Material mods allow you to load textures into the game for interior walls, exterior walls, floors, roofs and paths.

Code mod

Read the documentation here.

If you want to dive even further, you can put .cs files directly with the game, and it will compile and load your scripts on startup. For more control, you can compile your own DLL files for the game to load.

Localizations

To create a localization you can copy the English folder from the Localization folder and fill in your own text in the appropriate fields. Localization files are written entirely in TyD, to be easily human-readable.

Localizations can also contain femalefirstnames.txt, malefirstnames.txt and lastnames.txt files to overwrite the default employee names in the game. These should contain a list of names separated by new lines, ordered by how common the name is.

Helpful console commands

  • COMPARE_LOCALIZATION X Y - Compares what has changed between between localization X and Y, Y should almost always be "English"
  • CONVERT_LOCALIZATION_TYD X - Converts localization named X from XML to TyD
  • RELOAD_LOCALIZATION - Reloads all localizations, but does not update UI instantly when in-game