diff options
author | Jesusaves <cpntb1@ymail.com> | 2020-12-24 20:25:57 -0300 |
---|---|---|
committer | Jesusaves <cpntb1@ymail.com> | 2020-12-24 20:25:57 -0300 |
commit | 2577c43010c346470fca09d415b2b2a1d6fe2003 (patch) | |
tree | b7be98a49c7a306be467dd6bbfd8b75284c69040 /game/battle.rpy | |
parent | 8e3fd3eb61c82070bff74135fb45c4d275946fc2 (diff) | |
download | client-2577c43010c346470fca09d415b2b2a1d6fe2003.tar.gz client-2577c43010c346470fca09d415b2b2a1d6fe2003.tar.bz2 client-2577c43010c346470fca09d415b2b2a1d6fe2003.tar.xz client-2577c43010c346470fca09d415b2b2a1d6fe2003.zip |
Change battle logic to make it a bit more seamless to user.
And hopefully, less error prone?
Diffstat (limited to 'game/battle.rpy')
-rw-r--r-- | game/battle.rpy | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/game/battle.rpy b/game/battle.rpy index f41886c..44a3aba 100644 --- a/game/battle.rpy +++ b/game/battle.rpy @@ -38,6 +38,7 @@ label combat: # TODO: Swap units support # TODO: Display Spheres in the right place $ use_sphere=[AP_NONE, AP_NONE, AP_NONE, AP_NONE, AP_NONE] + $ btl_ready = False python: try: renpy.call_screen("battle") @@ -47,7 +48,10 @@ label combat: sdelay(0.5) renpy.jump("combat") - $stdout("================= call ended") + stdout("================= call ended") + btl_ready=True + renpy.show_screen("battle") + # TODO: Send to server new arrangement of units # Update Battle with server response @@ -81,7 +85,6 @@ label combat: # Fight continues # TODO this is suboptimal, and the loops are also wrong # Maybe we should get info about what was used and whatnot? - show screen battle python: # TODO: Render sphere usage # Render enemy damage @@ -188,6 +191,11 @@ label results: story=dl_search(allstory, "quest_id", qid) if (story != ERR_INVALID): + try: + renpy.hide_screen("battle") + except: + stdout("Failed to hide screen battle D:") + pass hud_story() print ".:: Story logs (%d) ::." % qid |