noobprotection don't work

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • noobprotection don't work

      The noobprotection don't work in 2moons 2.0.

      The players witch millions of points can attack others players witch 1 point.

      La proteccion a novatos y la proteccion a jugadores no funciona. Jugadores con millones de puntos pueden atacar a otros con solo 1 punto.


      PHP Source Code: GeneralFunctions.php

      1. function CheckNoobProtec($OwnerPlayer, $TargetPlayer, $Player)
      2. {
      3. $config = Config::get();
      4. if(
      5. $config->noobprotection == 0
      6. || $config->noobprotectiontime == 0
      7. || $config->noobprotectionmulti == 0
      8. || $Player['banaday'] > TIMESTAMP
      9. || $Player['onlinetime'] < TIMESTAMP - INACTIVE
      10. ) {
      11. return array('NoobPlayer' => false, 'StrongPlayer' => false);
      12. }
      13. return array(
      14. 'NoobPlayer' => (
      15. /* WAHR:
      16. Wenn Spieler mehr als 25000 Punkte hat UND
      17. Wenn ZielSpieler weniger als 80% der Punkte des Spieler hat.
      18. ODER weniger als 5.000 hat.
      19. VERDADERO:
      20. Si el jugador tiene más de 25000 puntos Y
      21. Si el jugador objetivo tiene menos del 80% de la puntuación del jugador.
      22. O tiene menos de 5,000.
      23. */
      24. // Addional Comment: Esto último no tiene sentido, por favor prueba.
      25. ($TargetPlayer['total_points'] <= $config->noobprotectiontime) && // Default: 25.000
      26. ($OwnerPlayer['total_points'] > $TargetPlayer['total_points'] * $config->noobprotectionmulti)
      27. ),
      28. 'StrongPlayer' => (
      29. /* WAHR:
      30. Wenn Spieler weniger als 5000 Punkte hat UND
      31. Mehr als das funfache der eigende Punkte hat
      32. VERDADERO:
      33. Si el jugador tiene menos de 5000 puntos Y
      34. Más de cinco veces el número de puntos.
      35. */
      36. ($OwnerPlayer['total_points'] < $config->noobprotectiontime) && // Default: 5.000
      37. ($OwnerPlayer['total_points'] * $config->noobprotectionmulti < $TargetPlayer['total_points'])
      38. ),
      39. );
      40. }
      Display All