Nameless::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 16
Code Lines 13

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 14
CRAP Score 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 13
c 1
b 0
f 0
dl 0
loc 16
ccs 14
cts 14
cp 1
rs 9.8333
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace AardsGerds\Game\Entity\Nameless;
6
7
use AardsGerds\Game\Build\Attribute\Etherum;
8
use AardsGerds\Game\Build\Attribute\Health;
9
use AardsGerds\Game\Build\Attribute\Initiative;
10
use AardsGerds\Game\Build\Attribute\Strength;
11
use AardsGerds\Game\Build\Talent\SecretKnowledge\Ascension;
12
use AardsGerds\Game\Build\Talent\SecretKnowledge\SecretKnowledge;
13
use AardsGerds\Game\Build\Talent\TalentCollection;
14
use AardsGerds\Game\Build\Talent\WeaponMastery\ShortSword\Novice\Slash;
15
use AardsGerds\Game\Build\Talent\WeaponMastery\WeaponMastery;
16
use AardsGerds\Game\Build\Talent\WeaponMastery\WeaponMasteryLevel;
17
use AardsGerds\Game\Entity\Corruption;
18
use AardsGerds\Game\Entity\Entity;
19
use AardsGerds\Game\Inventory\Inventory;
20
use AardsGerds\Game\Inventory\Weapon\GreatSword\SteelFromAbyss;
21
22
final class Nameless extends Entity
23
{
24 2
    public function __construct()
25
    {
26 2
        parent::__construct(
27 2
            'Nameless',
28 2
            new Health(500),
29 2
            new Etherum(rand(2, 10)),
30 2
            new Strength(100),
31 2
            new Initiative(40),
32 2
            new TalentCollection([
33 2
                WeaponMastery::greatSword(WeaponMasteryLevel::veteran()),
34 2
                new SecretKnowledge(Ascension::sixthAscension()),
35 2
                new Slash(),
36
            ]),
37 2
            new Inventory([]),
38 2
            new SteelFromAbyss(),
39 2
            Corruption::medium(),
40
        );
41 2
    }
42
}
43