Knp\Bundle\KnpBundlesBundle\Badge\BadgeGenerator::getPositionByType PHP Method

getPositionByType() protected method

Get score points position x:y
protected getPositionByType ( integer | string $score, string $type ) : Imagine\Image\Point
$score integer | string
$type string
return Imagine\Image\Point
    protected function getPositionByType($score, $type)
    {
        // Count scores numbers
        $n = strlen($score) - 1 ?: 0;
        $coordinates = explode(':', $this->position[$type][$n]);
        return new Point($coordinates[0], $coordinates[1]);
    }