Page 4 of 17
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Fri Jun 10, 2011 8:40 pm
by another_commander
I would not expect the frequent updates to be a problem. Drawing the HUD may be somewhat expensive compared to other functions in the code, but you do it per frame anyway, even with the timers that run once every 0.25 seconds. The actual script update of the numerical values should cause next to no overhead. Of course, the most secure way to check this is to try profiling it and find out.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Fri Jun 10, 2011 10:26 pm
by Ganelon
That looks pretty frackin' nifty! Smaller *could* be good, as some have mentioned.. Or even left large but capable of being dimmed down a bit, so one can see space a bit better.
Now I don't know how it works, but is it possible for a HUD to be turned on and off like non-pod player gear? If one could select HUDs sort of like a transparent MFD, one could have HUDs that are specialised for combat, docking, landing, and even an "off" setting for basic cruising and sightseeing or getting pretty pics.
I really like what you've done with getting it to look rather reminiscent of the old multi-segment LED displays. I look forward to giving it a try when you get it up for dl somewhere.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Fri Jun 10, 2011 11:16 pm
by CommonSenseOTB
Well I've managed to jury rig it with next to no script change and the hud just flies
with next to no slow down. The difference is night and day. Hooray for frame callback!(and another_commander)
There is some room for optimization for better performance in my protoype script but the modular nature of the script design has the advantage that new gauges can be added easily. I don't want to give that up. I'll make a few performance tweaks but leave the main code essentially unchanged. Version 2 will be fully optimized and modular with all the bells and whistles.
Ganelon wrote:That looks pretty frackin' nifty! Smaller *could* be good, as some have mentioned.. Or even left large but capable of being dimmed down a bit, so one can see space a bit better.
Now I don't know how it works, but is it possible for a HUD to be turned on and off like non-pod player gear? If one could select HUDs sort of like a transparent MFD, one could have HUDs that are specialised for combat, docking, landing, and even an "off" setting for basic cruising and sightseeing or getting pretty pics.
I really like what you've done with getting it to look rather reminiscent of the old multi-segment LED displays. I look forward to giving it a try when you get it up for dl somewhere.
I'm glad you like it Ganelon, wait till you play it.
To answer, the alphas of any huds can be dimmed or one can use hud switching to switch between huds of different brightnesses.Different huds for combat, docking, landing, or off is also doable with hud switching. The new techniques being used here even make that unneccessary allowing most changes to be done within the hud itself using a script.
I'm pleased that you like the old school "digital watch" look because that is currently the only way to make this type of hud.
On a side note I discovered what is probably a bug in the hud.plist. It would appear that if you have no scanner in your hud.plist you can go to torus drive even when you are supposed to be mass-locked. Got a nasty surprise in testing when I engaged the torus drive just outside the main station and before I could react was burning through the lower atmosphere and crashed.Hehe!
Was a cool moment to be sure and wish I had an external picture of it.
When I put the scanner back in things were normal again. Well if I ever want to arrange a malfunction in the torus drive to crash a ship into a planet I now know how to do it.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Fri Jun 10, 2011 11:51 pm
by Gnudoll
DaddyHoggy wrote:Amazing job - given that not so long ago - such things were considered impossible!
They're a bit overwhelming but as a proof-of-concept - simply stunning.
Does this remind anyone else of what Braben and Bell were told when they demo'd Elite to a few big game houses? OTB, you seem to be in very good company!
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Sat Jun 11, 2011 1:33 am
by Ganelon
An old poem by Edgar Guest comes to mind..
http://www.appleseeds.org/guest_couldntbedone.htm
But in any case, this and the pie chart gauges open up some new possibilities for HUD and cockpit panels. Amazing.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Sat Jun 11, 2011 2:24 am
by Gnudoll
OTB, your signature needs to have the line:
Always listen to experts. They will tell you exactly what cannot be done and why. Then do it.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Sat Jun 11, 2011 7:56 am
by Staer9
Ganelon wrote:Now I don't know how it works, but is it possible for a HUD to be turned on and off like non-pod player gear? If one could select HUDs sort of like a transparent MFD, one could have HUDs that are specialised for combat, docking, landing, and even an "off" setting for basic cruising and sightseeing or getting pretty pics.
To turn the hud off just press 'p' to pause the 'o' then unpause, the hud will dissapear, do the same to get it to re-appear
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Sat Jun 11, 2011 9:37 am
by Ganelon
Yeah, that's the usual for pictures. But if you usually have a control panel or like at least the basic scanner up for cruising, switchable is good.
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Mon Jun 13, 2011 5:57 am
by CommonSenseOTB
Thanks for the kind remarks Gnudoll and Ganelon and I like the poem.
The last couple of days has been spent optimizing the script to prevent the frame rate from dropping. Frame callbacks do an incredible job but converting my existing script left some bugs to squash and this required extensive plumbing enough to make a plumber blush. At this point my framerate on my 1+Ghz acer netbook is about 5 or 6 fps lower overall and probably most people won't notice much as my computer is as low end as it gets and I find it excellent. The method used to create and animate the numeric gauges can be improved for better fps but not without an extensive rewrite. No retrofit is possible. If most people don't notice any real slowdown I probably won't do more than reorganize/streamline the existing script for version 2.
Currently the bugs have disappeared for over a dozen thorough tests now when it used to be happening every time so I think it's ready for prime time. Only have some cosmetic features/issues to deal with and package and download link to do.
You guys are gonna love this hud, even as a prototype version 1. There are some cool things in here!
Get ready playtesters!
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Mon Jun 13, 2011 7:12 am
by Wildeblood
CommonSenseOTB, I have a question: why do the fragments of script you posted earlier use mission variables? E.g.:
missionVariables.numericgaugevalue = ((player.ship.position.distanceTo(player.ship.target.position) - player.ship.target.collisionRadius) / 1000);
Why would the state of the HUD go into the saved game file; the game can only be saved when docked, so the HUD would always be in the same state? What have I misunderstood?
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Mon Jun 13, 2011 1:25 pm
by Zireael
I can't wait to download this!
BTW maik, would you add this to the OXP List?
Re: (WIP) Numeric Style HUDs(another first!)
Posted: Tue Jun 14, 2011 1:57 am
by CommonSenseOTB
Wildeblood wrote:CommonSenseOTB, I have a question: why do the fragments of script you posted earlier use mission variables? E.g.:
missionVariables.numericgaugevalue = ((player.ship.position.distanceTo(player.ship.target.position) - player.ship.target.collisionRadius) / 1000);
Why would the state of the HUD go into the saved game file; the game can only be saved when docked, so the HUD would always be in the same state? What have I misunderstood?
Wildeblood, missionVariables can store information that can then be passed on to other functions within the same script as it runs(like I'm doing) or to other scripts or saved with the save game file to be referenced later.
Zireael, I'll take care of it.
Re: (RELEASE) NUMERIC HUDv1.oxp(Finally!)
Posted: Tue Jun 14, 2011 6:46 am
by CommonSenseOTB
Well, it's done. The prototype numeric hud is finished.
The extra couple of days delay was worth it to use frame callbacks. Most of the bugs have been squashed and the fps has dropped only slightly. Because this is a jury-rigged script it is not as efficient or clean a script as I would like and the only bug now is related to script occasionally running a little to long.(Sometimes produces an error message but has no impact on the oxp performance. Will be cleaned up for version 2.) Please report on your experience and impression of this oxp and how you would improve it at this viewtopic.
Playtesters Wanted: Download Below.
Edit: link updated
http://wiki.alioth.net/index.php/Numeric_Style_HUDs
I look forward to all your comments!
Re: (NEW RELEASE) NUMERIC HUDv1.oxp(Finally!)
Posted: Tue Jun 14, 2011 7:17 pm
by Zireael
Pros: Giant scanner, giant font, giant numbers, numbers at last, brand new idea in the form of blinking colours changing on the scanner, target range...
Cons: slight slowdown at times (randomly), no targeting dot which I'm used to
My idea: add colour change to the shield/energy numbers, you know (yellow for medium, red for really bad situations)
It's on its way to be my no. 1 HUD!
Re: (NEW RELEASE) NUMERIC HUDv1.oxp(Finally!)
Posted: Tue Jun 14, 2011 7:49 pm
by CommonSenseOTB
I can't use red for the number colors Zireael but in a future version I could make the hud switch to flash a red background image behind the gauge as a warning light or I could use the status indicator sized up as a background for the gauge and equipment activate/animate it to flash as a warning without hud switching. Good idea.
About the slow down, if you could edit your post to include your regular hud fps and the numeric hud fps numbers and check your logs to see if there are any bugs OTHER than a script terminated from running too long and report them here.
If any other playtesters could also please report fps regular hud/fps numeric hud and any error messages OTHER than script terminated from running too long I would greatly appreciate it.
Zireael, I'm so happy that you like this hud. Have fun!!!