Author Topic: A Bunch of Keys?  (Read 559 times)

Legacy_Tyndrel

  • Sr. Member
  • ****
  • Posts: 313
  • Karma: +0/-0
A Bunch of Keys?
« on: January 14, 2011, 04:26:24 pm »


               Inspired by Birdman's recent book thread I'm making my first tottering steps upon the custom content ladder by trying to add a little more variety to the keys selection. I am, however, lacking understanding of how some of the systems work at present.

Instead of three part keys I would like to get rid of the boring centre section and use that to create more “bottoms” (24 plus a blank one in each of the 2 categories?).  There are currently the three colours, is that a limit too?

Rather than interfere with the existing ones I was thinking of doing a “Keys_2” thing so does that mean adding a new line to the baseitems.2da? Is this a straight copy of the existing key line but with a different number?

Compatibility: The first line in the CEP baseitems 2da that is labelled “USER” is line 213, will that work for Project Q too? Do I pick that next available line or is it best to leave a gap?


Is there an “Icons for dummies” tutorial somewhere?  The Photoshop bit is straightforward enough, it will be these pesky technical thingies that will get me!

Probably the biggest question of them all, what have I forgotten, neglected, or been too blissfully ignorant to ask?

Thanks,

Tyndrel.
               
               

               


                     Modifié par Tyndrel, 14 janvier 2011 - 04:33 .
                     
                  


            

Legacy_Eradrain

  • Sr. Member
  • ****
  • Posts: 365
  • Karma: +0/-0
A Bunch of Keys?
« Reply #1 on: January 14, 2011, 05:14:40 pm »


               You don't need to get rid of the middle section in order to open up more options for bottoms, luckily!.  The only limit on how many different bottom-parts you can have is how many you're capable of thinking up and making in photoshop (Or your 2D art program of choice).  There isn't a finite amount of available "slots" for the key bottom (Well, there is a ceiling for how many entries you can put in a 2da list, but in this case it's so high as to be ignorable, so let's not even worry about it here). Disabling or repurposing the middle section will also cause serious compatibility issues with the CEP and Q, unless you're also going to remake all of their keys to account for that (Assuming that Q and the CEP have custom key icons, I really don't know).

Project Q and CEP are completely non-compatible, so you'll have to pad your 2das to account for both of them.  Project Q has listed their reserved 2da ranges on their forum somewhere.

This is a short post because I'm in a bit of a hurry, and it probably doesn't answer half your questions satisfactorily, but I'm sure someone else will be able to help you before I get back this evening.  Good luck, welcome to the modding community, and thank you for making something!
               
               

               


                     Modifié par Eradrain, 14 janvier 2011 - 08:21 .
                     
                  


            

Legacy_TheSpiritedLass

  • Hero Member
  • *****
  • Posts: 1118
  • Karma: +0/-0
A Bunch of Keys?
« Reply #2 on: January 14, 2011, 09:23:56 pm »


               Hey Ty *hugs and noogies*

When you are ready, I can make the baseitems 2da line for you.  I also use photoshop to make icons if you have questions there, zap me out an IM.  You should still have it from the days of the Lexicon?  '<img'>

Some vague technical stuff:

- make sure there is a 1 pixel black out line around the outside of the icon.

- make sure to set the background of the icon to the Alpha channel so it is transparent in game.  

- the size of the icon is very picky.  

- the file type is picky as well.

--- Mistress
               
               

               
            

Legacy_The Amethyst Dragon

  • Hero Member
  • *****
  • Posts: 2981
  • Karma: +0/-0
A Bunch of Keys?
« Reply #3 on: January 15, 2011, 07:56:59 am »


               Keys are made up of 3 (32-bit) .tga images that are layered over each other.  Each is 32 pixels wide by 64 pixels high with it's own alpha transparency layer (black=transparent, white=solidly visible).  Any part of the image with an alpha layer transparency will allow the lower layers to show through...the "bottom" part layer is covered by the "middle" part layer, which is in turn covered by the "top" part layer.

You are not limited to 3 colors for each part.  You can have up to 10 "colors" for each "part".  You'll just need to expand on "part number 1", adding colors 0 and 4 to 9.

Keys are a very basic item (with no animations or anything associated with them), so you should have no problem just copying and renumbering the existing key item line in baseitems.2da.  Just remember to change the name for the model names (or is it icon names...don't have the file open right now so can't be sure) so that it's slightly different from the existing keys (or else you'll still just be using the existing key appearances).

Inventory icons for items that don't have 3D models associated with them are much easier to make than ones that require model-making skills.

Good luck, and have fun!
               
               

               


                     Modifié par The Amethyst Dragon, 15 janvier 2011 - 07:58 .
                     
                  


            

Legacy_Tyndrel

  • Sr. Member
  • ****
  • Posts: 313
  • Karma: +0/-0
A Bunch of Keys?
« Reply #4 on: January 17, 2011, 05:48:11 pm »


               Thank you folks, and my appologies for the late reply, darned RL got me again.

This Alpha layer thingie still has me a little confuddled, The background for the parts is set to transparent. So the Alpha layer for the top part will have the shape of the middle and bottom parts but in black, while the alpha layer for the mid section will just have the bottom part reproduced in black?  Are these on a white backgound?  Sorry about the noobish questions.

I'll forget about using the middle part to get extra "bottoms", I'm just starting gently with some numbered keys for inn rooms and such. The small size is rather a limiting factor for anything too ornate but I've always thought there is way too little variety of keys.

Hi Mistress, noogies to you too (what ever they are) I shall have to pop into R.o.M. for a quick bit of power levelling '<img'> and to say hello.
               
               

               
            

Legacy_The Amethyst Dragon

  • Hero Member
  • *****
  • Posts: 2981
  • Karma: +0/-0
A Bunch of Keys?
« Reply #5 on: January 17, 2011, 06:39:40 pm »


               .tga files don't have actual transparency.  They are a solid image (and that's all for 24-bit files), and can have an extra layer added (the alpha layer, in a 32-bit file).  This alpha layer is what controls the transparency in-game.

The alpha layer lines up with the visible layer.  Wherever there is white in the alpha layer, that same part of the main image will remain solid in-game.  Wherever there is black in the alpha layer, that same part of the main image will be transparent in-game.  And yes, grey in the alpha layer will give partial transparency.

As far as layering the icon image files in-game, I like to think of them as layers of glass with the non-transparent parts "painted on".  Anything on the bottom layer that isn't covered by a visible part of the middle or top layers will be visible in-game.  Anything on the middle layer that isn't covered by a visible part of the top layer will be visible in-game.
               
               

               


                     Modifié par The Amethyst Dragon, 17 janvier 2011 - 06:40 .
                     
                  


            

Legacy_Tyndrel

  • Sr. Member
  • ****
  • Posts: 313
  • Karma: +0/-0
A Bunch of Keys?
« Reply #6 on: January 17, 2011, 07:14:58 pm »


               Thanks AD, I think I understand now...  no transparency huh, who would have thought it '<img'>