How to add the Potion effects with ModPE with infinite duration while using an item, and if the Item is not used, the effect will automatically wear off, how to add/do it on js ModPE?
if (Player.getCarriedItem(itemId)){
if (itemId = 501){
Entity.addEffect(getPlayerEnt(), MobEffect.movementSpeed, time, 0, false, true);
} //the time is where the time is supposed to be infinite
Ok, oh and btw I am currently working on a new cool mod named The 7 Deadly Sins. From the anime 7 Deadly Sins, I am adding 7 new weapons, and if I had a chance to have 7 custom mobs, I could add the characters from 7 Deadly Sins. So 1 more question, how to add a custom mob with name, with an item holding and custom attack damage. And I would like help from you, if I had any problems, can I contact you? If I can, where can I Contact you?
function modTick(){
if(getCarriedItem()==501){
Entity.addEffect(getPlayerEnt(), MobEffect.movementSpeed, 40/*2 seconds*/, 2/*sets speed II*/, false, true/*if you dont want bubbles in your screen bc I find that annoying sometimes, say false in this one*/);
}
}
Rollback Post to RevisionRollBack
Heard of an app called AppNana? It's an app that rewards you for installing games, testing apps, watching adds, with Google Play, Amazon, and iTunes gift cards, and more! And the app, is completely free!
An easy way of earning Nanas is to add other people's Invite Codes. Whenever you invite someone or get invited, you get 2.5k nanas!
My code is t3305123, pm me your codes so we can just keep gettin nanas for doing pretty much nothing at all!
Exploit. Everything.
To post a comment, please login or register a new account.
How to add the Potion effects with ModPE with infinite duration while using an item, and if the Item is not used, the effect will automatically wear off, how to add/do it on js ModPE?
if (Player.getCarriedItem(itemId)){ if (itemId = 501){ Entity.addEffect(getPlayerEnt(), MobEffect.movementSpeed, time, 0, false, true); } //the time is where the time is supposed to be infiniteTry adding -1 into it
The heck is this for
Ok, oh and btw I am currently working on a new cool mod named The 7 Deadly Sins. From the anime 7 Deadly Sins, I am adding 7 new weapons, and if I had a chance to have 7 custom mobs, I could add the characters from 7 Deadly Sins. So 1 more question, how to add a custom mob with name, with an item holding and custom attack damage. And I would like help from you, if I had any problems, can I contact you? If I can, where can I Contact you?
function entityAddedHook(ent){
if(Entity.getMobSkin(ent) == "mob/YOURMOBSKIN.png") {
Entity.setNameTag(ent, " MOB NAME");
Entity.setCarriedItem(ent, ITEM, COUNT, DATA);
}
}
function attackHook(a, v){
if(Entity.getMobSkin(a) == "mob/YOURMOBSKIN.png") {
Entity.setHealth(v, Entity.getHealth(v) - DAMAGE);
}
}
The heck is this for
Try using
function modTick(){ if(getCarriedItem()==501){ Entity.addEffect(getPlayerEnt(), MobEffect.movementSpeed, 40/*2 seconds*/, 2/*sets speed II*/, false, true/*if you dont want bubbles in your screen bc I find that annoying sometimes, say false in this one*/); } }