sector mines and defenses

Do you need help playing, have ideas for the game or just want to talk about what's going on in the game? This is the place.

User avatar

Posts: 2

Joined: Wed Feb 28, 2018 3:03 pm

Post Wed Feb 28, 2018 3:12 pm

sector mines and defenses

So guys, what determines how many mines a player hits when they enter a sector?

I'm pretty sure that the code makes a determination based on your cloak level about whether they hit any mines at all. I guess this is put up against the sector owner's sensor level. Is it similar to scanning, where the results are a percentage based on the difference between the 2 players sensor and cloak levels?

thanks!
User avatar

Site Admin

Posts: 234

Joined: Thu Apr 17, 2014 10:15 am

Post Wed Feb 28, 2018 8:56 pm

Re: sector mines and defenses

The players Ship Cloak level has nothing to do with hitting mines, the cloak is used with fighter sector defences only.

The following code is how it works out how many mines hit you.
  Code:
// calculate the percentage between 5 and 100% of mines to hit ship.
$pren = (mt_rand (5, 100)/100);

// calculate the actual amount of mines to hit ship.
$roll = round ($pren * $total_sector_mines - 1) + 1;
 

So if $total_sector_mines = 5 Mil and $pren = 0.65 (65%), then $roll would = 3.25Mil mines will hit ship.

TBH, I think it should be the larger you are the more mines you should hit, but that's how it calculates it.
TheMightyDude::Blacknova Development.
Development Blog Twitter

Return to BNT help and discussion



Who is online

Users browsing this forum: No registered users and 1 guest

cron