Page 1 of 1

Something weird with the size circle

Posted: Sat Jan 30, 2010 6:48 am
by Rugdumph
I've just noticed whilst peacefully building away, that the circle that dictates the size (and hence threat etc for any metagamers) was at nearest, still a good 20 pixels away from any part of the ship, like so...
Image

I can't think of any reason for this, there are no obscenely big section selection boxes which would invisibly extent the size either. More of a puzzlement than a problem but any answer would be enlightening.

Posted: Sat Jan 30, 2010 7:28 am
by Droid
I think it counts the longest dimension of the sprite, and treats it as a square (or something like that).
if you rotate it, the corner sticks out and extends the size.
Anyhow, it's not perfect.

Posted: Sat Jan 30, 2010 8:05 am
by jwa8402
Plus even if you delete all sections, the size of the core is still 20 so maybe it adds it on top of that.

Posted: Sat Jan 30, 2010 4:28 pm
by Arcalane
jwa8402 wrote:Plus even if you delete all sections, the size of the core is still 20 so maybe it adds it on top of that.
That's a stupid assumption. :?

Furthermore:

Image

It's possible that there's a slight colour error for one of the custom sections used there. The game automatically calculates simple hitboxes based off the colour of the bottom left corner of the sprite compared to other colours. If the bottom left pixel's colour is 0,0,0, then only a 0,0,0 pixel is treated as background. Even 1,1,1 counts as part of the section.

That's the main thing I can think of that might cause it. Alternately it might be a minor hiccup in the size calc - try moving one of the sections near the edge a bit and see if it fixes itself.

With a little testing, I believe it is somehow related to the rotation of the Kae_gnr-sw79 you're using on the ringtips. Not sure exactly why.

Posted: Sat Jan 30, 2010 7:27 pm
by Rugdumph
Hmm i think you're right, since if i add more sections outwards, the circle forms perfectly, but deleting them again just causes the previous problem to return. Oh well it's all the fun of ship building though isn't it?

Posted: Sun Jan 31, 2010 2:42 am
by Droid
I'm pretty sure that it's rotating sections that messes it up.

Posted: Sun Jan 31, 2010 8:19 am
by Kaelis
Every section sprite has an axis aligned bounding box (ie the box rotates when you rotate the sections). The bounding box takes scaling into account. Ship size is simply the furthest (from the ship core) corner from all section bounding boxes.