User:Mistiryshak/sandbox8

Jump to navigation Jump to search

THESE ARE WORKS IN PROGRESS AND SHOULD NOT BE CONSIDERED OFFICIAL GUIDELINES AT THIS TIME. Only follow guidelines found through our official index.

Guidelines-in-progress on this page are still under review and construction. They represent the opinions of the author (me) at this time and do not reflect official staff stances.

Code Review

Megami Tensei Wiki asks for certain standards to be upheld when writing or using code, which can include Lua-based modules, template code, example code, imported code, and decompiled or leaked source logic.

Internal Code

Templates

Lua

This section details information regarding writing original code in Lua. For information on data modules, which use Lua, see Guidelines:Data Modules.

Lua code should be kept clean and readable for maintenance.

Outside Code

Imported Code

Imported code refers to any and all code used on Megami Tensei Wiki that is taken directly from another source to be used in one's own project, including code on Megami Tensei Wiki itself that was created by another user. Such code should be handled with care, as permission was not given to use the code. Code taken from another user's work should be attributed to that user in a comment, with some exceptions. Template code from within Megami Tensei Wiki, for example, should be written in a consistent manner across templates to ensure that modifications between two similar kinds of templates (i.e. stat tables, infoboxes) can be made if needed. Unique templates and templates from other wikis, however, should be treated as distinct and attribution given when copied or iterated upon. For these cases, as well as for larger bodies of code such as Lua modules or JavaScript, a comment should be inserted with attribution and licensing information. This comment may be placed either above the portion of code that was copied or at the top of the module or node.

Code with a license incompatible with Megami Tensei Wiki's should not be copied without explicit permission. Code is incompatible with Megami Tensei Wiki if it not compatible with CC BY-NC-SA 4.0. For information on license compatibility, visit the website for Creative Commons. Additonally, code created automatically through sources such as generative AI should never be used on Megami Tensei Wiki due to security concerns, difficulty maintaining the code, and stylistic inconsistency with user-generated code.

Decompiled Logic and Source Code

When referring to code from software that is of interest to Megami Tensei Wiki, care should be taken to distinguish between logic and code. Because of compiler optimization, code that comes from decompilation may perform identically to the original source code when recompiled into a running program or game file. However, that code may not necessarily be identical to the original code for that same reason. Therefore, all code from decompilation of any kind should not be treated as "original source code" but as the original logic. Furthermore, decompiled logic should be verified to be identical to the original file through file integrity checks such as ensuring that the final recompiled file has identical binary and through hash signature comparisons. If the hash signature is not identical, it cannot be verified to have identical properties and therefore cannot be treated as a valid source under any circumstances.

Source code, by comparison, can be seen as the original code. In some cases, this is plainly visible to those with the proper expertise to view it, and in other cases may come from leaked or otherwise illicitly obtained materials. However, for this reason, original source code should not be utilized directly on the wiki. Source code is copyrighted and even when taken out of context for educational purposes is legally risky to host.

Instead of hosting source code or referring to decompiled logic as code, pseudo-code or mathematical formulas should be used. For mathematical formulas, the Math extension is used. A manual of syntax for the Math extension can be found here. Pseudo-code is code that is written to demonstrate what a more complicated piece of code does in a simpler, more newbie-friendly fashion, often by replacing more generic terms with those that are readable to those less familiar with code, reducing the complexity of the code, and using explicit variable, function, or table ID names rather than their internal identifiers. Below is an example of pseudo-code, and that same pseudo-code as a mathematical formula. The following example is for demonstration purposes only; code that evaluates to an extremely simple function should be described in prose rather than as code or a formula.

Pseudo-code Demonstration
Original code Pseudo-code Math
if (hero.hp > 0) then
 actor[active].setAction(actor[active].use[2])
end
if ProtagonistHP > 0 then Enemy.useSkill(Swift_Strike)
protagonistHP>0⇒Enemy uses Swift Strike

User Groups

User groups are a term for how the MediaWiki software that Megami Tensei Wiki uses handles special permissions. All accounts on Megami Tensei Wiki are given the User user group, followed by the Autoconfirmed users user group after a period of activity and good faith edits. A list of all users in each noted user group can be found be selecting that user group via Special:ListUsers.

General User Groups

Users

All users are part of this group upon account creation and have the following permissions:

  • Creating pages, including talk pages
  • Editing pages
  • Editing their personal CSS, JSON, and JavaScript files (which only apply to themselves)
  • Creating a watchlist
  • Sending an e-mail via the wiki

If a user has been blocked, the ability to edit and create pages, excepting their own talk page, will be disabled. At the discretion of the user who blocked said user, the ability to send an e-mail via the wiki and editing of their own talk page may be disabled. This is often the case when a user is blocked for unacceptable behavior such as abuse.

Autoconfirmed users

All users who have made at least ten edits without being blocked and have had an account for a period of seven days will be automatically added to the Autoconfirmed users user group. This comes with the following additional permissions:

  • Edit pages or create pages on protected page titles with a protection level of "Allow autoconfirmed users"
  • Automatically skipping the CAPTCHA for some CAPTCHA-triggering actions
  • Upload new files

Autopatrolled users

Users in this user group must manually receive it from a member of the bureaucrats user group. All edits made by users in this group will be autopatrolled. More information about patrolling is found in the patroller user group information.

Moderation User Groups

Moderators

Moderators

Page Movers

Page Movers have the capability to move pages, including files, to new titles.

Patrollers

Patrollers

Administration User Groups

Bureaucrats

Bureaucrats are top-level moderators with the ability to change user groups of other users as well as rename users. This role is only given to trusted users.

Interface Administrators

Interface Administrators have the capability to edit the CSS, JavaScript, and JSON used by Megami Tensei Wiki across all users, alongside the user-specific CSS/JS/JSON for other users. These users are responsible for the "look" of Megami Tensei Wiki and must be involved with any work that relates to custom CSS/JS/JSON.

Administrators

Administrators have the highest permission tier of user groups and have all permissions. The majority of users in this user group are members of site staff who are responsible for the most major decisions regarding the wiki. The current host of Megami Tensei Wiki, who is responsible for implementing the most major of changes, is Rman41.

Dx2 Skill Module Guidelines Revision

Purpose

Data module used to document skill details from Shin Megami Tensei: Liberation Dx2.

Usage

This module contains skill data for use with Template:SkillDx2, Template:Skill Effect, and Template:Skill List.

For more information on how to enter data, see the guidelines on data modules.

Parameter Notes
[' ']
The name of the skill. Must be input between the apostrophes in all lowercase.
attribute
The attribute of the skill. This parameter determines the icon of the skill.
Attributes should be rendered as the following: "phys", "fire", "ice", "elec", "force", "light", "dark", "fractional", "multi-element", "almighty", "healing", "enhance", "debuff", "good status", "bad status", "passive", and "special".
The following skill attributes do not have icons to display: Ailment and Fractional.
multi
The attributes of the skill if the attribute is "multi-element". This parameter determines the icons that will display.
Multi should be rendered like so: "phys, ice, fire", "ice, elec, dark", "force, light" and so forth.
mainapt
The main aptitude of Devil Connector skills. This parameter determines the icon of the aptitude.
Aptitudes should be rendered as the following: "phys", "fire", "ice", "elec", "force", "light", "dark", "almighty", "healing", "support", and "obstruction".
maintype
The main aptitude's typing for Devil Connector skills.
The following are acceptable types: "Damage", "Healing", "Enhance", "Debuff", "Good Status", "Bad Status", and "Other".
subapt
The secondary aptitude of Devil Connector skills. This parameter determines the icon of the aptitude.
Aptitudes should be rendered as the following: "phys", "fire", "ice", "elec", "force", "light", "dark", "almighty", "healing", "support", and "obstruction".
subtype
The secondary aptitude's typing for Devil Connector skills.
The following are acceptable types: "Damage", "Healing", "Enhance", "Debuff", "Good Status", "Bad Status", and "Other".
cost
The cost of the skill.
costtype
The cost type of the skill, i.e. 'MP'.
power
The base power of the skill.
use
The amount of times a skill can be used in a single battle.
hit
The amount of hits a skill does per target. This parameter should not be used for Passive skills where an attack is part of an effect.
In the case of skills that hit multiple times as part of separate effects or the amount of hits changes, input the amount of initial hit(s) upon first use without counting subsequent hits or levels. Those details should be recorded in the hit_note parameter not hit. Do not use an Template:Exp note.
hit_note
Optional; not used when parameter is omitted. Only use when the amount of hit(s) for an attack is non-standard, such as an attack that activates subsequent hit(s) after an initial hit is successful or an attack with variable hits based on the move's current Boost level.
In the case of skills that hit multiple times as part of separate effects, input "Subsequent attack(s) upon success".
If the amount of hits changes, input "Increases with Boost level".
target
The unit(s) targeted by the skill.
damagetype
The damage type of a skill, i.e. Physical, Magic, and Healing.
skillpoints
The amount of skill points it costs to transfer a skill onto a demon.
unique
The demon(s) that the skill is unique to. A skill is considered unique when less than 5 demons have access to it. Any skill that can be transferred cannot be considered unique.
level
The description of a skill's maximum level when leveled via Kasane Magatama or Blood Crystals.
  • Example: For the skill Cleave, level would be rendered as level = 'Lv. 6: +17% to damage.',
component
The Connect Components required to equip Devil Connector skills.
skilltype
The category of a skill, i.e. Magic, Armament, Devil Connector.
description
The official description of the skill.
If a description has multiple sub-effects, use <hr> to separate them.
If an effect/sub-effect has minor details that explains how a skill works mechanically, separate the text using <br>.
If a description starts with a plus sign (+), use &plus; instead of the symbol. If character "+" is used at the start of the information, the parameter will not function.
effect
A brief unofficial description of the skill and its effects.
rarity
The rarity of a skill, if applicable. Should be rendered as a single integer compatible with Template:Star.
armname
The armament's name for Armament skills, if applicable.
armdemon
The related Demon for Armament skills.
name
The name of a skill. Should be rendered as text.
name_note
Places Template:Exp next to the name of a skill for the purpose of leaving vital notes on stat tables. Should be rendered as text.
effect_note
Places Template:Exp next to the name of a skill for the purpose of leaving vital notes on skill pages. Should be rendered as text.
link
The article that will be linked to by the name of the skill. Should be rendered as text. If omitted, the link will direct to the article that is identical to name.

Code

[''] = {
    attribute = '',
    multi = '',
    mainapt = '',
    maintype = '',
    subapt = '',
    subtype = '',
    cost = '',
    costtype = '',
    power = '',
    use = '',
    hit = '',
    hit_note = '',
    target = '',
    skillpoints = '',
    damagetype = '',
    unique = '',
    level = '',
    component = '',
    skilltype = '',
    description = '',
    effect = '',
    rarity = '',
    armname = '',
    armdemon = '',
    name = '',
    name_note = '',
    effect_note = '',
    link = '',
},

Examples

['cleave'] = {
    attribute = 'phys',
    cost = 4,
    costtype = 'MP',
    power = '120',
    hit = '1',
    target = 'Single enemy',
    damagetype = 'Physical',
    attribute = 'Phys',
    description = 'Inflicts Phys (Physical) damage with 120 power on a Single Enemy.',
    skillpoints = '1',
    level = 'Lv. 6: +17% to damage.',
    name = 'Cleave',
},

Maintenance Guidelines

When using Megami Tensei Wiki, an editor may come across a page that has some sort of issue that they cannot fix, do not have time to fix, or at the moment does not want to fix (for various reasons). In these scenarios, Megami Tensei Wiki has a variety of templates that can be placed on pages in order to alert other users to content in need of attention. The following is a table of each template, its general purpose, and where it is typically utilized:

Maintenance Templates
Name Purpose NamespacesThese are the primary namespaces that this applies to; if it would apply to any article not listed here, the template should still be used.
Template:By Whom Used when a statement says something to the effect of "experts say", "according to some", and so forth. This template asks that the experts or opinion group in question be attributed to with a credible source. Main
Template:Citation Needed Used when a statement requires verification to ensure accuracy. For profile sections, this must usually be from a trustworthy source such as an academic journal or a book by a reliable author. For other sections involving in-game data or plot, guidebooks or direct quotes are preferred. Further information on citations can be found at Guidelines:Citations. Main, Gameplay, Plot
Template:Clarify Used when a statement is unclear and needs to be clarified, often by rewriting the statement or surrounding section. Main, Gameplay, Plot
Template:Cleanup Used when a section or article does not follow our manual of style. It is recommended that the article be rewritten or redone to meet our baseline standard of quality.

It is important to note that Cleanup is not used for articles or sections that are written in a way that a user disagrees with, nor is it for sections that a user may personally find "messy." The purpose of Cleanup is to alert users to violations of the manual of style (such as not following media order or sections that were rearranged to be inconsistent with the rest of the wiki); if the manual of style is not in violation, do not use this template. Instead, please use an article's talk page to discuss disagreements with page structure or content flow.

Main, Gallery, Gameplay, Plot
Template:Delete Used to nominate an article for deletion. Further information on what qualifies for deletion can be found at Guidelines:Deletion. Main, Category, File, Gallery, Gameplay, Module, Plot, Template
Template:Guide Used to denote that a section was written like a walkthrough or guide and should instead be written from an encyclopedic point of view. Further information on what makes a section seem written like a guide can be found at Guidelines:Article Writing. Main, Gameplay
Template:Image Used to denote that an article or section is in need of an image that has not already been uploaded to Megami Tensei Wiki. Main, Gameplay, Gallery
Template:Merge Used to nominate that the content of two articles should be combined into a single article. Leaving a message on the article's talk page to explain the reasoning behind this decision is recommended. Main, Category, Gallery, Gameplay
Template:Move Used to nominate an article for moving to a new title or location on the wiki. Main, Category, File, Gallery, Gameplay
Template:Page Needed Used in citations to denote that the relevant page number from a book is missing from a citation. Main, Gameplay, Plot
Template:Quality Used to indicate that a file is in lower quality than would be preferred and should be replaced with a higher-quality version. Further information can be found at Guidelines:Files. File
Template:Research Used to indicate that an article or section requires additional research for various reasons, often to answer a notable question or verify the accuracy of information. Main, Gameplay, Plot
Template:Sectionstub Used to indicate that a section is a stub. For further information, see the below guidelines. Main, Gallery, Gameplay, Plot
Template:Split Used to nominate an article for splitting into two separate articles. Main, Gallery, Gameplay, Plot
Template:Stub Used to indicate that an article is a stub. For further information, see the below guidelines. Main, Gallery, Gameplay, Plot
Template:Translation Needed Used to indicate that an article or section is in need of a translation. Main, Gallery, Gameplay, Plot
Template:When Used to indicate that an article or section is poorly conveying time and should be clarified to be specific. Main, Gameplay, Plot
Template:You Used to indicate that an article is written from a personal, conversational, or otherwise fourth-wall breaking point of view by referring to the reader as you, or by referring to playable characters as the player when inappropriate (such as plot summaries).

Note that this does not apply to documentation of in-game text (such as skill descriptions that use the word you), and that some situations may arise where the player is the only appropriate term of reference (such as describing mechanics in a mobile app that only exist for the player and not in-universe).

Main, Gallery, Gameplay, Plot

Most maintenance templates allow users to include a reason for placing the template. While not a requirement (and in some cases the reason for the notice is self-evident, therefore leaving a reason is redundant), it is all the same heavily encouraged to leave a reason on every notice. Not every editor will see the same issues as each other, especially if the article content appears otherwise excellent. Templates without a reason given may be removed unceremoniously without addressing the issue simply because a member of Wiki staff or another editor performing cleanup does not think the template is relevant. For example, an article may be given a Research notice, and then, after time, various aspects of the article have now been improved, except for the reason the template was added. Without a reason given, this may be invisible to another editor, who only sees an excellent, well-written article, allowing the incomplete information to slip in, undetected and unquestioned.

When an article has been improved such that any notice would no longer apply, it is courteous to remove the notice. Notices should be removed once the reason given for the notice is resolved or (if no reason is given) the editor believes that the most likely reason for the notice has been resolved. This is another motive for leaving a reason on notices - it ensures that for whatever issue caused an editor to leave a notice, it will be resolved before the notice is taken down.

Stubs

The most common maintenance templates on Megami Tensei Wiki are, by far, Stub and Sectionstub. This is not surprising - the Megami Tensei franchise is vast and covers nearly 40 years of history encapsulated within countless formats. It is fair to say that Megami Tensei Wiki would not be possible with a team of one, and that no one person could possibly have all of the knowledge or technical skill required to make comprehensive articles on every possible subject. With all this in mind, stubs making up such a large quantity of articles is a natural result. For this reason, Megami Tensei Wiki utilizes a large amount of subcategories denoting what kind of article is a stub or section stub. Properly utilizing stub templates helps users that have the requisite knowledge to improve an article find that article. The following guidelines help to identify when to use Stub and Sectionstub:

  • Stub
    • When an article is newly created and the article creator knows that the majority of content is missing
    • When an article is missing large amounts of information in various sections
      • What qualifies as "large amounts" will vary from article-to-article and will depend on the editor's judgement. That said, if an article is missing its entire Gameplay section but every other section is complete, then that is not a stub; it is a section stub.
    • When an article has content in every section, but every section's content is so incomplete that someone unfamiliar with the subject would still be able to tell it is missing information
    • When an article for a subject that appears in a significant amount of media has detailed information, but all of it is only relevant to one piece of media
    • When an article is clearly mostly empty and only exists to prevent red links
  • Sectionstub
    • When a section of an article that is otherwise not a stub is missing notable content (such as gameplay information for various games, the plot information for a specific appearance, etc)
    • When a notable section of an otherwise good article is blank or consists of only a single sentence
    • When a section would otherwise appear complete if not for the notice of missing information provided by Sectionstub
      • This provides an additional benefit to not just editors, but also readers. Readers who see this notice will understand that there is undocumented information, preventing them from mistakenly believing that an article's content is complete. While this does make Megami Tensei Wiki look "worse" to some, it upholds our standards of quality and commitment to constant improvement. It may even inspire someone to join the Wiki to add what is missing themselves!

When using Stub and Sectionstub, it is recommended to apply relevant subcategories. For Stub, those are the article type and article series; for Sectionstub, it is the section type. Further information can be found on each template's documentation.

As an additional note, it is recommended (but not required) that Stub and Sectionstub be mutually exclusive. In other words, if an article is an overall stub, it should avoid using Sectionstub; likewise, if an article uses Sectionstub, it should avoid having a larger Stub notice. This is because Stub notices are broad and only contain information about what kind of article it is, while a Sectionstub notice contains narrower information about what kind of work needs done. In the case of the former, Megami Tensei Wiki prefers that those well-versed on the topic as a whole step in to improve the overall article, while in the case of the latter, it is recommended that those less familiar with the media but the requisite skills attempt to collaborate with other users to improve the section. This is not a hard rule, however; for example, an article may still be a general stub, but one section in particular already has decent progress and needs further work to improve it, so it may use Sectionstub to identify this as a section in particular need. An editor's judgement should be used in these cases.

Lastly, Sectionstub's gallery category and Image should only be used together when a gallery is missing an exceptional amount of images; for example, if Jack Frost's gallery were for whatever reason to only have his sprite from Shin Megami Tensei IV and a few other scattered images, that would be a gallery section stub.

Flavor

The flavor section of an article is used to document various instances of flavor text regarding a subject. Examples include compendium entries for Demons, descriptions from manuals, inserts, guidebooks, etc. and unique dialogue in games that may play upon leveling up, being fused (for Demons and similar entities), or non-generic dialogue when spoken to in specific locations such as Demon Haunts. Text that typically serves a gameplay purpose, such as menu descriptions of skills and items, should not be included - the flavor section is primarily for things that explain the subject in-universe and have little to no mechanical bearing (though may have narrative weight, depending on the title).

The flavor section is divided into two subsections labeled Descriptions and Dialogue. The descriptions subsection is used for compendium entries, text in manuals, and so forth - anything which describes the subject. The dialogue subsection is used for unique, short dialogue spoken by the subject in video games. It is not a full quotes repository, nor is it a full transcript of all dialogue spoken by the subject in question - the dialogue subsection for Jack Frost would not include all of the possible dialogue for Demons with the Hee-Ho speech pattern, only dialogue that is only spoken by Jack Frost. Furthermore, dialogue from the main story, side quests, or specific NPCs should not be included, as these characters and events should instead be covered in prose in the Game Appearances section. Unique dialogue for giving gifts, activating a field skill, recruiting a demon, leveling up, winning a battle, taking damage and so forth are examples of acceptable dialogue.

Compendium entries should use Template:Compendium, manual entries should use Template:Manual, and dialogue should use Template:Dialogue. Different types of dialogue within the same subsection should be placed into tabs using Template:Tabs. When tabs are in use, the descriptions subsection should place the tabs in the following order (omitting any that would be empty): Compendium, Manual, then Books. Similarly, the dialogue subsection should place Unique Quotes first, followed by any longer game-specific dialogue with that game's standard abbreviation denoted; for example: Demon Haunt (SMT5V). Game-specific tabs should follow the wiki's media order. Game-specific dialogue types may require the use of a specialized template. For unique quotes, quote types should be prefaced with a bolded explanation of when the quote occurs (like so: Gift: You may like this...) and separated by a newline using <br/> if multiple quote types exist. For when multiple quotes of the same type exist, to reduce confusion, each quote should be placed on a new line, and the bolded preface should include a number, i.e. Gift 1, Gift 2 and so on.

If no flavor text of any kind exists for the subject, this section may be omitted entirely. If a subject has unique dialogue but no entries in manuals, the compendium, guidebooks and so forth then the descriptions subsection may be omitted, and this likewise applies to the dialogue subsection when none exists.

Descriptions

CompendiumManual
Compendium Entries
Shin Megami Tensei
(A-Mode DDS)

Example entry.

Shin Megami Tensei II
(A-Mode DDS)

Example entry.

Manual Descriptions
Shin Megami Tensei IV

Example entry.

Dialogue

Unique QuotesDemon Haunt (SMT5V)
Dialogue
Shin Megami Tensei IV

Gift 1: Example entry.
Gift 2: Example entry.
Level Up: Example entry.
Fusion: Example entry.

Shin Megami Tensei V

Level Up: Example entry.

Dialogue
Shin Megami Tensei V: Vengeance

Dialogue 1: Example entry.
Dialogue 2: Example entry.
Dialogue 3: Example entry.
Dialogue 4: Example entry.