milestoneSegment.py (1692B)
1 #Embedded file name: C:\BuildAgent\work\20d73f1b24eed06e\eve\release\V24.01\eve\client\script\ui\skillPlan\milestone\milestoneSegment.py 2 import trinity 3 from carbonui import uiconst 4 from carbonui.uianimations import animations 5 from eve.client.script.ui import eveColor 6 from eve.client.script.ui.control.donutSegment import DonutSegment 7 from eve.client.script.ui.skillPlan.milestone.milestoneConst import TRANSFORM_RADIUS 8 9 class MilestoneSegment(DonutSegment): 10 default_textureWidth = 43.0 11 default_spriteEffect = trinity.TR2_SFX_COPY 12 default_radius = TRANSFORM_RADIUS 13 default_state = uiconst.UI_DISABLED 14 default_colorEnd = eveColor.WHITE 15 16 def ApplyAttributes(self, attributes): 17 super(MilestoneSegment, self).ApplyAttributes(attributes) 18 19 def GetColor(self): 20 return self.color 21 22 def SetStartEnd(self, start = None, end = None, animate = False): 23 duration = 1.0 24 if start is not None: 25 if animate: 26 animations.MorphScalar(self, 'start', self.start, start, duration=duration) 27 else: 28 self.start = start 29 if end is not None: 30 if animate: 31 animations.MorphScalar(self, 'end', self.end, end, duration=duration) 32 else: 33 self.end = end 34 35 36 class ProgressSegment(MilestoneSegment): 37 default_color = eveColor.WHITE 38 39 40 class InTrainingSegment(MilestoneSegment): 41 default_color = eveColor.CRYO_BLUE 42 43 44 class SkillsMissingSegment(MilestoneSegment): 45 46 def ApplyAttributes(self, attributes): 47 self.highlightNotInTraining = attributes.highlightNotInTraining 48 super(SkillsMissingSegment, self).ApplyAttributes(attributes)