Jump to content

Help
Latest News Article

Forester for Beta & MCEdit, adds large trees


112 replies to this topic

#1

  • Minecraft: dudecon

Posted 12 March 2011 - 12:15 AM

Add huge trees to your maps, now works with Beta minecraft, single and multiplayer.
Download: Forester script (latest version, 7)
Download: Interface module (latest version, 5)
Perfect for building tree houses in the trunks, treeforts, etc.
Posted Image

Thanks to salisburymistake for the idea. Thanks to God for designing trees in the first place. Please let me know if there are other types of trees you'd like or various changes or additions.
Instructions:
1. You must have Python (3.x) installed, go get it if you don't http://www.python.org/download/.
2. Save (or copy) the script and interface module to the folder where your maps are (usually .../.minecraft/saves).
3. Open the script with a text editor.
4. Change the settings at the top of the file to your liking (the file includes extensive instructions). Save it.
5. Make a backup of your world (just in case!)
6. Double click the script (for debugging open it in IDLE). Wait for it to finish (can take a while if adding a lot of trees).
Optional: update the lighting in your favorite level editor (the script re-lighting is not perfect).
7. If you had loaded the file since you started Minecraft, restart Minecraft. This prevents caching errors which could corrupt the save file!
8. Load up the map in Minecraft and and enjoy!


NOTE: If you want to use this script inside MCEdit, you now can! Download the
MCEdit filter along with the script and the interface module (top) and place them all in the "MCEdit\MCEditData\filters" folder. You can then use Forester as a filter with an interactive GUI! No more editing the script to change settings!

Old thread here http://www.minecraft...=125465#p125465

Register or log in to remove.

#2

Posted 18 March 2011 - 07:35 PM

Great stuff man! I got it to work once, but then I tried it again and I keep getting this error. Mind interpreting for me?

Traceback (most recent call last):
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 990, in 
    main()
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 974, in main
    processtrees(the_map,treelist)
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 959, in processtrees
    newtree.prepare()
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 839, in prepare
    ProceduralTree.prepare(self)
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 771, in prepare
    shapefac = self.shapefunc(y-ystart)
  File "C:\Users\Navi\AppData\Roaming\.minecraft\saves\Forester.py", line 846, in shapefunc
    if HEIGHT < self.height:
NameError: global name 'HEIGHT' is not defined

EDIT: Never mind, I guess I just deleted HEIGHT = X.

Anyways, I love this script! Are you planning on updating your other ones?

#3

  • Minecraft: dudecon

Posted 18 March 2011 - 08:50 PM

Okay, that error appeared because you chose to use rainforest type trees, and I overlooked some code when I was changing stuff. I've uploaded a new version that should fix it forever!

Yes, I am going to update the other ones eventually, but this one is by far the most popular, so I figured I'd do it first. Is there a particular one you are interested in?

I'd love to see some of the stuff people are doing with this script (if anything). What kinds of features would you guys like added?

#4

  • Location: In yo house, stealin yo bagels.

Posted 18 March 2011 - 09:21 PM

...How download...?

#5

Posted 19 March 2011 - 08:14 AM

could this be combined with Greater Greenery that Mike is working on? atm the download link doesnt contain anything smo's like me can use
My texture pack(Will never use the word CRAFT in its name; viewtopic.php?f=1021&t=343382
Posted Image
Posted ImagePosted Image

#6

  • Minecraft: dudecon

Posted 19 March 2011 - 05:26 PM

I'm actually in contact with Mike and we've agreed to try to add these trees to his mod at some point. However, at the present I'm very busy with more important projects.
The stand-alone script is, in some ways, more flexible than a mod. It directly edits the map file; You won't have to re-install it every time Notch updates the software; It is totally compatible and non-interfering with mods or map editors; and you can tell it exactly what you want and where you want it.
If it's any consolation, all you need to make this work is Python (which is platform independent) and a text editor. I understand it's a bit arcane to use... Sorry!

#7

  • Location: In the end of the world as we know it!
  • Minecraft: anders9009

Posted 19 March 2011 - 08:12 PM

Ummh...Can't you make it as a normal modloader mod? B)
Posted ImagePosted ImagePosted ImagePosted ImagePosted Image

#8

  • Location: Romania

Posted 19 March 2011 - 08:41 PM

anders9009 said:

Ummh...Can't you make it as a normal modloader mod? :(
Yesh please. Nothing for you, because it's not a modloader v5 mod.
Make it and you get :D x64
Nutzu's Skins!
Being NUTZ everyday. Brb going to get a small bag of NOM NOM...
Posted ImagePosted ImagePosted ImagePosted Image
I... Punch pigs for log and cut trees with my sword for pork!

#9

Posted 19 March 2011 - 09:22 PM

EDIT: Fixed :Diamond:
:iapprove:

#10

    onyxe

    Tree Puncher

  • Members
  • 16 posts

Posted 19 March 2011 - 09:35 PM

Argh i don't understand the Python part. Can't you make it a mod instead ? D:

#11

Posted 19 March 2011 - 11:16 PM

Cool?

The Hunter races ever forward, Full of vim naught can dispel.
Loyal, stubborn and straightforward, He'd follow a friend straight to Hell.


#12

  • Location: Somewhere.. Somewhere.
  • Minecraft: Mattarias

Posted 22 March 2011 - 07:22 AM

Oh, you silly people. The BEAUTY of this is that it ISN'T a mod!

Dudecon, I LOVE your scripts. I stumbled across your site once and was amazed at the things you've done with just code! Sadly, I didn't know how to work them back then, and by the time I did, they were incompatible, but all I can say now is

YES! YES! HELL YES! Giant trees are AWESOME and you should feel AWESOME! :P Now I can finally have the world tree, Yggdrasil, IN MINECRAFT! :DBlock: Absolutely amazing.

As for other scripts you should update.. I'm really torn between Groundwork, MountainFortress, and Starstone. Really, any of these would be absolutely terrific. OH, and a suggestion for Starstone, I think it would be a nifty idea to perhaps have some meteors contain rare ores and such, like Glowstone or even Diamonds. Though some could contain evil creatures from beyond! (I.e., monster spawners.) I dunno, just a thought.

As for features that I'd like added to Forester... Maybe an option for hollow trees/tree dungeons?
Ex incendia et flamma.

#13

  • Location: Denmark

Posted 22 March 2011 - 02:39 PM

Wait... am I supposed to just put those two big files into Notepad, save them under my saves, then do that funky thing with Python? I don't really understand... at all :S
Posted Image

#14

  • Minecraft: dudecon

Posted 22 March 2011 - 05:59 PM

Thanks Mattarias! I'm glad you like it! If you can, link some pics of stuff you make. I don't have time to make huge tree fortresses of my own, but I'd love to see some other people's.

Okay, you other guys who are confused? Take a deep breath. I know you can do this! Do you know how I know?
Because I too, once knew nothing about Python! That's right; I am completely self-taught! Which means I buckled down and read some stuff on the internet and took the time to understand it.
Okay. Another deep breath. Take a look around to make sure no one else is in the room. Narrow your eyes to savage slits. Now, glare at your computer screen and scream at the top of your lungs!
"YOU ARE MAN'S CREATION, AND I WILL MASTER YOU!"

Got your adrenaline pumping didn't it? Good. Good! You are ready to learn how to use this tool, to wrestle with the Python. Go back to the top of the page and read the instructions again, then go, do, and fear no more!

#15

Posted 22 March 2011 - 08:59 PM

dudecon said:

Narrow your eyes to savage slits. Now, glare at your computer screen and scream at the top of your lungs!
"YOU ARE MAN'S CREATION, AND I WILL MASTER YOU!"

Sigged.

dudecon said:

Narrow your eyes to savage slits. Now, glare at your computer screen and scream at the top of your lungs! "YOU ARE MAN'S CREATION, AND I WILL MASTER YOU!"

#16

    Derkit

    Stone Miner

  • Members
  • 77 posts

Posted 23 March 2011 - 01:26 AM

dudecon said:

Thanks Mattarias! I'm glad you like it! If you can, link some pics of stuff you make. I don't have time to make huge tree fortresses of my own, but I'd love to see some other people's.

Okay, you other guys who are confused? Take a deep breath. I know you can do this! Do you know how I know?
Because I too, once knew nothing about Python! That's right; I am completely self-taught! Which means I buckled down and read some stuff on the internet and took the time to understand it.
Okay. Another deep breath. Take a look around to make sure no one else is in the room. Narrow your eyes to savage slits. Now, glare at your computer screen and scream at the top of your lungs!
"YOU ARE MAN'S CREATION, AND I WILL MASTER YOU!"

Got your adrenaline pumping didn't it? Good. Good! You are ready to learn how to use this tool, to wrestle with the Python. Go back to the top of the page and read the instructions again, then go, do, and fear no more!

That was simply awesome, and this is a great script, works great, though i do completely want to see a mod loader v5 version of this come out sometime, i have no problems using it as is. ;) Would be cooler though if the world gen created them on its own. ;)

Either way thanks again for taking the time to enrich all of our minecraft experience! ;) for you sir!

#17

Posted 23 March 2011 - 07:24 AM

Love this idea really wish natural trees came in larger sizes and more styles like this.

so I have a question and a question/suggestion.

first the question will this work on a world that has never had any chunks loaded (I think that's what i mean)
like a world generated by a server that no one has ever logged into?

now the question/suggestion I'd like to run this on large areas that no one has ever visited
perhaps even a whole world if that's feasible but i don't really want big trees cropping up on open fields
or other places where there's dirt but no other trees so would it be possible to check if there are trees
nearby and only generate new trees if there's a serten number of natural trees nearby or even better
make this a bit more procedural and look for forest biomes and only add trees there
idk perhaps that is outside the scope of this script and i should be looking at world generators?

#18

  • Minecraft: dudecon

Posted 23 March 2011 - 01:26 PM

a2omega: excellent questions!
In short, no... and no.
The script modifies already-existing chunk files, but will not create new ones. If you want to plant trees, you must generate the land first. I'm sure there is a tool somewhere that will allow you to invoke the "create terrain" routine on a specific area.

Running it on a "whole world" would require the whole world to be on your hard-drive already. What you are looking for is a terrain generator mod; I'll get to this eventually (probably) but it's not as easy as it sounds. Generating complex structures larger than 16x16 gets sticky. Either way, it will almost definitely slow the game down.

Furthermore, I have already sold the Java class to Notch. It's currently being used (in some form) to generate the large trees. I want to get his permission to release that code to the public, since he paid for it and all. It's been hard to contact him recently (as you can imagine) so that may not happen for a while. Essentially, I don't want to give away confidential information. You can de-compile the source (and are welcome to do so as far as I can tell) but because of my previous involvement in Minecraft, I am more constrained. I wish I had thought to ask him about it at the time, but that's where we are.

However! I will continue to work on converting the old scripts to Beta, and improving these ones. Adding hollow trees (with mushrooms inside!) to Forester, impact debris and more core materials to StarStone, better castle code to MountainFortress, and perhaps even developing Groundwork into a full city generator are all possibilities. Please be patient though. I have a a wife, a toddler (and another one on in development), plus multiple other personal projects, some of which I am being paid for. I'll get back to scripting eventually, but it may be a few months, or years. Or it may be this week! Who can tell?

In the meantime, enjoy!

#19

  • Location: Big Island

Posted 24 March 2011 - 01:26 AM

Dudecon: I've modified your Forester script to work as a filter plugin for MCEdit. Do you mind if I include it with the program?
MCEdit: Minecraft World Editor
The sun rises in the +X and sets in the -X. Clouds travel -X.

#20

Posted 24 March 2011 - 01:40 AM

so I went and did some reading after I posted that last question and realised how dumb the first one was
props and :) :) :Diamond: to you for responding to such noob questions and so quickly too.

Ok so I now have a couple of (hopefully) less noobish requests I guess is what they are.

1. would it be possible to add an option to only spawn new trees near natural trees
some nice settings might be how close and how many natural trees are required for a new tree to spawn.

2. have an option to not grow on on player built structures or better yet grow around player structures
an example would be I build a bridge up in the air above some dirt
then i run the script and get a nice forest pathway through the tree tops
(if this doesn't make sense I'll get a picture)
I imagine this would actually be a pain to implement but I'll put it out there anyway.

again I'd like to say awsome scripts great for making interesting semi random world features I'll be using them
on most of my maps.
also if anyone's interested here's a tool i found for generating larges chunks of map, no flying about required.
http://www.minecraft...f=1022&t=203394