Treebl, will you be adding a function where you can add your own items?
I was thinking of functions like these:
function addNewItem(image, x, y, z,name,id)//Adds a new item using coordinates from the items.png or any custom image
function deleteItem(id)//Makes an item unused as long as the script is used
function setItemDurability(id, durabiltiy)//Sets the durability of an item; Make durability 0 to make it unlimited
function replaceItem(id, image, x,y,z)//Replaces item texture with the coordinates used in the items.png file or any custom image
this happened before i loaded the script. (i am on ios.)
i have a new problem though, as stated in my edits. XD
Cool to see 1 person using my mod XD. Anyway, there is nothing in my code that make's prints in the chat "1.0000", and what "Welcome message"? Btw, the mod isn't made for 0.7.1 (I guess it should work, but not tested).
Could you add an additional parameter to setTile that sets the data value (you know, that thing that determines wool color and tree type) of the block and a getTileData(x,y,z) function that returns it?
I really need it in my newest project
Would this let you add new items into the game? I'm not a coder so I would like to know.
No, but I could for example make a code that works only with a SPECIAL stone block that behaves exactly like a normal stone but explodes after touch. Or I could hold some kind of signal in blocks - possibilities are infinite, as in everything in programming ^^
EDIT: Let's say it could make you add new blocks if there was also a code that would make the game give other texture to block with other data value (as in wood - normal, birch and dark, even through they're the same block they have other data values)
So you use the code that lets there be different varients of the same block and use that to make a new "stone" block. And write a script that makes it explode upon touch? I'm guessing this has to do with the fact that making different kinds of the same block with mostly the same code is easier than making a different block altogether and saves space in the game. The devs space saving laziness is a good thing!
function setSpeed(ent, speed) //sets an entities speed
function setGamemode(gamemode)//sets the players Gamemode
function getGamemode()//can be used as a trigger
And maybe add a function where it overrides a buttons action(jump, forward, backward, settings, chat,...etc)
I was thinking of functions like these:
And an example:
function useItem(x,y,z,itemId,blockId,side){ if(item==280){ addNewItem("gui/items.png", x,y,z, NewItem, 500); setItemDurability(500, 0); } }What exactly did you fix? It'd be good to know so I won't make the mistake again.
Back to modding! Follow me on Twitter @byteandahalf
Also meaning for mobile iOS and android (So not meaning this in a mean way just wanting u to see it)
i am getting this spammed in my chat CONSTANTLY. anyone have any idea why, or how to stop it?
edit: is it possible to make this work on 0.7.1? it crashes instantly.
crash reporter said treeblhax.dylib was the cause of the crash.
i have the crash reports, and the syslog if you want to look into it.
edit 2: reinstalling 0.7.2 make the client message go away.
edit 3: nevermind. now it is just repeating the welcome message every 2 seconds.
-
View User Profile
-
View Posts
-
Send Message
Curse PremiumWhich scripts do you have? There's probably a debug statement that does this in one of them.
lambo's mod pack. (http://www.mediafire.com/download/1civzau4l0v6hgh/ModPack.js)
this happened before i loaded the script. (i am on ios.)
i have a new problem though, as stated in my edits. XD
(and u removed guide about funcs. right?)
Sorry for my bad English Skills
Would this let you add new items into the game? I'm not a coder so I would like to know.
So you use the code that lets there be different varients of the same block and use that to make a new "stone" block. And write a script that makes it explode upon touch? I'm guessing this has to do with the fact that making different kinds of the same block with mostly the same code is easier than making a different block altogether and saves space in the game. The devs space saving laziness is a good thing!
Back to modding! Follow me on Twitter @byteandahalf
And maybe add a function where it overrides a buttons action(jump, forward, backward, settings, chat,...etc)