IPB

Welcome Guest ( Log In | Register )

> Mathematical Analysis of Daka, Using math to optimize character builds
Strungest
post Oct 6 2012, 05:36 PM
Post #1


Target
*

Group: Members
Posts: 13
Joined: 4-October 12
Member No.: 56,646



Due to the relitave compelxity of shadowruns firearms resolution mechanics, I decided to try to write a program to analyze specific outcomes so that I would have a better understanding of how the mechanics work. If you have a copy of Matlab or similar program you can just copy and paste the code and run it. Things I have learned:
Damage value is a Huge deal, as is called shots/long bursts. If possible you should always go for a higher effective damage value.
-Wide bursts are useless in almost every situation.
-Armor is not very important except for a threshold where several points can make the difference between mostly stun damage and mostly lethal damage. An example would be with the having 20 armor instead of 17 armor gives you 40% less chance to take lethal damage, while only lowering the actual damage you will take by ~5%
-It is almost impossible to disable a moderately optimized combat character in one simple action, and almost easy to do it in two.

I'm Posting this here so that some other people can play around with it and fix bugs/learn more about how the mechanics of Shadowrun firefights ACTUALLY work.

clear all
close all
format short g
format compact
screen_size=get(0,'ScreenSize');
clc
fig=figure;
set(fig,'units','normalized','outerposition',[0 0 1 1]);
tic
for a=6:2:22
for b=4:2:10
for j=2:2:26
for n=[0,1]
for l=4:2:20
for e=[0,1]
clearvars -except a b j n l e fig
%a=12; %attack Pool
%b=6; %Gun Damage
%c=20; %Recoil Controll
d=6; %Burst Count(semi=1, short=3, long=6)
%e=1; %Narrow burst(1=yes, 0=no)
f=0; %Off hand(1=yes, 0=no)
%g=0; %called shot(1=yes, 0=no)
h=0; %range penalty
%j=12; %Defense pool
%l=7; %Armor
m=1; %Health
%n=2; %armor piercing value
o=ceil((l-3)/3); %body value
c=d-1;
g=e;
info=sprintf('Attack Pool %1.0f, Gun Damage %1.0f, Shot Count %1.0f, Narrow Burst %1.0f, Called Shot %1.0f, Defense Pool %1.0f, Armor %1.0f, Body %1.0f, Armor Piercing %1.0f',a,b,d,e,g,j,l,o,n);
i=a-4*g-2*f-(d-1-c);%total attack pool
k=j-(1-e)*(d-1)-n;%total soak pool
m=zeros(50,1);
m(1,1)=2/3;
m(2,1)=1/3;
if i>1
for x=[2:i]
m(1,x)=m(1,x-1)*2/3;
for p=[2:50]
m(p,x)=(m(p,x-1)*2/3)+(m(p-1,x-1)/3);
end
end
m=m(1:50,i);
end
if k>0
for x=[2:k+1]
m(1,x)=m(1,x-1)+(m(1+1,x-1)/3);
for p=[2:49]
m(p,x)=m(p,x-1)*2/3+(m(p+1,x-1)/3);
end
end
m=m(1:50,k+1);
end
for x=[1:50]
m1(b+e*(d-1)+g*4+x,1)=m(x,1);
end
m=m1;
%shock=stun
%lethal=physical
shock=zeros(50,1);
lethal=zeros(50,1);
oneHkill=zeros(50,1);
twoHkill=zeros(50,1);
for x=[1:50]
if x>l-n
lethal(x,1)=m(x,1);
else
shock(x,1)=m(x,1);
end
end
if l+o-n>0
for x=[2:l+o-n+1]
shock(1,x)=shock(1,x-1)+(shock(1+1,x-1)/3);
for p=[2:49]
shock(p,x)=shock(p,x-1)*2/3+(shock(p+1,x-1)/3);
end
end
shock=shock(1:50,l+o-n+1);
end
if l+o-n>0
for x=[2:l+o-n+1]
lethal(1,x)=lethal(1,x-1)+(lethal(1+1,x-1)/3);
for p=[2:49]
lethal(p,x)=lethal(p,x-1)*2/3+(lethal(p+1,x-1)/3);
end
end
lethal=lethal(1:50,l+o-n+1);
end
total=lethal+shock;
for y=[1:50]
lethal1(y,1)=sum(lethal(y:50,1));
shock1(y,1)=sum(shock(y:50,1));
end
total1=lethal1+shock1;
x=[0:49]';
plot(x(1:20),shock1(1:20).*100,'- .b',x(1:20),lethal1(1:20).*100,'- .r',x(1:20),total1(1:20).*100,'.k',x(1:20),shock(1:20).*100,'-. .b',x(1:20),lethal(1:20).*100,'-. .r',x(1:20),total(1:20).*100,'ok');
axis([0 20 0 100])
grid minor
xlabel('Damge')
ylabel('% Chance, Solid: At least this much damage, Dashed/Hollow: Exactly this much damage')
legend('Shock Damage','Lethal Damage','Total')
title(info)
print(fig,info,'-dpng')
end
end
end
end
end
end
toc
Go to the top of the page
 
+Quote Post

Posts in this topic
- Strungest   Mathematical Analysis of Daka   Oct 6 2012, 05:36 PM
- - Yerameyahu   Stand back, he's using MATH!   Oct 6 2012, 05:54 PM
|- - CanRay   QUOTE (Yerameyahu @ Oct 6 2012, 12:54 PM)...   Oct 6 2012, 07:38 PM
- - Cabral   You might want to put the code in spoiler tags. It...   Oct 6 2012, 06:07 PM
|- - Strungest   QUOTE (Cabral @ Oct 6 2012, 07:07 PM) You...   Oct 6 2012, 06:21 PM
- - UmaroVI   One point about armor - the thing with it is that ...   Oct 6 2012, 06:22 PM
- - Yerameyahu   Well, that's the reason that everyone uses a c...   Oct 6 2012, 06:28 PM
- - UmaroVI   I was just pointing out that the reason armor seem...   Oct 6 2012, 06:34 PM
- - Ryu   Electing a Wide burst is sensible if an agile oppo...   Oct 6 2012, 06:54 PM
- - Strungest   QUOTE (UmaroVI @ Oct 6 2012, 07:34 PM) I ...   Oct 6 2012, 07:30 PM
|- - thorya   QUOTE (Strungest @ Oct 6 2012, 03:30 PM) ...   Oct 6 2012, 08:40 PM
||- - Strungest   QUOTE (thorya @ Oct 6 2012, 09:40 PM) Exc...   Oct 6 2012, 09:02 PM
|- - Lantzer   QUOTE (Strungest @ Oct 6 2012, 07:30 PM) ...   Oct 7 2012, 12:26 AM
|- - Draco18s   QUOTE (Lantzer @ Oct 6 2012, 08:26 PM) Wh...   Oct 7 2012, 12:45 AM
- - Dolanar   20 is not uncommon for an Adept specialist   Oct 7 2012, 01:27 AM
- - Yerameyahu   How common is that?   Oct 7 2012, 01:39 AM
- - Falconer   His analysis is seriously flawed... you only do mo...   Oct 7 2012, 06:51 AM
- - Jaid   as has been pointed out, wide bursts can help impr...   Oct 7 2012, 07:07 AM
- - Ryu   Your general conclusion is based on a high attack ...   Oct 7 2012, 07:36 AM
- - Jaid   agi 5 skill 5 is not exactly a standard guard. for...   Oct 7 2012, 06:27 PM
|- - Ryu   QUOTE (Jaid @ Oct 7 2012, 08:27 PM) agi 5...   Oct 8 2012, 06:18 PM
- - Strungest   QUOTE (Draco18s @ Oct 7 2012, 01:45 AM) D...   Oct 7 2012, 06:30 PM
|- - Tymeaus Jalynsfein   QUOTE (Strungest @ Oct 7 2012, 12:30 PM) ...   Oct 8 2012, 02:01 PM
|- - ZeroPoint   QUOTE (Tymeaus Jalynsfein @ Oct 8 2012, 09...   Oct 8 2012, 02:32 PM
|- - Tymeaus Jalynsfein   QUOTE (ZeroPoint @ Oct 8 2012, 08:32 AM) ...   Oct 8 2012, 02:43 PM
- - Yerameyahu   They both 'make sense'. It's just a qu...   Oct 8 2012, 03:42 PM
|- - Tymeaus Jalynsfein   QUOTE (Yerameyahu @ Oct 8 2012, 09:42 AM)...   Oct 8 2012, 03:51 PM
|- - Draco18s   QUOTE (Tymeaus Jalynsfein @ Oct 8 2012, 11...   Oct 8 2012, 04:08 PM
|- - Draco18s   QUOTE (Tymeaus Jalynsfein @ Oct 8 2012, 11...   Oct 8 2012, 04:08 PM
|- - Tymeaus Jalynsfein   QUOTE (Draco18s @ Oct 8 2012, 10:08 AM) H...   Oct 8 2012, 04:22 PM
- - ZeroPoint   First, that was Yerameyahu that posted that, not D...   Oct 8 2012, 04:09 PM
|- - Tymeaus Jalynsfein   QUOTE (ZeroPoint @ Oct 8 2012, 10:09 AM) ...   Oct 8 2012, 04:23 PM
||- - Aerospider   QUOTE (Tymeaus Jalynsfein @ Oct 8 2012, 05...   Oct 9 2012, 05:06 PM
||- - Tymeaus Jalynsfein   QUOTE (Aerospider @ Oct 9 2012, 10:06 AM)...   Oct 9 2012, 05:48 PM
|- - Manunancy   QUOTE (ZeroPoint @ Oct 8 2012, 06:09 PM) ...   Oct 9 2012, 05:45 AM
- - Yerameyahu   I think I pretty clearly mentioned the glitches. I...   Oct 8 2012, 04:50 PM
|- - Tymeaus Jalynsfein   QUOTE (Yerameyahu @ Oct 8 2012, 09:50 AM)...   Oct 8 2012, 05:26 PM
- - Xenefungus   I think every guard worth his name should have at ...   Oct 8 2012, 07:40 PM
|- - Jaid   QUOTE (Xenefungus @ Oct 8 2012, 03:40 PM)...   Oct 9 2012, 12:10 AM
- - Strungest   QUOTE (Tymeaus Jalynsfein @ Oct 8 2012, 03...   Oct 8 2012, 08:15 PM
- - Midas   I think that it is fair to say that different GMs ...   Oct 9 2012, 06:03 AM
- - Blade   QUOTE ("legal text on boxes of explosive ammo...   Oct 9 2012, 09:36 AM
- - Aerospider   Not to derail the thread, but the main mechanical ...   Oct 9 2012, 05:21 PM
- - Yerameyahu   QUOTE It might be near you, it might obscure half ...   Oct 9 2012, 06:21 PM
|- - Aerospider   QUOTE (Yerameyahu @ Oct 9 2012, 07:21 PM)...   Oct 9 2012, 07:48 PM
- - Yerameyahu   If 'extreme cases' means 'whenever we...   Oct 9 2012, 08:07 PM
|- - Aerospider   QUOTE (Yerameyahu @ Oct 9 2012, 09:07 PM)...   Oct 10 2012, 01:15 PM
|- - Draco18s   QUOTE (Aerospider @ Oct 10 2012, 09:15 AM...   Oct 10 2012, 03:32 PM
- - Strungest   I now have 16+ thousand images showing values for ...   Oct 9 2012, 10:44 PM
- - Yerameyahu   Dropbox. QUOTE A glitch isn't necessarily a j...   Oct 9 2012, 11:35 PM
- - Yerameyahu   Ah, in that case I just disagree, Aerospider. Cove...   Oct 10 2012, 04:34 PM
|- - Aerospider   QUOTE (Yerameyahu @ Oct 10 2012, 05:34 PM...   Oct 10 2012, 07:09 PM
- - Yerameyahu   I halfway wish glitch chance *was* a separate cons...   Oct 10 2012, 09:15 PM
|- - UmaroVI   QUOTE (Yerameyahu @ Oct 10 2012, 05:15 PM...   Oct 10 2012, 10:56 PM
- - Strungest   https://docs.google.com/open?id=0B-ccVvfxapeAdnBDT...   Oct 10 2012, 09:37 PM
- - Yerameyahu   Yeah, though still a lot to keep track of. Hm.   Oct 11 2012, 05:12 PM
- - Ryu   One could throw two differently colored dice and h...   Oct 11 2012, 08:35 PM
- - Draco18s   QUOTE (Ryu @ Oct 11 2012, 04:35 PM) One c...   Oct 11 2012, 09:09 PM


Reply to this topicStart new topic

 



RSS Lo-Fi Version Time is now: 2nd July 2025 - 01:46 AM

Topps, Inc has sole ownership of the names, logo, artwork, marks, photographs, sounds, audio, video and/or any proprietary material used in connection with the game Shadowrun. Topps, Inc has granted permission to the Dumpshock Forums to use such names, logos, artwork, marks and/or any proprietary materials for promotional and informational purposes on its website but does not endorse, and is not affiliated with the Dumpshock Forums in any official capacity whatsoever.