Difference between revisions of "ButtonResult"

From Cheat Engine
Jump to navigation Jump to search
m
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
[[Category:Lua]]
 
[[Category:Lua]]
The following button results are defined in defines.lua
+
''ButtonResult'' is an enumeration in Cheat Engine Lua that represents the result of a dialog box, indicating which button the user pressed. Each constant corresponds to a specific button action (such as OK, Cancel, Yes, No, etc.) and is returned by functions like [[messageDialog]] to let your script know how the user responded.
  
*mrNone (0): Returned when the dialog is closed or the Close button is pressed
+
Defined in: '''defines.lua'''
*mrOK (1): Returned when the 'ok' button is pressed
+
 
*mrCancel (2): Returned when the 'cancel' button is pressed
+
===Button Results===
*mrAbort (3): Returned when the 'abort' button is pressed
+
{|width="85%" cellpadding="5" cellspacing="0" border="0"
*mrRetry (4): Returned when the 'retry' button is pressed
+
!align="left"|Constant
*mrIgnore (5): Returned when the 'ignore' button is pressed
+
!align="left"|Value
*mrYes (6): Returned when the 'yes' button is pressed
+
!align="left"|Description
*mrNo (7): Returned when the 'no' button is pressed
+
|-
*mrAll (8): Returned when the 'all' button is pressed
+
|mrNone
*mrNoToAll (9): Returned when the 'no to all' button is pressed
+
|0
*mrYesToAll (10): Returned when the 'yes to all' button is pressed  
+
|None
*mrLast (10): Returned when the 'last' button is pressed
+
|-
 +
|mrOK
 +
|1
 +
|OK pressed
 +
|-
 +
|mrCancel
 +
|2
 +
|Cancel pressed
 +
|-
 +
|mrAbort
 +
|3
 +
|Abort pressed
 +
|-
 +
|mrRetry
 +
|4
 +
|Retry pressed
 +
|-
 +
|mrIgnore
 +
|5
 +
|Ignore pressed
 +
|-
 +
|mrYes
 +
|6
 +
|Yes pressed
 +
|-
 +
|mrNo
 +
|7
 +
|No pressed
 +
|-
 +
|mrAll
 +
|8
 +
|All pressed
 +
|-
 +
|mrNoToAll
 +
|9
 +
|No to All pressed
 +
|-
 +
|mrYesToAll
 +
|10
 +
|Yes to All pressed
 +
|-
 +
|mrLast
 +
|10
 +
|Last result (same as mrYesToAll)
 +
|}
  
 
== See also ==
 
== See also ==
* [[ButtonResult]]
+
* [[ButtonType]]
 
* [[messageDialog]]
 
* [[messageDialog]]
 
* [[form_showModal]]
 
* [[form_showModal]]
 
* [[Lua]]
 
* [[Lua]]

Latest revision as of 18:34, 11 July 2025

ButtonResult is an enumeration in Cheat Engine Lua that represents the result of a dialog box, indicating which button the user pressed. Each constant corresponds to a specific button action (such as OK, Cancel, Yes, No, etc.) and is returned by functions like messageDialog to let your script know how the user responded.

Defined in: defines.lua

Button Results[edit]

Constant Value Description
mrNone 0 None
mrOK 1 OK pressed
mrCancel 2 Cancel pressed
mrAbort 3 Abort pressed
mrRetry 4 Retry pressed
mrIgnore 5 Ignore pressed
mrYes 6 Yes pressed
mrNo 7 No pressed
mrAll 8 All pressed
mrNoToAll 9 No to All pressed
mrYesToAll 10 Yes to All pressed
mrLast 10 Last result (same as mrYesToAll)

See also[edit]