Page 1 of 1

Miss aligned missiles

Posted: Fri Jun 12, 2009 5:33 pm
by Alex
Hi all,
Another wee prob, well just asthetics really.
I've reacently upgraded fron a supa cob to a cad but the extra missiles don't show where the should.

Image

Any idea how I move them across a bit?
Do I need a particular prog to to play with oolite code?
How do you guys get the quotes to keep coming up in your posts?

Happy hunting
A

Posted: Fri Jun 12, 2009 6:10 pm
by Nemoricus
Which HUD are you using? I'm sure that I can figure out how to fix this, but I need to know what I'm looking at.

Quotes are done with [ quote][/quote] tags. Remove the space from the first one to use them.

OXPs just need a text editor for most purposes. There's a file called hud.plist in the Config folder of the OXP that added that hud. There's a line in there that you can change to adjust where the missiles show up. Unfortunately, I don't yet know which line you need to change.

EDIT: Here it is:

Code: Select all

selector  drawMissileDisplay:  spacing  16  width  12  x  -140  y  -216    height  8
There's a line in the hud file that looks like this. I believe that you need to make y more negative in order to move it over.

Adjust the line in your hud file. Don't use the one in my code box here.

Posted: Fri Jun 12, 2009 7:31 pm
by Screet
Nemoricus wrote:
Adjust the line in your hud file.
...and don't forget to hold down shift while launching oolite in order to force a re-read of the files contents! The log file will then show that the cache was explicitly flushed - otherwise the changes won't appear.

Screet

Posted: Sun Jun 21, 2009 8:30 am
by Alex
Code:
selector drawMissileDisplay: spacing 16 width 12 x -140 y -216 height 8


There's a line in the hud file that looks like this. I believe that you need to make y more negative in order to move it over.
Thank you very much, I'll away and look for it now

Happy flying
A

Posted: Sun Jun 21, 2009 9:16 am
by Alex
<dict><!-- missle display -->
<key>height</key>
<integer>8</integer>
<key>selector</key>
<string>drawMissileDisplay:</string>
<key>spacing</key>
<integer>14</integer>
<key>width</key>
<integer>10</integer>
<key>x</key>
<integer>-45</integer>
<key>y</key>
<integer>-139</integer>

Code looked like this on word pad.
But not to worry figured it out with a few tries. It was the "X" factor to move left or right.
Thanks heaps n heaps, Hud looks great now for 8 units, I can live with 4 starting at the left of missile display area.
It's an old medusa hud oxp. I don't think it's in the oxp list anymore.
Looks like this;
http://img3.imageshack.us/my.php?image=hud.jpg

Do you thiunk I can remember how to get a picture in this box??
Thanks again for the code to move my missile display

A

Old hud

Posted: Sun Jun 21, 2009 11:11 am
by ClymAngus
Yes (it's one of mine that is the old hud. The problem with putting the missile listing in the centre has always been that there is no way to centre the display. It's drawn from left to right.

So I removed the box and averaged out the starting point of the box for an average of 6 -8 missiles any more and it gets a little right lopsided.

Most people get round this one with their own huds by having the missile listing at the bottom on the right. It's a compromise until centering in huds becomes an option.