LanguageBat_smg.php 554 B

1234567891011121314151617181920212223242526
  1. <?php
  2. /** Samogitian (Žemaitėška)
  3. *
  4. * @ingroup Language
  5. *
  6. * @author Niklas Laxström
  7. */
  8. class LanguageBat_smg extends Language {
  9. function convertPlural( $count, $forms ) {
  10. if ( !count($forms) ) { return ''; }
  11. $forms = $this->preConvertPlural( $forms, 4 );
  12. $count = abs( $count );
  13. if ( $count === 0 || ($count%100 === 0 || ($count%100 >= 10 && $count%100 < 20)) ) {
  14. return $forms[2];
  15. } elseif ( $count%10 === 1 ) {
  16. return $forms[0];
  17. } elseif ( $count%10 === 2 ) {
  18. return $forms[1];
  19. } else {
  20. return $forms[3];
  21. }
  22. }
  23. }