Coverage for thb/meta/characters/remilia.py : 73%
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
4# -- stdlib --
5import random
7# -- third party --
8# -- own --
9from thb import characters
10from thb.meta.common import ui_meta
13# -- code --
14@ui_meta(characters.remilia.SpearTheGungnir)
15class SpearTheGungnir:
16 # Skill
17 name = '神枪'
18 description = (
19 '满足下列条件之一时,你可以令你的|G弹幕|r不能被响应:\n'
20 '|B|R>> |r目标角色的体力值 大于 你的体力值。\n'
21 '|B|R>> |r目标角色的手牌数 小于 你的手牌数。'
22 )
25@ui_meta(characters.remilia.SpearTheGungnirAction)
26class SpearTheGungnirAction:
27 def effect_string(self, act):
28 return '|G【%s】|r举起右手,将|G弹幕|r汇聚成一把命运之矛,向|G【%s】|r掷去!' % (
29 act.source.ui_meta.name,
30 act.target.ui_meta.name,
31 )
33 def sound_effect(self, act):
34 return 'thb-cv-remilia_stg'
37@ui_meta(characters.remilia.SpearTheGungnirHandler)
38class SpearTheGungnirHandler:
39 # choose_option
40 choose_option_buttons = (('发动', True), ('不发动', False))
41 choose_option_prompt = '你要发动【神枪】吗?'
44@ui_meta(characters.remilia.VampireKiss)
45class VampireKiss:
46 # Skill
47 name = '红魔之吻'
48 description = '|B锁定技|r,你使用红色|G弹幕|r时无距离限制。当你使用红色|G弹幕|r对一名其他角色造成伤害后,你回复1点体力。'
51@ui_meta(characters.remilia.VampireKissAction)
52class VampireKissAction:
53 def effect_string_before(self, act):
54 return '|G【%s】|r:“B型血,赞!”' % (
55 act.source.ui_meta.name
56 )
58 def sound_effect(self, act):
59 return 'thb-cv-remilia_vampirekiss'
62@ui_meta(characters.remilia.ScarletMistAttackLimit)
63class ScarletMistAttackLimit:
64 target_independent = False
65 shootdown_message = '红雾:你只能对距离1的角色使用弹幕'
68@ui_meta(characters.remilia.ScarletMistAction)
69class ScarletMistAction:
70 def effect_string(self, act):
71 src = act.source
72 tl = list(act.target_list)
73 try:
74 tl.remove(src)
75 except Exception:
76 pass
78 return '|G【%s】|r释放出了|G红雾|r,威严爆表!%s流了鼻血!' % (
79 src.ui_meta.name,
80 '、'.join(['|G【%s】|r' % p.ui_meta.name for p in tl]),
81 )
83 def sound_effect(self, act):
84 return random.choice([
85 'thb-cv-remilia_scarletmist1',
86 'thb-cv-remilia_scarletmist2',
87 ])
90@ui_meta(characters.remilia.ScarletMistEndAction)
91class ScarletMistEndAction:
92 def effect_string(self, act):
93 return '|G红雾|r结束了。'
96@ui_meta(characters.remilia.ScarletMist)
97class ScarletMist:
98 name = '红雾'
99 description = (
100 '|BBOSS技|r,|B限定技|r,出牌阶段,你可以选择至多X名其他角色(X为存活道中数量),直到你的下个回合开始阶段,所有角色受到以下影响:\n'
101 '|B|R>> |r你与被选择的角色使用|G弹幕|r时无视距离,且使用|G弹幕|r造成伤害后回复等量的体力。\n'
102 '|B|R>> |r其他角色使用|G弹幕|r时只能指定距离为1的目标。'
103 )
105 def clickable(self):
106 me = self.me
107 return self.my_turn() and not me.tags['scarlet_mist_used']
109 def is_action_valid(self, sk, tl):
110 if sk.associated_cards:
111 return (False, '红雾:请不要选择牌!')
113 if not tl:
114 return (False, '红雾:选择目标')
116 return (True, '红雾:选择这些角色获得增益效果')
119@ui_meta(characters.remilia.Remilia)
120class Remilia:
121 # Character
122 name = '蕾米莉亚'
123 title = '永远幼小的红月'
124 illustrator = '小D@星の妄想乡'
125 cv = 'VV'
127 port_image = 'thb-portrait-remilia'
128 figure_image = 'thb-figure-remilia'
129 miss_sound_effect = 'thb-cv-remilia_miss'