我正在尝试制作一个约会模拟游戏,我想做的一件事就是在游戏中间点击鼠标,立即将字符串写完整。
newman run Collection.json --delay-request 2000 --timeout-request 240000 -e env.json -d data.json -r cli,html -k -n 1 --color on
data file:
[
{"Url": "12:9002"},
{"Url": "13:9002"}
]
为此,我想测量bbcode中的可见字符;但我只是不知道该怎么做。
答案 0 :(得分:0)
没关系,我在这里想通了。
func _input(event):
if event is InputEventMouseButton:
if get_visible_characters() > get_total_character_count():
if page < dialog.size()-1:
page += 1
set_bbcode(dialog[page])
set_visible_characters(0)
if event is InputEventMouseButton:
if get_visible_characters() < get_total_character_count():
set_visible_characters(get_total_character_count())
只需在已存在的输入事件中放入另一个事件类型输入,然后检查get_visible_characters是否小于get_total_character_count。如果为true,则将可见字符设置为总字符数。