Should Rock Hermit asteroids block laser fire?
Moderators: winston, another_commander
- Cmdr James
- Commodore
- Posts: 1357
- Joined: Tue Jun 05, 2007 10:43 pm
- Location: Berlin
Re: Should Rock Hermit asteroids block laser fire?
Ok, I think I know what's happening now!
NPC ships launched from a Rock Hermit or Pirate Cove shoot their lasers through the "mother" station they launched from...but no one else does.
Probably done this way to reduce friendly fire issues?
Similar/related thread:
https://bb.oolite.space/viewtopic.php?f=3&t=8105
NPC ships launched from a Rock Hermit or Pirate Cove shoot their lasers through the "mother" station they launched from...but no one else does.
Probably done this way to reduce friendly fire issues?
Similar/related thread:
https://bb.oolite.space/viewtopic.php?f=3&t=8105
Last edited by Switeck on Sun Jan 09, 2011 9:07 pm, edited 2 times in total.
- DaddyHoggy
- 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?
If that's true - that's just wrong - whatever way you slice it...
Oolite Life is now revealed hereSelezen wrote:Apparently I was having a DaddyHoggy moment.
Re: Should Rock Hermit asteroids block laser fire?
If my guess is correct, laser pass-through may apply to any station's ships.
- Eric Walch
- Slightly Grand Rear Admiral
- Posts: 5536
- Joined: Sat Jun 16, 2007 3:48 pm
- Location: Netherlands
Re: Should Rock Hermit asteroids block laser fire?
And i think that your guess is correct.Switeck wrote:If my guess is correct, laser pass-through may apply to any station's ships.
I just browsed trough the code. In
Universe
at getFirstEntityHitByLaserFromEntity:
the trajectory to the first ship in line is calculated. But it first filters out some of the ships in the system:
Code: Select all
for (i = 0; i < ent_count; i++)
{
Entity* ent = sortedEntities[i];
if (ent != srcEntity && ent != parent && [ent isShip] && [ent canCollide])
{
my_entities[ship_count++] = [ent retain];
}
}
UPS-Courier & DeepSpacePirates & others at the box and some older versions
- JensAyton
- Grand Admiral Emeritus
- Posts: 6657
- Joined: Sat Apr 02, 2005 2:43 pm
- Location: Sweden
- Contact:
Re: Should Rock Hermit asteroids block laser fire?
parent
should probably be [srcEntity parentEntity]
rather than [srcEntity owner]
, or for more generality it should compare [ent rootShipEntity]
to [srcEntity rootShipEntity]
.E-mail: [email protected]
- Eric Walch
- Slightly Grand Rear Admiral
- Posts: 5536
- Joined: Sat Jun 16, 2007 3:48 pm
- Location: Netherlands
Re: Should Rock Hermit asteroids block laser fire?
Yes, I already has a look at it. There is already a check for being a subentitie in it. When I define the owner than as parent after it was explicit recognised as subentitie, things tested okay:Ahruman wrote:parent
should probably be[srcEntity parentEntity]
rather than[srcEntity owner]
, or for more generality it should compare[ent rootShipEntity]
to[srcEntity rootShipEntity]
.
Before the ship shot completely trough the hermit and with the code I noticed nothing. (I could not see the ship firing). But after moving a bit sideways, I just saw the defender hitting the side of its mother station. So this bug seems to be solved. And I hope no others introduced with it. Using
[srcEntity parentEntity]
looks even better than my approach, so I test it a bit further.The observation of Switeck that it were always the station-ships gave the clue away for finding the bug.
1.74 still has the bug that ships fly themselves into the station when I hide behind them. Testing with trunk went better because this bug was fixed there also.
Remains that ships keep shooting when in line of the target, even when the view is blocked. For now I call this a feature.
UPS-Courier & DeepSpacePirates & others at the box and some older versions
Re: Should Rock Hermit asteroids block laser fire?
my shots were never blocked by rock hermits!
R
R
Becca the Hermit Slayer, and part-time unpredictable avatar assassin.
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Should Rock Hermit asteroids block laser fire?
Yeah... BtHS returns... unpredictable as ever.Rebecca wrote:my shots were never blocked by rock hermits!
R
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
Re: Should Rock Hermit asteroids block laser fire?
didnt i kill you? or was it the other way round?El Viejo wrote:Yeah... BtHS returns... unpredictable as ever.Rebecca wrote:my shots were never blocked by rock hermits!
R
R
Becca the Hermit Slayer, and part-time unpredictable avatar assassin.
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Should Rock Hermit asteroids block laser fire?
Yes... and no!Rebecca wrote:didnt i kill you? R
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
Re: Should Rock Hermit asteroids block laser fire?
glad thats cleared up thenEl Viejo wrote:Yes... and no!Rebecca wrote:didnt i kill you? R
R
Becca the Hermit Slayer, and part-time unpredictable avatar assassin.
- Cody
- Sharp Shooter Spam Assassin
- Posts: 16081
- Joined: Sat Jul 04, 2009 9:31 pm
- Location: The Lizard's Claw
- Contact:
Re: Should Rock Hermit asteroids block laser fire?
Anyone who is puzzled by the last few posts should read this thread in the fiction section.
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
And any survivors, their debts I will certainly pay. There's always a way!
- DaddyHoggy
- 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?
El Viejo wrote:Anyone who is puzzled by the last few posts should read this thread in the fiction section.
You will still be confused, but you'll have had a good time along the way.
Oolite Life is now revealed hereSelezen wrote:Apparently I was having a DaddyHoggy moment.