bcdice/BCDice

View on GitHub
lib/bcdice/game_system/Nuekagami.rb

Summary

Maintainability
B
5 hrs
Test Coverage
A
100%

File Nuekagami.rb has 268 lines of code (exceeds 250 allowed). Consider refactoring.
Open

module BCDice
  module GameSystem
    class Nuekagami < Base
      # ゲームシステムの識別子
      ID = 'Nuekagami'
Severity: Minor
Found in lib/bcdice/game_system/Nuekagami.rb - About 2 hrs to fix

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "BL" => {
                name: "血脈の喪失表",
                type: '1D20',
                table: [
                  '髪の色。一夜にしてあなたの髪は白くなった。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "OG" => {
                name: "応天門通過描写表",
                type: '1D20',
                table: [
                  '光捕らへど暗し。新たなる地獄の門に落つる己を知りたり。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "SL" => {
                name: "魂魄の喪失表",
                type: '1D20',
                table: [
                  '誇り。誇りなど残ってはいない。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "RG" => {
                name: "羅生門通過描写表",
                type: '1D20',
                table: [
                  'むごき所業、目にせり。心強張りて、常の様にてあれず.',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "VG" => {
                name: "朱雀門通過描写表",
                type: '1D20',
                table: [
                  '雷響きて、暗霊いよいよ濃ゆし。己が先を見せるるが如し。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "LR" => {
                name: "喪失取戻表",
                type: '1D20',
                table: [
                  '鬼化。妄執かくして鬼と結実す。欠けたるところすでになし。あやかし、己の欠けたるを足せり。すなわちその身、人ならず。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "LL" => {
                name: "生様の喪失表",
                type: '1D20',
                table: [
                  '主君の寵愛。不興を買ってしまった。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "HG" => {
                name: "地獄門通過描写表",
                type: '1D20',
                table: [
                  '背後見れば、地獄の門をば幻視せり。危うき次第を知りたり.',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 153..177
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

              "FL" => {
                name: "因縁表",
                type: '1D20',
                table: [
                  '仇敵。奴は敵だ。あなたの敵だ。',
    Severity: Major
    Found in lib/bcdice/game_system/Nuekagami.rb and 8 other locations - About 20 mins to fix
    lib/bcdice/game_system/Nuekagami.rb on lines 45..69
    lib/bcdice/game_system/Nuekagami.rb on lines 72..96
    lib/bcdice/game_system/Nuekagami.rb on lines 99..123
    lib/bcdice/game_system/Nuekagami.rb on lines 126..150
    lib/bcdice/game_system/Nuekagami.rb on lines 180..204
    lib/bcdice/game_system/Nuekagami.rb on lines 207..231
    lib/bcdice/game_system/Nuekagami.rb on lines 234..258
    lib/bcdice/game_system/Nuekagami.rb on lines 261..285

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 27.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    There are no issues that match your filters.

    Category
    Status