Home » Stars! 2.6/7 » The Academy » Missile hit rate vs additional target tokens
Missile hit rate vs additional target tokens |
Mon, 22 November 2004 08:22 |
|
|
I'm trying to write the pseudo-code for missile attacks and I have a fundamental problem if the damage streams over to additional tokens.
There are 3 rules at work here:
1/ The maximum number of kills is limited to the number of missiles that hit. That's simple enough.
2/ The number of missiles that hit depends on (amongst other things) the jammers on the target. Again, simple.
3/ Each missile is tested individually against it's adjusted accuracy to see whether it hits. Still no problems.
Put all these together though and you do have a problem...
How many shots are available to target other tokens after killing all the ships in the primary target ?
Lets say the target token is 80 chaff, and I have 200 missiles with an accuracy of about 80%. The shot kills all 80 ships in the chaff stack, and now streams over to a set of beam BBs.
How many missiles should target the beamers ? Is it 120 (ie. 200 - the 80 kills) ? That doesn't sound right, as it implies that no missiles targeted at the chaff missed.
Should it be 100 ? That sounds better - if I got 80 kills then I must have fired 100 missiles.
Unfortunately this runs into problems because of 3/ above. I can't tell whether the actual accuracy really was 80% as results vary statistically.
As an alternative, I could just calculate the number of hits, and then only carry over the hits to other tokens. This, however, doesn't take into account the fact that the beam BBs have jammers and so should the missiles should be less accurate against them.
The fundamental problem is that all the missiles are initially available to kill the chaff, but then if they aren't all needed some of them can be used to target other ships.
I hope I am missing something obvious here. Can anyone see what it is ?
Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Mon, 22 November 2004 08:47 |
|
platon79 | | Chief Warrant Officer 3 | Messages: 185
Registered: February 2004 Location: Norway | |
|
Hm, maybe it would be better to simulate X number of combats, and present the "median value".
For example, for each combat, have a counter counting the number of ships killed on each side,
and store the battle results, then find the the median values of the ships-killed-counters after X
combat simulations, and present the stored battle result for that particular combat.
If you do it as a simulation, then you can do each missile by itself, individually.
But remember to take into consideration the number of missiles fired from each slot........
Report message to a moderator
|
|
| |
Re: Missile hit rate vs additional target tokens |
Tue, 23 November 2004 02:49 |
|
iztok | | Commander | Messages: 1207
Registered: April 2003 Location: Slovenia, Europe | |
|
Hi!
Staz wrote on Mon, 22 November 2004 14:22 | I'm trying to write the pseudo-code for missile attacks and I have a fundamental problem if the damage streams over to additional tokens.
|
I'd suggest you the following procedure:
1. pick the target token.
2. shot at that token with x missiles of type y:
- calculate number of missiles that hit, apply damage,
- calculate number of missiles, that miss (for 1/8 shield damage), apply damage,
- subtract both numbers from x,
- if x>0 goto 1.
My .
BR, Iztok
Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Tue, 23 November 2004 05:30 |
|
|
iztok wrote on Tue, 23 November 2004 07:49 |
I'd suggest you the following procedure:
1. pick the target token.
2. shot at that token with x missiles of type y:
- calculate number of missiles that hit, apply damage,
- calculate number of missiles, that miss (for 1/8 shield damage), apply damage,
- subtract both numbers from x,
- if x>0 goto 1.
My .
BR, Iztok
|
I'm not sure I understand that. You seem to be saying something like "subtract the number of hits plus the number of misses from the number of missiles, then see if you have any left". In which case there won't be any left, so no damage is applied to other stacks.
Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Tue, 23 November 2004 17:56 |
|
iztok | | Commander | Messages: 1207
Registered: April 2003 Location: Slovenia, Europe | |
|
Hi!
Staz wrote on Tue, 23 November 2004 11:30 | I'm not sure I understand that. You seem to be saying something like "subtract the number of hits plus the number of misses from the number of missiles, then see if you have any left". In which case there won't be any left, so no damage is applied to other stacks.
|
Sorry for not being clear enough. 've been thinking too much along the "1 missile 1 kill". The suggested procedure was just my first attempt. Will try to refine it later. Just now I'm thinking along two lines: how it could be, or how Stars! actually works. For the later procedure to be accurate I (still) lack proper info and will need to do some more testbeds. The former could be pretty simple.
We have a token with slot(s) of missiles with known FP and accuracy. We also have tokens with known armour, shields and jamming (AKA target). For one slot of missiles the procedure looks like:
1. chose the target.
2. calculate base hit percentage (BHP) for that target.
3. number of needed missiles to kill one target's ship NMKO = int(1+(target's single ship armor / BHP * actual missile damage with_without shields)).
4. if NMKO * count of ships in target * current armor% > number of missile currently firing from slot
then execute missile firing procedure
else calculate how many missiles are acutally used and execute missile firing procedure with only those missiles.
5. subtract used missiles from slot's number of missiles
6. if result > 1 goto 1.
Stars! probably uses something similar, but there are those extreme results with all missile missing that this procedure doesn't apply.
BTW to complicate you a bit the damage calculation: Stars! tokens can have some ships damaged by a certain percent.
Well, it's pretty late and I need some sleep to . Later...
BR, Iztok
Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Tue, 23 November 2004 22:11 |
|
|
I think the code is fairly simple...
Do one missile at a time.
If damage is enough to take out target ship eliminate it, spread out remaining damage among the target ships stack buddies and move on to next ship (now most attractive target).
If a firing slot is used up take the remaining accumulated damage (that does not destroy a ship) and spread out remaining damage among the target ships stack buddies and move on to next ship (now most attractive target) and missile in next missile slot.
[Updated on: Tue, 23 November 2004 22:13] Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Wed, 24 November 2004 07:27 |
|
iztok | | Commander | Messages: 1207
Registered: April 2003 Location: Slovenia, Europe | |
|
Hi!
multilis wrote on Wed, 24 November 2004 04:11 | Do one missile at a time.
|
You'd get damage spread over all ships in the token this way, not whole ship kills.
Quote: | If damage is enough to take out target ship eliminate it, spread out remaining damage among the target ships stack buddies
|
Remaining damage from a single/last_that_kills missile shouldn't spread because of 1 missile 1 kill rule.
BR, Iztok
[Updated on: Wed, 24 November 2004 07:34] Report message to a moderator
|
|
| | |
Re: Missile hit rate vs additional target tokens |
Fri, 10 March 2006 06:28 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
Staz wrote on Mon, 22 November 2004 14:22 | I'm trying to write the pseudo-code for missile attacks and I have a fundamental problem if the damage streams over to additional tokens.
There are 3 rules at work here:
1/ The maximum number of kills is limited to the number of missiles that hit. That's simple enough.
2/ The number of missiles that hit depends on (amongst other things) the jammers on the target. Again, simple.
3/ Each missile is tested individually against it's adjusted accuracy to see whether it hits. Still no problems.
Put all these together though and you do have a problem...
How many shots are available to target other tokens after killing all the ships in the primary target ?
Lets say the target token is 80 chaff, and I have 200 missiles with an accuracy of about 80%. The shot kills all 80 ships in the chaff stack, and now streams over to a set of beam BBs.
How many missiles should target the beamers ? Is it 120 (ie. 200 - the 80 kills) ? That doesn't sound right, as it implies that no missiles targeted at the chaff missed.
Should it be 100 ? That sounds better - if I got 80 kills then I must have fired 100 missiles.
Unfortunately this runs into problems because of 3/ above. I can't tell whether the actual accuracy really was 80% as results vary statistically.
|
I guess it is quite late to put in my 2cents, but, as I don't see this issue actually explained in this thread, here it goes:
"Accuracy" is a fiction. [I meant "deflection" is the fiction, actually. ] Missiles are actually launched/spent, even if they don't "hit". What accuracy does is modify the damage done, not change actual number of "hits" in any way.
i.e:
- a 75% accurate missile targets a chaff: one missile is launched/spent, 100% damage is done, chaff dies.
- same 75% accurate missile targets a 75%-jammed Battleship. "Some missiles don't hit", reduced damage is done and BB (presumably) survives. One missile is still launched/spent, anyway.
[Updated on: Sun, 12 March 2006 04:56]
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Fri, 10 March 2006 22:53 |
|
LEit | | Lt. Commander | Messages: 879
Registered: April 2003 Location: CT | |
|
My understanding is that it first applies the chance of each missile hitting a stack, and then calculates damage and # of kills not counting max one kill per missile. Then it applies the one kill per missile max. And if there is damage left over, then it figures out the number of missiles left, and sends them to the next stack.
One way to test m.a's theory is to have a ship with a single cap missile (and low accuracy), (FF with one Juggernaut would be ideal) build 10 (or 100) of them, put them in seperate fleets, and send them after 10 (or 100) chaff in seperate fleets. If every missile kills a chaff then he's right. I expect however, that most missiles will miss.
Now if you took those missile ships and put them all in one stack, and fired them at the chaff all in one stack, a few hits would be enough damage to equate to 10 (or 100) kills, and all the chaff would die. This is what would happen in both m.a's theory and mine.
All missiles in one stack and chaff still split is another good test. It would be best to do 100 and not 10 for this. If my theory is right, it will kill most of the chaff that way, first 100 missiles at one chaff, one (or more) will hit, calculate damage, apply 1 missile 1 kill rule, and then 99 missiles will shoot at the next chaff...
What it should probably do is have each missile try to hit, and keep track of damage (applying 1 hit 1 kill immediatly) and total hits until damage >= dp, and then the remaining missiles can shoot at the next stack.
- LEitReport message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Sat, 11 March 2006 04:46 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
LEit wrote on Sat, 11 March 2006 04:53 | My understanding is that it first applies the chance of each missile hitting a stack, and then calculates damage and # of kills not counting max one kill per missile. Then it applies the one kill per missile max. And if there is damage left over, then it figures out the number of missiles left, and sends them to the next stack.
|
I reckon some testbedding will be needed.
Quote: | One way to test m.a's theory is to have a ship with a single cap missile (and low accuracy), (FF with one Juggernaut would be ideal) build 10 (or 100) of them, put them in seperate fleets, and send them after 10 (or 100) chaff in seperate fleets. If every missile kills a chaff then he's right. I expect however, that most missiles will miss.
|
You mean setting a bunch of "1 Jug vs 2 chaff" battles?
Quote: | Now if you took those missile ships and put them all in one stack, and fired them at the chaff all in one stack, a few hits would be enough damage to equate to 10 (or 100) kills, and all the chaff would die. This is what would happen in both m.a's theory and mine.
|
I don't even have a theory about how "leftover missile damage" might work.
Quote: | All missiles in one stack and chaff still split is another good test. It would be best to do 100 and not 10 for this. If my theory is right, it will kill most of the chaff that way, first 100 missiles at one chaff, one (or more) will hit, calculate damage, apply 1 missile 1 kill rule, and then 99 missiles will shoot at the next chaff...
|
That would seem too complex a way of doing things, even for the Jeffs...
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Sat, 11 March 2006 04:47 |
|
|
LEit wrote on Sat, 11 March 2006 03:53 | One way to test m.a's theory is to have a ship with a single cap missile (and low accuracy), (FF with one Juggernaut would be ideal) build 10 (or 100) of them, put them in seperate fleets, and send them after 10 (or 100) chaff in seperate fleets. If every missile kills a chaff then he's right. I expect however, that most missiles will miss.
|
Just did a quick test - a stack of 10 FFs with a single Jihad each, attacking 10 chaff (unstacked).
First round, 1 kill.
Second round, 5 kills.
Third round, 3 kills.
Fourth round, 1 kill.
In each case, scouts are either killed or undamaged.
Sorry m.a, but accuracy is real.
Report message to a moderator
|
|
| |
Re: Missile hit rate vs additional target tokens |
Sun, 12 March 2006 04:37 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
Staz wrote on Sat, 11 March 2006 10:47 |
LEit wrote on Sat, 11 March 2006 03:53 | One way to test m.a's theory is to have a ship with a single cap missile (and low accuracy), (FF with one Juggernaut would be ideal) build 10 (or 100) of them, put them in seperate fleets, and send them after 10 (or 100) chaff in seperate fleets. If every missile kills a chaff then he's right. I expect however, that most missiles will miss.
|
Just did a quick test - a stack of 10 FFs with a single Jihad each, attacking 10 chaff (unstacked).
First round, 1 kill.
Second round, 5 kills.
Third round, 3 kills.
Fourth round, 1 kill.
In each case, scouts are either killed or undamaged.
Sorry m.a, but accuracy is real.
|
I was meaning "deflection" is the fiction, sorry. Must learn to re-read what I write in a hurry.
Here's my own test on the matter. Nothing out of the ordinary, really:
50 scouts were loaded with Galaxy Scoops and Armageddon missiles (525 pwr, accuracy=30%), and sent to 50 separate places to battle pairs of Galaxy Scoop frigates carrying only 3 Jammer30s (66% jamming, armor = 45dp, no shields)
Every time, "deflected" missiles failed to damage anything, regardless of the frigates being both in the same token or independent. In fact, survival rate for the jammed frigates was at least 80%, since the undamaged ones fled after two missile shots.
So, at least for the simplest case, my guess is supported by what the VCR shows: missiles "hit" and are spent even if they are deflected. However, it seems the percentage of damage done to armor by deflected missiles is exactly zero in all cases, whereas I was hoping it would be something noticeable. Unless it is so low that it needs a bigger base armor to show, that is.
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| | | |
Re: Missile hit rate vs additional target tokens |
Sun, 12 March 2006 18:41 |
|
|
Hi Staz,
If your original question is not answered, I can try to make and post some code for you. I still think doing one missile at a time is easiest.
More detailed description: damage is accumulated in special variable and applied whenever a ship is killed or firing slot is used up. If firing slot is used up rather than ship killed, the damage is spread out among the target ships.
Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Mon, 13 March 2006 05:15 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
rowenstin wrote on Sun, 12 March 2006 12:55 |
m.a@stars wrote on Sun, 12 March 2006 04:37 | However, it seems the percentage of damage done to armor by deflected missiles is exactly zero in all cases, whereas I was hoping it would be something noticeable. Unless it is so low that it needs a bigger base armor to show, that is.
|
IIRC there´s a bug that sets a minimum for damage dealt per stack, so either there´s no damage at all, or you can try with more slots of torpedoes or missiles and confirm with theory is right.
|
That's a "minimun damage" cap. In other words, if anything does damage, it does *at least* that damage. Worth trying the same tests with, say, nubian hulls, though.
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
|
Re: Missile hit rate vs additional target tokens |
Mon, 13 March 2006 05:30 |
|
m.a@stars | | Commander | Messages: 2765
Registered: October 2004 Location: Third star to the left | |
|
Staz wrote on Sun, 12 March 2006 20:51 |
m.a@stars wrote on Sun, 12 March 2006 09:41 | Scratch "accuracy" and write "deflection" in my post. Sorry to have brought confusion when I was trying to clarify/simplify things.
|
Quote: | What accuracy does is modify the damage done, not change actual number of "hits" in any way.
|
Still not sure what you mean by "deflection". Deflection in Stars! battles is something that happens to beam weapons. Did you mean jamming ?
|
Oh no, not again.
Please excuse my overly fast fingers. I did not realize there could still be confusion. I meant the "some missiles where deflected" message, which can be interpreted as "some missiles are detoured to other targets" by the unwary.
There's no equivalent message for beams, even if there's a "beam deflector" item.
Quote: | Or are you talking collateral damage ? According to the manual, "Torpedoes that miss do collateral damage to the target token only. Collateral damage is 1/8th of the normal damage of the torpedo and works much like a Shield Buster beam weapon. In other words it only affects shields."
Your test targets had no shields, so you wouldn't see this at all.
|
Yep. I haven't extended tests to shields, as I thought there was a good understanding on those. I was only trying to settle what happened to missiles that "didn't hit" as your original question of so long ago asked, and also what kind of "reduced damage", if any, was applied to armor.
It also seems a working algorithm has been evolved which copes with most situations. Is that right? I can envision testing what Stars! actually does when the 1st missile of a multi-missile slot fails to hit. Does it target the same ship with the next missile? and the next?
Unless all of those have been already solved, that is.
So many Stars, so few Missiles!
In space no one can hear you scheme! Report message to a moderator
|
|
| | |
Re: Missile hit rate vs additional target tokens |
Mon, 13 March 2006 14:36 |
|
Kotk | | Commander | Messages: 1227
Registered: May 2003 | |
|
LEit wrote on Mon, 13 March 2006 19:56 | Where the 10 FFs in one stack? It sounds like it. And if so, it means that my theory is probably wrong too, although I suppose it is possible to get 9 misses in a row with Jihads. Could you repeat the test with 100 FFs (in one stack) and 100 chaff (in 100 stacks)?
|
Actually i cant reproduce the Staz outcome with my JRC4 unless these frigates are split out.
Basically: 10 uncomputered Jihads against 1000 frigates in stack seem to love to kill none, 3, 7 or 10. I get only these discrete kills, nothing else. Seems that:
if none hit they kill none,
if 1 hits they kill 3,
If 2 hit they kill 7,
if 3 or more hit they kill 10.
Also ... the stack seems to get damage (when less than 10 is killed)! So missing jihads still seem to aid the hitting ones to kill stack.
Firing at split out chaff works like Staz posted. Usually 0 to 5 chaffs die and never get damage.
[Updated on: Mon, 13 March 2006 17:57] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Mon May 13 01:39:36 EDT 2024
|