Skip to content

Commit

Permalink
new:窗口添加装备版本、增幅版本显示
Browse files Browse the repository at this point in the history
  • Loading branch information
wxh0402 committed Dec 31, 2020
1 parent 18e4863 commit ca1d13e
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 22 deletions.
25 changes: 7 additions & 18 deletions PublicReference/base.py
Expand Up @@ -7,16 +7,6 @@
from PublicReference.choise.细节选项 import *
from PublicReference.common import *

装备版本 = "GF"
装备增幅版本 = "GF"

with open("ResourceFiles\\Config\\release_version.json") as fp:
versionInfo = json.load(fp)
装备版本 = versionInfo['EquipmentVersion'].upper()
装备增幅版本 = versionInfo['ZFVersion'].upper()
fp.close()


class 技能:
名称 = ''
备注 = ''
Expand Down Expand Up @@ -94,8 +84,6 @@ class 被动技能(技能):

class 角色属性(属性):

版本 = 装备版本
增幅版本 = 装备增幅版本
职业分类 = '输出'
主BUFF = 1.0
系统奶 = False
Expand Down Expand Up @@ -735,10 +723,11 @@ def 自适应计算(self):

if self.希洛克武器词条 == 0:
self.词条提升率 = [0] * 6
return
# 残香第一词条-10%
self.词条选择.clear()
self.词条选择.append(self.词条提升率计算([0, 1, 2, 3, 4, 5], [0.10] * 6, 1))
# return
# 残香第一词条-10%
else:
self.词条选择.clear()
self.词条选择.append(self.词条提升率计算([0, 1, 2, 3, 4, 5], [0.10] * 6, 1))

# 宠物红色装备词条-7~8%
if self.自适应选项[0] != 0: #宠物
Expand All @@ -752,7 +741,7 @@ def 自适应计算(self):
self.自适应描述[1] = '{}%{}'.format(5, 词条属性列表[index].描述)

# 残香第二词条-5%
if self.武器词条触发 == 1:
if self.希洛克武器词条 == 1 and self.武器词条触发 == 1:
self.词条选择.append(self.词条提升率计算([0, 1, 2, 3, 4, 5], [0.05] * 6))


Expand Down Expand Up @@ -3242,7 +3231,7 @@ def 输出界面(self, index, name = ''):
temp += '详细数据'
else:
temp += name
temp += '(最多显示前18个技能)'
temp += '(最多显示前18个技能)' + "装备版本:"+self.角色属性A.版本 + " 增幅版本:" + self.角色属性A.增幅版本
输出窗口.setWindowTitle(temp)
输出窗口.setWindowIcon(self.icon)
QLabel(输出窗口).setPixmap(self.输出背景图片)
Expand Down
5 changes: 3 additions & 2 deletions PublicReference/base_buff.py
Expand Up @@ -6,6 +6,7 @@
from PublicReference.choise.选项设置_buff import *
from PublicReference.common import *


class 技能:
名称 = ''
备注 = ''
Expand Down Expand Up @@ -298,7 +299,7 @@ def 装备基础(self):
for i in range(0,12):
temp = 装备列表[装备序号[self.装备栏[i]]]
if self.是否增幅[i] and temp.所属套装 != '智慧产物':
x = 增幅计算(temp.等级, temp.品质,self.强化等级[i],temp.增幅版本)
x = 增幅计算(temp.等级, temp.品质,self.强化等级[i],self.增幅版本)
if '智力' in self.类型:
self.智力 += x
if '体力' in self.类型:
Expand Down Expand Up @@ -2215,7 +2216,7 @@ def 输出界面(self, index, name = ''):
temp += '详细数据'
else:
temp += name
temp += '(最多显示前18个技能)'
temp += '(最多显示前18个技能)'+"装备版本:"+self.角色属性A.版本 + " 增幅版本:" + self.角色属性A.增幅版本
输出窗口.setWindowTitle(temp)
输出窗口.setWindowIcon(self.icon)
QLabel(输出窗口).setPixmap(self.输出背景图片)
Expand Down
7 changes: 5 additions & 2 deletions PublicReference/common.py
@@ -1,9 +1,11 @@
from PublicReference.equipment.equ_list import *

装备版本 = "GF"
装备增幅版本 = "GF"

with open("ResourceFiles\\Config\\release_version.json") as fp:
versionInfo = json.load(fp)
装备版本 = versionInfo['EquipmentVersion'].upper()
装备增幅版本 = versionInfo['ZFVersion'].upper()
fp.close()

Expand All @@ -12,6 +14,7 @@ class 属性():
实际名称 = ''
角色 = ''
职业 = ''
版本 = 装备版本
增幅版本 = 装备增幅版本

武器选项 = []
Expand Down Expand Up @@ -243,7 +246,7 @@ def 窗口属性输入(self):
pass

def 界面(self):
self.setWindowTitle(self.角色属性A.实际名称 + "搭配计算器&17173DNF专区 (点击标签栏按钮切换界面)")
self.setWindowTitle(self.角色属性A.实际名称 + "搭配计算器&17173DNF专区 (点击标签栏按钮切换界面)"+"装备版本:"+self.角色属性A.版本 + " 增幅版本:" + self.角色属性A.增幅版本)
self.icon = QIcon('./ResourceFiles/'+self.角色属性A.实际名称 + '/技能/BUFF.png')
self.setWindowIcon(self.icon)
self.setStyleSheet('''QToolTip {
Expand Down Expand Up @@ -1368,7 +1371,7 @@ def 排行界面(self, 筛选 = {}, 显示序号 = [x for x in range(100)]):
滚动排行.setMinimumSize(630,530)
滚动排行.setMaximumSize(630,1230)
if len(筛选) == 0:
滚动排行.setWindowTitle('当前模板配装排行(点击数字查看详情)')
滚动排行.setWindowTitle('当前模板配装排行(点击数字查看详情)'+"装备版本:"+self.角色属性A.版本 + " 增幅版本:" + self.角色属性A.增幅版本)
else:
temp = ''
for name in 筛选.values():
Expand Down

0 comments on commit ca1d13e

Please sign in to comment.