@plugify-plugins/s2sdk-types 1.1.15 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +255 -100
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -636,6 +636,48 @@ declare module ":s2sdk" {
|
|
|
636
636
|
DoNotEcho = 2
|
|
637
637
|
}
|
|
638
638
|
|
|
639
|
+
/**
|
|
640
|
+
* @description Enum representing the possible types of a vote actions.
|
|
641
|
+
*/
|
|
642
|
+
export enum VoteAction {
|
|
643
|
+
|
|
644
|
+
/**
|
|
645
|
+
* @description Triggered when the vote begins. No additional parameters are used.
|
|
646
|
+
* */
|
|
647
|
+
Start = 0,
|
|
648
|
+
|
|
649
|
+
/**
|
|
650
|
+
* @description Triggered when a player casts a vote. 'clientSlot' holds the voter's slot and 'choice' is the selected option (e.g., VOTE_OPTION1 for yes, VOTE_OPTION2 for no).
|
|
651
|
+
* */
|
|
652
|
+
Vote = 1,
|
|
653
|
+
|
|
654
|
+
/**
|
|
655
|
+
* @description Triggered when the vote concludes. 'clientSlot' is typically -1. 'choice' contains the reason the vote ended (from YesNoVoteEndReason).
|
|
656
|
+
* */
|
|
657
|
+
End = 2
|
|
658
|
+
}
|
|
659
|
+
|
|
660
|
+
/**
|
|
661
|
+
* @description Enum representing the possible types of a vote.
|
|
662
|
+
*/
|
|
663
|
+
export enum VoteEndReason {
|
|
664
|
+
|
|
665
|
+
/**
|
|
666
|
+
* @description All possible votes were cast.
|
|
667
|
+
* */
|
|
668
|
+
AllVotes = 0,
|
|
669
|
+
|
|
670
|
+
/**
|
|
671
|
+
* @description Time ran out.
|
|
672
|
+
* */
|
|
673
|
+
TimeUp = 1,
|
|
674
|
+
|
|
675
|
+
/**
|
|
676
|
+
* @description The vote got cancelled.
|
|
677
|
+
* */
|
|
678
|
+
Cancelled = 2
|
|
679
|
+
}
|
|
680
|
+
|
|
639
681
|
/**
|
|
640
682
|
* @description Enum representing the possible flags of a timer.
|
|
641
683
|
*/
|
|
@@ -841,42 +883,7 @@ declare module ":s2sdk" {
|
|
|
841
883
|
/**
|
|
842
884
|
* @description undefined
|
|
843
885
|
* */
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
/**
|
|
847
|
-
* @description undefined
|
|
848
|
-
* */
|
|
849
|
-
BreachCharge = 13,
|
|
850
|
-
|
|
851
|
-
/**
|
|
852
|
-
* @description undefined
|
|
853
|
-
* */
|
|
854
|
-
BumpMine = 14,
|
|
855
|
-
|
|
856
|
-
/**
|
|
857
|
-
* @description undefined
|
|
858
|
-
* */
|
|
859
|
-
Tablet = 15,
|
|
860
|
-
|
|
861
|
-
/**
|
|
862
|
-
* @description undefined
|
|
863
|
-
* */
|
|
864
|
-
Melee = 16,
|
|
865
|
-
|
|
866
|
-
/**
|
|
867
|
-
* @description undefined
|
|
868
|
-
* */
|
|
869
|
-
Shield = 17,
|
|
870
|
-
|
|
871
|
-
/**
|
|
872
|
-
* @description undefined
|
|
873
|
-
* */
|
|
874
|
-
ZoneRepulsor = 18,
|
|
875
|
-
|
|
876
|
-
/**
|
|
877
|
-
* @description undefined
|
|
878
|
-
* */
|
|
879
|
-
Unknown = 19
|
|
886
|
+
Unknown = 12
|
|
880
887
|
}
|
|
881
888
|
|
|
882
889
|
/**
|
|
@@ -1416,6 +1423,33 @@ declare module ":s2sdk" {
|
|
|
1416
1423
|
|
|
1417
1424
|
function EventCallback(name: string, event: number, dontBroadcast: boolean): ResultType;
|
|
1418
1425
|
|
|
1426
|
+
/**
|
|
1427
|
+
* @description Handles the final result of a Yes/No vote. This function is called when a vote concludes, and is responsible for determining whether the vote passed based on the number of 'yes' and 'no' votes. Also receives context about the clients who participated in the vote.
|
|
1428
|
+
*
|
|
1429
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-YesNoVoteResult|Docs}
|
|
1430
|
+
*
|
|
1431
|
+
* @param numVotes Total number of votes submitted (yes + no).
|
|
1432
|
+
* @param yesVotes Number of 'yes' votes cast.
|
|
1433
|
+
* @param noVotes Number of 'no' votes cast.
|
|
1434
|
+
* @param numClients Total number of clients eligible to vote.
|
|
1435
|
+
* @param clientInfoSlot List of player slot indices representing voting clients.
|
|
1436
|
+
* @param clientInfoItem List of contextual data associated with each client (e.g., vote weight or custom info).
|
|
1437
|
+
*/
|
|
1438
|
+
|
|
1439
|
+
function YesNoVoteResult(numVotes: number, yesVotes: number, noVotes: number, numClients: number, clientInfoSlot: number[], clientInfoItem: number[]): boolean;
|
|
1440
|
+
|
|
1441
|
+
/**
|
|
1442
|
+
* @description
|
|
1443
|
+
*
|
|
1444
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-YesNoVoteHandler|Docs}
|
|
1445
|
+
*
|
|
1446
|
+
* @param action The action type from VoteAction enum.
|
|
1447
|
+
* @param clientSlot For Vote actions, this is the slot of the client who voted. For Start/End, typically -1.
|
|
1448
|
+
* @param choice For Vote actions, the vote choice (VOTE_OPTION1=yes, VOTE_OPTION2=no). For End, the YesNoVoteEndReason value.
|
|
1449
|
+
*/
|
|
1450
|
+
|
|
1451
|
+
function YesNoVoteHandler(action: VoteAction, clientSlot: number, choice: number): void;
|
|
1452
|
+
|
|
1419
1453
|
/**
|
|
1420
1454
|
* @description This function is invoked when a timer event occurs. It handles the timer-related logic and performs necessary actions based on the event.
|
|
1421
1455
|
*
|
|
@@ -1614,6 +1648,16 @@ declare module ":s2sdk" {
|
|
|
1614
1648
|
|
|
1615
1649
|
function OnServerActivateCallback(): void;
|
|
1616
1650
|
|
|
1651
|
+
/**
|
|
1652
|
+
* @description Called on every level change.
|
|
1653
|
+
*
|
|
1654
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-OnChangeLevelCallback|Docs}
|
|
1655
|
+
*
|
|
1656
|
+
*
|
|
1657
|
+
*/
|
|
1658
|
+
|
|
1659
|
+
function OnChangeLevelCallback(): void;
|
|
1660
|
+
|
|
1617
1661
|
/**
|
|
1618
1662
|
* @description Called before every server frame. Note that you should avoid doing expensive computations or declaring large local arrays.
|
|
1619
1663
|
*
|
|
@@ -3109,7 +3153,7 @@ declare module ":s2sdk" {
|
|
|
3109
3153
|
*
|
|
3110
3154
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-FindModule|Docs}
|
|
3111
3155
|
*
|
|
3112
|
-
* @param name
|
|
3156
|
+
* @param name The name of the module to find.
|
|
3113
3157
|
*/
|
|
3114
3158
|
export function FindModule(name: string): number;
|
|
3115
3159
|
|
|
@@ -3127,9 +3171,10 @@ declare module ":s2sdk" {
|
|
|
3127
3171
|
*
|
|
3128
3172
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-QueryInterface|Docs}
|
|
3129
3173
|
*
|
|
3130
|
-
* @param
|
|
3174
|
+
* @param module The name of the module to query the interface from.
|
|
3175
|
+
* @param name The name of the interface to find.
|
|
3131
3176
|
*/
|
|
3132
|
-
export function QueryInterface(name: string): number;
|
|
3177
|
+
export function QueryInterface(module: string, name: string): number;
|
|
3133
3178
|
|
|
3134
3179
|
/**
|
|
3135
3180
|
* @description Returns the path of the game's directory.
|
|
@@ -3861,10 +3906,10 @@ declare module ":s2sdk" {
|
|
|
3861
3906
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-HookEvent|Docs}
|
|
3862
3907
|
*
|
|
3863
3908
|
* @param name The name of the event to hook.
|
|
3864
|
-
* @param
|
|
3909
|
+
* @param callback The callback function to call when the event is fired.
|
|
3865
3910
|
* @param type Whether the hook was in post mode (after processing) or pre mode (before processing).
|
|
3866
3911
|
*/
|
|
3867
|
-
export function HookEvent(name: string,
|
|
3912
|
+
export function HookEvent(name: string, callback: typeof Callbacks.EventCallback, type: HookMode): number;
|
|
3868
3913
|
|
|
3869
3914
|
/**
|
|
3870
3915
|
* @description Removes a hook for when a game event is fired.
|
|
@@ -3872,10 +3917,10 @@ declare module ":s2sdk" {
|
|
|
3872
3917
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-UnhookEvent|Docs}
|
|
3873
3918
|
*
|
|
3874
3919
|
* @param name The name of the event to unhook.
|
|
3875
|
-
* @param
|
|
3920
|
+
* @param callback The callback function to remove.
|
|
3876
3921
|
* @param type Whether the hook was in post mode (after processing) or pre mode (before processing).
|
|
3877
3922
|
*/
|
|
3878
|
-
export function UnhookEvent(name: string,
|
|
3923
|
+
export function UnhookEvent(name: string, callback: typeof Callbacks.EventCallback, type: HookMode): number;
|
|
3879
3924
|
|
|
3880
3925
|
/**
|
|
3881
3926
|
* @description Creates a game event to be fired later.
|
|
@@ -3892,289 +3937,289 @@ declare module ":s2sdk" {
|
|
|
3892
3937
|
*
|
|
3893
3938
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-FireEvent|Docs}
|
|
3894
3939
|
*
|
|
3895
|
-
* @param
|
|
3896
|
-
* @param
|
|
3940
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3941
|
+
* @param dontBroadcast A boolean indicating whether to broadcast the event.
|
|
3897
3942
|
*/
|
|
3898
|
-
export function FireEvent(
|
|
3943
|
+
export function FireEvent(info: number, dontBroadcast: boolean): void;
|
|
3899
3944
|
|
|
3900
3945
|
/**
|
|
3901
3946
|
* @description Fires a game event to a specific client.
|
|
3902
3947
|
*
|
|
3903
3948
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-FireEventToClient|Docs}
|
|
3904
3949
|
*
|
|
3905
|
-
* @param
|
|
3950
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3906
3951
|
* @param playerSlot The index of the client to fire the event to.
|
|
3907
3952
|
*/
|
|
3908
|
-
export function FireEventToClient(
|
|
3953
|
+
export function FireEventToClient(info: number, playerSlot: number): void;
|
|
3909
3954
|
|
|
3910
3955
|
/**
|
|
3911
3956
|
* @description Cancels a previously created game event that has not been fired.
|
|
3912
3957
|
*
|
|
3913
3958
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-CancelCreatedEvent|Docs}
|
|
3914
3959
|
*
|
|
3915
|
-
* @param
|
|
3960
|
+
* @param info A pointer to the EventInfo structure of the event to cancel.
|
|
3916
3961
|
*/
|
|
3917
|
-
export function CancelCreatedEvent(
|
|
3962
|
+
export function CancelCreatedEvent(info: number): void;
|
|
3918
3963
|
|
|
3919
3964
|
/**
|
|
3920
3965
|
* @description Retrieves the boolean value of a game event's key.
|
|
3921
3966
|
*
|
|
3922
3967
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventBool|Docs}
|
|
3923
3968
|
*
|
|
3924
|
-
* @param
|
|
3969
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3925
3970
|
* @param key The key for which to retrieve the boolean value.
|
|
3926
3971
|
*/
|
|
3927
|
-
export function GetEventBool(
|
|
3972
|
+
export function GetEventBool(info: number, key: string): boolean;
|
|
3928
3973
|
|
|
3929
3974
|
/**
|
|
3930
3975
|
* @description Retrieves the float value of a game event's key.
|
|
3931
3976
|
*
|
|
3932
3977
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventFloat|Docs}
|
|
3933
3978
|
*
|
|
3934
|
-
* @param
|
|
3979
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3935
3980
|
* @param key The key for which to retrieve the float value.
|
|
3936
3981
|
*/
|
|
3937
|
-
export function GetEventFloat(
|
|
3982
|
+
export function GetEventFloat(info: number, key: string): number;
|
|
3938
3983
|
|
|
3939
3984
|
/**
|
|
3940
3985
|
* @description Retrieves the integer value of a game event's key.
|
|
3941
3986
|
*
|
|
3942
3987
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventInt|Docs}
|
|
3943
3988
|
*
|
|
3944
|
-
* @param
|
|
3989
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3945
3990
|
* @param key The key for which to retrieve the integer value.
|
|
3946
3991
|
*/
|
|
3947
|
-
export function GetEventInt(
|
|
3992
|
+
export function GetEventInt(info: number, key: string): number;
|
|
3948
3993
|
|
|
3949
3994
|
/**
|
|
3950
3995
|
* @description Retrieves the long integer value of a game event's key.
|
|
3951
3996
|
*
|
|
3952
3997
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventUInt64|Docs}
|
|
3953
3998
|
*
|
|
3954
|
-
* @param
|
|
3999
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3955
4000
|
* @param key The key for which to retrieve the long integer value.
|
|
3956
4001
|
*/
|
|
3957
|
-
export function GetEventUInt64(
|
|
4002
|
+
export function GetEventUInt64(info: number, key: string): number;
|
|
3958
4003
|
|
|
3959
4004
|
/**
|
|
3960
4005
|
* @description Retrieves the string value of a game event's key.
|
|
3961
4006
|
*
|
|
3962
4007
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventString|Docs}
|
|
3963
4008
|
*
|
|
3964
|
-
* @param
|
|
4009
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3965
4010
|
* @param key The key for which to retrieve the string value.
|
|
3966
4011
|
*/
|
|
3967
|
-
export function GetEventString(
|
|
4012
|
+
export function GetEventString(info: number, key: string): string;
|
|
3968
4013
|
|
|
3969
4014
|
/**
|
|
3970
4015
|
* @description Retrieves the pointer value of a game event's key.
|
|
3971
4016
|
*
|
|
3972
4017
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventPtr|Docs}
|
|
3973
4018
|
*
|
|
3974
|
-
* @param
|
|
4019
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3975
4020
|
* @param key The key for which to retrieve the pointer value.
|
|
3976
4021
|
*/
|
|
3977
|
-
export function GetEventPtr(
|
|
4022
|
+
export function GetEventPtr(info: number, key: string): number;
|
|
3978
4023
|
|
|
3979
4024
|
/**
|
|
3980
4025
|
* @description Retrieves the player controller address of a game event's key.
|
|
3981
4026
|
*
|
|
3982
4027
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventPlayerController|Docs}
|
|
3983
4028
|
*
|
|
3984
|
-
* @param
|
|
4029
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3985
4030
|
* @param key The key for which to retrieve the player controller address.
|
|
3986
4031
|
*/
|
|
3987
|
-
export function GetEventPlayerController(
|
|
4032
|
+
export function GetEventPlayerController(info: number, key: string): number;
|
|
3988
4033
|
|
|
3989
4034
|
/**
|
|
3990
4035
|
* @description Retrieves the player index of a game event's key.
|
|
3991
4036
|
*
|
|
3992
4037
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventPlayerIndex|Docs}
|
|
3993
4038
|
*
|
|
3994
|
-
* @param
|
|
4039
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
3995
4040
|
* @param key The key for which to retrieve the player index.
|
|
3996
4041
|
*/
|
|
3997
|
-
export function GetEventPlayerIndex(
|
|
4042
|
+
export function GetEventPlayerIndex(info: number, key: string): number;
|
|
3998
4043
|
|
|
3999
4044
|
/**
|
|
4000
4045
|
* @description Retrieves the player pawn address of a game event's key.
|
|
4001
4046
|
*
|
|
4002
4047
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventPlayerPawn|Docs}
|
|
4003
4048
|
*
|
|
4004
|
-
* @param
|
|
4049
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4005
4050
|
* @param key The key for which to retrieve the player pawn address.
|
|
4006
4051
|
*/
|
|
4007
|
-
export function GetEventPlayerPawn(
|
|
4052
|
+
export function GetEventPlayerPawn(info: number, key: string): number;
|
|
4008
4053
|
|
|
4009
4054
|
/**
|
|
4010
4055
|
* @description Retrieves the entity address of a game event's key.
|
|
4011
4056
|
*
|
|
4012
4057
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventEntity|Docs}
|
|
4013
4058
|
*
|
|
4014
|
-
* @param
|
|
4059
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4015
4060
|
* @param key The key for which to retrieve the entity address.
|
|
4016
4061
|
*/
|
|
4017
|
-
export function GetEventEntity(
|
|
4062
|
+
export function GetEventEntity(info: number, key: string): number;
|
|
4018
4063
|
|
|
4019
4064
|
/**
|
|
4020
4065
|
* @description Retrieves the entity index of a game event's key.
|
|
4021
4066
|
*
|
|
4022
4067
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventEntityIndex|Docs}
|
|
4023
4068
|
*
|
|
4024
|
-
* @param
|
|
4069
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4025
4070
|
* @param key The key for which to retrieve the entity index.
|
|
4026
4071
|
*/
|
|
4027
|
-
export function GetEventEntityIndex(
|
|
4072
|
+
export function GetEventEntityIndex(info: number, key: string): number;
|
|
4028
4073
|
|
|
4029
4074
|
/**
|
|
4030
4075
|
* @description Retrieves the entity handle of a game event's key.
|
|
4031
4076
|
*
|
|
4032
4077
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventEntityHandle|Docs}
|
|
4033
4078
|
*
|
|
4034
|
-
* @param
|
|
4079
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4035
4080
|
* @param key The key for which to retrieve the entity handle.
|
|
4036
4081
|
*/
|
|
4037
|
-
export function GetEventEntityHandle(
|
|
4082
|
+
export function GetEventEntityHandle(info: number, key: string): number;
|
|
4038
4083
|
|
|
4039
4084
|
/**
|
|
4040
4085
|
* @description Retrieves the name of a game event.
|
|
4041
4086
|
*
|
|
4042
4087
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetEventName|Docs}
|
|
4043
4088
|
*
|
|
4044
|
-
* @param
|
|
4089
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4045
4090
|
*/
|
|
4046
|
-
export function GetEventName(
|
|
4091
|
+
export function GetEventName(info: number): string;
|
|
4047
4092
|
|
|
4048
4093
|
/**
|
|
4049
4094
|
* @description Sets the boolean value of a game event's key.
|
|
4050
4095
|
*
|
|
4051
4096
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventBool|Docs}
|
|
4052
4097
|
*
|
|
4053
|
-
* @param
|
|
4098
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4054
4099
|
* @param key The key for which to set the boolean value.
|
|
4055
4100
|
* @param value The boolean value to set.
|
|
4056
4101
|
*/
|
|
4057
|
-
export function SetEventBool(
|
|
4102
|
+
export function SetEventBool(info: number, key: string, value: boolean): void;
|
|
4058
4103
|
|
|
4059
4104
|
/**
|
|
4060
4105
|
* @description Sets the floating point value of a game event's key.
|
|
4061
4106
|
*
|
|
4062
4107
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventFloat|Docs}
|
|
4063
4108
|
*
|
|
4064
|
-
* @param
|
|
4109
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4065
4110
|
* @param key The key for which to set the float value.
|
|
4066
4111
|
* @param value The float value to set.
|
|
4067
4112
|
*/
|
|
4068
|
-
export function SetEventFloat(
|
|
4113
|
+
export function SetEventFloat(info: number, key: string, value: number): void;
|
|
4069
4114
|
|
|
4070
4115
|
/**
|
|
4071
4116
|
* @description Sets the integer value of a game event's key.
|
|
4072
4117
|
*
|
|
4073
4118
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventInt|Docs}
|
|
4074
4119
|
*
|
|
4075
|
-
* @param
|
|
4120
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4076
4121
|
* @param key The key for which to set the integer value.
|
|
4077
4122
|
* @param value The integer value to set.
|
|
4078
4123
|
*/
|
|
4079
|
-
export function SetEventInt(
|
|
4124
|
+
export function SetEventInt(info: number, key: string, value: number): void;
|
|
4080
4125
|
|
|
4081
4126
|
/**
|
|
4082
4127
|
* @description Sets the long integer value of a game event's key.
|
|
4083
4128
|
*
|
|
4084
4129
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventUInt64|Docs}
|
|
4085
4130
|
*
|
|
4086
|
-
* @param
|
|
4131
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4087
4132
|
* @param key The key for which to set the long integer value.
|
|
4088
4133
|
* @param value The long integer value to set.
|
|
4089
4134
|
*/
|
|
4090
|
-
export function SetEventUInt64(
|
|
4135
|
+
export function SetEventUInt64(info: number, key: string, value: number): void;
|
|
4091
4136
|
|
|
4092
4137
|
/**
|
|
4093
4138
|
* @description Sets the string value of a game event's key.
|
|
4094
4139
|
*
|
|
4095
4140
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventString|Docs}
|
|
4096
4141
|
*
|
|
4097
|
-
* @param
|
|
4142
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4098
4143
|
* @param key The key for which to set the string value.
|
|
4099
4144
|
* @param value The string value to set.
|
|
4100
4145
|
*/
|
|
4101
|
-
export function SetEventString(
|
|
4146
|
+
export function SetEventString(info: number, key: string, value: string): void;
|
|
4102
4147
|
|
|
4103
4148
|
/**
|
|
4104
4149
|
* @description Sets the pointer value of a game event's key.
|
|
4105
4150
|
*
|
|
4106
4151
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventPtr|Docs}
|
|
4107
4152
|
*
|
|
4108
|
-
* @param
|
|
4153
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4109
4154
|
* @param key The key for which to set the pointer value.
|
|
4110
4155
|
* @param value The pointer value to set.
|
|
4111
4156
|
*/
|
|
4112
|
-
export function SetEventPtr(
|
|
4157
|
+
export function SetEventPtr(info: number, key: string, value: number): void;
|
|
4113
4158
|
|
|
4114
4159
|
/**
|
|
4115
4160
|
* @description Sets the player controller address of a game event's key.
|
|
4116
4161
|
*
|
|
4117
4162
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventPlayerController|Docs}
|
|
4118
4163
|
*
|
|
4119
|
-
* @param
|
|
4164
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4120
4165
|
* @param key The key for which to set the player controller address.
|
|
4121
4166
|
* @param value A pointer to the player controller to set.
|
|
4122
4167
|
*/
|
|
4123
|
-
export function SetEventPlayerController(
|
|
4168
|
+
export function SetEventPlayerController(info: number, key: string, value: number): void;
|
|
4124
4169
|
|
|
4125
4170
|
/**
|
|
4126
4171
|
* @description Sets the player index value of a game event's key.
|
|
4127
4172
|
*
|
|
4128
4173
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventPlayerIndex|Docs}
|
|
4129
4174
|
*
|
|
4130
|
-
* @param
|
|
4175
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4131
4176
|
* @param key The key for which to set the player index value.
|
|
4132
4177
|
* @param value The player index value to set.
|
|
4133
4178
|
*/
|
|
4134
|
-
export function SetEventPlayerIndex(
|
|
4179
|
+
export function SetEventPlayerIndex(info: number, key: string, value: number): void;
|
|
4135
4180
|
|
|
4136
4181
|
/**
|
|
4137
4182
|
* @description Sets the entity address of a game event's key.
|
|
4138
4183
|
*
|
|
4139
4184
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventEntity|Docs}
|
|
4140
4185
|
*
|
|
4141
|
-
* @param
|
|
4186
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4142
4187
|
* @param key The key for which to set the entity address.
|
|
4143
4188
|
* @param value A pointer to the entity to set.
|
|
4144
4189
|
*/
|
|
4145
|
-
export function SetEventEntity(
|
|
4190
|
+
export function SetEventEntity(info: number, key: string, value: number): void;
|
|
4146
4191
|
|
|
4147
4192
|
/**
|
|
4148
4193
|
* @description Sets the entity index of a game event's key.
|
|
4149
4194
|
*
|
|
4150
4195
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventEntityIndex|Docs}
|
|
4151
4196
|
*
|
|
4152
|
-
* @param
|
|
4197
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4153
4198
|
* @param key The key for which to set the entity index.
|
|
4154
4199
|
* @param value The entity index value to set.
|
|
4155
4200
|
*/
|
|
4156
|
-
export function SetEventEntityIndex(
|
|
4201
|
+
export function SetEventEntityIndex(info: number, key: string, value: number): void;
|
|
4157
4202
|
|
|
4158
4203
|
/**
|
|
4159
4204
|
* @description Sets the entity handle of a game event's key.
|
|
4160
4205
|
*
|
|
4161
4206
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventEntityHandle|Docs}
|
|
4162
4207
|
*
|
|
4163
|
-
* @param
|
|
4208
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4164
4209
|
* @param key The key for which to set the entity handle.
|
|
4165
4210
|
* @param value The entity handle value to set.
|
|
4166
4211
|
*/
|
|
4167
|
-
export function SetEventEntityHandle(
|
|
4212
|
+
export function SetEventEntityHandle(info: number, key: string, value: number): void;
|
|
4168
4213
|
|
|
4169
4214
|
/**
|
|
4170
4215
|
* @description Sets whether an event's broadcasting will be disabled or not.
|
|
4171
4216
|
*
|
|
4172
4217
|
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-SetEventBroadcast|Docs}
|
|
4173
4218
|
*
|
|
4174
|
-
* @param
|
|
4219
|
+
* @param info A pointer to the EventInfo structure containing event data.
|
|
4175
4220
|
* @param dontBroadcast A boolean indicating whether to disable broadcasting.
|
|
4176
4221
|
*/
|
|
4177
|
-
export function SetEventBroadcast(
|
|
4222
|
+
export function SetEventBroadcast(info: number, dontBroadcast: boolean): void;
|
|
4178
4223
|
|
|
4179
4224
|
/**
|
|
4180
4225
|
* @description Load game event descriptions from a file (e.g., "resource/gameevents.res").
|
|
@@ -4466,6 +4511,80 @@ declare module ":s2sdk" {
|
|
|
4466
4511
|
*/
|
|
4467
4512
|
export function LogFullColored(channelID: number, severity: LoggingSeverity, file: string, line: number, callback: string, color: number, message: string): number;
|
|
4468
4513
|
|
|
4514
|
+
/**
|
|
4515
|
+
* @description Start a new Yes/No vote
|
|
4516
|
+
*
|
|
4517
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaSendYesNoVote|Docs}
|
|
4518
|
+
*
|
|
4519
|
+
* @param duration Maximum time to leave vote active for
|
|
4520
|
+
* @param caller Player slot of the vote caller. Use VOTE_CALLER_SERVER for 'Server'.
|
|
4521
|
+
* @param voteTitle Translation string to use as the vote message. (Only '#SFUI_vote' or '#Panorama_vote' strings)
|
|
4522
|
+
* @param detailStr Extra string used in some vote translation strings.
|
|
4523
|
+
* @param filter Recipient filter with all the clients who are allowed to participate in the vote.
|
|
4524
|
+
* @param result Called when a menu action is completed.
|
|
4525
|
+
* @param handler Called when the vote has finished.
|
|
4526
|
+
*/
|
|
4527
|
+
export function PanoramaSendYesNoVote(duration: number, caller: number, voteTitle: string, detailStr: string, filter: number, result: typeof Callbacks.YesNoVoteResult, handler: typeof Callbacks.YesNoVoteHandler): boolean;
|
|
4528
|
+
|
|
4529
|
+
/**
|
|
4530
|
+
* @description Start a new Yes/No vote with all players included
|
|
4531
|
+
*
|
|
4532
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaSendYesNoVoteToAll|Docs}
|
|
4533
|
+
*
|
|
4534
|
+
* @param duration Maximum time to leave vote active for
|
|
4535
|
+
* @param caller Player slot of the vote caller. Use VOTE_CALLER_SERVER for 'Server'.
|
|
4536
|
+
* @param voteTitle Translation string to use as the vote message. (Only '#SFUI_vote' or '#Panorama_vote' strings)
|
|
4537
|
+
* @param detailStr Extra string used in some vote translation strings.
|
|
4538
|
+
* @param result Called when a menu action is completed.
|
|
4539
|
+
* @param handler Called when the vote has finished.
|
|
4540
|
+
*/
|
|
4541
|
+
export function PanoramaSendYesNoVoteToAll(duration: number, caller: number, voteTitle: string, detailStr: string, result: typeof Callbacks.YesNoVoteResult, handler: typeof Callbacks.YesNoVoteHandler): boolean;
|
|
4542
|
+
|
|
4543
|
+
/**
|
|
4544
|
+
* @description Removes a player from the current vote.
|
|
4545
|
+
*
|
|
4546
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaRemovePlayerFromVote|Docs}
|
|
4547
|
+
*
|
|
4548
|
+
* @param playerSlot The slot/index of the player to remove from the vote.
|
|
4549
|
+
*/
|
|
4550
|
+
export function PanoramaRemovePlayerFromVote(playerSlot: number): void;
|
|
4551
|
+
|
|
4552
|
+
/**
|
|
4553
|
+
* @description Checks if a player is in the vote pool.
|
|
4554
|
+
*
|
|
4555
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaIsPlayerInVotePool|Docs}
|
|
4556
|
+
*
|
|
4557
|
+
* @param playerSlot The slot/index of the player to check.
|
|
4558
|
+
*/
|
|
4559
|
+
export function PanoramaIsPlayerInVotePool(playerSlot: number): boolean;
|
|
4560
|
+
|
|
4561
|
+
/**
|
|
4562
|
+
* @description Redraws the vote UI to a specific player client.
|
|
4563
|
+
*
|
|
4564
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaRedrawVoteToClient|Docs}
|
|
4565
|
+
*
|
|
4566
|
+
* @param playerSlot The slot/index of the player to update.
|
|
4567
|
+
*/
|
|
4568
|
+
export function PanoramaRedrawVoteToClient(playerSlot: number): boolean;
|
|
4569
|
+
|
|
4570
|
+
/**
|
|
4571
|
+
* @description Checks if a vote is currently in progress.
|
|
4572
|
+
*
|
|
4573
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaIsVoteInProgress|Docs}
|
|
4574
|
+
*
|
|
4575
|
+
*
|
|
4576
|
+
*/
|
|
4577
|
+
export function PanoramaIsVoteInProgress(): boolean;
|
|
4578
|
+
|
|
4579
|
+
/**
|
|
4580
|
+
* @description Ends the current vote with a specified reason.
|
|
4581
|
+
*
|
|
4582
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-PanoramaEndVote|Docs}
|
|
4583
|
+
*
|
|
4584
|
+
* @param reason The reason for ending the vote.
|
|
4585
|
+
*/
|
|
4586
|
+
export function PanoramaEndVote(reason: VoteEndReason): void;
|
|
4587
|
+
|
|
4469
4588
|
/**
|
|
4470
4589
|
* @description Get the offset of a member in a given schema class.
|
|
4471
4590
|
*
|
|
@@ -5545,6 +5664,24 @@ declare module ":s2sdk" {
|
|
|
5545
5664
|
*/
|
|
5546
5665
|
export function OnServerActivate_Unregister(callback: typeof Callbacks.OnServerActivateCallback): void;
|
|
5547
5666
|
|
|
5667
|
+
/**
|
|
5668
|
+
* @description Register callback to event.
|
|
5669
|
+
*
|
|
5670
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-OnChangeLevel_Register|Docs}
|
|
5671
|
+
*
|
|
5672
|
+
* @param callback Function callback.
|
|
5673
|
+
*/
|
|
5674
|
+
export function OnChangeLevel_Register(callback: typeof Callbacks.OnChangeLevelCallback): void;
|
|
5675
|
+
|
|
5676
|
+
/**
|
|
5677
|
+
* @description Unregister callback to event.
|
|
5678
|
+
*
|
|
5679
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-OnChangeLevel_Unregister|Docs}
|
|
5680
|
+
*
|
|
5681
|
+
* @param callback Function callback.
|
|
5682
|
+
*/
|
|
5683
|
+
export function OnChangeLevel_Unregister(callback: typeof Callbacks.OnChangeLevelCallback): void;
|
|
5684
|
+
|
|
5548
5685
|
/**
|
|
5549
5686
|
* @description Register callback to event.
|
|
5550
5687
|
*
|
|
@@ -5599,6 +5736,15 @@ declare module ":s2sdk" {
|
|
|
5599
5736
|
*/
|
|
5600
5737
|
export function OnPreWorldUpdate_Unregister(callback: typeof Callbacks.OnPreWorldUpdateCallback): void;
|
|
5601
5738
|
|
|
5739
|
+
/**
|
|
5740
|
+
* @description Retrieves the pointer to the current game rules proxy instance.
|
|
5741
|
+
*
|
|
5742
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetGameRulesProxy|Docs}
|
|
5743
|
+
*
|
|
5744
|
+
*
|
|
5745
|
+
*/
|
|
5746
|
+
export function GetGameRulesProxy(): number;
|
|
5747
|
+
|
|
5602
5748
|
/**
|
|
5603
5749
|
* @description Retrieves the pointer to the current game rules instance.
|
|
5604
5750
|
*
|
|
@@ -6719,6 +6865,15 @@ declare module ":s2sdk" {
|
|
|
6719
6865
|
*/
|
|
6720
6866
|
export function PbAddQAngle(userMessage: number, fieldName: string, value: vec3): boolean;
|
|
6721
6867
|
|
|
6868
|
+
/**
|
|
6869
|
+
* @description Retrieves the weapon VData for a given weapon name.
|
|
6870
|
+
*
|
|
6871
|
+
* {@link https://untrustedmodders.github.io/plugify-generator/?file=https://github.com/untrustedmodders/plugify-source-2/blob/main/s2sdk.pplugin.in#item-GetWeaponVDataFromKey|Docs}
|
|
6872
|
+
*
|
|
6873
|
+
* @param name The name of the weapon.
|
|
6874
|
+
*/
|
|
6875
|
+
export function GetWeaponVDataFromKey(name: string): number;
|
|
6876
|
+
|
|
6722
6877
|
/**
|
|
6723
6878
|
* @description Retrieves the weapon VData for a given weapon.
|
|
6724
6879
|
*
|