Advanced Naval Targeting System

General discussion for players of Oolite.

Moderators: winston, another_commander

User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Advanced Naval Targeting System

Post by winston »

OK, so I'm working in an experimental branch, playing around with concepts for the ANTS (Advanced Naval Targeting System).

Here are some screen shots of an early prototype.

Features - targets colour coded by type and hostility status
Info block displayed (like the normal Targeting Enhancement) for currently selected target
Fighter jet style deadly diamond of death target highlighter on currently selected target to make it easy to spot amongst the mass of potentials

http://www.alioth.net/tmp/loot.png - It makes it MUCH easier for you to spot your loot.
http://www.alioth.net/tmp/targetrich.png - A target rich environment
http://www.alioth.net/tmp/thargs.png - A Thargoid encounter

Yes, some of the colours need fixing :-)

Other features I want to do - a *brief* info block (maybe just small icons) on non-selected targets, and a target 'pipper' to help you line up your laser (this is trivial).

Code-wise, currently I'm just putting this over the normal Scanner Targeting Enhancement since I've done nothing to actually make it into a piece of equipment. If you're interested in running it, the change is under the 'FancyTargetter' branch in SVN.
User avatar
the alberts
Competent
Competent
Posts: 54
Joined: Fri Mar 03, 2006 8:41 am
Location: West Sussex

Post by the alberts »

Looks great! I particularly like the colour coding too. Good stuff.

Is this going in possibly as an OXP or as part of a game update?
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

It involves code changes to the HUD so it'd have to be a game update. Of course, Giles needs to approve too :-)
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton »

How about a lead indicator for plasma cannons? :-)
User avatar
TGHC
---- E L I T E ----
---- E L I T E ----
Posts: 2157
Joined: Mon Jan 31, 2005 4:16 pm
Location: Berkshire, UK

Re: Advanced Naval Targeting System

Post by TGHC »

winston wrote:
and a target 'pipper' to help you line up your laser (this is trivial).
What is that?

I'm hoping it's something like the crosshairs changing colour (to red for example) when a target is in the crosshairs and able to be hit by laser. Very useful on long range targets and also helps to conserve laser temperature by not wasting shots.
The Grey Haired Commander has spoken!
OK so I'm a PC user - "you know whats scary? Out of billions of sperm I was the fastest"
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

Ahruman wrote:
How about a lead indicator for plasma cannons? :-)
That sounds disturbingly like it would need differential calculus to do. The last time I tried to do that my head exploded.
User avatar
JensAyton
Grand Admiral Emeritus
Grand Admiral Emeritus
Posts: 6657
Joined: Sat Apr 02, 2005 2:43 pm
Location: Sweden
Contact:

Post by JensAyton »

Only if the plasma pulses accelerate, which’d be a strange thing for them to do. If they don’t, it’s a simple matter of projecting the target’s velocity vector onto the camera plane and scaling by distance. Taking ship acceleration into account would make the scaling polynomial. Supporting accelerating munitions would make it go all differential-shaped.
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

OK - on those long range shots, well, I think the general consensus is we don't wanna do anything that makes Oolite a 'Press F3 to kill all enemies and collect cargo' type of thing...so hopefully this strikes a balance.

For the ANTS, a 'precision targeting helper' appears when your laser crosshairs come close enough to the target's 'centre of gravity'. Its appearance doesn't guarantee you'll hit at long range, but you can use it to see a bit more easily how well lined up the target is since you can see how far the extensions are from your cross hairs (in most cases, having the extensions lying exactly on your cross hairs should mean you'll hit). It looks like this:

So, you're lining up your target:

http://www.alioth.net/tmp/helper-not-showing.png

and now he gets into your crosshairs, and the helper shows:

http://www.alioth.net/tmp/helper-showing.png

If anyone wants to try and play with this I'll build the branch (for Linux and Mac OS X, I don't have a viable Windows system at the moment unfortunately) and put them up for download.

I also had a go at making the ANTS a piece of equipment you could purchase, and I didn't realise how easy that was to code! (Thanks Giles!)
User avatar
Odo987
Dangerous
Dangerous
Posts: 121
Joined: Fri Mar 03, 2006 3:56 am
Location: San Francisco
Contact:

Post by Odo987 »

winston wrote:
and now he gets into your crosshairs, and the helper shows
Looks great!

Just a word of caution, I found that the original Elite's guns got worse and worse as you bought better models. Sure the firepower was superior, but the crosshairs became more elaborate. The end result was that the military laser could blow up anything, but its crosshairs were so large they obscured anything smaller than a planet. Just keep this consideration in mind while adding HUD stuff.

Maybe use dotted lines for the cross hair? Or lines with alpha transparency?
Attacking a Navigational Beacon is illegal. Police are on their way.
User avatar
lex_talionis
Deadly
Deadly
Posts: 160
Joined: Thu Nov 10, 2005 3:46 pm
Location: Inverness, Scotland

Post by lex_talionis »

tbh, i have to say that the helper is just a bit too cumbersome. like Odo987 pointed out, it gets to the point where you can't see the target for the targetting equipment. the crosshairs chainging colour is a better idea - assuming it can be done with a minimum of hassle.

i agree with the idea of making them partly transparent... definately a good way to go.
edible poet? onna stick?
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

Well, I'll play around with the alpha channel. Perhaps just tick marks on the corners of the 'diamond of death' rather than a full cross may be better too.
oO
Competent
Competent
Posts: 32
Joined: Sat Oct 15, 2005 8:51 pm

Post by oO »

Great! just bought mine :P

What about some range indication for the non-selected targets?

In example, alpha value of the reticle decreases with distance:

Code: Select all

Index: src/Core/HeadUpDisplay.m
===================================================================
--- src/Core/HeadUpDisplay.m	(revision 370)
+++ src/Core/HeadUpDisplay.m	(working copy)
@@ -2029,7 +2029,15 @@
 	//rotate to face player1
 	glMultMatrixf(back_mat);
 	// draw the reticle	
-	glColor4fv(targetColor);
+	if (!show_info) //distance hint for non-targetted items
+	{
+		double mass_lock_range2 = 25600.0*25600.0;
+		double dist_alpha = 1 - target->zero_distance/mass_lock_range2;
+		GLfloat targetColorAlpha[4] = {targetColor[0], targetColor[1], targetColor[2], dist_alpha};
+		glColor4fv(targetColorAlpha);
+	} else {
+		glColor4fv(targetColor);
+	}
 	glBegin(GL_LINES);
 		glVertex2f(rs0,rs2);	glVertex2f(rs0,rs0);
 		glVertex2f(rs0,rs0);	glVertex2f(rs2,rs0);
User avatar
TGHC
---- E L I T E ----
---- E L I T E ----
Posts: 2157
Joined: Mon Jan 31, 2005 4:16 pm
Location: Berkshire, UK

Post by TGHC »

Sorry to keep going on about this ( too much wine and Belgian beer) yes I'm flying a kite right now! The most useful enhancement I've used is in Xelite, where the croshhairs target changes from the normal green to red when the "target" can be hit by laser fire. If its's green you miss, if it's red you hit, very simple and very very effective.
The Grey Haired Commander has spoken!
OK so I'm a PC user - "you know whats scary? Out of billions of sperm I was the fastest"
ArkanoiD
---- E L I T E ----
---- E L I T E ----
Posts: 452
Joined: Mon Mar 13, 2006 5:46 pm
Location: St Petersburg, Russia
Contact:

Post by ArkanoiD »

TGHC wrote:
Sorry to keep going on about this ( too much wine and Belgian beer) yes I'm flying a kite right now! The most useful enhancement I've used is in Xelite, where the croshhairs target changes from the normal green to red when the "target" can be hit by laser fire. If its's green you miss, if it's red you hit, very simple and very very effective.
btw what is Xelite?
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

The trouble is as you say - it's TOO simple and effective - it reduces aiming to moving around waiting for a cross hair to change colour. The idea behind the 'precision targeting designation' is to make it more visible when something is properly lined up, but without going as far as suggesting when to fire and still requiring the pilot to aim as before (the problem at the moment isn't that it's difficult to aim on a distant target, it's that it's virtually impossible).

IMHO, the problem with 'long range shooting' is it's very difficult to see when a ship is actually lined up into the cross hairs for two reasons:

- the cross hairs don't actually cross so you can't easily tell when something is precisely lined up
- space is very dark.

To amplify on the second point, Oolite is *very* much harder when it comes to aiming than the original Elites for a couple of reasons - one, more precision is needed but, two - just as importantly - in the 8-bit Elites ships were always bright white against a black background and so were very easy to see even at a large distance. In Oolite, a distant ship is virtually invisible (especially in a planet's shadow).

Anyway, I'll play with it a bit more tonight. It is of course all experimental anyway so anything goes :-)
Post Reply