SBARINFO
Moderator: GZDoom Developers
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49226
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: SBARINFO
Never mind. I replaced one with a TArray and the other one with an FString.
Compiles now.
Compiles now.
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
Yeah I use GCC since VC++ takes a year and a half to start, and I prefer my text editor over any other IDE I have used. Though can I ask what it was complaining about? I don't recall assuming anything should ever expand.
- Graf Zahl
- Lead GZDoom+Raze Developer
- Posts: 49226
- Joined: Sat Jul 19, 2003 10:19 am
- Location: Germany
Re: SBARINFO
Standard C++ wants indices of array declarations to be constant. In 2 places you used a variable expression to declare an array. I had to replace both with either a dynamic array or a string object to make it work. There was also another problem: Your calls to the pow function were ambiguous and needed some minor alteration.
(Yeah, the compiler differences really suck...)
(Yeah, the compiler differences really suck...)
Re: SBARINFO
Very very nice! So is the Heretic/Hexen health gem implemented?
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
Not yet, but heretics interpolated health value is, so it is half there.
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
Update! Below is a list of changes. I implemented the drawgem (complete with wiggling). Of course I would like to know how heretic gets the chain to wrap around. I currently have it drawing the chain twice and placing the gem on the chains. The only problem I noticed with my approach is it looks ugly for widescreen users like myself.
Attached is the diff.
Code: Select all
- Fixed: The user could have supplied an invalid accuracy for drawmugshot in
SBARINFO.
- Fixed: If ammo1 or ammo2 was used with bars it would not draw at all if the
weapon didn't supply the said ammo. It should draw nothing if such is the
case.
- Added drawgem to SBARINFO.
- Added the ability to draw inventory.icon from any inventory item. Just name
the item instead of putting a sprite name.
Re: SBARINFO
Regarding the chain wrapping... can't you wrap it infinitely, like a horizontal floodfill?
(I know nothing about programming so please forgive me :))
(I know nothing about programming so please forgive me :))
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
I could add another two calls to draw the chain on the ends so it would look better. The problem is this would cause ZDoom to render (even if unnoticeably) slower. Additionally although I think my chain drawing is accurate it could vary well be off. Ideally I would want to get the image to wrap as it does in Heretic.
I have a question to Randy or Graf. Are there any proper ways to get the translations for the status bar image? I'm referring to the translations for the player color. (STFBANNY for example.) My current method only works in Doom (though I'm guessing it would work in Heretic if you used the same shades of green). In the worst case I could just figure out what game is running and adjust the translation table used.
I have a question to Randy or Graf. Are there any proper ways to get the translations for the status bar image? I'm referring to the translations for the player color. (STFBANNY for example.) My current method only works in Doom (though I'm guessing it would work in Heretic if you used the same shades of green). In the worst case I could just figure out what game is running and adjust the translation table used.
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
I re-read the Heretic statusbar code at least 10 times looking for how the wrapping was done. I finally realized that the answer was it never does wrap it simply moves the chain at a maximum of 16 pixels to the right. So I figure it is best to break SBARINFOs using drawgem now while it has only been in for a day.
Here is the changelog:
The new syntax is: drawgem [flags, ..., ] <chainimage>, <gemimage>, <leftpadding>, <rightpadding>, <chainsize>, x, y; Chain size represents the amount of pixels that the chain image should shift.
Here is the changelog:
Code: Select all
- SBARINFO should adjust the translationtables according to the game type.
- Changed drawgem to be more like the methods used for Heretic and Hexen,
although this will break any existing definitions it is worth it.
Re: SBARINFO
Can you update the documentation?
-
- Posts: 327
- Joined: Tue Oct 12, 2004 3:19 pm
- Location: On your boards, trolling your threads!!!
Re: SBARINFO
Any demo wad of what can be done with this?
-
-
- Posts: 3203
- Joined: Wed Nov 24, 2004 12:59 pm
- Graphics Processor: ATI/AMD with Vulkan/Metal Support
- Contact:
Re: SBARINFO
I do not have an demo since everything I made with it is just test cases with the original statusbars. Nash could probably provide an demo if he wanted.
Re: SBARINFO
Yeah, I'm working on it. It'll be a recreation of this ACS-based HUD:


- Kinsie
- Posts: 7402
- Joined: Fri Oct 22, 2004 9:22 am
- Graphics Processor: nVidia with Vulkan support
- Location: MAP33
- Contact:
Re: SBARINFO
Holy crap, it's a christmas miracle!
Thanks Bluzt and Graf!
Thanks Bluzt and Graf!