diff --git a/sa/sa.json b/sa/sa.json index 8ddb1e3f..79716980 100644 --- a/sa/sa.json +++ b/sa/sa.json @@ -1,7 +1,7 @@ { "meta": { - "last_update": 1740992885346, - "version": "0.872", + "last_update": 1741008902287, + "version": "0.873", "url": "https://library.sannybuilder.com/#/sa" }, "extensions": [ @@ -61927,66 +61927,79 @@ "short_desc": "Returns a pointer to RakPeer" }, { + "input": [ + { + "name": "index", + "type": "int" + } + ], + "output": [ + { + "name": "address", + "type": "int", + "source": "var_any" + } + ], "id": "0B7C", "name": "SAMP_GET_RAKCLIENT_FUNC_BY_INDEX", "num_params": 2, + "short_desc": "Returns the address of the RakClientInterface virtual method table function by index" + }, + { "input": [ { - "name": "_p1", + "name": "index", "type": "int" - }, + } + ], + "output": [ { - "name": "_p2", - "type": "int" + "name": "address", + "type": "int", + "source": "var_any" } - ] - }, - { + ], "id": "0B7D", "name": "SAMP_GET_RPC_FUNC_BY_INDEX", "num_params": 2, "attrs": { "is_condition": true - }, + } + }, + { "input": [ { - "name": "_p1", + "name": "index", "type": "int" - }, + } + ], + "output": [ { - "name": "_p2", - "type": "int" + "name": "address", + "type": "int", + "source": "var_any" } - ] - }, - { + ], "id": "0B7E", "name": "SAMP_GET_RPC_NODE_BY_INDEX", "num_params": 2, "attrs": { "is_condition": true }, - "input": [ - { - "name": "_p1", - "type": "int" - }, - { - "name": "_p2", - "type": "int" - } - ] + "short_desc": "Returns a pointer to the RPC structure at index" }, { + "output": [ + { + "name": "address", + "type": "int", + "source": "var_any" + } + ], "id": "0B7F", "name": "SAMP_GET_SAMP_INFO_POINTER", "num_params": 1, - "input": [ - { - "name": "_p1", - "type": "int" - } - ] + "short_desc": "Returns a pointer to a SampInfo structure" }, { "input": [ @@ -62013,236 +62026,276 @@ "short_desc": "Creates a DXUTDialog Object with Title" }, { - "id": "0B81", - "name": "SAMP_DIALOG_POP", - "num_params": 3, - "attrs": { - "is_condition": true - }, "input": [ { - "name": "_p1", - "type": "int" - }, + "name": "self", + "type": "DxutDialog" + } + ], + "output": [ { - "name": "_p2", - "type": "int" + "name": "eventid", + "type": "int", + "source": "var_any" }, { - "name": "_p3", - "type": "int" + "name": "controlid", + "type": "int", + "source": "var_any" } - ] + ], + "id": "0B81", + "name": "SF_DXUT_DIALOG_POP", + "num_params": 3, + "attrs": { + "is_condition": true + }, + "short_desc": "Returns the last event and component ID that occurred with the specified dialog", + "class": "DxutDialog", + "member": "Pop" }, { - "id": "0B82", - "name": "SAMP_DIALOG_ADD_BUTTON", - "num_params": 7, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", + "name": "id", "type": "int" }, { - "name": "_p3", - "type": "int" + "name": "text", + "type": "string" }, { - "name": "_p4", + "name": "relcoordx", "type": "int" }, { - "name": "_p5", + "name": "relcoordy", "type": "int" }, { - "name": "_p6", + "name": "width", "type": "int" }, { - "name": "_p7", + "name": "height", "type": "int" } - ] + ], + "id": "0B82", + "name": "SF_DXUT_DIALOG_ADD_BUTTON", + "num_params": 7, + "short_desc": "Adds a button on the DXUTDialog", + "class": "DxutDialog", + "member": "AddButton" }, { - "id": "0B83", - "name": "SAMP_DIALOG_ADD_CHECKBOX", - "num_params": 7, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", + "name": "id", "type": "int" }, { - "name": "_p3", - "type": "int" + "name": "text", + "type": "string" }, { - "name": "_p4", + "name": "coordx", "type": "int" }, { - "name": "_p5", + "name": "coordy", "type": "int" }, { - "name": "_p6", + "name": "width", "type": "int" }, { - "name": "_p7", + "name": "height", "type": "int" } - ] + ], + "id": "0B83", + "name": "SF_DXUT_DIALOG_ADD_CHECKBOX", + "num_params": 7, + "class": "DxutDialog", + "member": "AddCheckbox", + "short_desc": "Creates a checkbox on the DxutDialog" }, { - "id": "0B84", - "name": "SAMP_DIALOG_SET_POSITION_SIZE", - "num_params": 5, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", + "name": "coordx", "type": "int" }, { - "name": "_p3", + "name": "coordy", "type": "int" }, { - "name": "_p4", + "name": "width", "type": "int" }, { - "name": "_p5", + "name": "height", "type": "int" } - ] + ], + "id": "0B84", + "name": "SF_DXUT_DIALOG_SET_COORDS_AND_DIMS", + "num_params": 5, + "short_desc": "Sets the coordinates and dimensions of the DxutDialog", + "class": "DxutDialog", + "member": "SetCoordsAndDims" }, { - "id": "0B85", - "name": "SAMP_DIALOG_GET_POSITION_SIZE", - "num_params": 5, "input": [ { - "name": "_p1", - "type": "int" - }, + "name": "self", + "type": "DxutDialog" + } + ], + "output": [ { - "name": "_p2", - "type": "int" + "name": "coordx", + "type": "int", + "source": "var_any" }, { - "name": "_p3", - "type": "int" + "name": "coordy", + "type": "int", + "source": "var_any" }, { - "name": "_p4", - "type": "int" + "name": "width", + "type": "int", + "source": "var_any" }, { - "name": "_p5", - "type": "int" + "name": "height", + "type": "int", + "source": "var_any" } - ] + ], + "id": "0B85", + "name": "SF_DXUT_DIALOG_GET_COORDS_AND_DIMS", + "num_params": 5, + "class": "DxutDialog", + "member": "GetCoordsAndDims", + "short_desc": "Returns the Coordinates and Dimensions of the DxutDialog" }, { - "id": "0B86", - "name": "SAMP_DIALOG_SET_VISIBLE", - "num_params": 2, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", - "type": "int" + "name": "isvisible", + "type": "bool" } - ] + ], + "id": "0B86", + "name": "SF_DXUT_DIALOG_SET_VISIBILITY", + "num_params": 2, + "short_desc": "Sets the visibility status of the DxutDialog", + "class": "DxutDialog", + "member": "Visibility" }, { + "input": [ + { + "name": "self", + "type": "DxutDialog" + } + ], "id": "0B87", - "name": "SAMP_DIALOG_IS_VISIBLE", + "name": "SF_DXUT_DIALOG_IS_VISIBLE", "num_params": 1, "attrs": { "is_condition": true }, - "input": [ - { - "name": "_p1", - "type": "int" - } - ] + "class": "DxutDialog", + "member": "IsVisible", + "short_desc": "Checks if the DxutDialog is visible" }, { - "id": "0B88", - "name": "SAMP_DIALOG_ADD_EDITBOX", - "num_params": 7, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", + "name": "id", "type": "int" }, { - "name": "_p3", - "type": "int" + "name": "initialtext", + "type": "string" }, { - "name": "_p4", + "name": "coordx", "type": "int" }, { - "name": "_p5", + "name": "coordy", "type": "int" }, { - "name": "_p6", + "name": "width", "type": "int" }, { - "name": "_p7", + "name": "height", "type": "int" } - ] + ], + "id": "0B88", + "name": "SF_DXUT_DIALOG_ADD_EDITBOX", + "num_params": 7, + "short_desc": "Creates a text input field on a DxutDialog", + "class": "DxutDialog", + "member": "AddEditbox" }, { - "id": "0B89", - "name": "SAMP_DIALOG_GET_CONTROL_TEXT", - "num_params": 3, - "attrs": { - "is_condition": true - }, "input": [ { - "name": "_p1", - "type": "int" + "name": "self", + "type": "DxutDialog" }, { - "name": "_p2", + "name": "id", "type": "int" - }, + } + ], + "output": [ { - "name": "_p3", - "type": "int" + "name": "text", + "type": "int", + "source": "var_any" } - ] + ], + "id": "0B89", + "name": "SF_DXUT_DIALOG_GET_TEXT_OF_CONTROL", + "num_params": 3, + "attrs": { + "is_condition": true + }, + "short_desc": "Gets the text of a control using its ID", + "class": "DxutDialog", + "member": "GetControlText" }, { "id": "0B8A", diff --git a/sa/snippets/SAMPFUNCS/0B7C.txt b/sa/snippets/SAMPFUNCS/0B7C.txt new file mode 100644 index 00000000..0bedb35c --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B7C.txt @@ -0,0 +1 @@ +int ptr = SAMP_GET_RAKCLIENT_FUNC_BY_INDEX 0 \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B7D.txt b/sa/snippets/SAMPFUNCS/0B7D.txt new file mode 100644 index 00000000..1fac0649 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B7D.txt @@ -0,0 +1,5 @@ +int ptr +if ptr = SAMP_GET_RPC_FUNC_BY_INDEX {index} 0 +then // do something +else // index is invalid +end \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B7E.txt b/sa/snippets/SAMPFUNCS/0B7E.txt new file mode 100644 index 00000000..896d792a --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B7E.txt @@ -0,0 +1,5 @@ +int ptr +if ptr = SAMP_GET_RPC_NODE_BY_INDEX {index} 0 +then // do something +else // index is invalid +end \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B7F.txt b/sa/snippets/SAMPFUNCS/0B7F.txt new file mode 100644 index 00000000..a7582768 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B7F.txt @@ -0,0 +1 @@ +int ptr = SAMP_GET_SAMP_INFO_POINTER \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B81.txt b/sa/snippets/SAMPFUNCS/0B81.txt new file mode 100644 index 00000000..64c76737 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B81.txt @@ -0,0 +1,8 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" + +// somewhere in the code +int eventID, controlID +if eventID, controlID = SAMP_DIALOG_POP clientSidedDialog +then // do something to eventID, controlID +else // clientSidedDialog is invalid +end \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B82.txt b/sa/snippets/SAMPFUNCS/0B82.txt new file mode 100644 index 00000000..d2f5b905 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B82.txt @@ -0,0 +1,3 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +SF_DXUT_DIALOG_ADD_BUTTON clientSidedDialog {id} 0 {text} "Cancel" {relcoordx} 25 {relcoordy} 200 {width} 50 {height} 10 +SF_DXUT_DIALOG_ADD_BUTTON clientSidedDialog {id} 1 {text} "Submit" {relcoordx} 85 {relcoordy} 200 {width} 50 {height} 10 \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B83.txt b/sa/snippets/SAMPFUNCS/0B83.txt new file mode 100644 index 00000000..025c1c3a --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B83.txt @@ -0,0 +1,3 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +SF_DXUT_DIALOG_ADD_CHECKBOX clientSidedDialog {id} 40 {text} "God Mode" {relcoordx} 10 {relcoordy} 80 {width} 50 {height} 10 +SF_DXUT_DIALOG_ADD_CHECKBOX clientSidedDialog {id} 41 {text} "No Collision" {relcoordx} 10 {relcoordy} 140 {width} 50 {height} 10 \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B84.txt b/sa/snippets/SAMPFUNCS/0B84.txt new file mode 100644 index 00000000..0aea7d12 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B84.txt @@ -0,0 +1,2 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +SF_DXUT_DIALOG_SET_COORDS_AND_DIMS clientSidedDialog {coordx} 900 {coordy} 500 {width} 500 {height} 300 \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B85.txt b/sa/snippets/SAMPFUNCS/0B85.txt new file mode 100644 index 00000000..ef28cca8 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B85.txt @@ -0,0 +1,2 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +int dialogCoordX, dialogCoordY, dialogWidth, dialogHeight = SF_DXUT_DIALOG_GET_COORDS_AND_DIMS clientSidedDialog \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B86.txt b/sa/snippets/SAMPFUNCS/0B86.txt new file mode 100644 index 00000000..fb557214 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B86.txt @@ -0,0 +1,5 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" + +SF_DXUT_DIALOG_SET_VISIBILITY clientSidedDialog {isvisible} true // show dialog + +SF_DXUT_DIALOG_SET_VISIBILITY clientSidedDialog {isvisible} false // hide dialog \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B87.txt b/sa/snippets/SAMPFUNCS/0B87.txt new file mode 100644 index 00000000..39541e1b --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B87.txt @@ -0,0 +1,13 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" + +SF_DXUT_DIALOG_SET_VISIBILITY clientSidedDialog {isvisible} true // show dialog +if SF_DXUT_DIALOG_IS_VISIBLE clientSidedDialog +then // expected +else // will not reach this section +end + +SF_DXUT_DIALOG_SET_VISIBILITY clientSidedDialog {isvisible} false // hide dialog +if SF_DXUT_DIALOG_IS_VISIBLE clientSidedDialog +then // will not reach this section +else // expected +end \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B88.txt b/sa/snippets/SAMPFUNCS/0B88.txt new file mode 100644 index 00000000..bfc09b11 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B88.txt @@ -0,0 +1,2 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +SF_DXUT_DIALOG_ADD_EDITBOX clientSidedDialog {id} 60 {initialtext} "Password" {relcoordx} 10 {relcoordy} 200 {width} 100 {height} 10 \ No newline at end of file diff --git a/sa/snippets/SAMPFUNCS/0B89.txt b/sa/snippets/SAMPFUNCS/0B89.txt new file mode 100644 index 00000000..edf4d387 --- /dev/null +++ b/sa/snippets/SAMPFUNCS/0B89.txt @@ -0,0 +1,12 @@ +int clientSidedDialog = SF_DXUT_CREATE_DIALOG {title} "SF Dialog" +SF_DXUT_DIALOG_ADD_CHECKBOX clientSidedDialog {id} 40 {text} "God Mode" {relcoordx} 10 {relcoordy} 80 {width} 50 {height} 10 + +int controlText +if controlText = SF_DXUT_DIALOG_GET_TEXT_OF_CONTROL clientSidedDialog {id} 14 +then // this section will not be be executed +else // clientSidedDialog has no control with ID = 14 +end +if controlText = SF_DXUT_DIALOG_GET_TEXT_OF_CONTROL clientSidedDialog {id} 40 +then // expected controlText = "God Mode" +else // this section will not be be executed +end \ No newline at end of file diff --git a/sa/version.txt b/sa/version.txt index 56936d49..e3d81a86 100644 --- a/sa/version.txt +++ b/sa/version.txt @@ -1 +1 @@ -0.872 \ No newline at end of file +0.873 \ No newline at end of file