[DEV] How to create national focus design documents - SoM-Team/Sons-of-Mobius GitHub Wiki
How to create national focus design documents
The implementation of national focuses in the game means transformation of a textual description into a formal description. The more formal the original description, the easier it is to implement.
Incomplete and conflicting descriptions may create implementation problems, so as a result the programmer will have to ask additional questions to the author of the original document.
To prevent such problems, writers must write their design documents in the common format which is based on the following rules:
-
Formal and simple style. The simpler the document, the easier it is will be understood and implemented.
-
Strict format. If all design documents are written in the same format, the programmer can easily switch between different documents.
-
Completeness. The focus description should contain the focus name, description text, complete rewards, availability and visibility conditions. Also, don't forget about events and decisions: they should be completely described with all their consequences.
The following pseudo design document represents the main parts of any design document: the textual focuses description and the diagram.
The diagram shows the location of the focuses and their interdependence.
The diagram should be made in SVG and high-resolution PNG formats. THe vector one is needed to zoom it without pixelation, while PNG one should be inserted to the design document.
Use this document as a template. Copy it and modify its content leaving its structure as-is.
It's recommended to use draw.io to draw diagrams. The above diagram can be downloaded from there. You can open this .drawio file on this site and use it as a template for creating your own diagrams, or you can create it on your own. Stick to the following notation:
-
Focuses are located in rectangles with their names inside.
-
A line with one arrow indicates a parent-child relation.
-
A two-arrowed line with "X" character (which can be omitted) between two focuses means that they are mutually exclusive.
-
A dotted line means that the children focuses will be available only when all their parents will be completed. In our example:
- Focuses B1, B2, C1 and C2 are available if B0 or C0 is completed. Note that B0 and C0 are mutually exclusive.
- Focus B3 is available if at least one focus from B1 and B2 will be completed.
-
A solid line from multiple parent focuses means that their child will only be available when all its parents are completed. For example, focus C3 will be available only when both C1 and C2 are completed.