-
Notifications
You must be signed in to change notification settings - Fork 0
Adding a Disc
Auxves edited this page Nov 18, 2022
·
7 revisions
Let's assume that your addon is called disco-example
and the id of your new disc is new_disc
. Replace these with the actual ones in the following steps.
If this file doesn't already exist, create it at the root of the project with these contents
Add the id to the discs
array as shown below:
{
"schemaVersion": 1,
"id": "disco-example",
"version": "1.0.0",
"name": "Disco Example",
"description": "Example Disco addon",
"custom": {
"disco": {
"discs": [
+ "new_disc"
],
"tables": []
}
}
}
- Convert your audio to a
.ogg
file with one channel (mono) - Place the file at
assets/disco-example/sounds/new_disc.ogg
Add the following lines to assets/disco-example/sounds.json
:
{
+ "new_disc": {
+ "category": "record",
+ "sounds": [{ "name": "disco-example:new_disc", "stream": true }]
+ }
}
Place your 16x16 sprite at assets/disco-example/textures/item/new_disc.png
Create assets/disco-example/models/item/new_disc.json
with the following contents:
{
"parent": "item/generated",
"textures": {
"layer0": "disco-example:item/new_disc"
}
}
Add the following line to assets/disco-example/lang/en_us.json
:
{
+ "item.disco-example.new_disc.desc": "Artist - New Disc"
}
Make sure to add this to any other languages your addon supports