hugoruscitti/pilas

View on GitHub
pilasengine/actores/__init__.py

Summary

Maintainability
F
1 wk
Test Coverage

Actores has 78 functions (exceeds 20 allowed). Consider refactoring.
Open

class Actores(object):
    """Representa la forma de acceso y construcción de actores.

    Esta clase representa el objeto creado por pilas que
    se puede acceder escribiendo ``pilas.actores``. Desde aquí
Severity: Major
Found in pilasengine/actores/__init__.py - About 1 day to fix

    File __init__.py has 570 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    # -*- encoding: utf-8 -*-
    # pilas engine: un motor para hacer videojuegos
    #
    # Copyright 2010-2014 - Hugo Ruscitti
    # License: LGPLv3 (see http://www.gnu.org/licenses/lgpl.html)
    Severity: Major
    Found in pilasengine/actores/__init__.py - About 1 day to fix

      Function _vincular_todos_los_actores_estandar has 62 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          def _vincular_todos_los_actores_estandar(self):
              self.vincular_actor_estandar('misil', 'Misil')
              self.vincular_actor_estandar('actor', 'Actor')
              self.vincular_actor_estandar('texto', 'Texto')
              self.vincular_actor_estandar('texto_inferior', 'TextoInferior')
      Severity: Major
      Found in pilasengine/actores/__init__.py - About 2 hrs to fix

        Function _validar_argumentos has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
        Open

            def _validar_argumentos(self, metodo, nombre_clase, funcion, k, kv):
                """Se asegura que la función iniciar del actor
                se pueda ejecutar con los argumentos indicados."""
        
                argumentos_esperados = inspect.getargspec(funcion)
        Severity: Minor
        Found in pilasengine/actores/__init__.py - About 2 hrs 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

        Function agregar_actor has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring.
        Open

            def agregar_actor(self, actor):
                """Agrega un actor a la escena actual.
        
                Este método se ejecuta internamente cada vez que se
                contruye un actor escribiendo algo como:
        Severity: Minor
        Found in pilasengine/actores/__init__.py - 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

        Function Globo has 9 arguments (exceeds 4 allowed). Consider refactoring.
        Open

            def Globo(self, texto="sin texto", x=0, y=0, dialogo=None, avance_con_clicks=True,
        Severity: Major
        Found in pilasengine/actores/__init__.py - About 1 hr to fix

          Function Mapa has 9 arguments (exceeds 4 allowed). Consider refactoring.
          Open

              def Mapa(self, x=0, y=0, grilla=None, filas=20, columnas=20,
          Severity: Major
          Found in pilasengine/actores/__init__.py - About 1 hr to fix

            Function Energia has 8 arguments (exceeds 4 allowed). Consider refactoring.
            Open

                def Energia(self, x=0, y=0, progreso=100, ancho=200, alto=30,
            Severity: Major
            Found in pilasengine/actores/__init__.py - About 1 hr to fix

              Function Texto has 8 arguments (exceeds 4 allowed). Consider refactoring.
              Open

                  def Texto(self, cadena_de_texto="Sin texto", magnitud=20, vertical=False,
              Severity: Major
              Found in pilasengine/actores/__init__.py - About 1 hr to fix

                Function Opcion has 8 arguments (exceeds 4 allowed). Consider refactoring.
                Open

                    def Opcion(self, texto="", x=0, y=0,
                Severity: Major
                Found in pilasengine/actores/__init__.py - About 1 hr to fix

                  Function MapaTiled has 7 arguments (exceeds 4 allowed). Consider refactoring.
                  Open

                      def MapaTiled(self, ruta_mapa, x=0, y=0,
                  Severity: Major
                  Found in pilasengine/actores/__init__.py - About 50 mins to fix

                    Function Particula has 7 arguments (exceeds 4 allowed). Consider refactoring.
                    Open

                        def Particula(self, emisor=None, x=0, y=0, dx=0, dy=0, imagen="particula.png", vida=1):
                    Severity: Major
                    Found in pilasengine/actores/__init__.py - About 50 mins to fix

                      Function Menu has 6 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                          def Menu(self, opciones=[], x=0, y=0, fuente=None,
                      Severity: Minor
                      Found in pilasengine/actores/__init__.py - About 45 mins to fix

                        Function Torreta has 6 arguments (exceeds 4 allowed). Consider refactoring.
                        Open

                            def Torreta(self,  municion_bala_simple=None, enemigos=[], cuando_elimina_enemigo=None, x=0, y=0, frecuencia_de_disparo=10):
                        Severity: Minor
                        Found in pilasengine/actores/__init__.py - About 45 mins to fix

                          Function ManejadorPropiedad has 6 arguments (exceeds 4 allowed). Consider refactoring.
                          Open

                              def ManejadorPropiedad(self, x, y, actor, propiedad, minimo, maximo):
                          Severity: Minor
                          Found in pilasengine/actores/__init__.py - About 45 mins to fix

                            Function Dinamita has 5 arguments (exceeds 4 allowed). Consider refactoring.
                            Open

                                def Dinamita(self, x=0,y=0,rotacion=0,velocidad_maxima=4, angulo_de_movimiento=90):
                            Severity: Minor
                            Found in pilasengine/actores/__init__.py - About 35 mins to fix

                              Function Boton has 5 arguments (exceeds 4 allowed). Consider refactoring.
                              Open

                                  def Boton(self, x=0, y=0,
                              Severity: Minor
                              Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                Function DeslizadorHorizontal has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                Open

                                    def DeslizadorHorizontal(self, x=0, y=0, min=0, max=100, etiqueta=''):
                                Severity: Minor
                                Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                  Function Animacion has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                  Open

                                      def Animacion(self, grilla='sin_imagen.png', ciclica=False, x=0, y=0, velocidad=10):
                                  Severity: Minor
                                  Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                    Function Misil has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                    Open

                                        def Misil(self, x=0, y=0, rotacion=0, velocidad_maxima=8,
                                    Severity: Minor
                                    Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                      Function _validar_argumentos has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                      Open

                                          def _validar_argumentos(self, metodo, nombre_clase, funcion, k, kv):
                                      Severity: Minor
                                      Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                        Function Bala has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                        Open

                                            def Bala(self, x=0, y=0, rotacion=0, velocidad_maxima=9,
                                        Severity: Minor
                                        Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                          Function DisparoLaser has 5 arguments (exceeds 4 allowed). Consider refactoring.
                                          Open

                                              def DisparoLaser(self, x=0, y=0, rotacion=0, velocidad=10, imagen="disparo_laser.png"):
                                          Severity: Minor
                                          Found in pilasengine/actores/__init__.py - About 35 mins to fix

                                            Function vincular has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                                            Open

                                                def vincular(self, clase_del_actor):
                                                    """Permite vincular una clase de actor con pilas.
                                            
                                                    Esto permite de después el actor se pueda crear desde
                                                    el módulo "pilas.actores".
                                            Severity: Minor
                                            Found in pilasengine/actores/__init__.py - About 35 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

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

                                                def DeslizadorHorizontal(self, x=0, y=0, min=0, max=100, etiqueta=''):
                                                    ":rtype: deslizador_horizontal.DeslizadorHorizontal"
                                                    return self._crear_actor('deslizador_horizontal',
                                                                             'DeslizadorHorizontal',
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 555..557

                                            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 46.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Misil(self, x=0, y=0, rotacion=0, velocidad_maxima=8,
                                                            angulo_de_movimiento=90):
                                                    ":rtype: misil.Misil"
                                                    return self._crear_actor('misil', 'Misil',
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 569..572

                                            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 46.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def DisparoLaser(self, x=0, y=0, rotacion=0, velocidad=10, imagen="disparo_laser.png"):
                                                    ":rtype: disparo_laser.DisparoLaser"
                                                    return self._crear_actor('disparo_laser', 'DisparoLaser',
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 515..518

                                            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 46.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Bala(self, x=0, y=0, rotacion=0, velocidad_maxima=9,
                                                         angulo_de_movimiento=90):
                                                    ":rtype: bala.Bala"
                                                    return self._crear_actor('bala', 'Bala',
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 561..564

                                            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 46.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Mapa(self, x=0, y=0, grilla=None, filas=20, columnas=20,
                                                         densidad=0, restitucion=0, friccion=10.5, amortiguacion=0.1):
                                                    ":rtype: mapa.Mapa"
                                                    return self._crear_actor('mapa', 'Mapa', x=x, y=y,
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 489..492

                                            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 42.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Globo(self, texto="sin texto", x=0, y=0, dialogo=None, avance_con_clicks=True,
                                                          autoeliminar=False, ancho_globo=0, alto_globo=0, objetivo=None):
                                                    ":rtype: globo.Globo"
                                                    return self._crear_actor('globo', 'Globo', texto=texto, x=x, y=y,
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 387..390

                                            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 42.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Energia(self, x=0, y=0, progreso=100, ancho=200, alto=30,
                                                            color_relleno=pilasengine.colores.amarillo, con_sombra=True,
                                                            con_brillo=True):
                                                    ":rtype: energia.Energia"
                                                    return self._crear_actor('energia', 'Energia', x=x, y=y,
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 329..334

                                            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 39.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Opcion(self, texto="", x=0, y=0,
                                                             funcion_a_invocar=None,argumentos=None,fuente=None,
                                                             color_normal=pilasengine.colores.gris,
                                                             color_resaltado=pilasengine.colores.blanco):
                                                    ":rtype: opcion.Opcion"
                                            Severity: Major
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 1 hr to fix
                                            pilasengine/actores/__init__.py on lines 367..371

                                            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 39.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Tortuga(self, x=0, y=0, dibuja=True):
                                                    ":rtype: martian.Martian"
                                                    return self._crear_actor('tortuga', 'Tortuga', x=x, y=y, dibuja=dibuja)
                                            Severity: Minor
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 50 mins to fix
                                            pilasengine/actores/__init__.py on lines 311..313

                                            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 36.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def CursorDisparo(self, x=0, y=0, usar_el_mouse=True):
                                                    ":rtype: cursor_disparo.CursorDisparo"
                                                    return self._crear_actor('cursor_disparo', 'CursorDisparo', x=x, y=y, usar_el_mouse=usar_el_mouse)
                                            Severity: Minor
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 50 mins to fix
                                            pilasengine/actores/__init__.py on lines 303..305

                                            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 36.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def ActorInvisible(self, x=0, y=0, imagen='sin_imagen.png'):
                                                    ":rtype: actor_invisible.ActorInvisible"
                                                    return self._crear_actor('actor_invisible', 'ActorInvisible', x=x, y=y, imagen=imagen)
                                            Severity: Minor
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 50 mins to fix
                                            pilasengine/actores/__init__.py on lines 262..264

                                            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 36.

                                            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 2 locations. Consider refactoring.
                                            Open

                                                def Actor(self, x=0, y=0, imagen='sin_imagen.png'):
                                                    ":rtype: actor.Actor"
                                                    return self._crear_actor('actor', 'Actor', x=x, y=y, imagen=imagen)
                                            Severity: Minor
                                            Found in pilasengine/actores/__init__.py and 1 other location - About 50 mins to fix
                                            pilasengine/actores/__init__.py on lines 266..268

                                            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 36.

                                            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