+ Reply to Thread
Page 21 of 53 FirstFirst ... 11192021222331 ... LastLast
Results 201 to 210 of 526

Thread: Advanced HUD Tools

  1. #201
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Had to post something... Parser works! I can display arbitrary lines on screen! yay ^.^

    Oh god... I just jubilated over a damn line... ergh.

    Quote Originally Posted by Asphid_Jackal View Post
    Zeik was playing with those before... I think he got frustrated and gave up.
    Yeah, I saw that... Although, after I have HML working properly for HUD2, I can fairly quickly build a cut down version for the panels, a-la in-game script-able panels (again!)

  2. #202
    Bug Buster TomyLobo's Avatar
    Join Date
    Feb 2009
    Posts
    2,796

    Default Re: Advanced HUD Tools

    what are you using to edit? e2 editor? if yes, have you added syntax highlighting?
    "It's easy to win forgiveness for being wrong; being right is what gets you into real trouble." - Bjarne Stroustrup

    Lífið læðist lúmskt áfram

  3. #203
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Quote Originally Posted by TomyLobo View Post
    what are you using to edit? e2 editor? if yes, have you added syntax highlighting?
    Indeed, I am using the E2 editor, and no, syntax highlighting isn't currently on - I deemed it far less important than getting it to work :P

    I'll put in a proper syntax table later.

    -=Progress Update=-

    Nested tags now know what context they're in, so rendering outside a parent tag's area wont be drawn!

    Output from a simulated run:
    Code:
    Would have drawn:
    <startdraw>
    Renderable Area: 0x0 to 1024x768
    <RECT>    (10x10) -> (200x200)
    Renderable Area: 10x10 to 200x200
    <LINE>    (20x20) -> (40x40)
    <enddraw>
    From this HML:
    Code:
    <hml>
        <rect start={10,10} end={200,200}>
            <line start={10,10} end={30,30} />
        </rect>
     </hml>
    Last edited by moggie100; 06-20-2009 at 11:51 AM.

  4. #204
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Double post, but hey, the last one was 4 days ago, and this is kinda important!

    WIP SCREENSHOT!



    The square on the left, with the diagonal cross in it is being drawn from the HML code on the right - updating realtime as I edited. As the editor is entirely clientside, it affects no-one but you with lag (if any actually occurred)

    The code uses both constants (Uppercase named values "WHITE" for example) and vectors (curly-braced couplets, triplets and quadruplets, ie. {10,10} )

    Anyhow - Taa-daa!

  5. #205
    Wirererer Lancelot's Avatar
    Join Date
    Feb 2009
    Posts
    292

    Default Re: Advanced HUD Tools

    I like. Keep it up.

  6. #206
    Wire Amateur lavacano201014's Avatar
    Join Date
    Dec 2008
    Posts
    40

    Default Re: Advanced HUD Tools

    Can it have inputs on certain things?

    (i.e. color of the lines)

    If not, can you set it up like that?

  7. #207
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Quote Originally Posted by lavacano201014 View Post
    Can it have inputs on certain things?

    (i.e. color of the lines)

    If not, can you set it up like that?
    Anything that you can set as a value in the script can also be set as an input on the SENT

    Eg. "color=WHITE" can be written as "color=#Color" and the SENT will have a vector3 input named 'Color' on it.

    Additionally, for vectors (or any compound type) you can specify one or more components, ie. "color={255,255,255,#Alpha}" would produce an 'NORMAL' type input named 'Alpha' which only controlled the alpha component of that color.

  8. #208
    Wirererer Lancelot's Avatar
    Join Date
    Feb 2009
    Posts
    292

    Default Re: Advanced HUD Tools

    Ok, so I see how drawing shapes with the indicator works. How about using those fun crosshairs you made?
    You know what I hate? Sentences with ridiculous and very purposefully implanted subliminal messages.

    Chinoto: I just explained an idea that requires no parenting or bacon sensor.

    MOOCOW Admin Mod Beta Tester

  9. #209
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Quote Originally Posted by Lancelot View Post
    Ok, so I see how drawing shapes with the indicator works. How about using those fun crosshairs you made?
    Same syntax - different tag types

    The general tag syntax is a follows:

    <[type] [parameter]=[value] [/]>

    and tag pairs are defined as: <tag>[enclosed child tags]</tag>

    (This is subject to change as I work on this, but the general principle will be the same)

    Say we wanted a target marker, and the tag type for a marker was 'marker', and we wanted no other tags to be *inside* the rendered area of the marker...

    <marker />

    to set a position we'd used the "position" (long form) or "pos" (short form - same meaning) variables;

    <marker pos={#TargetX, #TargetY, #TargetZ} />

    Giving us 3 normal-type inputs for X,Y and Z world positions, or alternatively, we can do this:

    <marker pos=w#Target />

    Which would give the SENT 1 vector3 input (the w# defines the input type as world-vector)

    Now markers can have several forms (crosshair, etc.) so we choose which we want with the "type" parameter:

    <marker type="boxed" pos=w#Target />

    The types themselves are just strings, I'll document what does what once I get the code more finalized.

    Hope that clears things up a bit!

    (Aside: I'm away for the rest of the week, so no updates 'till the weekend I'm afraid!)

  10. #210
    Wire Sofaking moggie100's Avatar
    Join Date
    Dec 2007
    Posts
    416
    Blog Entries
    1

    Default Re: Advanced HUD Tools

    Double post... again (ergh!) but again, this is worth an update.

    Updated stuff:
    • Tags are now defined by entires in a tags tables, allowing for E2-like extensibility!
    • The return of an 'old favourite'
    • 3D positions are now resolved on the fly to screenspace coordinates
    • Inputs should now evaluate to actual values, but untested

    Stuff still to do:
    • Actually have the SENT be created (currently all code is clientside for speedy testing)
    • Build lookup tables on both clientside and serverside to hold variable values at runtime
    • Build a "HUD Loading" screen (probably just a progress bar) for when people hook the indicator, but haven't got a HML table sent to them yet...
    • Add more support for building your own tags and including them with the core set.
    • Formalize HML 1.0 spec. (largely for me, so I'm forced to follow my own guidelines)
    • And quite a few more things

    Despite the above list, this is coming along nicely - the code's a bit messy at the moment while I dev and bughunt at the same time, but it'll get cleaner the more I work on it.

    And finally, for those interested, the code to draw the 'old favourite' above is:

    Code:
    <marker type="boxed" size=40 position={0,0,0} color=$WHITE background=$BLACK50 />
    Note the 3d position vector, and the new constant syntax ($ prefix'd, for faster/neater parsing)
    Attached Thumbnails Attached Thumbnails Advanced HUD Tools-old_fav.png  

+ Reply to Thread
Page 21 of 53 FirstFirst ... 11192021222331 ... LastLast

LinkBacks (?)

  1. 02-14-2010, 12:00 AM
  2. 01-28-2010, 12:12 PM

Similar Threads

  1. Advanced Colourer (as opposed to LevyBreak's Advanced Colorer) :D
    By andy1976uk in forum Ideas & Suggestions
    Replies: 8
    Last Post: 07-10-2008, 03:16 AM
  2. Some code tools
    By CAANz in forum Off-Topic
    Replies: 0
    Last Post: 04-30-2008, 07:00 AM
  3. Replies: 16
    Last Post: 02-26-2008, 07:29 AM
  4. OMG! what happen to my tools
    By GhostBuster in forum Installation and Malfunctions Support
    Replies: 4
    Last Post: 10-11-2007, 07:31 AM
  5. better tools
    By kilroy in forum Ideas & Suggestions
    Replies: 7
    Last Post: 10-02-2007, 10:08 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
proceed-collector
proceed-collector
proceed-collector
proceed-collector
linguistic-parrots
linguistic-parrots
linguistic-parrots
linguistic-parrots