Alternate HUD implementation requirements

Discussion area for user-created Allegiance models, textures, voicechats, music, and other ingame content.
Post Reply
Bunnywabbit
Posts: 965
Joined: Sun May 15, 2005 7:00 am
Location: Amsterdam, the Netherlands

Post by Bunnywabbit »

hi all,

I'm nearing completion of GlassHUD, read all about it here.

Only recently i noticed that there is a new way to switch huds in Alleg, which is great, but how do i supply a hud for that?

What names should i give my files and variables? Are there standards or best practices? How does that work?

thanks!
ImageImage current version r158 new beta as of jan 23 2012
Andon
Posts: 5453
Joined: Sun Jun 03, 2007 8:29 pm
Location: Maryland, USA
Contact:

Post by Andon »

Since you're familiar with dialog.mdl, I'll assume you've seen how the software and hardware huds are switched.

Simply adding another number, along with the hud, to dialog.mdl will make it work with this switch.

It's currently like this for default:

Code: Select all

CenterHudDisplay = 
    SwitchImage(
        StyleHUD,
        emptyImage,
        [   
            (0, CenterHudOn)
        ]
    );

softCenterHudDisplay =
    SwitchImage(
        StyleHUD,
        emptyImage,
        [   
            (1, CenterHudSoftware)
        ]
    );
Simply add something like this below it, and then add your own HUD stuff as needed:

Code: Select all

GlassHudDisplay = 
    SwitchImage(
        StyleHUD,
        emptyImage,
        [   
            (2, CenterHudOn)
        ]
    );
Image
ImageImage
Clay_Pigeon
Posts: 3211
Joined: Tue Mar 29, 2005 8:00 am
Location: my pod

Post by Clay_Pigeon »

This just may be awesome enough to migrate me away from lessHUD
Image
"Therefore I will boast all the more gladly about my weaknesses, so that Christ's power may rest on me." -2 Cor 12:9
"Never know how long I've waited, anticipated your smile pressed against mine." -Running
Bunnywabbit
Posts: 965
Joined: Sun May 15, 2005 7:00 am
Location: Amsterdam, the Netherlands

Post by Bunnywabbit »

@ andon, great, that's what i was looking for. thanks !

@ Clay: :D that's high praise indeed. I was using lessHud myself when i decided to make this. It's a great hud, but I feel it doesn't immerse you in the game as much as I would have liked it to. It's very pretty and very subtle, but I felt that Allegiance needed a bit more pathos.
ImageImage current version r158 new beta as of jan 23 2012
Post Reply