Ousret/Picross-L3S6

View on GitHub

Showing 91 of 2,952 total issues

Assignment Branch Condition size for initialize is too high. [15.39/15]
Open

  def initialize()

    @kRender = Render::Game.new
    @kRender.game_scenes.add_observer(self) #Pattern Observable

Severity: Minor
Found in main.rb by rubocop

This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric

Method setup has 38 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    def setup

      @scene_loops_per_second = 24
      @@vertex = nil

Severity: Minor
Found in class/render.class.rb - About 1 hr to fix

    Method creer has 9 arguments (exceeds 4 allowed). Consider refactoring.
    Open

        def Sprite.creer(uneDesignation, uneImage, uneDimX, uneDimY, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY)
    Severity: Major
    Found in class/sprite.class.rb - About 1 hr to fix

      Method initialize has 9 arguments (exceeds 4 allowed). Consider refactoring.
      Open

          def initialize(uneDesignation, uneImage, uneDimX, uneDimY, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY) # :nodoc:
      Severity: Major
      Found in class/sprite.class.rb - About 1 hr to fix

        Method read_dib_header has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring.
        Open

                def read_dib_header(file)
                #méthode qui effectue des tests pour les exceptions :
                #test si l'url est bonne
                #test si l'image est convenable :
                #    l'image doit être codée avec du 24bit par pixel
        Severity: Minor
        Found in class/bmp.class.rb - About 1 hr to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Method initialize has 8 arguments (exceeds 4 allowed). Consider refactoring.
        Open

          def initialize(uneDesignation, unCheminRelatif, lectureInfinie, uneAttenuation, uneFrequencePitch, unePositionX, unePositionY, unePositionZ) # :nodoc:
        Severity: Major
        Found in class/audio.class.rb - About 1 hr to fix

          Method creer has 8 arguments (exceeds 4 allowed). Consider refactoring.
          Open

            def Audio.creer(uneDesignation, unCheminRelatif, lectureInfinie, uneAttenuation, uneFrequencePitch, unePositionX, unePositionY, unePositionZ)
          Severity: Major
          Found in class/audio.class.rb - About 1 hr to fix

            Method setup has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                def setup
            
                  @scene_loops_per_second = 24
                  @@vertex = nil
            
            
            Severity: Minor
            Found in class/render.class.rb - About 55 mins to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Method calculeIndiceHaut has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                def calculeIndiceHaut()
            
                    nbCaseNoirConsecutif = 0 #variable qui permet de gerer les cases noir consecutifs
                    y=0
                    while y < @matriceComparaison.length #------------------------------------on parcours chaque colonne
            Severity: Minor
            Found in class/grille.class.rb - About 55 mins to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Method calculeIndiceCote has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                def calculeIndiceCote()
            
                    nbCaseNoirConsecutif = 0 #variable qui permet de gerer les cases noir consecutifs
                    x=0
                    while x < @matriceComparaison.length #--------------------------------------on parcours chaque ligne
            Severity: Minor
            Found in class/grille.class.rb - About 55 mins to fix

            Cognitive Complexity

            Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

            A method's cognitive complexity is based on a few simple rules:

            • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
            • Code is considered more complex for each "break in the linear flow of the code"
            • Code is considered more complex when "flow breaking structures are nested"

            Further reading

            Method initialize has 6 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                def initialize(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY) # :nodoc:
            Severity: Minor
            Found in class/fenetre.class.rb - About 45 mins to fix

              Method creer has 6 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  def creer(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY)
              Severity: Minor
              Found in class/objetgui.class.rb - About 45 mins to fix

                Method initialize has 6 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    def initialize(uneDesignation, unContenu, uneTaillePolice, unePositionX, unePositionY, unePositionZ) # :nodoc:
                Severity: Minor
                Found in class/text.class.rb - About 45 mins to fix

                  Method creer has 6 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                      def Boutton.creer(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY)
                  Severity: Minor
                  Found in class/button.class.rb - About 45 mins to fix

                    Method creer has 6 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        def Saisie.creer(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY)
                    Severity: Minor
                    Found in class/saisie.class.rb - About 45 mins to fix

                      Method creer has 6 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          def Fenetre.creer(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY)
                      Severity: Minor
                      Found in class/fenetre.class.rb - About 45 mins to fix

                        Method initialize has 6 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                            def initialize(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY) # :nodoc:
                        Severity: Minor
                        Found in class/button.class.rb - About 45 mins to fix

                          Method initialize has 6 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                              def initialize(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY) # :nodoc:
                          Severity: Minor
                          Found in class/popup.class.rb - About 45 mins to fix

                            Method initialize has 6 arguments (exceeds 4 allowed). Consider refactoring.
                            Open

                                def initialize(uneDesignation, unePositionX, unePositionY, unePositionZ, uneTailleX, uneTailleY) # :nodoc:
                            Severity: Minor
                            Found in class/objetgui.class.rb - About 45 mins to fix

                              Method creer has 6 arguments (exceeds 4 allowed). Consider refactoring.
                              Open

                                  def Text.creer(uneDesignation, unContenu, uneTaillePolice, unePositionX, unePositionY, unePositionZ)
                              Severity: Minor
                              Found in class/text.class.rb - About 45 mins to fix
                                Severity
                                Category
                                Status
                                Source
                                Language