I'm sorry to say this, but no. Currently adding new blocks are not supported. Currently only adding items are supported. ModPE is still young, and I'm sure it will have a lot of potential later in the year. I'm pretty sure it will be supported soon, so don't worry.
function newLevel(){if(readData("getFortuneLevel")==null/*or whatever returned when undefined*/){saveData("getFortuneLevel",0);//hope accept int}if(readData("xp")==null)saveData("xp",0);if(readData("nethered")==null)saveData("xp",0);//DONTDO function toggle(a){if(readData(a)=="true"){saveData(a, "false");}else{saveData(a, "true");}}//hope this thing is useless}function useItem(x,y,z,i, { if(b==247){ aE(6); saveData("nethered",1);} else if(b==54&&i==3){ if(readData("xp"<100))return; preventDefault(); saveData("getFortuneLevel",readData("getFortuneLevel")+1); saveData("xp",readData("xp")-100); }}function destroyBlock(x,y,z,s){ if(getCarriedItem!=285)return; addItemInventory(getTile(x,y,z),readData("getFortuneLevel")*Math.random()-1,getData(x,y,z));}function aE( { saveData("xp",readData("xp")+ ;//Connor4898 said accept any data but parameters can only be string?}function deathHook(a,v){ var vT=Entity.getEntityTypeId(v); if(Math.abs(Entity.getX(v)-Player.getX())+Math.abs(Entity.getZ(v)-Player.getZ())<322)return;//Even in MCPC you won't be able to get XP from that far. Can be changed when there is getTime(). switch(vT){ case 32:aE(3);break; case 33:aE(5);break; case 34:ae(4);break; case 35:aE(4);break; case 36:aE(6);break; case 10:aE(1);break; default:aE(2); }}function modTick(){ playerTime++;//what did I want to use this for?}function leaveGame(){5 lines script name:add mobs
//Creepig01's Second Entry For The "ModPE In 50 Lines Challenge"
function useItem(x,y,z,itemId,blockId,side)
{
var gpx = getPlayerX(); var gpy = getPlayerY(); var gpz = getPlayerZ();
if(itemId==267)
{
setTile(gpx+10,gpy+10,gpz+10,12);//First line in "Hi"
setTile(gpx+10,gpy+11,gpz+10,12);
setTile(gpx+10,gpy+12,gpz+10,12);
setTile(gpx+10,gpy+13,gpz+10,12);
setTile(gpx+10,gpy+14,gpz+10,12);//End of the first line in "Hi"
setTile(gpx+9,gpy+1,gpz+10,24);//Start of the middle line in the "H" in "Hi"
setTile(gpx+8,gpy+1,gpz+10,24);//End of the middle line in the "H" in "Hi"
setTile(gpx+7,gpy+10,gpz+10,12);//Start or the second line in "Hi"
setTile(gpx+7,gpy+11,gpz+10,12);
setTile(gpx+7,gpy+12,gpz+10,12);
setTile(gpx+7,gpy+13,gpz+10,12);
setTile(gpx+7,gpy+14,gpz+10,12);//End of the second line in "Hi"
setTile(gpx+4,gpy+10,gpz+10,12);//Start of the "I" in "Hi"
setTile(gpx+4,gpy+11,gpz+10,12);
setTile(gpx+4,gpy+12,gpz+10,12);
setTile(gpx+4,gpy+13,gpz+10,12);
setTile(gpx+4,gpy+14,gpz+10,12);//End of the "I" in "Hi"
}
}
I don't think its possible. 1. devices would be laggy with all the mobs. 2. You can't add new mobs, you can only change the texture not the size or shape of them
0
0
If it helps any here is a example of loops in real JavaScript
0
0
I already got a cookie!
0
0
0
0
0
0
0
0
0
0
0