Animated Crosshairs

enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
edited December 2003 in NS Customization
<div class="IPBDescription">some cool ideas</div> How bout it? is it possible, to animate crosshairs? is it possible too incorporate ammo count into the crosshair? health?

just some ideas, id be willing too make the sprites if it were possible.

example image below*
«1

Comments

  • MausMaus Join Date: 2002-11-03 Member: 5599Members
    Nope, not possible.
  • BlackPantherBlackPanther Join Date: 2002-02-11 Member: 197Members
    Yes it's possible.
    But maybe it has to be coded in.

    Normally, crosshairs have only 1 "frame" in the sprite's animation. Adding more frames will make the sprite animated.
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    ok, so this would have too be something hardcoded by the devs before it would be possible..?

    could the crosshair be incorporated into the hud? and if so couldnt the hud be changed too show some sort of circular ammo and health counters in it, and if it were part of the hud then could it be animate? as the minimap is?
  • WarfareWarfare Join Date: 2002-10-29 Member: 1697Members
    I think adding more frames would make it animated, like any other frame. Don't think they hardcoded the crosshair that much.
  • BlackPantherBlackPanther Join Date: 2002-02-11 Member: 197Members
    edited December 2003
    Maybe...

    Right now, the sprite definition for the weapons are in the weapon_name.txt files in the /ns/sprites folder, telling the game what crosshair the weapon uses, in what file and in what position inside the sprite itself on an XY axis.

    *edit* ok, i just did a test, and my xhair did not animate... guess it only plays the first frame <!--emo&:(--><img src='http://www.unknownworlds.com/forums/html/emoticons/sad.gif' border='0' style='vertical-align:middle' alt='sad.gif'><!--endemo-->
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    yes, it only uses the first frame, does the hud use animation.. well, yes it does.. it shows ammo count etc.. like i said why couldnt it be added too the hud, just placed in the center of the screen? it may not change on a per weapon basis, but it would be worth it too just use one CH that was animated with the ammo and health count right there and visible..

    i think im gonna begin work on this.. if anyone wants too help, lemme know i forgot how too do sprites quite some time ago. =)
  • g0opyg0opy Join Date: 2003-11-02 Member: 22233Members, Constellation
    I tried once.. But the transparency didn´t work..
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    incorporating into the hud?

    wierd, because the hud is semi transparent itself.
  • g0opyg0opy Join Date: 2003-11-02 Member: 22233Members, Constellation
    That try was 4 cs... I don´t really know about ns
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    ok, cool. we may still have a chance then... when i get home ill look into it, start a mock drawup of a hud with the ch in there..

    i desire this too work.
  • BlackPantherBlackPanther Join Date: 2002-02-11 Member: 197Members
    The crosshairs, if you look at the sprite file in SPRVIEWER, you'll see that they are grey, yet ingame, are blue.

    Right there, you know that the transparency that needs to be used is INDEXEDALPHA instead of ADDITIVE, because the BLUE is coded in, and overlayed over the crosshair to give it the right color, unlike HL, which the color was given straight in the .bmp itself prior to compiling.
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    edited December 2003
    Just an example i made up.. maybe spark some interest.

    the blue bar applies too ammo count.

    red to health and grean too armor.. if we can get this too work with the hud then they could be incorporated in several ways.. again this is just an example.
  • DocterJDocterJ Join Date: 2003-04-09 Member: 15357Members
    Probably would be hard to code it to represent your health and ammo, but if its possible, hotness.

    Nice crosshair enfurno... Doesnt quite look the same blue as the regular one tho, why dont you just steal that blue?
  • RuByRuBy Join Date: 2002-12-12 Member: 10732Members
    yeah its definitely possible but it would have to be coded in...
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    edited December 2003
    hrmm, i see. well, the devs have way too much on thier hands.... maybe this idea should be forgotten.

    btw thanks for the comment. the colors i just randomly chose for this example, didnt put much thought into design at all.

    edit. i am assuming the devs would have too code this in correct? this isnt something we can do, or is it?
  • NpgamerNpgamer Join Date: 2003-12-17 Member: 24489Members
    Very cool. I wish Condition Zero had these crosshair as well! <!--emo&:0--><img src='http://www.unknownworlds.com/forums/html/emoticons/wow.gif' border='0' style='vertical-align:middle' alt='wow.gif'><!--endemo-->
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    edited December 2003
    <!--QuoteBegin--BlackPanther+Dec 18 2003, 08:03 AM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (BlackPanther @ Dec 18 2003, 08:03 AM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> The crosshairs, if you look at the sprite file in SPRVIEWER, you'll see that they are grey, yet ingame, are blue.

    Right there, you know that the transparency that needs to be used is INDEXEDALPHA instead of ADDITIVE, because the BLUE is coded in, and overlayed over the crosshair to give it the right color, unlike HL, which the color was given straight in the .bmp itself prior to compiling. <!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
    Try decompiling a crosshair sprite into a BMP, and check out the last color of its palette. The color for the crosshair <b>is</b> compiled along with the sprite, and can be changed easily.

    In SpriteViewer, it's all grayscale, because using Indexed Alpha requires that all of the pixels should be shades of gray (used to determine transparency), or else it won't know what to do with the pixels that aren't gray.

    However, the Health, Armor, and Ammo Counts are using Additive transparency, and the sprite are really grayscale. For these, color is overlayed depending on which team you're on.

    The only place that the 'animated crosshair' could be incorporated into, is the mainhud.spr (the sprite which acts as the holder for the team resources and minimap). However, there are many problems, as of right now:<ul>
    <li>The 'animated crosshair' won't be able to animate.
    <li>The crosshair would probably not be centered.
    <li>Attempting to center it would result in having only a semi-circle left.
    <li>It could only be in shades of a single colour (since the mainhud.spr uses Indexed Alpha, and changing that would have unpredictable consequences).
    <li>You wouldn't have it for the Aliens, no matter how hard you try.</ul>
    There might be one way to get the crosshair above into the correct position, for starters. I'll give it a try.
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    hmm, well since this is the case.. its a good thing hte half life 2 engine will be out soon..

    thats where i got the idea for this crosshair, if you havent seen the video on hl2 then download it and you will see.
  • ChronoChrono Local flyboy Join Date: 2003-08-05 Member: 18989Members
    you can try moving the health and ammo counts from the corners of the screen to somewhere else near the crosshair
  • BlackPantherBlackPanther Join Date: 2002-02-11 Member: 197Members
    <!--QuoteBegin--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->Try decompiling a crosshair sprite into a BMP, and check out the last color of its palette.  The color for the crosshair <b>is</b> compiled along with the sprite, and can be changed easily.
    In SpriteViewer, it's all grayscale, because using Indexed Alpha requires that all of the pixels should be shades of gray (used to determine transparency), or else it won't know what to do with the pixels that aren't gray.<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
    Well i'll be damned... you're right!

    <!--QuoteBegin--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->However, the Health, Armor, and Ammo Counts are using Additive transparency, and the sprite are really grayscale.  For these, color is overlayed depending on which team you're on.
    <!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
    Yeap!
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    <!--QuoteBegin--chrono5454+Dec 18 2003, 10:08 AM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (chrono5454 @ Dec 18 2003, 10:08 AM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> you can try moving the health and ammo counts from the corners of the screen to somewhere else near the crosshair <!--QuoteEnd--> </td></tr></table><span class='postcolor'> <!--QuoteEEnd-->
    AFAIK, moving the counters is impossible without some changes in coding.
  • Dark_SoulDark_Soul Hive King Join Date: 2003-11-11 Member: 22527Members
    First of all, condition zero sucks Npgamer <!--emo&:p--><img src='http://www.unknownworlds.com/forums/html/emoticons/tounge.gif' border='0' style='vertical-align:middle' alt='tounge.gif'><!--endemo-->

    well the crosshair reminds me of the TS one a bit, but yeah, it's clear this can't be made for NS unless the code was changed
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    I just tried to incorporate the above crosshair into the mainhud.spr, and the result? Failure.
    There was no way to center it at any resolution.

    Great idea, though, and I would've loved to make it work, animated or not.
  • enfurnoenfurno Join Date: 2003-01-25 Member: 12729Members
    yes, an idea.... hl2 will support it right out of the box.. lets just hope that NS makes the shift too hl2 and then it can be schnazzed alll over the place.

    =)
  • UrdUrd Join Date: 2003-05-25 Member: 16696Members, Constellation
    <!--QuoteBegin--enfurno+Dec 17 2003, 06:04 PM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (enfurno @ Dec 17 2003, 06:04 PM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> Just an example i made up.. maybe spark some interest.

    the blue bar applies too ammo count.

    red to health and grean too armor.. if we can get this too work with the hud then they could be incorporated in several ways.. again this is just an example. <!--QuoteEnd--> </td></tr></table><span class='postcolor'> <!--QuoteEEnd-->
    That would make a nice motion tracking sprite.
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    Do you want the whole circle, or just the moving bit in the middle?
  • WindelkronWindelkron Join Date: 2002-04-11 Member: 419Members
    animated xhairs must be hardcoded, yes.
    I like that concept of the health/armor rings around the crosshair... but that must be hardcoded as well.
    What you CAN do, though, is edit hud.txt and reposition the health and armor counters next to the crosshair. of course that might get a little crowded up there.
  • VerthandiVerthandi Join Date: 2002-12-12 Member: 10687Members, NS1 Playtester
    I'll be enlightened as to how you would go about achieving that. AFAIK, there is no way to reposition the HUD elements without changing the code, but I'd love to be wrong on this.
  • PowerslavEPowerslavE Join Date: 2003-10-25 Member: 21962Members
    <!--QuoteBegin--Urd+Dec 22 2003, 04:13 AM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (Urd @ Dec 22 2003, 04:13 AM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> <!--QuoteBegin--enfurno+Dec 17 2003, 06:04 PM--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> (enfurno @ Dec 17 2003, 06:04 PM)</td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> Just an example i made up.. maybe spark some interest.

    the blue bar  applies too ammo count.

    red to health and grean too armor.. if we can get this too work with the hud then they could be incorporated in several ways.. again this is just an example. <!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
    That would make a nice motion tracking sprite. <!--QuoteEnd--> </td></tr></table><span class='postcolor'> <!--QuoteEEnd-->
    My thoughts exactly. The default xhairs take up enough space as it is. No need for it to carry vital info. That's why we have ze hud.
  • pikeypikey Join Date: 2003-06-16 Member: 17406Members
    "The Specialists" mod has a semi-animated xhair... maybe if you emailed them, they'd help out.
Sign In or Register to comment.