ID:171018
Nov 22 2004, 6:47 am
|
|
Before i started coding my game, i searched for alot of different things, to examine the code. I remember seeing an auto tiler somewhere, but now that i need it, i cant remember what its called... Any help? X.x
|
Nov 22 2004, 6:47 am
|
|
I think Zaltron made one.
|
It depends on what you mean by auto-tiler. All of the following could fit that label:
Gughunter has a library that automatically tiles large png or bmp graphics seamlessly. Lummox JR, pmikell, Foomer and I all have our own systems of automatically merging the graphics of adjacent tiles. I think Ebonshadow has or had one too. I've seen a few programs advertised that take an icon and break all the icon states into individual turf types, writing a text file that you can include in your project. If you want a useful answer, it's best to define your needs as clearly as possible. |
In response to Shadowdarke
|
|
Shadowdarke wrote:
I've seen a few programs advertised that take an icon and break all the icon states into individual turf types, writing a text file that you can include in your project. Yep, thats what i meant. Shadowdarke wrote: If you want a useful answer, it's best to define your needs as clearly as possible. Sorry about that.. |
In response to Takaru
|
|
I thought Nadrew had one, but I don't see it. Zaltron's appears to be unavailable.
I have an appointment soon, so I don't have time right now to whip one up, but it is a simple process and I can get you started on the path. Load the icon with input() as null|icon. Create an /icon datum from it. Use IconStates() to get a list of all icon_states in the icon. Input a custom parent name for all turfs with this icon. Open a textfile and write any header info you want into it, like "turf" to declare everything after as turfs, then "\t[pregen_name]" to declare the subtype and "\t\ticon = '[iconname]'" to declare that all children of this use the same icon. Loop through the icon states. Write "\t\t[statename]" to declare the turf path, then "\t\t\ticon_state = \"[statename]\"" to set the icon state. Close the file and you're done! The result should look like: turf |
In response to Shadowdarke
|
|
You're in luck. My 1 o'clock cancelled and here is the result:
mob Not all icon state names are valid typepaths, so you may have to modify the file before it compiles correctly. Also, it does no checking on the name you enter. Make sure it's a valid type path AND a valid filename with the ".dm" extension added. |
Takaru wrote:
Before i started coding my game, i searched for alot of different things, to examine the code. I remember seeing an auto tiler somewhere, but now that i need it, i cant remember what its called... Any help? X.x You might want to check out Lummox JR's tutorial on byondscape. http://www.byondscape.com/ascape.dmb/LummoxJR.2002-1231/ It comes with his icon_cutter tool which is extremely useful for making autojoining icons. |
In response to XxDohxX
|
|
I made a thing that will program all the coding for an icon for you but it was taken off the hub when BYOND's staff cleared off the hub, i'll be sure to stick it back on later today.
|
In response to Zaltron
|
|
Zaltron wrote:
I made a thing that will program all the coding for an icon for you but it was taken off the hub when BYOND's staff cleared off the hub, i'll be sure to stick it back on later today. It looks like it's not on my brother's comp. I won't be getting my dad's comp until hopefully this weekend so my hard drive is just laying round in my room until I get my dad's computer so it won't be on the hub till then. |