Hide keyboard shortcuts

Hot-keys on this page

r m x p   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

1# -*- coding: utf-8 -*- 

2from __future__ import annotations 

3 

4# -- stdlib -- 

5# -- third party -- 

6# -- own -- 

7from thb import characters 

8from thb.cards.base import Skill 

9from thb.meta.common import ui_meta 

10 

11 

12# -- code -- 

13@ui_meta(characters.sp_aya.WindWalk) 

14class WindWalk: 

15 # Skill 

16 name = '疾走' 

17 description = '出牌阶段,你可以弃置一张牌,然后摸一张牌,对你上一张使用的牌的目标角色(或之一)使用之并重复此流程,否则结束你的回合。' 

18 

19 def clickable(self): 

20 if not self.my_turn(): 

21 return False 

22 

23 me = self.me 

24 return bool(me.cards or me.showncards or me.equips) 

25 

26 def is_action_valid(self, sk, tl): 

27 acards = sk.associated_cards 

28 if (not acards) or len(acards) != 1: 

29 return (False, '请选择一张牌') 

30 

31 card = acards[0] 

32 

33 if card.resides_in.type not in ('cards', 'showncards', 'equips'): 

34 return (False, '请选择一张牌!') 

35 

36 if card.is_card(Skill): 

37 return (False, '你不可以像这样组合技能') 

38 

39 return (True, '疾走') 

40 

41 def effect_string(self, act): 

42 return '唯快不破!|G【%s】|r弃置了%s,开始加速追击!' % ( 

43 act.source.ui_meta.name, 

44 self.card_desc(act.card), 

45 ) 

46 

47 def sound_effect(self, act): 

48 return 'thb-cv-sp_aya_windwalk' 

49 

50 

51@ui_meta(characters.sp_aya.WindWalkLaunch) 

52class WindWalkLaunch: 

53 pass 

54 

55 

56@ui_meta(characters.sp_aya.WindWalkAction) 

57class WindWalkAction: 

58 idle_prompt = '疾走:请使用摸到的牌(否则结束出牌并跳过弃牌阶段)' 

59 

60 def choose_card_text(self, act, cards): 

61 if not act.cond(cards): 

62 return False, '疾走:只能使用摸到的牌(或者结束)' 

63 else: 

64 return True, '不会显示……' 

65 

66 

67@ui_meta(characters.sp_aya.WindWalkSkipAction) 

68class WindWalkSkipAction: 

69 def effect_string_before(self, act): 

70 return '|G【%s】|r放弃了追击。' % act.target.ui_meta.name 

71 

72 def sound_effect(self, act): 

73 return 'thb-cv-sp_aya_windwalk_stop' 

74 

75 

76@ui_meta(characters.sp_aya.WindWalkTargetLimit) 

77class WindWalkTargetLimit: 

78 # target_independent = True 

79 shootdown_message = '你只能对上一张使用的牌的目标角色(或之一)使用。' 

80 

81 

82@ui_meta(characters.sp_aya.DominanceHandler) 

83class DominanceHandler: 

84 choose_option_prompt = '你要发动【风靡】吗?' 

85 choose_option_buttons = (('发动', True), ('不发动', False)) 

86 

87 

88@ui_meta(characters.sp_aya.DominanceAction) 

89class DominanceAction: 

90 def effect_string_before(self, act): 

91 return '|G【%s】|r成功地了搞了个大新闻!' % ( 

92 act.target.ui_meta.name, 

93 ) 

94 

95 def sound_effect(self, act): 

96 return 'thb-cv-sp_aya_dominance' 

97 

98 

99@ui_meta(characters.sp_aya.Dominance) 

100class Dominance: 

101 # Skill 

102 name = '风靡' 

103 description = '回合结束时,若你本回合的出牌阶段使用了四种花色的牌,你可执行一个额外的回合。' 

104 

105 

106@ui_meta(characters.sp_aya.SpAya) 

107class SpAya: 

108 # Character 

109 name = 'SP射命丸文' 

110 title = '剑圣是谁有我快吗' 

111 designer = '吹风姬' 

112 illustrator = '躲猫' 

113 cv = '君寻' 

114 

115 port_image = 'thb-portrait-sp_aya' 

116 figure_image = 'thb-figure-sp_aya' 

117 miss_sound_effect = 'thb-cv-sp_aya_miss'