def addnewunit(title, text, style):
ctypes.windll.user32.MessageBoxW(0, text, title, style)
Ive seen a lot of people show this code, however no
You set the answer as equal to the command, like so:
import ctypes
answer = ctypes.windll.user32.MessageBoxW(0, "Message", "Title", 4)
Then you can just use
print(answer)
to see what number is the outcome of the user's choice.
Then use an "If" statement based on what the answer number is to make it do what you want.