colonizers/colonizers-core

View on GitHub
lib/scenario-builder.js

Summary

Maintainability
C
7 hrs
Test Coverage

Function getScenario has 112 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  getScenario() {
    var circumradius = hexInfo.circumradius;
    var apothem = hexInfo.apothem;
    var layout = this.getLayout();
    var numberTokens = layout.numberTokens;
Severity: Major
Found in lib/scenario-builder.js - About 4 hrs to fix

    Function getTileLayout has 39 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

      getTileLayout(layout) {
        var circumradius = hexInfo.circumradius;
        var apothem = hexInfo.apothem;
    
        var tiles = layout.tiles.map(function(row) {
    Severity: Minor
    Found in lib/scenario-builder.js - About 1 hr to fix

      Function processEdges has 27 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        processEdges(board, edges) {
          var edges1 = _.chain(edges)
            .map(function(edge) {
              return {
                center: edge.center,
      Severity: Minor
      Found in lib/scenario-builder.js - About 1 hr to fix

        There are no issues that match your filters.

        Category
        Status