Sniper Sight - MilHUD integrated

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

Post Reply
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Sniper Sight - MilHUD integrated

Post by Wildeblood »

Image

The Seeker of Indulgence moments before its terrible end. There are two versions of the Wildefire Systems Type 1 Gunsight available for download here:-

No, there aren't.

The file "SniperScope.99.zip" is a stand-alone version that can be purchased through the "Ship Outfitting" screen at any tech level 10 planet.

The file "MilHUD-v3.5-WS.zip" is the latest version of Cmdr Wyvern's Military HUD, with the sniper sight already integrated.

Those early prototype versions are long gone, but unfortunately there are still some links from the wiki pointing at this thread. For the latest versions of Sniper Sight and my modified version of MilHUD see these other threads:-

Sniper Sight 2 OXP.

MilHUD 4000 and matching MilHUD 4000 Sniper Sight version.
Last edited by Wildeblood on Wed Feb 08, 2012 10:22 am, edited 9 times in total.
In your heart, you know it's flat.
User avatar
DaddyHoggy
Intergalactic Spam Assassin
Intergalactic Spam Assassin
Posts: 8515
Joined: Tue Dec 05, 2006 9:43 pm
Location: Newbury, UK
Contact:

Re: [WIP] Sniper Scope

Post by DaddyHoggy »

OK....

So, what have you done and how does it work? Some kind of zoom facility? What do the rings do/mean?

Confused and drugged-up on painkillers, so accept my apologies if it should be obvious.
Selezen wrote:
Apparently I was having a DaddyHoggy moment.
Oolite Life is now revealed here
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Re: [WIP] Sniper Scope

Post by Wildeblood »

It's what a giant, centred compass looks like. I've been messing about with it all week, making it bigger, bigger, bigger... oops too big, smaller, bigger. After many hours of testing, I've settled on this as the optimum size and transparency to use the compass in place of the usual cross-hairs. When the compass is in target mode, those crosses on the compass follow a target around, and when the two crosses are aligned that target is absolutely dead centre and soon to be history. Much better than the usual cross-hairs.

My problem is this: it's a damned eye-sore when not in target mode - i.e. in beacon mode, planet mode etc. - you get a giant N or W obscuring most of the screen. It needs to be scripted to make it only appear when the compass is in target mode. That's simple and only needs about 8 lines of code, but javascript and I have a hate/hate relationship. Someone else, who knows why some lines end in semi-colons and others don't, could have this finished in 15 minutes. I can describe what the script needs to do.

So spoon-feed me the script, someone! Or wait for a few weeks while I learn.

Image

And this has the advantage that, unlike the usual cross-hairs, it's visible in custom view mode. So it would be ridiculously appropriate for ships that have a custom "Gun Camera" view defined.
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Re: [WIP] Sniper Scope

Post by JensAyton »

You might want to get rid of the standard crosshairs. In a HUD plist:

Code: Select all

crosshairs = { OTHER = (); };
Zireael
---- E L I T E ----
---- E L I T E ----
Posts: 1396
Joined: Tue Nov 09, 2010 1:44 pm

Re: [WIP] Sniper Scope

Post by Zireael »

I love the idea. L-O-V-E.
Someone help the guy with scripting, please...
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Re: [WIP] Sniper Scope

Post by Wildeblood »

Ahruman wrote:
You might want to get rid of the standard crosshairs. In a HUD plist:

Code: Select all

crosshairs = { OTHER = (); };
Thank you. I actually did hide them by setting them to clearColor in my own HUD. The images above were chosen because they have the standard HUD.
User avatar
Capt. Murphy
Commodore
Commodore
Posts: 1127
Joined: Fri Feb 25, 2011 8:46 am
Location: UK South Coast.

Re: [WIP] Sniper Scope

Post by Capt. Murphy »

I guess it's a custom hud.plist to have the compass like that?

Something like this should start you off.

Code: Select all

this.compassTargetChanged = function(whom, mode)
{
  if (mode == "COMPASS_MODE_TARGET")
{player.ship.hud = "name of your hud.plist with big compass";}
else if (mode != "COMPASS_MODE_TARGET" && player.ship.hud == "name of your hud.plist with big compass")
{player.ship.hud = "name of the standard hud.plist with no big compass";}
}
edit to add - I knew absolutely zilch javascript a couple of months ago and am not a programmer*. I found this website, along with the wiki JS documentation and trawling through other's scripts helped me pick the basics up. I'm still learning.....

http://www.w3schools.com/js/default.asp

* not entirely true - I taught myself 80x86 Assembler a good 5-6 years ago whilst hacking the executable of the game Hardwar to make mods for it. Completely forgotten again now. Oh and I was a whizz on BBC Basic when I was a kid.
Last edited by Capt. Murphy on Wed Jun 22, 2011 5:18 pm, edited 1 time in total.
[EliteWiki] Capt. Murphy's OXPs
External JavaScript resources - W3Schools & Mozilla Developer Network
Win 7 64bit, Intel Core i5 with HD3000 (driver rev. 8.15.10.2696 - March 2012), Oolite 1.76.1
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Re: [WIP] Sniper Scope

Post by Wildeblood »

Not quite.
Last edited by Wildeblood on Wed Jun 22, 2011 5:49 pm, edited 2 times in total.
User avatar
Capt. Murphy
Commodore
Commodore
Posts: 1127
Joined: Fri Feb 25, 2011 8:46 am
Location: UK South Coast.

Re: [WIP] Sniper Scope

Post by Capt. Murphy »

Wildeblood wrote:

Not quite. Don't go away, yeah?
:lol: unfortunately Vice Admiral Field Commander Mrs Murphy tends to demand I leave the computer alone when she gets home from work. Whilst whipping my trousers off and putting them on herself.
[EliteWiki] Capt. Murphy's OXPs
External JavaScript resources - W3Schools & Mozilla Developer Network
Win 7 64bit, Intel Core i5 with HD3000 (driver rev. 8.15.10.2696 - March 2012), Oolite 1.76.1
User avatar
Cmdr Wyvern
---- E L I T E ----
---- E L I T E ----
Posts: 1649
Joined: Tue Apr 11, 2006 1:47 am
Location: Somewhere in the great starry void

Re: [WIP] Sniper Scope

Post by Cmdr Wyvern »

Finally a use for the compass' target mode! I thought it was as useless as a spammer's rogue product 'till now...

I'll be keeping an eye on this thread, and mebbe take a crack at making it work.
Running Oolite buttery smooth & rock stable w/ tons of eyecandy oxps on:
ASUS Prime X370-A
Ryzen 5 1500X
16GB DDR4 3200MHZ
128GB NVMe M.2 SSD (Boot drive)
1TB Hybrid HDD (For software and games)
EVGA GTX-1070 SC
1080P Samsung large screen monitor
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Re: [WIP] Sniper Scope

Post by Wildeblood »

Uploaded a demo, link is in the first post. Just drop it in your AddOns after disabling any custom HUDs. If you like it, and want to add it to your HUD, the bit to copy/paste is right at the top of the hud.plist file, and clearly commented. If you try it and don't like it, please come back and say why.
Last edited by Wildeblood on Wed Jun 22, 2011 7:44 pm, edited 1 time in total.
User avatar
CaptSolo
---- E L I T E ----
---- E L I T E ----
Posts: 909
Joined: Wed Feb 23, 2011 10:08 pm
Location: Preying Manta
Contact:

Re: [WIP] Sniper Scope

Post by CaptSolo »

I applaud your work thus far but for some reason I don't have a problem hitting the mark using only the cross-hairs.
User avatar
Cmdr Wyvern
---- E L I T E ----
---- E L I T E ----
Posts: 1649
Joined: Tue Apr 11, 2006 1:47 am
Location: Somewhere in the great starry void

Re: [WIP] Sniper Scope

Post by Cmdr Wyvern »

Wildeblood wrote:
Uploaded a demo, link is in the first post. Just drop it in your AddOns after disabling any custom HUDs. If you like it, and want to add it to your HUD, the bit to copy/paste is right at the top of the hud.plist file, and clearly commented. If you try it and don't like it, please come back and say why.
Your link doesn't quite work; that is, it downloads a zip with nothing in it. :?

Anyway, using Cptn Murphy's code and some plist hackery, I managed to add the feature to MilHUD. I swear I just became 50% more lethal to fighters at the extreme edge of scanner range. :twisted:
Running Oolite buttery smooth & rock stable w/ tons of eyecandy oxps on:
ASUS Prime X370-A
Ryzen 5 1500X
16GB DDR4 3200MHZ
128GB NVMe M.2 SSD (Boot drive)
1TB Hybrid HDD (For software and games)
EVGA GTX-1070 SC
1080P Samsung large screen monitor
User avatar
Wildeblood
---- E L I T E ----
---- E L I T E ----
Posts: 2453
Joined: Sat Jun 11, 2011 6:07 am
Location: Western Australia
Contact:

Re: [WIP] Sniper Scope

Post by Wildeblood »

Cmdr Wyvern wrote:
Your link doesn't quite work; that is, it downloads a zip with nothing in it. :?
Sorry about that. Fixed now I hope.
User avatar
Capt. Murphy
Commodore
Commodore
Posts: 1127
Joined: Fri Feb 25, 2011 8:46 am
Location: UK South Coast.

Re: [WIP] Sniper Scope, please test

Post by Capt. Murphy »

I've just had a little tester and quite like this. It is a real boon for extreme range sniping when even the sensitive reticle often gets it wrong.

I think it should cost to buy as a final OXP.
[EliteWiki] Capt. Murphy's OXPs
External JavaScript resources - W3Schools & Mozilla Developer Network
Win 7 64bit, Intel Core i5 with HD3000 (driver rev. 8.15.10.2696 - March 2012), Oolite 1.76.1
Post Reply