Surprisingly, its easier to make a button in an add-on than in a modscript.
Yes, in an addon it uses less lines, but you sometimes Brain**** yourself. I have never added a button natively in MCPE. I consider it very hard to do.
Rollback Post to RevisionRollBack
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
Yeah, buttons arent as easy as I first imagined. But once I successfully added one, I was stuck at making it do something when you click it.
Well, I've never succesfully added a button to MCPE: I did things so wrong I caused the MCPE Play button to redirect to the Settings tab. All thanks to Button::clicked().
Rollback Post to RevisionRollBack
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
Overview
My greatest disappointment of MCPE was the inability of mobs to fight each other. This mod changes that and adds 3 new items: The Orb of Anger, Orb of Jumping, and the Orb of Health. Hit 2 mobs with the orb of anger to make them fight. Only certain mobs can fight however (Creepers, Skeletons, and Zombie Pigmen don't fight unless hit; passive mobs can't fight). Best of all, it works in multiplayer!
To install, please refer to 500_Internal_Server_Error's thread: http://www.minecraftforum.net/forums/minecraft-pocket-edition/mcpe-mods-tools/1987233-please-help-me-test-my-android-blocklauncher-addon
Items
Orb of Anger- Tap two mobs to start a battle!
Orb of Jumping- Tap a mob to make it jump.
Orb of Health- Tap a mob to heal it by one heart.
Sword of the Fallen- Causes massive fall damage to mobs.
I didnt put any commands, so I didn't hook the command function.
And also you can create your own hooks out of the thousands of functions on MCPE. You aren't limited to the ModPE hooks. For example, if you hook Entity::outOfWorld, you can detect when an entity is in the void.
", sans-serif">Want to get paid for uploading mods?
", sans-serif">Click here
For free Bitcoins, click here!
I was actually making a Colosseum Arena just for this mod. Do you want to add it?
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
Yes, in an addon it uses less lines, but you sometimes Brain**** yourself. I have never added a button natively in MCPE. I consider it very hard to do.
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
", sans-serif">Want to get paid for uploading mods?
", sans-serif">Click here
For free Bitcoins, click here!
Well, I've never succesfully added a button to MCPE: I did things so wrong I caused the MCPE Play button to redirect to the Settings tab. All thanks to Button::clicked().
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
", sans-serif">Want to get paid for uploading mods?
", sans-serif">Click here
For free Bitcoins, click here!
Btw, try reading this example addon for adding Chat Color, Strings, Screens (Tabs), Buttons (yay!), and other cool stuff to MCPE. It was made by KsyMC: https://github.com/KsyMC/MCPE-addons/tree/master/example/ExampleScreen/jni
I tried to learn how to do it, but since the explanation was in Korean, I suddenly gave up
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
Thanks lol
Java, JavaScript, Lua, HTML, CSS, C++ | Nooby MCPE Modder | Author of many addons | Learning PHP | Half-time penguin | Christian
Subscribe to my YT channel to be informed about upcoming updates/new mods/Texturepacks and much more
https://www.youtube.com/channel/UCy-gPnisSCWH9bvCKJsVeoQ
Can i use your Main code im just curious on creating an Addon
Just Having A Break in creating mods
so the main code has the attack hook how about a command hook?
Just Having A Break in creating mods
And also you can create your own hooks out of the thousands of functions on MCPE. You aren't limited to the ModPE hooks. For example, if you hook Entity::outOfWorld, you can detect when an entity is in the void.