PhaseTimeUpdateEvent::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 2
1
<?php
2
/**
3
 * Copyright (c) 2018 VectorNetworkProject. All rights reserved. MIT license.
4
 *
5
 * GitHub: https://github.com/VectorNetworkProject/TheMix
6
 * Website: https://www.vector-network.tk
7
 */
8
9
namespace VectorNetworkProject\TheMix\game\event\game;
10
11
use pocketmine\event\Cancellable;
12
use pocketmine\event\Event;
13
14
class PhaseTimeUpdateEvent extends Event implements Cancellable
15
{
16
    /** @var int $time */
17
    private $time;
18
    /** @var int $phase */
19
    private $phase;
20
21
    /**
22
     * PhaseTimeUpdateEvent constructor.
23
     *
24
     * @param int $time
25
     * @param int $phase
26
     */
27
    public function __construct(int $time, int $phase)
28
    {
29
        $this->time = $time;
30
        $this->phase = $phase;
31
    }
32
33
    /**
34
     * @return int
35
     */
36
    public function getTime(): int
37
    {
38
        return $this->time;
39
    }
40
41
    /**
42
     * @return int
43
     */
44
    public function getPhase(): int
45
    {
46
        return $this->phase;
47
    }
48
}
49