PositionedSound .java

net.minecraft.client.audio.PositionedSound (class): members: positionedSoundLocation, attenuationType, repeatDelay, repeat, xPosF, yPosF, zPosF, canRepeat.

net.minecraft.client.audioclass69 linesclient1.4 KB

Implements

API Surface (9)

ResourceLocation getSoundLocation()
boolean canRepeat()
int getRepeatDelay()
float getVolume()
float getPitch()
float getXPosF()
float getYPosF()
float getZPosF()
ISound.AttenuationType getAttenuationType()

Fields & Constants (9)

positionedSoundLocation
volume
pitch
xPosF
yPosF
zPosF
repeat
repeatDelay
attenuationType

Code Graph: Dependencies (2)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

PositionedSound.java69 lines · MCP 1.8.9 · verbatimOriginal ↗
1
package net.minecraft.client.audio;
2
3
import net.minecraft.util.ResourceLocation;
4
5
public abstract class PositionedSound implements ISound
6
{
7
    protected final ResourceLocation positionedSoundLocation;
8
    protected float volume = 1.0F;
9
    protected float pitch = 1.0F;
10
    protected float xPosF;
11
    protected float yPosF;
12
    protected float zPosF;
13
    protected boolean repeat = false;
14
15
    /** The number of ticks between repeating the sound */
16
    protected int repeatDelay = 0;
17
    protected ISound.AttenuationType attenuationType = ISound.AttenuationType.LINEAR;
18
19
    protected PositionedSound(ResourceLocation soundResource)
20
    {
21
        this.positionedSoundLocation = soundResource;
22
    }
23
24
    public ResourceLocation getSoundLocation()
25
    {
26
        return this.positionedSoundLocation;
27
    }
28
29
    public boolean canRepeat()
30
    {
31
        return this.repeat;
32
    }
33
34
    public int getRepeatDelay()
35
    {
36
        return this.repeatDelay;
37
    }
38
39
    public float getVolume()
40
    {
41
        return this.volume;
42
    }
43
44
    public float getPitch()
45
    {
46
        return this.pitch;
47
    }
48
49
    public float getXPosF()
50
    {
51
        return this.xPosF;
52
    }
53
54
    public float getYPosF()
55
    {
56
        return this.yPosF;
57
    }
58
59
    public float getZPosF()
60
    {
61
        return this.zPosF;
62
    }
63
64
    public ISound.AttenuationType getAttenuationType()
65
    {
66
        return this.attenuationType;
67
    }
68
}
69

Deobfuscated MCP 1.8.9 source of PositionedSound from Marcelektro/MavenMCP-1.8.9 (net/minecraft/client/audio/PositionedSound.java), stored verbatim.