SoundType
Link to soundtype
导入类
Link to 导入类
It might be required for you to import the package if you encounter any issues (like casting an Array), so better be safe than sorry and add the import at the very top of the file.
ZenScript Copyimport crafttweaker.api.sound.SoundType;
使用方式
Link to 使用方式
Name: getBreakSound
Return Type: SoundEvent
ZenScript Copy// SoundType.getBreakSound() as SoundEvent
mySoundType.getBreakSound();
Name: getFallSound
Return Type: SoundEvent
ZenScript Copy// SoundType.getFallSound() as SoundEvent
mySoundType.getFallSound();
Name: getHitSound
Return Type: SoundEvent
ZenScript Copy// SoundType.getHitSound() as SoundEvent
mySoundType.getHitSound();
Name: getPitch
Return Type: float
ZenScript Copy// SoundType.getPitch() as float
mySoundType.getPitch();
Name: getPlaceSound
Return Type: SoundEvent
ZenScript Copy// SoundType.getPlaceSound() as SoundEvent
mySoundType.getPlaceSound();
Name: getStepSound
Return Type: SoundEvent
ZenScript Copy// SoundType.getStepSound() as SoundEvent
mySoundType.getStepSound();
Name: getVolume
Return Type: float
ZenScript Copy// SoundType.getVolume() as float
mySoundType.getVolume();
名称 | 类型 | 可获得 | 可设置 |
---|---|---|---|
名称 breakSound | 类型 SoundEvent | 可获得 true | 可设置 false |
名称 fallSound | 类型 SoundEvent | 可获得 true | 可设置 false |
名称 hitSound | 类型 SoundEvent | 可获得 true | 可设置 false |
名称 pitch | 类型 float | 可获得 true | 可设置 false |
名称 placeSound | 类型 SoundEvent | 可获得 true | 可设置 false |
名称 stepSound | 类型 SoundEvent | 可获得 true | 可设置 false |
名称 volume | 类型 float | 可获得 true | 可设置 false |