Should Rock Hermit asteroids block laser fire?

General discussion for players of Oolite.

Moderators: winston, another_commander

Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Should Rock Hermit asteroids block laser fire?

Post by Switeck »

Because in my game, I'm taking laser hits by ai ships shooting through the Rock Hermit asteroid.

It does block missiles and accidental-ramming by the same ai ships trying to take the shortest route to get to me. :lol:

This not-blocking-laser-fire may also extend to other ships in general...they're just too small and hard to test with.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Of course they should, and if they don't, it's a bug.

I blame the collision detection (but I could be wrong). By the way, I have also seen ships pass through bigger asteroids, which is of course also wrong.
User avatar
DaddyHoggy
Intergalactic Spam Assassin
Intergalactic Spam Assassin
Posts: 8515
Joined: Tue Dec 05, 2006 9:43 pm
Location: Newbury, UK
Contact:

Re: Should Rock Hermit asteroids block laser fire?

Post by DaddyHoggy »

Switeck wrote:
Because in my game, I'm taking laser hits by ai ships shooting through the Rock Hermit asteroid.

It does block missiles and accidental-ramming by the same ai ships trying to take the shortest route to get to me. :lol:

This not-blocking-laser-fire may also extend to other ships in general...they're just too small and hard to test with.
Ah, so you've discovered the special holographic rock hermits... :wink:
Selezen wrote:
Apparently I was having a DaddyHoggy moment.
Oolite Life is now revealed here
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

I tried hiding behind regular asteroids to test laser fire on them...but for whatever reason they don't last too long. They can usually take 1 missile hit though, if you have an annoying ECM-resistant hardhead on your tail.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Switeck wrote:
I tried hiding behind regular asteroids to test laser fire on them...but for whatever reason they don't last too long. They can usually take 1 missile hit though, if you have an annoying ECM-resistant hardhead on your tail.
Yes, asteroids have an energy of 100, and no recharge (of course). A mining laser inflicts a damage of 50, so two hits vaporize the asteroid. With a military laser it takes a couple more shots (off the top of my head the damage inflicted is 23, which makes for five hits, which coincides with my experiences), but because of the almost permanent firing power I guess it takes less seconds than with a mining laser which has a fairly big interval between two shots.

Most (if not all) missiles inflict less damage than 100, so you would indeed expect an asteroid to survive one direct hit.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Commander McLane wrote:
Most (if not all) missiles inflict less damage than 100, so you would indeed expect an asteroid to survive one direct hit.
Where are you getting your missiles from? You should ask for a refund ;)

Unless they happened to detonate near the edge of their collision radius (250m), they'll do rather more damage than that. On my system an asteroid is almost always vaped by a standard missile (but that says more about my lack of FPS than anything else I guess).
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Thargoid wrote:
Commander McLane wrote:
Most (if not all) missiles inflict less damage than 100, so you would indeed expect an asteroid to survive one direct hit.
Where are you getting your missiles from? You should ask for a refund ;)

Unless they happened to detonate near the edge of their collision radius (250m), they'll do rather more damage than that.
Oops! :oops: You're right, of course. I should've looked it up before answering. A missile detonating right on an asteroid should of course take it out. But the damage drops dramatically with distance (by power of two?, of three?, exponentially?; I'm not sure), so at a greater distance the asteroid could survive.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

With nonmoving asteroids, missiles should consistently 1-shot-kill them...or NOT 1-shot-kill them if the missiles are meant to be weak.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

Here's a bit of definitive proof that Rock Hermits (or Pirate Coves, which uses the Rock Hermit model) do not make good cover from laser fire:

Image

Image

Image

The 2nd and 3rd smaller pictures link to short animated versions of what was happening. (They're about 2 and 4 MB in size!)
User avatar
snork
---- E L I T E ----
---- E L I T E ----
Posts: 551
Joined: Sat Jan 30, 2010 4:21 am
Location: northern Germany

Post by snork »

Would it maybe have to do with the very low framerate that Switeck has the game running at ?

In 1.73, before the asteroids and such got their "solidity" raised, I could sometimes fly right through them (iirc), when torusdrive-speeding and framerates were low. I once even flew right through a rock hermit.

I have no idea how Lasers actually work, game-mechanism-wise.
Does their lightbeam actually take time to "travel" or is the whole laserbeam there in one moment ?
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

snork wrote:
Would it maybe have to do with the very low framerate that Switeck has the game running at ?

In 1.73, before the asteroids and such got their "solidity" raised, I could sometimes fly right through them, when torusdrive-speeding and framerates were low. I once even flew right through a rock hermit.

I have no idea how Lasers actually work, game-mechanism-wise.
Does their lightbeam actually take time to "travel" or is the whole laserbeam there in one moment ?
Laser hits should not be framerate related. With collisions, the positions of two objects are only calculated on the "frame". There is no interpolation between frames. Would also not make sense to try that as we only would need it al low frame rates, and that is the situation were the processor already runs at its max.

With laser fire, framerate has no effect on quality. When a laser is fired, Oolite is checking every entity in the system against that beam. And with all entities than lie in the path of the beam, it chooses the closest to hit. So, what is described here should never happen and is a bug.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

snork wrote:
In 1.73, before the asteroids and such got their "solidity" raised, I could sometimes fly right through them (iirc), when torusdrive-speeding and framerates were low. I once even flew right through a rock hermit.
The framerate is taking hits from me making screenshots at the rate of ~1 a second plus all the OXPs I have loaded plus this system's over 5 years away from being top-of-the-line.

At the end of the second short animation, there's a bright flash. That's the Moray failing to fly through the Pirate Cove/Rock Hermit to get to me.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

Inside Oolite's shipdata.plist file, I noticed "asteroid" has this line:
density = 5;
...while "rock-hermit" does not.

Either that, or the hollow space needed to make Rock Hermits allow docking without crashing could be to blame.

I'll be testing Rock Hermits with density = 5; ...but I don't know whether to make the 5 higher or lower.

From http://wiki.alioth.net/index.php/Shipdata.plist :
density
This real value is used to calculate a ships total mass. Default is 1.0 (Introduced in version 1.69?)

Example:
<key>density</key>
<real>1.5</real>
User avatar
Eric Walch
Slightly Grand Rear Admiral
Slightly Grand Rear Admiral
Posts: 5536
Joined: Sat Jun 16, 2007 3:48 pm
Location: Netherlands

Post by Eric Walch »

Switeck wrote:
Inside Oolite's shipdata.plist file, I noticed "asteroid" has this line:
density = 5;
...while "rock-hermit" does not.
Density as parameter was added long ago, but Oolites own ships always had a value of 1. I changed it to 5 for asteroids with 1.74 because asteroids should be much denser than hollow ships or even hollow hermits. But the main reason to raise the asteroid weight was to discourage ramming boulders with the ship to mine splinters :lol:

Density has nothing to do with laser fire. Which entity is hit by laser is fully calculated in universe.m in the function: getFirstEntityHitByLaserFromEntity. That function uses a starting point, a direction and a beam length. Based on that it calculates for every entity in the system if the beam hits the entity and chooses the closest. When something goes wrong, it would be here.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

What I don't get is my laser is blocked by the Rock Hermit/Pirate Cove just fine.
Post Reply