Kill Sprites

Seph_KimaraSeph_Kimara Join Date: 2003-08-10 Member: 19359Members
<div class="IPBDescription">which file(s) do I need to edit?</div> As the topic states, I want to make some kill sprites. However, I'm at a loss as to what I need to edit (I assume the 320/640hud files, but even then, I have no clue how the hud.txt file is set up ie. what means what). Any specific image dimensions that need to be adhered to? etc.

Thanks for any help in advance. Looked around for anything else about it and gotten nowhere.

Comments

  • StarStarGrizzlyStarStarGrizzly Join Date: 2004-02-06 Member: 26139Members
    I've made some kill sprites for myself before. Its very easy to do. I don't know about the hud.txt or the dimensions. Get the default Killsprites onto a .bmp format. Then just edit them how you like. Try to make them about the sizes of the default ones, cause I dont know the dimensions.Then just compiles it, put it in game. Just test it from there.
  • UrdUrd Join Date: 2003-05-25 Member: 16696Members, Constellation
    You only have to edit the 640 sprites, the 320s aren't used at all as far as I know.
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    <b>First, the essentials: <a href='http://sjc.edu.hk/~verthandi/sprite_tools.zip' target='_blank'>Standard Issue Sprite Editing Kit</a>
    Without it, you will get nowhere fast.</b>

    <!--c1--></div><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>CODE</b> </td></tr><tr><td id='CODE'><!--ec1-->d_knife                     640 640aw3-s        100     232     64     24
    d_handgrenade         640 640aw1           192     231     64     24
    <!--c2--></td></tr></table><div class='postcolor'><!--ec2-->
    In the above, you see two lines from the unmodified hud.txt file. Should be pretty easy to figure out the weapons they relate to... for this example, I'll be using the d_knife line.
    <span style='color:red'>640</span>: As Urd said, you'll only have to edit these lines, if you edit the hud.txt at all, <b>unless</b> you play on a resolution lower than 640x480, in which case, you'll be editing the 320s.
    <span style='color:yellow'>640aw3-s</span>: Name of sprite file; located in /nsp/sprites.
    <span style='color:green'>100 and 232</span>: Position of sprite in the file (refer to image)
    <span style='color:blue'>64 and 24</span>: Size of sprite in the file (refer to image)
    <img src='http://sjc.edu.hk/~verthandi/640aw3-s.gif' border='0' alt='user posted image' />

    That's the basics of editing the hud.txt file. It's nothing too complex, once you get accustomed to all the numbers. However, take note that the reference for "death by Mine" is 'd_item_mine', and <b>not</b> 'd_tripmine'. The latter is one of the many obsolete references and can be ignored.

    You don't always have to mess with the hud.txt file, but it's good to know how to. At any rate, that takes care of the boring part. <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html//emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif' /><!--endemo--><ul><li>Now, locate the death sprite you want to change, by finding the reference in the hud.txt file</li><li>Open the SPR file with Sprite Viewer, and then 'Save BMP' (preferably somewhere easy to access, like the Desktop)</li><li>Edit the BMP to your liking, using any image editor with palette support (MSPaint does not count)</li><li>After you're done editing the BMP, it's the same drill all sprite artists go through every time: <ul><li>256-color palette</li><li>the above, properly configured for the type of transparency required (this is the 'usual' problem)</li><li>both dimensions are a multiple of 8</li><li>neither dimension larger than 256 pixels</li></ul></li><li>Compile the sprite, using Sprite Wizard, and give it a test-run!</li></ul>
  • TheGuyTheGuy Join Date: 2003-08-09 Member: 19295Members, Constellation
    edited July 2006
    It's much easier if you just edit hud.txt instead of editing the death sprites

    d_machinegun 640 640aw3-s 192 96 64 24

    That's the death sprite for the machinegun. Notice it has a d_prefix. that means it's a death sprite

    640 means the res or higher ,, 640aw3-s is the actual sprite file name. 192 is the x origin position in the sprite(tells it where to start the sprite) , 96 is the Y . 64 is the width, and 24 is the height..

    So if you wanted to change it to your own machinegun sprite you'd put

    d_machinegun 640 machinegunspritenamehere 0 0 64 24

    if you made a sprite that is 64wx24h

    the size is completely up to you.

    Notice I put 0 0 for the origin, since it's a separate file it'll start in the topleft corner at 0,0 coords.

    Good luck and happy spriting

    (I'll include a pic in a min)
  • Seph_KimaraSeph_Kimara Join Date: 2003-08-10 Member: 19359Members
    Thanks for the info, that was exactly what I was after.
  • CaptainPanakaCaptainPanaka Join Date: 2002-11-02 Member: 4718Members
    there is an even easier way to do this:

    lets say you want to change the killsprite of the knife. Open up the hud.txt and look for

    <!--QuoteBegin--></div><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->d_knife 640 640aw3-s 100 232 64 24<!--QuoteEnd--></td></tr></table><div class='postcolor'><!--QuoteEEnd-->
    Now, take the new sprite for it (here lets say the sprite is 64x24 px) and change the line to:

    <!--QuoteBegin--></div><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->d_knife 640 knifekill 0 0 64 24<!--QuoteEnd--></td></tr></table><div class='postcolor'><!--QuoteEEnd-->

    Done... <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html//emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif' /><!--endemo-->

    So you don't need to look for the coordinates of the sprite. The only real problem is:

    You can't just replace the sprite later... you need to edit the hud.txt again, if you want your old sprite/another w/o the same size... <!--emo&???--><img src='http://www.unknownworlds.com/forums/html//emoticons/confused.gif' border='0' style='vertical-align:middle' alt='confused.gif' /><!--endemo-->
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    I like keeping the original references, because that way, I only have to backup a single sprite file, whenever there's a new patch.
  • CaptainPanakaCaptainPanaka Join Date: 2002-11-02 Member: 4718Members
    what I said... <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html//emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif' /><!--endemo-->

    This one here is for people that are too lazy to search the right coordinates from the sprite. <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html//emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif' /><!--endemo--> (=> people like me <!--emo&???--><img src='http://www.unknownworlds.com/forums/html//emoticons/confused.gif' border='0' style='vertical-align:middle' alt='confused.gif' /><!--endemo--> )
Sign In or Register to comment.