SPELLBOOK BUG WHEN UNCLOSED need help

Status
Not open for further replies.
Level 6
Joined
Feb 5, 2012
Messages
1,685
There is a bug where if your currently selected unit opens a spellbook then it dies and there is a trigger that force you to select another unit. That unit's command buttons as well as ALL THE OTHER BUTTONS WILL BE COMPLETELY BLACK, UNCLICKABLE AND UNUSABLE.

There is a fix but very annoying and for those who dont know how to fix it, it will cause a SEVERE PANIC.

Manually select other units then the bug will be removed.

What is the best solution to force the player to close the spell book before dying?

PLEASE DONT ANSWER ME SHOW THEM A WARNING ABOUT THIS BUG BECAUSE THERE A BRAINLESS PLAYERS WHO CAN'T UNDERSTAND THIS BUG AND HOW TO FIX IT BY THEMSELVES.
 
Level 14
Joined
Jul 1, 2008
Messages
1,314
You can force a player to press the ESC buttong by using:

JASS:
call ForceUICancelBJ( Player(0) )

In GUI, you find this function in the category Game (ForceUI).

You have to get the moment, just before the unit dies and then force the player to press ESC by the mentioned function.
I am currently not sure, whether the event "A unit dies" fires right before or right after the actual "death action" of the unit. You should try it out though
 
Status
Not open for further replies.
Top