Page 1 of 2

editorIcon = ?

Posted: Mon Dec 17, 2012 7:15 pm
by scorp29
A simple question about the attribute "editorIcon".

Is there a place where all the icons related to each index is listed ?

Re: editorIcon = ?

Posted: Mon Dec 17, 2012 9:16 pm
by Soaponarope
It shouldn't actually effect anything, just makes it so you can better identify your custom objects. To see a good icon to use, just to open the script in the asset pack(such as objects.lua) and run a search for the type of object closest to the one your creating. Example, alcove is 8.

Re: editorIcon = ?

Posted: Mon Dec 17, 2012 9:28 pm
by Komag
a nice little graphical reference list would be handy

Re: editorIcon = ?

Posted: Mon Dec 17, 2012 10:45 pm
by JohnWordsworth
Here you go. About 10 lines of Lua and a bit of work with Paint.NET. These are all generated procedurally.

Image

To calculate the editorIcon value for a given icon, just add up the number to the left and top of it. ie. the Teleporter icons start at 30+6=36. I don't know about the repetition and how the editor knows to rotate the icons. I presume you just use the first value and then it adds 0,1,2 or 3 to it depending on the facing?

Re: editorIcon = ?

Posted: Mon Dec 17, 2012 11:35 pm
by Skuggasveinn
Awesome john.

I never noticed before but door_wooden and door_iron don't have the same editor icon number, I always thought it was the same, but now I see that door_iron has a hint of more orange (or I'm having too much jólaglögg)

Also pressure plate and hidden pressure plate have different numbers but look the same (maybe hidden was supposed to look different but never got done ??)

anyway, great info for people making custom assets and need to give them some editor icons that make sense.

Skuggasveinn.

Re: editorIcon = ?

Posted: Mon Dec 17, 2012 11:56 pm
by Komag
I thought hidden plates were dotted and regular plates solid?

Re: editorIcon = ?

Posted: Tue Dec 18, 2012 12:32 am
by Xanathar
I regular plates are 0 .. 3, while hidden plates are 140 .. 143.

Disclaimer: I'm right after a very strong belgian beer :D , don't take anything I say as truth!

Re: editorIcon = ?

Posted: Tue Dec 18, 2012 1:18 am
by JohnWordsworth
Oh, thinking about it my image should have started at 0. I'm so used to Lua arrays starting at 1 I forgot the graphic atlas indices start at zero. Will update tomorrow - but the only difference is that the standard pressure plate starts at zero!

Re: editorIcon = ?

Posted: Tue Dec 18, 2012 2:04 am
by scorp29
Héhé, thank a lot JohnWordsworth, this listing will definitly become handy while building custom dungeon!

Re: editorIcon = ?

Posted: Tue Dec 18, 2012 3:20 am
by LordYig
Definitely handy to have !
Thanks a lot John.