2024-12-12 12:57:04 +00:00
|
|
|
#!/usr/bin/env python3
|
2024-12-13 17:46:59 +00:00
|
|
|
import logging
|
2024-12-12 12:57:04 +00:00
|
|
|
|
2024-12-13 17:46:59 +00:00
|
|
|
import valconomy
|
2024-12-15 17:30:08 +00:00
|
|
|
from valconomy import ValorantPlayerInfo, RiotPlayerInfo, EconomyDecision
|
2024-12-12 12:57:04 +00:00
|
|
|
|
|
|
|
def main():
|
2024-12-13 17:46:59 +00:00
|
|
|
logging.basicConfig(
|
|
|
|
format='%(asctime)s %(name)s %(levelname)s %(message)s', level=logging.INFO)
|
2024-12-12 12:57:04 +00:00
|
|
|
|
2024-12-13 17:46:59 +00:00
|
|
|
h = valconomy.HIDValconomyHandler()
|
2024-12-12 12:57:04 +00:00
|
|
|
try:
|
2024-12-13 17:46:59 +00:00
|
|
|
h.menu(None, False)
|
|
|
|
h.none()
|
2024-12-14 16:26:34 +00:00
|
|
|
h.queue_start(RiotPlayerInfo.dummy(
|
|
|
|
valorant=ValorantPlayerInfo()))
|
2024-12-13 17:46:59 +00:00
|
|
|
h.menu(None, True)
|
|
|
|
h.idle(None)
|
2024-12-14 16:26:34 +00:00
|
|
|
h.queue_start(RiotPlayerInfo.dummy(
|
|
|
|
valorant=ValorantPlayerInfo(queue_type='unrated', is_party_owner=True)))
|
2024-12-15 12:05:36 +00:00
|
|
|
h.match_found(RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(queue_type='premier-seasonmatch')))
|
2024-12-15 13:57:31 +00:00
|
|
|
h.pregame(RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(map='/Game/Maps/Bonsai/Bonsai')))
|
2024-12-15 12:05:36 +00:00
|
|
|
h.match_found(RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo()))
|
2024-12-15 13:57:31 +00:00
|
|
|
h.pregame(RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo()))
|
2024-12-15 14:37:12 +00:00
|
|
|
h.game_generic(RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(queue_type='ggteam')))
|
2024-12-15 15:36:52 +00:00
|
|
|
h.game_start(None)
|
|
|
|
h.game_over(None, False)
|
|
|
|
h.game_over(None, True)
|
2024-12-15 17:30:08 +00:00
|
|
|
h.round_start(
|
|
|
|
RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(score=3, enemy_score=7)),
|
|
|
|
won=True, economy=EconomyDecision.SAVE)
|
|
|
|
h.round_start(
|
|
|
|
RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(score=10, enemy_score=2)),
|
|
|
|
won=False, economy=EconomyDecision.BUY)
|
|
|
|
h.round_start(
|
|
|
|
RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(score=10, enemy_score=2)),
|
|
|
|
won=None, economy=EconomyDecision.MATCH_TEAM)
|
|
|
|
h.round_start(
|
|
|
|
RiotPlayerInfo.dummy(valorant=ValorantPlayerInfo(score=2, enemy_score=0)),
|
|
|
|
won=True, economy=EconomyDecision.BONUS)
|
2024-12-13 17:46:59 +00:00
|
|
|
|
|
|
|
h.service()
|
2024-12-12 12:57:04 +00:00
|
|
|
finally:
|
2024-12-13 17:46:59 +00:00
|
|
|
h.close()
|
2024-12-12 12:57:04 +00:00
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
main()
|