How to make power with sound?
FuZOID opened this issue ยท 1 comments
So i want to make invisibility power but with sound. So when you press button you shoul turn invisible and play sound to you and near players... I was trying to make it by myself then after 30 attempts i stoped and here my last attempt:
{
"type": "origins:invisibility",
"render_armor": true,
"condition": {
"type": "origins:power_active",
"power": "origins:phantomize"
},
"type": "origins:active_self",
"entity_action": {
{
"type": "origins:play_sound",
"sound": "minecraft:entity.mooshroom.convert"
}
},
"condition": {
"type": "origins:power_active",
"power": "origins:phantomize"
}
}
Can you help me plz? [im really bad at programming]
{
"type": "origins:multiple",
"turn_invisible": {
"type": "origins:invisibility",
"render_armor": true,
"condition": {
"type": "origins:power_active",
"power": "origins:phantomize"
}
},
"make_sound": {
"type": "origins:active_self",
"entity_action": {
"type": "origins:play_sound",
"sound": "minecraft:entity.mooshroom.convert"
},
"cooldown": 20,
"hud_render": {
"should_render": false
},
"key": {
"key": "key.origins.primary_active",
"continuous": false
}
}
}
cooldown can be changed(is in ticks, 1s=20 ticks) as it would currently cap at being played once a second
key needs to be changed from primary_active to secondary_active if you decide to change the key to become invisible from primary to secondary
turn_invisible and make_sound are literally just names so you know what bit of code does what, isnt visible ingame
suggest putting this kind of question in the comments rather than here, as the issues page is more for improvement suggestions and bug reports if anything