提供: Minecraft Modding Wiki
(ページの作成:「public class ExampleMod { public static final Identifier SAMPLE_SOUND_ID = new Identifier(MOD_ID":sample_sound") public static SoundEvent SAMPLE_SOUND_EVENT = new…」) |
|||
1行目: | 1行目: | ||
− | public class | + | |
+ | public class SampleMod { | ||
public static final Identifier SAMPLE_SOUND_ID = new Identifier(MOD_ID":sample_sound") | public static final Identifier SAMPLE_SOUND_ID = new Identifier(MOD_ID":sample_sound") | ||
public static SoundEvent SAMPLE_SOUND_EVENT = new SoundEvent(SAMPLE_SOUND_ID); | public static SoundEvent SAMPLE_SOUND_EVENT = new SoundEvent(SAMPLE_SOUND_ID); | ||
5行目: | 6行目: | ||
@Override | @Override | ||
public void onInitialize(){ | public void onInitialize(){ | ||
− | + | Registry.register(Registry.SOUND_EVENT, SampleMod.SAMPLE_SOUND_ID, SAMPLE_SOUND_EVENT); | |
− | Registry.register(Registry.SOUND_EVENT, SampleMod. | ||
} | } | ||
} | } |
2019年9月14日 (土) 22:31時点における版
public class SampleMod {
public static final Identifier SAMPLE_SOUND_ID = new Identifier(MOD_ID":sample_sound") public static SoundEvent SAMPLE_SOUND_EVENT = new SoundEvent(SAMPLE_SOUND_ID);
@Override public void onInitialize(){ Registry.register(Registry.SOUND_EVENT, SampleMod.SAMPLE_SOUND_ID, SAMPLE_SOUND_EVENT); }
}