clear %a damage plot for Knaughty, showing the damage of each ability. %uses the 5V+2C spec advanced_init gly=1; %V glyph spec=0; %1V+3C gearset=0; %Default gear set advanced_config(gly,spec,gearset); stats_recalc ability_recalc ability_summary %pick out the parts of the damage summary we want names=dmg_labels; dmg=zeros(length(dmg_labels),2); dmg(:,1)=dmg_vals; dmgr(:,1)=dmg_raw; %now, to get the glyphed Judgement numbers, recalculate with VJ glyphs advanced_config(8,spec,gearset); stats_recalc ability_recalc ability_summary dmg(4,2)=dmg_vals(4); %fix JoV dmgr(4,2)=dmg_raw(4); %glyphed Avenger's Shield. VA for this advanced_config(12,spec,gearset); stats_recalc ability_recalc ability_summary dmg(7,2)=dmg_vals(7); dmgr(7,2)=dmg_raw(7); %incorporate seal procs into damage jj=[1:4 7:8 12:13 15]; dmgs=dmg(jj,:); thrs=dmg(jj,:).*repmat([Th.*ones(size(dmgs)-1,1);Tp],1,2); procs=[1 2 4 length(dmgs)]; %shor, hotr, jud, and melee get SoV procs dmgs(procs)=dmgs(procs)+dmg(9,1); thrs(procs)=thrs(procs)+dmg(9,1).*Th; dmgs(4,2)=dmgs(4,2)+dmg(9,1); %also fix judgement's glyphed section thrs(4,2)=thrs(4,2)+dmg(9,1).*Th; %effective cooldowns in a 969 rotation for dps/tps calculation rotation_969 sov_speed=1./(1./player_swing+1./t_hotr+1./t_jud+1./t_shor); sor_speed=1./(1./player_swing+1./t_hotr+2./t_jud+1./t_shor); cooldowns=[t_shor; t_hotr; t_cons; t_jud; t_jud; t_jud; 36; 6; sov_speed; sov_speed; sor_speed; 15; 1./avg_HS_pps; 15; player_swing]; %modifier for converting dmg/dps to threat/tps threatmod=repmat([Th.*ones(size(dmg,1)-1,1);Tp],1,2); kk=[1:4 7:9 12:13 15]; % kk=1:15; dmgplot=dmg(kk,:);dmgplot([4 5],2)=dmg([kk(4) kk(5)],2)-dmg([kk(4) kk(5)],1); dmgs_plot=dmgs;dmgs_plot(4:5,2)=dmgs(4:5,2)-dmgs(4:5,1); thrs_plot=thrs;thrs_plot(4:5,2)=thrs(4:5,2)-thrs(4:5,1); %dps variable dps=dmg./repmat(cooldowns,1,2); dpsplot=dmgplot./repmat(cooldowns(kk),1,2); dmgs_dps=dmgs./repmat(cooldowns(jj),1,2); thrs_tps=thrs./repmat(cooldowns(jj),1,2); dmgs_dpsplot=dmgs_plot./repmat(cooldowns(jj),1,2); thrs_tpsplot=thrs_plot./repmat(cooldowns(jj),1,2); %plot figure(20) set(gcf,'Position',[360 228 600 300]) bar20=bar(dmgplot,'BarWidth',0.5,'BarLayout','stacked'); set(bar20(2),'FaceColor',[0.749 0.749 0]); xlim([0.5 10.5]) set(gca,'XTickLabel',names(kk)) legend('Unglyphed','Glyphed','Location','NorthWest') xlabel('Ability') ylabel('Damage') figure(21) set(gcf,'Position',[360 228 600 300]) bar21=bar(dpsplot,'BarWidth',0.5,'BarLayout','stacked'); set(bar21(2),'FaceColor',[0.749 0.749 0]); xlim([0.5 10.5]) set(gca,'XTickLabel',names(kk)) leg1=legend('Unglyphed','Glyphed'); set(leg1,'Position',[0.5608 0.7344 0.1983 0.14]) xlabel('Ability') ylabel('DPS') %for threat, we just multiply the dmg or dps variable by the threat %modifier figure(30) set(gcf,'Position',[360 228 600 300]) bar30=bar(dmgplot.*threatmod(kk,:),'BarWidth',0.5,'BarLayout','stacked'); set(bar30(2),'FaceColor',[0.749 0.749 0]); xlim([0.5 10.5]) set(gca,'XTickLabel',names(kk)) legend('Unglyphed','Glyphed','Location','NorthWest') xlabel('Ability') ylabel('Threat') figure(31) set(gcf,'Position',[360 228 600 300]) bar31=bar(dpsplot.*threatmod(kk,:),'BarWidth',0.5,'BarLayout','stacked'); set(bar31(2),'FaceColor',[0.749 0.749 0]); xlim([0.5 10.5]) set(gca,'XTickLabel',names(kk)) leg1=legend('Unglyphed','Glyphed','Location','NorthEast'); % set(leg1,'Position',[0.5608 0.7344 0.1983 0.14]) xlabel('Ability') ylabel('TPS') figure(40) set(gcf,'Position',[360 228 600 300]) bar40=bar(dmgs_plot,'BarWidth',0.5,'BarLayout','stacked'); set(bar40(2),'FaceColor',[0.749 0.749 0]); % xlim([0.5 10.5]) set(gca,'XTickLabel',names(jj)) legend('Unglyphed','Glyphed','Location','NorthEast') xlabel('Ability') ylabel('Damage (including SoV procs)') figure(41) set(gcf,'Position',[360 228 600 300]) bar41=bar(thrs_tpsplot,'BarWidth',0.5,'BarLayout','stacked'); set(bar41(2),'FaceColor',[0.749 0.749 0]); % xlim([0.5 10.5]) set(gca,'XTickLabel',names(jj)) legend('Unglyphed','Glyphed','Location','NorthEast') xlabel('Ability') ylabel('TPS (including SoV procs)') %generate pretty tables pad11=repmat(' ',length(names),1); pad12=repmat(' ',length(names),1); header1=['Ability Raw Dmg. Net Dmg. Glyphed Net Threat Glyphed']; pt_dmg=[char(names) pad11 char(int2str(dmgr(:,1))) pad11 char(int2str(dmg(:,1))) pad11 char(int2str(dmg(:,2))) pad11 char(int2str(round(dmg(:,1).*threatmod(:,1)))) pad11 char(int2str(round(dmg(:,2).*threatmod(:,1)))) pad12]; pt_dmg=[pt_dmg repmat(' ',length(names),length(header1)-length(pt_dmg))]; pt_dmg=[header1; pt_dmg]; pad21=repmat(' ',length(names),1); pad22=repmat(' ',length(names),1); header2=['Ability DPS Glyphed TPS Glyphed']; pt_dps=[char(names) pad21 char(int2str(dps(:,1))) pad21 char(int2str(dps(:,2))) pad21 char(int2str(round(dps(:,1).*threatmod(:,1)))) pad21 char(int2str(round(dps(:,2).*threatmod(:,1)))) pad22]; pt_dps=[header2; pt_dps]; pad31=repmat(' ',length(names(jj)),1); header3=['Ability Damage Glyphed TPS Glyphed ']; pt_dmgs=[char(names(jj)) pad31 char(int2str(dmgs(:,1))) pad31 char(int2str(dmgs(:,2))) pad31 char(int2str(round(thrs_tps(:,1)))) pad31 char(int2str(round(thrs_tps(:,2))))]; pad32=repmat(' ',length(names(jj)),length(header3)-size(pt_dmgs,2)); pt_dmgs=[pt_dmgs pad32]; pt_dmgs=[header3; pt_dmgs]; pt_dmg pt_dps pt_dmgs %% Mongoose Uptime avoid=[0 8+6.5+14]./100; miss=[0 8]./100; p1=(1-avoid);p2=(1-avoid).^2;p3=1-miss; s=weapon_base_speed/60; %# attacks in 15 seconds for each ability type n1=15./player_swing; %auto-attack n2=15./6; %HotR n3=15./9; %Judgement n4=15./6; %ShoR % num_att_in_15_sec = 15.*((1-avoid).*((1+(1-avoid))./player_swing + (1+(1-avoid))./6) + (1-miss)./9 + (1-avoid)./6) %uptime = 1-product of chances that each ability does not proc % uptime=1-(1-1.6/60).^num_att_in_15_sec mong_up_old=1-((1-p1.*s).^(n1+n2) .* (1-p2.*s).^(n1+n2) .* (1-p3.*s).^(3.*n3)) mong_up_new=1-((1-p1.*s).^(n1+n2) .* (1-p3.*s).^(3.*n3)) bw_up_old = 1-((1-p1.*s).^(10./player_swing + 10./t_hotr) .* (1-p2.*s).^(10./player_swing + 10./t_hotr) .* (1-p3.*s).^(10./t_jud)) bw_up_new = 1-((1-p1.*s).^(10./player_swing + 10./t_hotr) .* (1-p3.*s).^(3.*10./t_jud)) % %plot of DPS for different rotation/glyph combos with 5V+2C. Done by hand % %in MATLAB % dtps=[3329 8344; 3360 8432; 3389 8512; 3399 8539; 3415 8583; 3492 8796];x_labels={'JsA()';'JsE()';'JsAE()';'JsE(JE)';'JsA(JA)';'JsAE(AE)'}; % figure(30) % bar(1:length(dtps),dtps(:,2)) % set(gca,'XTickLabel',x_labels) % ylim([8200 8900]) % xlabel('Rotation/glyph') % ylabel('TPS') % title('TPS for 5V+2C w/ SubaT8 gear') % % gdtps=[17 49; 26 71; 30 82; 3 109; 73 202];glabels={'J (blood)', 'J (veng)', 'E', 'V (veng)', 'A'}; % figure(31) % bar(1:length(glabels),gdtps(:,2)) % set(gca,'XTickLabel',glabels) % xlabel('Glyph (seal if applicable)') % ylabel('TPS Boost') % title('TPS boost of glyphs - E and A assume 18s and 36s substitutions')